DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] devtools: fix check symbol change script
@ 2020-03-19 14:44 Nithin Dabilpuram
  2020-03-19 14:56 ` David Marchand
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Nithin Dabilpuram @ 2020-03-19 14:44 UTC (permalink / raw)
  To: thomas, david.marchand, Neil Horman
  Cc: dev, jerinj, Nithin Dabilpuram, stable

Fix check symbol change script to detect new diff file when
it is in between  "--- /dev/null" to "b/lib/...".
Current awk line expects line to start with "a/..."
which is not always true for all diffs.
As a result if in_map was '1' earlier, it will not be changed
to '0' and we get check patch errors which are not true as the non
version.map files get interpreted as version map file.

Fixes: 4bec48184e33 ("devtools: add checks for ABI symbol addition")
Cc: nhorman@tuxdriver.com
Cc: stable@dpdk.org

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
---
Note: We have two examples where checkpatch errors are because of this
because the version.map file change comes earlier in the diff. Because of 
this bug, any new file change that comes after version.map file diff
as "/dev/null" to "b/.." gets misdetected as version.map file.
* http://patches.dpdk.org/patch/66878/
* https://patchwork.dpdk.org/patch/66900/
 devtools/check-symbol-change.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/devtools/check-symbol-change.sh b/devtools/check-symbol-change.sh
index c5434f3..19ce82f 100755
--- a/devtools/check-symbol-change.sh
+++ b/devtools/check-symbol-change.sh
@@ -17,13 +17,13 @@ build_map_changes()
 		# map files are altered, and all section/symbol names
 		# appearing between a triggering of this rule and the
 		# next trigger of this rule are associated with this file
-		/[-+] a\/.*\.map/ {map=$2; in_map=1}
+		/[-+] [ab]\/.*\.map/ {map=$2; in_map=1}
 
 		# Same pattern as above, only it matches on anything that
 		# does not end in 'map', indicating we have left the map chunk.
 		# When we hit this, turn off the in_map variable, which
 		# supresses the subordonate rules below
-		/[-+] a\/.*\.[^map]/ {in_map=0}
+		/[-+] [ab]\/.*\.[^map]/ {in_map=0}
 
 		# Triggering this rule, which starts a line and ends it
 		# with a { identifies a versioned section.  The section name is
-- 
2.8.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2020-03-23 13:19 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-19 14:44 [dpdk-dev] [PATCH] devtools: fix check symbol change script Nithin Dabilpuram
2020-03-19 14:56 ` David Marchand
2020-03-19 15:40   ` Neil Horman
2020-03-19 15:45     ` [dpdk-dev] [EXT] " Nithin Dabilpuram
2020-03-19 18:59       ` Neil Horman
2020-03-19 15:49     ` [dpdk-dev] " Bing Zhao
2020-03-22 14:37 ` Jerin Jacob
2020-03-23  8:13 ` David Marchand
2020-03-23  9:28   ` [dpdk-dev] [EXT] " Nithin Dabilpuram
2020-03-23  9:30     ` [dpdk-dev] [dpdk-stable] " David Marchand
2020-03-23 11:56 ` [dpdk-dev] [PATCH v2] " Nithin Dabilpuram
2020-03-23 13:19   ` David Marchand

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).