From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752946AbcIHApC (ORCPT ); Wed, 7 Sep 2016 20:45:02 -0400 Received: from shards.monkeyblade.net ([184.105.139.130]:50562 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751302AbcIHAoz (ORCPT ); Wed, 7 Sep 2016 20:44:55 -0400 Date: Wed, 07 Sep 2016 17:44:54 -0700 (PDT) Message-Id: <20160907.174454.2155488832420477020.davem@davemloft.net> To: Yuval.Mintz@qlogic.com Cc: baoyou.xie@linaro.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, arnd@arndb.de, xie.baoyou@zte.com.cn, Ariel.Elior@qlogic.com Subject: Re: [PATCH] qed: mark symbols static where possible From: David Miller In-Reply-To: References: <1473247341-1244-1-git-send-email-baoyou.xie@linaro.org> X-Mailer: Mew version 6.7 on Emacs 24.5 / 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]); Wed, 07 Sep 2016 17:44:55 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Yuval Mintz Date: Wed, 7 Sep 2016 11:55:34 +0000 >> We get a few warnings when building kernel with W=1: >> drivers/net/ethernet/qlogic/qed/qed_l2.c:112:5: warning: no previous >> prototype for 'qed_sp_vport_start' [-Wmissing-prototypes] >> .... >> >> In fact, these functions are only used in the file in which they are >> declared and don't need a declaration, but can be made static. >> so this patch marks these functions with 'static'. >> >> Signed-off-by: Baoyou Xie > > Most of this changes are correct. I have 2 reservations, though: > > 1. qed_get_vport_stats() is in use in net-next by qed_main.c starting with > 6c75424612a7 ("qed: Add support for NCSI statistics."), so we shouldn't > make it static. > [This raises the question of which repository was this patch built against?] > > 2. Regarding the changes in qed_cxt.c - some of the functions you're turning > into static are going to be used be other files in our pending RoCE driver > submissions [you could say those ARE really missing their prototypes]. > I don't have a real objection to this change - I'm just stating that if you'll > change those now to static, we'll probably 'revert' the change in the near > future. Baoyou, please respin this against net-next, thanks.