Ok, understand
> -Original Message-
> From: Johannes Berg [mailto:johan...@sipsolutions.net]
> Sent: Thursday, June 15, 2017 3:45 PM
> To: YUAN Linyu; netdev@vger.kernel.org
> Subject: Re: [RFC] networking: convert many more places to skb_put_zero()
>
> On Thu, 2017
On Thu, 2017-06-15 at 07:20 +, YUAN Linyu wrote:
> >
> In my opinion if spatch can do it even it found one place, keep it.
> Only leave difficult places like ndisc.c to me.
It's not so simple - I'd have to tailor the spatch to it pretty much I
guess, spending far more time on the spatch than
> -Original Message-
> From: Johannes Berg [mailto:johan...@sipsolutions.net]
> Sent: Thursday, June 15, 2017 3:12 PM
> To: YUAN Linyu; netdev@vger.kernel.org
> Subject: Re: [RFC] networking: convert many more places to skb_put_zero()
>
> On Thu, 2017-06-15 at 07
On Thu, 2017-06-15 at 07:05 +, YUAN Linyu wrote:
> > @@
> > type t;
> > expression skb, len;
> > identifier p;
> > @@
> > t *p
> > - = skb_put(skb, len);
> > + = skb_put_zero(skb, len);
> > -memset(p, 0, len);
> >
> > and it can't figure out that it should remove the variable, without
> > much
> -Original Message-
> From: Johannes Berg [mailto:johan...@sipsolutions.net]
> Sent: Thursday, June 15, 2017 2:58 PM
> To: YUAN Linyu; netdev@vger.kernel.org
> Subject: Re: [RFC] networking: convert many more places to skb_put_zero()
>
> On Thu, 2017-06-15 at 00
On Thu, 2017-06-15 at 00:23 +, YUAN Linyu wrote:
> Hi,
> Indeed, it find more.
> Compare with my patch, still lost pattern like below,
> 1. sctp and openvswitch
> --- a/net/sctp/output.c
> +++ b/net/sctp/output.c
> @@ -463,7 +463,7 @@ static int sctp_packet_pack(struct sctp_packet
> *packet,
>
disc.c once spatch done.
> -Original Message-
> From: netdev-ow...@vger.kernel.org [mailto:netdev-ow...@vger.kernel.org]
> On Behalf Of Johannes Berg
> Sent: Thursday, June 15, 2017 4:18 AM
> To: netdev@vger.kernel.org
> Cc: Johannes Berg
> Subject: [RFC] networking: c
From: Johannes Berg
There were many places that my previous spatch didn't find,
as pointed out by yuan linyu in various patches.
The following spatch found many more and also removes the
now unnecessary casts:
@@
identifier p, p2;
expression len;
expression skb;
type t, t2;