From patchwork Sat Oct 5 20:26:59 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Estevam X-Patchwork-Id: 280799 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 4D1E72C00C1 for ; Sun, 6 Oct 2013 07:27:08 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752484Ab3JEU1D (ORCPT ); Sat, 5 Oct 2013 16:27:03 -0400 Received: from mail-we0-f178.google.com ([74.125.82.178]:42417 "EHLO mail-we0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752366Ab3JEU1B (ORCPT ); Sat, 5 Oct 2013 16:27:01 -0400 Received: by mail-we0-f178.google.com with SMTP id q59so5088185wes.37 for ; Sat, 05 Oct 2013 13:26:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=r1sg/8JvKcEGrcPimKS7yqjcgYsM49RkTOSlmWUaNJk=; b=Hoiqz42XEfz0/MwuxJ4V1OTSu7p4nL6Ih71XIb+gFRDt7lUndL7MgsB7rm19gmVuri BXBzhc6YJsvwaOVKtp+ijvIwjWrbTwwFNPjIjlAQYXkxqPw7uqviqRkc1T9mJqgrZVYY yOFO/tjqcRJRGEsgVce3lLsKz5w4E0nKU/pULZEV0e+otEgFY9YGYSzrTcCkX05mAXWC /HaSnfvc0XcBzGEeGf4s4hWaGAB30ptdjbuc401MHxh3PM5GlXQJuKheMWN5D5kZzXMM wnIvxx+XcxZitPGxDGfR9s8WAuzyckAXtA9Hl1bxQ9UmmIWW7EC5G7jN9twy0pBXVVYa Vsbw== MIME-Version: 1.0 X-Received: by 10.180.198.79 with SMTP id ja15mr12780927wic.36.1381004819561; Sat, 05 Oct 2013 13:26:59 -0700 (PDT) Received: by 10.217.1.146 with HTTP; Sat, 5 Oct 2013 13:26:59 -0700 (PDT) In-Reply-To: <1381003790-12731-1-git-send-email-festevam@gmail.com> References: <1381003790-12731-1-git-send-email-festevam@gmail.com> Date: Sat, 5 Oct 2013 17:26:59 -0300 Message-ID: Subject: Re: [PATCH] net: secure_seq: Move net_secret_init() definition into CONFIG_IPV6 if block From: Fabio Estevam To: "David S. Miller" Cc: edumazet , "netdev@vger.kernel.org" , Olof Johansson , Fabio Estevam , Hannes Frederic Sowa Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Sat, Oct 5, 2013 at 5:09 PM, Fabio Estevam wrote: > From: Fabio Estevam > > Commit 9a3bab6b05 (net: net_secret should not depend on TCP) introduced > the following build warning when CONFIG_IPV6 is not selected: > > net/core/secure_seq.c:17:13: warning: 'net_secret_init' defined but not used [-Wunused-function] > > Fix it by moving net_secret_init(void) inside the '#if IS_ENABLED(CONFIG_IPV6)' > block. > > Reported-by: Olof Johansson > Signed-off-by: Fabio Estevam Another solution would be: the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/net/core/secure_seq.c +++ b/net/core/secure_seq.c @@ -10,6 +10,7 @@ #include +#if IS_ENABLED(CONFIG_IPV6) #define NET_SECRET_SIZE (MD5_MESSAGE_BYTES / 4) static u32 net_secret[NET_SECRET_SIZE] ____cacheline_aligned; @@ -29,6 +30,7 @@ static void net_secret_init(void) cmpxchg(&net_secret[--i], 0, tmp); } } +#endif If this is preferred, I can send a v2 like that. -- To unsubscribe from this list: send the line "unsubscribe netdev" in