From: Jakub Kicinski <kuba@kernel.org>
To: David Ahern <dsahern@gmail.com>
Cc: cgel.zte@gmail.com, davem@davemloft.net, yoshfuji@linux-ipv6.org,
dsahern@kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org,
Minghao Chi <chi.minghao@zte.com.cn>,
Zeal Robot <zealci@zte.com.cn>
Subject: Re: [PATCH] net/ipv6: remove redundant err variable
Date: Wed, 12 Jan 2022 08:39:42 -0800 [thread overview]
Message-ID: <20220112083942.391fd0d7@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net> (raw)
In-Reply-To: <33308db2-a583-165c-cae0-b055c7976f33@gmail.com>
On Wed, 12 Jan 2022 08:54:41 -0700 David Ahern wrote:
> On 1/12/22 1:26 AM, cgel.zte@gmail.com wrote:
> > diff --git a/net/ipv6/ip6_tunnel.c b/net/ipv6/ip6_tunnel.c
> > index fe786df4f849..897194eb3b89 100644
> > --- a/net/ipv6/ip6_tunnel.c
> > +++ b/net/ipv6/ip6_tunnel.c
> > @@ -698,13 +698,12 @@ mplsip6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
> > u8 type, u8 code, int offset, __be32 info)
> > {
> > __u32 rel_info = ntohl(info);
> > - int err, rel_msg = 0;
> > + int rel_msg = 0;
>
> this line needs to be moved down to maintain reverse xmas tree ordering.
>
> You need to make the subject
> '[PATCH net-next] net/ipv6: remove redundant err variable'
>
> and since net-next is closed you will need to resubmit when it is open.
Frankly I'm not sure these type of patches make sense.
Minghao how many instances of this pattern are there in the tree today?
What tools can we use to ensure the pattern does not get added back in
new patches?
> > u8 rel_type = type;
> > u8 rel_code = code;
> >
> > - err = ip6_tnl_err(skb, IPPROTO_MPLS, opt, &rel_type, &rel_code,
> > + return ip6_tnl_err(skb, IPPROTO_MPLS, opt, &rel_type, &rel_code,
> > &rel_msg, &rel_info, offset);
You should re-align continuation lines when you move the opening
bracket.
> > - return err;
> > }
next prev parent reply other threads:[~2022-01-12 16:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-12 8:26 cgel.zte
2022-01-12 15:54 ` David Ahern
2022-01-12 16:39 ` Jakub Kicinski [this message]
2022-01-19 3:00 ` cgel.zte
2022-01-19 3:28 ` Jakub Kicinski
2022-01-19 5:55 ` cgel.zte
2022-01-19 15:59 ` Jakub Kicinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220112083942.391fd0d7@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net \
--to=kuba@kernel.org \
--cc=cgel.zte@gmail.com \
--cc=chi.minghao@zte.com.cn \
--cc=davem@davemloft.net \
--cc=dsahern@gmail.com \
--cc=dsahern@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=yoshfuji@linux-ipv6.org \
--cc=zealci@zte.com.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®