From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-11.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D26B0C433E9 for ; Tue, 2 Feb 2021 18:57:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B087964F5D for ; Tue, 2 Feb 2021 18:57:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239115AbhBBS5c (ORCPT ); Tue, 2 Feb 2021 13:57:32 -0500 Received: from mail.kernel.org ([198.145.29.99]:41290 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238856AbhBBS4Q (ORCPT ); Tue, 2 Feb 2021 13:56:16 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 58C0064F66; Tue, 2 Feb 2021 18:55:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1612292136; bh=BjWZCFlqgjdNMZLVU5uAX8s9kz3EWVagnqa51rr2xCA=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=gbDEMsrNzRVJHy54V4CeoRSo7RDBd/5xx9QUX370/LxtHhOMIvJjsbHa0ZPKVUfki m8VzdOYard7X0Pl1+SQEqTvYUbYFtV593hqXl5k2HYXVswPcW2Gf05fsdTgTXdNta0 94ZORDd2MWSKbl8itx6SntzxLscatuq9yRpMIQHFZ0R8fcOq7SMZL4EF2ji/ikaeGJ Snnxog7I6+TI9Gs9niHYUwXTAVw7XPbxJMV2+nUPab6Ji//XFbnvtxkCTS24YvGOum vGuLCrFLsI/DDnhHoYs82M556L4ghubxHDUn1y3u//lS4j9q8kHMYXeCFoXa+2nkXB tgpXJVoS/u6mg== Date: Tue, 2 Feb 2021 20:55:28 +0200 From: Leon Romanovsky To: Jakub Kicinski Cc: "David S. Miller" , Pablo Neira Ayuso , coreteam@netfilter.org, Eric Dumazet , Florian Westphal , Hideaki YOSHIFUJI , Jozsef Kadlecsik , Julian Anastasov , linux-kernel@vger.kernel.org, lvs-devel@vger.kernel.org, Matteo Croce , netdev@vger.kernel.org, netfilter-devel@vger.kernel.org, Simon Horman Subject: Re: [PATCH net 1/4] ipv6: silence compilation warning for non-IPV6 builds Message-ID: <20210202185528.GE3264866@unreal> References: <20210202135544.3262383-1-leon@kernel.org> <20210202135544.3262383-2-leon@kernel.org> <20210202082909.7d8f479f@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210202082909.7d8f479f@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Tue, Feb 02, 2021 at 08:29:09AM -0800, Jakub Kicinski wrote: > On Tue, 2 Feb 2021 15:55:41 +0200 Leon Romanovsky wrote: > > From: Leon Romanovsky > > > > The W=1 compilation of allmodconfig generates the following warning: > > > > net/ipv6/icmp.c:448:6: warning: no previous prototype for 'icmp6_send' [-Wmissing-prototypes] > > 448 | void icmp6_send(struct sk_buff *skb, u8 type, u8 code, __u32 info, > > | ^~~~~~~~~~ > > > > In such configuration, the icmp6_send() is not used outside of icmp.c, so close > > its EXPORT_SYMBOL and add "static" word to limit the scope. > > > > Fixes: cc7a21b6fbd9 ("ipv6: icmp6: avoid indirect call for icmpv6_send()") > > Signed-off-by: Leon Romanovsky > > That's a little much ifdefinery, why not move the declaration from > under the ifdef in the header instead? We will find ourselves with exported but not used function, it will increase symbol file, not big deal but not nice, either. > > If you repost please target net-next, admittedly these fixes are pretty > "obviously correct" but they are not urgent either. I'll do. Thanks