From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Dumazet Subject: Re: [Patch net-next v3 1/3] net: introduce helper dev_change_tx_queue_len() Date: Wed, 27 Jun 2018 09:14:40 -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 Content-Transfer-Encoding: 7bit Cc: john.fastabend@gmail.com To: Cong Wang , netdev@vger.kernel.org Return-path: Received: from mail-pf0-f196.google.com ([209.85.192.196]:36486 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965344AbeF0QOm (ORCPT ); Wed, 27 Jun 2018 12:14:42 -0400 Received: by mail-pf0-f196.google.com with SMTP id u16-v6so1196342pfh.3 for ; Wed, 27 Jun 2018 09:14:42 -0700 (PDT) In-Reply-To: <20180126022624.20442-2-xiyou.wangcong@gmail.com> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: 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. Thanks !