devtools: do not complain when reordering symbols
PATCH 1/4 devtools: do not complain when reordering symbols
No need to shout when we are just reordering symbols in a section.
--- devtools/check-symbol-change.sh | 6 ++++++ 1 file changed, 6 insertions(+)
devtools/check-symbol-change.sh +6 -0
@@ -121,6 +121,12 @@ check_for_rule_violations() continue fi + # This symbol is moving inside a section, nothing to do + if [ "$oldsecname" = "$secname" ] + then + continue + fi + # This symbol is moving between two sections (the # original section is not experimental). # This can be legit, just warn.
Signature · 1 line
1.8.3.1
PATCH 2/4 devtools: handle section suppression
Even if rare, the check script should handle removing a section.
--- devtools/check-symbol-change.sh | 1 + 1 file changed, 1 insertion(+)
devtools/check-symbol-change.sh +1 -0
@@ -32,6 +32,7 @@ build_map_changes() # symbol rule below /^.*{/ { gsub("+", ""); + gsub("-", ""); if (in_map == 1) { sec=$(NF-1); in_sec=1; }
Signature · 1 line
1.8.3.1
Re: [dpdk-dev] [PATCH 2/4] devtools: handle section suppression
Quoted 26 lines · David Marchand
Even if rare, the check script should handle removing a section.
Fixes 4bec48184e33 ("devtools: add checks for ABI symbol addition")Signed-off-by David Marchand <[email protected]>--- devtools/check-symbol-change.sh | 1 + 1 file changed, 1 insertion(+)devtools/check-symbol-change.sh +1
-0@@ -32,6 +32,7 @@ build_map_changes() # symbol rule below /^.*{/ { gsub("+", ""); + gsub("-", ""); if (in_map == 1) { sec=$(NF-1); in_sec=1; }Signature · 1 line
1.8.3.1
Don't you also need to add some logic in the symbol detection match rule to print an appropriate indicator that a symbol is being removed? With just this change, you will note that you are parsing a section, but you will never trigger a symbol match
Neil
Re: [dpdk-dev] [PATCH 2/4] devtools: handle section suppression
Quoted 26 lines · Neil Horman
Review
Quoted 11 lines · David Marchand
Even if rare, the check script should handle removing a section.
Fixes 4bec48184e33 ("devtools: add checks for ABI symbol addition")Signed-off-by David Marchand <[email protected]>--- devtools/check-symbol-change.sh | 1 + 1 file changed, 1 insertion(+)(quoted diff) +0
-0
b/devtools/check-symbol-change.shQuoted 13 lines
index 8da7650..d5fad04 100755
devtools/check-symbol-change.sh +1
-1@@ -32,6 +32,7 @@ build_map_changes() # symbol rule below /^.*{/ { gsub("+", ""); + gsub("-", ""); if (in_map == 1) { sec=$(NF-1); in_sec=1; } --1.8.3.1
Quoted 9 lines
Quoted 2 lines
Don't you also need to add some logic in the symbol detection match rule to print an appropriate indicator that a symbol is being removed? With just this
change, you will note that you are parsing a section, but you will never trigger
a symbol match
I do remember seeing a warning about the "-EXPERIMENTAL" section. And this is why I added this.
But since then I reorganised my series and eliminated some parts... so you are most likely right.
I will double check and repost.
Signature · 1 line
David Marchand
Re: [dpdk-dev] [PATCH 2/4] devtools: handle section suppression
Quoted 39 lines · David Marchand
Quoted 27 lines · Neil Horman
Review
Quoted 11 lines · David Marchand
Even if rare, the check script should handle removing a section.
Fixes 4bec48184e33 ("devtools: add checks for ABI symbol addition")Signed-off-by David Marchand <[email protected]>--- devtools/check-symbol-change.sh | 1 + 1 file changed, 1 insertion(+)(quoted diff) +0
-0
b/devtools/check-symbol-change.shQuoted 14 lines
index 8da7650..d5fad04 100755
devtools/check-symbol-change.sh +1
-1@@ -32,6 +32,7 @@ build_map_changes() # symbol rule below /^.*{/ { gsub("+", ""); + gsub("-", ""); if (in_map == 1) { sec=$(NF-1); in_sec=1; } --1.8.3.1
Quoted 9 lines
Quoted 1 line
Don't you also need to add some logic in the symbol detection match rule to
print an appropriate indicator that a symbol is being removed? With just this
change, you will note that you are parsing a section, but you will never trigger
a symbol match
Quoted 7 lines
I do remember seeing a warning about the "
-EXPERIMENTAL" section. And this is why I added this.
But since then I reorganised my series and eliminated some parts... so you are most likely right.
I will double check and repost.
Yes, you are right, I moved this out of another patch that I ended up not sending.
But it makes no sense by itself.
I will drop this in v2.
Any comments on the other patches ?
Thanks Neil.
Signature · 1 line
David Marchand
Re: [dpdk-dev] [PATCH 2/4] devtools: handle section suppression
Quoted 49 lines · David Marchand
Quoted 39 lines · David Marchand
Quoted 27 lines · Neil Horman
Review
Quoted 11 lines · David Marchand
Even if rare, the check script should handle removing a section.
Fixes 4bec48184e33 ("devtools: add checks for ABI symbol addition")Signed-off-by David Marchand <[email protected]>--- devtools/check-symbol-change.sh | 1 + 1 file changed, 1 insertion(+)(quoted diff) +0
-0
b/devtools/check-symbol-change.shQuoted 14 lines
index 8da7650..d5fad04 100755
devtools/check-symbol-change.sh +1
-1@@ -32,6 +32,7 @@ build_map_changes() # symbol rule below /^.*{/ { gsub("+", ""); + gsub("-", ""); if (in_map == 1) { sec=$(NF-1); in_sec=1; } --1.8.3.1
Quoted 9 lines
Quoted 1 line
Don't you also need to add some logic in the symbol detection match rule to
print an appropriate indicator that a symbol is being removed? With just this
change, you will note that you are parsing a section, but you will never trigger
a symbol matchQuoted 7 lines
I do remember seeing a warning about the "
-EXPERIMENTAL" section. And this is why I added this.
But since then I reorganised my series and eliminated some parts... so you are most likely right.
I will double check and repost.
Quoted 8 lines
Yes, you are right, I moved this out of another patch that I ended up not sending.
But it makes no sense by itself.
I will drop this in v2.Any comments on the other patches ?
Thanks Neil.
No, I don't think I do, thanks for checking though! Neil
Quoted 3 lines
Signature · 2 lines
-- David Marchand
PATCH 3/4 devtools: fix symbol name in log message
In reply to David MarchandWe have an incorrect variable name in this log.
--- devtools/check-symbol-change.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/check-symbol-change.sh +1 -1
@@ -98,7 +98,7 @@ check_for_rule_violations() then # Just inform the user of this occurrence, but # don't flag it as an error - echo -n "INFO: symbol $syname is added but " + echo -n "INFO: symbol $symname is added but " echo -n "patch has insuficient context " echo -n "to determine the section name " echo -n "please ensure the version is "
Signature · 1 line
1.8.3.1
PATCH 4/4 devtools: fix direct additions to stable API
In reply to David MarchandThe incriminated commit broke the detection of new symbols skipping the EXPERIMENTAL step before entering a stable abi section.
sed won't return an error, check a null output instead.
--- devtools/check-symbol-change.sh | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-)
devtools/check-symbol-change.sh +17 -8
@@ -111,15 +111,24 @@ check_for_rule_violations() # A symbol can not enter a non experimental # section directly - if [ $? -ne 0 ] && [ "$secname" != 'EXPERIMENTAL' ] + if [ -z "$oldsecname" ] then - echo -n "ERROR: symbol $symname " - echo -n "is added in the $secname " - echo -n "section, but is expected to " - echo -n "be added in the EXPERIMENTAL " - echo "section of the version map" - ret=1 - continue + if [ "$secname" = 'EXPERIMENTAL' ] + then + echo -n "INFO: symbol $symname has " + echo -n "been added to the " + echo -n "EXPERIMENTAL section of the " + echo "version map" + continue + else + echo -n "ERROR: symbol $symname " + echo -n "is added in the $secname " + echo -n "section, but is expected to " + echo -n "be added in the EXPERIMENTAL " + echo "section of the version map" + ret=1 + continue + fi fi # This symbol is moving inside a section, nothing to do
Signature · 1 line
1.8.3.1
Re: [dpdk-dev] [dpdk-stable] [PATCH 4/4] devtools: fix direct additions to stable API
03/05/2019 16:34, David Marchand:
Quoted 8 lines
The incriminated commit broke the detection of new symbols skipping the EXPERIMENTAL step before entering a stable abi section.
sed won't return an error, check a null output instead.Fixes 3630757803ab ("devtools: accept experimental symbol promotion")Signed-off-by David Marchand <[email protected]>
Series applied (without patch 2), thanks
Hi David,
Do you have this script wired into the DPDK CI?
Or is this purely for testing before packaging?
Ray K
Quoted 25 lines · David Marchand
No need to shout when we are just reordering symbols in a section.
Signed-off-by David Marchand <[email protected]>--- devtools/check-symbol-change.sh | 6 ++++++ 1 file changed, 6 insertions(+)devtools/check-symbol-change.sh +6
-0@@ -121,6 +121,12 @@ check_for_rule_violations() continue fi + # This symbol is moving inside a section, nothing to do + if [ "$oldsecname" = "$secname" ] + then + continue + fi + # This symbol is moving between two sections (the # original section is not experimental). # This can be legit, just warn.
Hello Ray,
Quoted 3 lines · Ray Kinsella
Do you have this script wired into the DPDK CI?
Or is this purely for testing before packaging?
Iirc, Thomas has this script running on the server side.
See for example the report for this very patch on the dpdk-test ml:
http://mails.dpdk.org/archives/test-report/2019-May/081948.html
Which is seen in patchwork as:
http://patchwork.dpdk.org/patch/53255/
"ci/checkpatch success coding style OK"
Signature · 1 line
David Marchand