netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ted Chen <znscnchen@gmail.com>
To: Nikolay Aleksandrov <razor@blackwall.org>
Cc: roopa@nvidia.com, bridge@lists.linux.dev, netdev@vger.kernel.org
Subject: Re: [PATCH] bridge: Make br_is_nd_neigh_msg() accept pointer to "const struct sk_buff"
Date: Sat, 4 Jan 2025 16:46:06 +0800	[thread overview]
Message-ID: <Z3j1Tp428cuIHUzs@ted-dallas> (raw)
In-Reply-To: <e7a27b5f-a4fc-4eaa-b215-d7a1bb7fc234@blackwall.org>

On Fri, Jan 03, 2025 at 11:59:45AM +0200, Nikolay Aleksandrov wrote:
> On 1/3/25 09:09, Ted Chen wrote:
> > The skb_buff struct in br_is_nd_neigh_msg() is never modified. Mark it as const.
> > 
> > Signed-off-by: Ted Chen <znscnchen@gmail.com>
> > ---
> >  net/bridge/br_arp_nd_proxy.c | 2 +-
> >  net/bridge/br_private.h      | 2 +-
> >  2 files changed, 2 insertions(+), 2 deletions(-)
> > 
> > diff --git a/net/bridge/br_arp_nd_proxy.c b/net/bridge/br_arp_nd_proxy.c
> > index c7869a286df4..115a23054a58 100644
> > --- a/net/bridge/br_arp_nd_proxy.c
> > +++ b/net/bridge/br_arp_nd_proxy.c
> > @@ -229,7 +229,7 @@ void br_do_proxy_suppress_arp(struct sk_buff *skb, struct net_bridge *br,
> >  #endif
> >  
> >  #if IS_ENABLED(CONFIG_IPV6)
> > -struct nd_msg *br_is_nd_neigh_msg(struct sk_buff *skb, struct nd_msg *msg)
> > +struct nd_msg *br_is_nd_neigh_msg(const struct sk_buff *skb, struct nd_msg *msg)
> >  {
> >  	struct nd_msg *m;
> >  
> > diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
> > index 9853cfbb9d14..3fe432babfdf 100644
> > --- a/net/bridge/br_private.h
> > +++ b/net/bridge/br_private.h
> > @@ -2290,6 +2290,6 @@ void br_do_proxy_suppress_arp(struct sk_buff *skb, struct net_bridge *br,
> >  			      u16 vid, struct net_bridge_port *p);
> >  void br_do_suppress_nd(struct sk_buff *skb, struct net_bridge *br,
> >  		       u16 vid, struct net_bridge_port *p, struct nd_msg *msg);
> > -struct nd_msg *br_is_nd_neigh_msg(struct sk_buff *skb, struct nd_msg *m);
> > +struct nd_msg *br_is_nd_neigh_msg(const struct sk_buff *skb, struct nd_msg *m);
> >  bool br_is_neigh_suppress_enabled(const struct net_bridge_port *p, u16 vid);
> >  #endif
> 
> Hi,
> This should be targeted at net-next (subject should be PATCH net-next).
> Also please try to keep commit message lines shorter, checkpatch flags
> this one as over 75 characters. You should wait 24 hours before posting
> v2 of the patch.
> 
> Other than that the patch is ok.
> 
Thank you for your kindly guidance!
v2 is at: https://lore.kernel.org/all/20250104083846.71612-1-znscnchen@gmail.com

Ted

      reply	other threads:[~2025-01-04  8:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-03  7:09 [PATCH] bridge: Make br_is_nd_neigh_msg() accept pointer to "const struct sk_buff" Ted Chen
2025-01-03  9:59 ` Nikolay Aleksandrov
2025-01-04  8:46   ` Ted Chen [this message]

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=Z3j1Tp428cuIHUzs@ted-dallas \
    --to=znscnchen@gmail.com \
    --cc=bridge@lists.linux.dev \
    --cc=netdev@vger.kernel.org \
    --cc=razor@blackwall.org \
    --cc=roopa@nvidia.com \
    /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;
as well as URLs for NNTP newsgroup(s).