Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752117AbdDFT4G (ORCPT ); Thu, 6 Apr 2017 15:56:06 -0400 Received: from shards.monkeyblade.net ([184.105.139.130]:37248 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751608AbdDFTz5 (ORCPT ); Thu, 6 Apr 2017 15:55:57 -0400 Date: Thu, 06 Apr 2017 12:55:55 -0700 (PDT) Message-Id: <20170406.125555.1576050282465956628.davem@davemloft.net> To: tobias.regnery@gmail.com Cc: saeedm@mellanox.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next] net/mlx5e: fix build error without CONFIG_SYSFS From: David Miller In-Reply-To: <20170405091110.711-1-tobias.regnery@gmail.com> References: <20170405091110.711-1-tobias.regnery@gmail.com> X-Mailer: Mew version 6.7 on Emacs 25.1 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 06 Apr 2017 12:14:39 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1005 Lines: 21 From: Tobias Regnery Date: Wed, 5 Apr 2017 11:11:10 +0200 > Commit 9008ae074885 ("net/mlx5e: Minimize mlx5e_{open/close}_locked") > copied the calls to netif_set_real_num_{tx,rx}_queues from > mlx5e_open_locked to mlx5e_activate_priv_channels and wraps them in an > if condition to test for netdev->real_num_{tx,rx}_queues. > > But netdev->real_num_rx_queues is conditionally compiled in if CONFIG_SYSFS > is set. Without CONFIG_SYSFS the build fails: > > drivers/net/ethernet/mellanox/mlx5/core/en_main.c: In function 'mlx5e_activate_priv_channels': > drivers/net/ethernet/mellanox/mlx5/core/en_main.c:2515:12: error: 'struct net_device' has no member named 'real_num_rx_queues'; did you mean 'real_num_tx_queues'? > > Fix this by unconditionally call netif_set_real_num{tx,rx}_queues like before > commit 9008ae074885. > > Fixes: 9008ae074885 ("net/mlx5e: Minimize mlx5e_{open/close}_locked") > Signed-off-by: Tobias Regnery Applied, thanks.