netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: zhangqilong <zhangqilong3@huawei.com>
To: Joe Perches <joe@perches.com>, Vasily Averin <vvs@virtuozzo.com>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"kuba@kernel.org" <kuba@kernel.org>
Cc: "lirongqing@baidu.com" <lirongqing@baidu.com>,
	"roopa@cumulusnetworks.com" <roopa@cumulusnetworks.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: 答复: [PATCH -next] neigh: remove the extra slash
Date: Mon, 26 Oct 2020 02:20:53 +0000	[thread overview]
Message-ID: <f1bce5f03476409fa78920bddf4b4c06@huawei.com> (raw)
In-Reply-To: <a9bc6a8898116bc017152136265a523d5097da84.camel@perches.com>

> On Fri, 2020-10-23 at 13:16 +0300, Vasily Averin wrote:
> > On 10/23/20 1:01 PM, Zhang Qilong wrote:
> > > The normal path has only one slash.
> >
> > it is not normal path
> > this string is used to calculate number of symbols in
> > "net/%s/neigh/%s" used below
> 
> Then probably better would be to add +1 rather than use a rather odd filename.

Hi, Joe
	I use the splicing method to rewrite it in patch V2 [0001-neigh-Adjustment-calculation-method-of-neighbour-pat.patch], I think it will be clearer. Looking forward to your reply.
Thanks, best wish to you.
Zhang Qilong

> 
> > > diff --git a/net/core/neighbour.c b/net/core/neighbour.c
> []
> > > @@ -3623,7 +3623,7 @@ int neigh_sysctl_register(struct net_device *dev,
> struct neigh_parms *p,
> > >  	int i;
> > >  	struct neigh_sysctl_table *t;
> > >  	const char *dev_name_source;
> > > -	char neigh_path[ sizeof("net//neigh/") + IFNAMSIZ + IFNAMSIZ ];
> > > +	char neigh_path[sizeof("net/neigh/") + IFNAMSIZ + IFNAMSIZ];
> > >  	char *p_name;
> > >
> > >
> > >  	t = kmemdup(&neigh_sysctl_template, sizeof(*t), GFP_KERNEL);
> > >
> 


      reply	other threads:[~2020-10-26  2:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-23 10:01 [PATCH -next] neigh: remove the extra slash Zhang Qilong
2020-10-23 10:16 ` Vasily Averin
2020-10-25  2:27   ` Joe Perches
2020-10-26  2:20     ` zhangqilong [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=f1bce5f03476409fa78920bddf4b4c06@huawei.com \
    --to=zhangqilong3@huawei.com \
    --cc=davem@davemloft.net \
    --cc=joe@perches.com \
    --cc=kuba@kernel.org \
    --cc=lirongqing@baidu.com \
    --cc=netdev@vger.kernel.org \
    --cc=roopa@cumulusnetworks.com \
    --cc=vvs@virtuozzo.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).