1 From: Ingo Molnar <mingo@elte.hu>
2 Subject: Re: [PATCH 5/6] x86: ifdef ioapic related function out
3 Date: Mon, 14 Feb 2011 12:00:39 +0100
5 Message-ID: <20110214110039.GA7140@elte.hu>
6 References: <1297677612-12405-1-git-send-email-henne@nachtwindheim.de>
7 <1297677612-12405-5-git-send-email-henne@nachtwindheim.de>
9 Content-Type: text/plain; charset=us-ascii
10 Cc: mingo@readhat.com, tglx@linutronix.de, hpa@zytor.com,
11 x86@kernel.org, tj@kernel.org, yinghai@kernel.org,
12 ak@linux.intel.com, robert.richter@amd.com,
13 linux-kernel@vger.kernel.org
14 To: Henrik Kretzschmar <henne@nachtwindheim.de>
15 X-From: linux-kernel-owner@vger.kernel.org Mon Feb 14 12:01:04 2011
16 Return-path: <linux-kernel-owner@vger.kernel.org>
17 Envelope-to: glk-linux-kernel-3@lo.gmane.org
18 Received: from vger.kernel.org ([209.132.180.67])
19 by lo.gmane.org with esmtp (Exim 4.69)
20 (envelope-from <linux-kernel-owner@vger.kernel.org>)
22 for glk-linux-kernel-3@lo.gmane.org; Mon, 14 Feb 2011 12:01:04 +0100
23 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
24 id S1752962Ab1BNLA5 (ORCPT <rfc822;glk-linux-kernel-3@m.gmane.org>);
25 Mon, 14 Feb 2011 06:00:57 -0500
26 Received: from mx3.mail.elte.hu ([157.181.1.138]:38470 "EHLO mx3.mail.elte.hu"
27 rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP
28 id S1752556Ab1BNLAz (ORCPT <rfc822;linux-kernel@vger.kernel.org>);
29 Mon, 14 Feb 2011 06:00:55 -0500
30 Received: from elvis.elte.hu ([157.181.1.14])
31 by mx3.mail.elte.hu with esmtp (Exim)
33 from <mingo@elte.hu>; Mon, 14 Feb 2011 12:00:48 +0100
34 Received: by elvis.elte.hu (Postfix, from userid 1004)
35 id 7726F3E236B; Mon, 14 Feb 2011 12:00:41 +0100 (CET)
36 Content-Disposition: inline
37 In-Reply-To: <1297677612-12405-5-git-send-email-henne@nachtwindheim.de>
38 User-Agent: Mutt/1.5.20 (2009-08-17)
39 Received-SPF: neutral (mx3: 157.181.1.14 is neither permitted nor denied by domain of elte.hu) client-ip=157.181.1.14; envelope-from=mingo@elte.hu; helo=elvis.elte.hu;
40 X-ELTE-SpamScore: -2.0
43 X-ELTE-SpamVersion: ELTE 2.0
44 X-ELTE-SpamCheck-Details: score=-2.0 required=5.9 tests=BAYES_00 autolearn=no SpamAssassin version=3.2.5
45 -2.0 BAYES_00 BODY: Bayesian spam probability is 0 to 1%
47 Sender: linux-kernel-owner@vger.kernel.org
49 List-ID: <linux-kernel.vger.kernel.org>
50 X-Mailing-List: linux-kernel@vger.kernel.org
51 Archived-At: <http://permalink.gmane.org/gmane.linux.kernel/1099670>
54 * Henrik Kretzschmar <henne@nachtwindheim.de> wrote:
56 > arch_disable_smp_config() is an IO-APIC related function on x86,
57 > and should only be needed if SMP is enabled.
58 > But the IO-APIC code calls it when the parameter "noapic" is given to
59 > the kernel, which doesn't mean SMP is enabled.
61 > Anyway this fixes compilation on x86_32 UP systems with APIC and no IO-APIC.
63 > Signed-off-by: Henrik Kretzschmar <henne@nachtwindheim.de>
65 > arch/x86/kernel/apic/apic.c | 2 ++
66 > 1 files changed, 2 insertions(+), 0 deletions(-)
68 > diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c
69 > index 999c531..4998f0a 100644
70 > --- a/arch/x86/kernel/apic/apic.c
71 > +++ b/arch/x86/kernel/apic/apic.c
72 > @@ -1218,7 +1218,9 @@ void __cpuinit setup_local_APIC(void)
76 > +#ifdef CONFIG_X86_IO_APIC
77 > arch_disable_smp_support();
80 Why not make the arch_disable_smp_support() call generic in the
81 arch/x86/include/asm/smp.h file (via an inline helper) and thus
82 avoid an ugly #ifdef in the .c file?