[2/4] devtools: handle section suppression

Message ID 1556894060-13573-2-git-send-email-david.marchand@redhat.com (mailing list archive)
State Rejected, archived
Delegated to: Thomas Monjalon
Headers
Series [1/4] devtools: do not complain when reordering symbols |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

David Marchand May 3, 2019, 2:34 p.m. UTC
  Even if rare, the check script should handle removing a section.

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

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 devtools/check-symbol-change.sh | 1 +
 1 file changed, 1 insertion(+)
  

Comments

Neil Horman May 3, 2019, 3:03 p.m. UTC | #1
On Fri, May 03, 2019 at 04:34:18PM +0200, David Marchand wrote:
> Even if rare, the check script should handle removing a section.
> 
> Fixes: 4bec48184e33 ("devtools: add checks for ABI symbol addition")
> Cc: stable@dpdk.org
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
>  devtools/check-symbol-change.sh | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/devtools/check-symbol-change.sh b/devtools/check-symbol-change.sh
> index 8da7650..d5fad04 100755
> --- a/devtools/check-symbol-change.sh
> +++ b/devtools/check-symbol-change.sh
> @@ -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
> 
> 
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
  
David Marchand May 3, 2019, 5:16 p.m. UTC | #2
On Fri, May 3, 2019 at 5:18 PM Neil Horman <nhorman@tuxdriver.com> wrote:

> On Fri, May 03, 2019 at 04:34:18PM +0200, David Marchand wrote:
> > Even if rare, the check script should handle removing a section.
> >
> > Fixes: 4bec48184e33 ("devtools: add checks for ABI symbol addition")
> > Cc: stable@dpdk.org
> >
> > Signed-off-by: David Marchand <david.marchand@redhat.com>
> > ---
> >  devtools/check-symbol-change.sh | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/devtools/check-symbol-change.sh
> b/devtools/check-symbol-change.sh
> > index 8da7650..d5fad04 100755
> > --- a/devtools/check-symbol-change.sh
> > +++ b/devtools/check-symbol-change.sh
> > @@ -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
> >
> >
> 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.
  
David Marchand May 6, 2019, 12:56 p.m. UTC | #3
On Fri, May 3, 2019 at 7:16 PM David Marchand <david.marchand@redhat.com>
wrote:

> On Fri, May 3, 2019 at 5:18 PM Neil Horman <nhorman@tuxdriver.com> wrote:
>
>> On Fri, May 03, 2019 at 04:34:18PM +0200, David Marchand wrote:
>> > Even if rare, the check script should handle removing a section.
>> >
>> > Fixes: 4bec48184e33 ("devtools: add checks for ABI symbol addition")
>> > Cc: stable@dpdk.org
>> >
>> > Signed-off-by: David Marchand <david.marchand@redhat.com>
>> > ---
>> >  devtools/check-symbol-change.sh | 1 +
>> >  1 file changed, 1 insertion(+)
>> >
>> > diff --git a/devtools/check-symbol-change.sh
>> b/devtools/check-symbol-change.sh
>> > index 8da7650..d5fad04 100755
>> > --- a/devtools/check-symbol-change.sh
>> > +++ b/devtools/check-symbol-change.sh
>> > @@ -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
>> >
>> >
>> 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.
>
>
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.
  
Neil Horman May 6, 2019, 3:43 p.m. UTC | #4
On Mon, May 06, 2019 at 02:56:51PM +0200, David Marchand wrote:
> On Fri, May 3, 2019 at 7:16 PM David Marchand <david.marchand@redhat.com>
> wrote:
> 
> > On Fri, May 3, 2019 at 5:18 PM Neil Horman <nhorman@tuxdriver.com> wrote:
> >
> >> On Fri, May 03, 2019 at 04:34:18PM +0200, David Marchand wrote:
> >> > Even if rare, the check script should handle removing a section.
> >> >
> >> > Fixes: 4bec48184e33 ("devtools: add checks for ABI symbol addition")
> >> > Cc: stable@dpdk.org
> >> >
> >> > Signed-off-by: David Marchand <david.marchand@redhat.com>
> >> > ---
> >> >  devtools/check-symbol-change.sh | 1 +
> >> >  1 file changed, 1 insertion(+)
> >> >
> >> > diff --git a/devtools/check-symbol-change.sh
> >> b/devtools/check-symbol-change.sh
> >> > index 8da7650..d5fad04 100755
> >> > --- a/devtools/check-symbol-change.sh
> >> > +++ b/devtools/check-symbol-change.sh
> >> > @@ -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
> >> >
> >> >
> >> 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.
> >
> >
> 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

> 
> -- 
> David Marchand
  

Patch

diff --git a/devtools/check-symbol-change.sh b/devtools/check-symbol-change.sh
index 8da7650..d5fad04 100755
--- a/devtools/check-symbol-change.sh
+++ b/devtools/check-symbol-change.sh
@@ -32,6 +32,7 @@  build_map_changes()
 		# symbol rule below
 		/^.*{/ {
 			gsub("+", "");
+			gsub("-", "");
 			if (in_map == 1) {
 				sec=$(NF-1); in_sec=1;
 			}