public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Gabriel C <nix.or.die@googlemail.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Ingo Molnar <mingo@redhat.com>, Andi Kleen <ak@suse.de>
Subject: Re: [PATCH] Fix arch/i386/kernel/nmi.c - 'unknown_nmi_panic_callback' declared 'static' but never defined warning
Date: Tue, 24 Jul 2007 18:36:36 -0700	[thread overview]
Message-ID: <20070724183636.63844865.akpm@linux-foundation.org> (raw)
In-Reply-To: <46A3AE06.9030706@googlemail.com>

On Sun, 22 Jul 2007 21:20:38 +0200 Gabriel C <nix.or.die@googlemail.com> wrote:

> I get this warning when CONFIG_SYSCTL is not set :
> 
> ...
> 
> arch/i386/kernel/nmi.c:52: warning: 'unknown_nmi_panic_callback' declared 'static' but never defined
> 
> ...
> 
> Signed-off-by: Gabriel Craciunescu <nix.or.die@googlemail.com>
> 
> ---
> 
> diff --git a/arch/i386/kernel/nmi.c b/arch/i386/kernel/nmi.c
> index 03b7f55..cf11121 100644
> --- a/arch/i386/kernel/nmi.c
> +++ b/arch/i386/kernel/nmi.c
> @@ -49,8 +49,9 @@ static unsigned int nmi_hz = HZ;
>  static DEFINE_PER_CPU(short, wd_enabled);
>  
>  /* local prototypes */
> +#ifdef CONFIG_SYSCTL
>  static int unknown_nmi_panic_callback(struct pt_regs *regs, int cpu);
> -
> +#endif
>  static int endflag __initdata = 0;

guys, please take a closer look at the code which you're changing?  We can
obviously move do_nmi_callback() down to above
__trigger_all_cpu_backtrace() and then do away with this declaration
altogether.

  reply	other threads:[~2007-07-25  1:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-22 19:20 [PATCH] Fix arch/i386/kernel/nmi.c - 'unknown_nmi_panic_callback' declared 'static' but never defined warning Gabriel C
2007-07-25  1:36 ` Andrew Morton [this message]
     [not found]   ` <1820d69d0707250657y36c902deya66c2171dade843f@mail.gmail.com>
2007-07-25 14:51     ` Fwd: " Gabriel C

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070724183636.63844865.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=ak@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=nix.or.die@googlemail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox