From mboxrd@z Thu Jan 1 00:00:00 1970 From: Cong Wang Subject: Re: [Patch net-next v3 1/3] net: introduce helper dev_change_tx_queue_len() Date: Wed, 27 Jun 2018 10:41:09 -0700 Message-ID: References: <20180126022624.20442-1-xiyou.wangcong@gmail.com> <20180126022624.20442-2-xiyou.wangcong@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Cc: Linux Kernel Network Developers , John Fastabend To: Eric Dumazet Return-path: Received: from mail-pg0-f67.google.com ([74.125.83.67]:36691 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934337AbeF0RlW (ORCPT ); Wed, 27 Jun 2018 13:41:22 -0400 Received: by mail-pg0-f67.google.com with SMTP id m5-v6so1241304pgd.3 for ; Wed, 27 Jun 2018 10:41:22 -0700 (PDT) In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: On Wed, Jun 27, 2018 at 9:14 AM Eric Dumazet wrote: > > > > On 01/25/2018 06:26 PM, Cong Wang wrote: > > This patch promotes the local change_tx_queue_len() to a core > > helper function, dev_change_tx_queue_len(), so that rtnetlink > > and net-sysfs could share the code. This also prepares for the > > following patch. > > > > Note, the -EFAULT in the original code doesn't make sense, > > we should propagate the errno from notifiers. > > > > Cc: John Fastabend > > Signed-off-by: Cong Wang > > --- > > include/linux/netdevice.h | 1 + > > net/core/dev.c | 28 ++++++++++++++++++++++++++++ > > net/core/net-sysfs.c | 25 +------------------------ > > net/core/rtnetlink.c | 18 +++++------------- > > 4 files changed, 35 insertions(+), 37 deletions(-) > > > > Hi Cong > > What about using dev_change_tx_queue_len() helper from SIOCSIFTXQLEN path in > net/core/dev_ioctl.c ? > > This would make sure we call dev_qdisc_change_tx_queue_len() in this case. > Good catch! Will send a patch for net-next. Thanks.