From patchwork Wed Jan 18 05:13:05 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Christian Kujau X-Patchwork-Id: 136549 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id 896B7100A65 for ; Wed, 18 Jan 2012 16:13:16 +1100 (EST) Received: from trent.utfs.org (trent.utfs.org [194.246.123.103]) by ozlabs.org (Postfix) with ESMTP id 2EEE91007D1 for ; Wed, 18 Jan 2012 16:13:08 +1100 (EST) Received: by trent.utfs.org (Postfix, from userid 8) id 526183DB39; Wed, 18 Jan 2012 06:13:06 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on trent.utfs.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.5 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.3.1 Received: from trent.utfs.org (localhost [127.0.0.1]) by trent.utfs.org (Postfix) with ESMTP id C4E6B3DB27; Wed, 18 Jan 2012 06:13:05 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by trent.utfs.org (Postfix) with ESMTP id B0E3C3DACA; Wed, 18 Jan 2012 06:13:05 +0100 (CET) Date: Tue, 17 Jan 2012 21:13:05 -0800 (PST) From: Christian Kujau To: LKML Subject: Re: error: 'cpus_in_crash' defined but not used In-Reply-To: Message-ID: References: User-Agent: Alpine 2.01 (DEB 1266 2009-07-14) MIME-Version: 1.0 X-AV-Checked: ClamAV using ClamSMTP (127.0.0.1) Cc: linuxppc-dev@lists.ozlabs.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org On Tue, 17 Jan 2012 at 20:13, Christian Kujau wrote: > > compiling today's git (mainline, a25a2b8) on powerpc32 gives: > > CC arch/powerpc/kernel/crash.o > cc1: warnings being treated as errors > /usr/local/src/linux-2.6-git/arch/powerpc/kernel/crash.c:49: error: > ‘cpus_in_crash’ defined but not used > make[2]: *** [arch/powerpc/kernel/crash.o] Error 1 > make[1]: *** [arch/powerpc/kernel] Error 2 > make: *** [sub-make] Error 2 I could not find cpus_in_crash anywhere in the sourcetree, except for arch/powerpc/kernel/crash.c. Moving the definition into the CONFIG_SMP ifdef helps on my UP system, of course - not sure about other machines though: Christian. diff --git a/arch/powerpc/kernel/crash.c b/arch/powerpc/kernel/crash.c index 28be345..abef751 100644 --- a/arch/powerpc/kernel/crash.c +++ b/arch/powerpc/kernel/crash.c @@ -46,7 +46,6 @@ /* This keeps a track of which one is the crashing cpu. */ int crashing_cpu = -1; -static atomic_t cpus_in_crash; static int time_to_dump; #define CRASH_HANDLER_MAX 3 @@ -66,6 +65,7 @@ static int handle_fault(struct pt_regs *regs) #ifdef CONFIG_SMP +static atomic_t cpus_in_crash; void crash_ipi_callback(struct pt_regs *regs) { static cpumask_t cpus_state_saved = CPU_MASK_NONE;