From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753296AbXCWS3e (ORCPT ); Fri, 23 Mar 2007 14:29:34 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753300AbXCWS3e (ORCPT ); Fri, 23 Mar 2007 14:29:34 -0400 Received: from smtp.osdl.org ([65.172.181.24]:59717 "EHLO smtp.osdl.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753296AbXCWS3d (ORCPT ); Fri, 23 Mar 2007 14:29:33 -0400 Date: Fri, 23 Mar 2007 11:28:41 -0700 (PDT) From: Linus Torvalds To: Thomas Gleixner cc: Ingo Molnar , "Eric W. Biederman" , Nick Piggin , Mingming Cao , Adrian Bunk , Andrew Morton , Linux Kernel Mailing List , Michal Piotrowski , Mariusz Kozlowski , Oliver Pinter , Sid Boyce , Nick Piggin , Jens Axboe , Thomas Renninger , Len Brown Subject: Re: [1/6] 2.6.21-rc4: known regressions In-Reply-To: Message-ID: References: <20070318184908.GU752@stusta.de> <46020385.50301@yahoo.com.au> <1174612132.16068.114.camel@localhost.localdomain> <20070323114223.GA23483@elte.hu> <1174650969.10840.274.camel@localhost.localdomain> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 23 Mar 2007, Linus Torvalds wrote: > > Thomas, please fix. Here's a possible fix. It compiles. And I still wish we had common files. ia64 shouldn't be affected, because ia64 doesn't #define the ARCH_APICTIMER_STOPS_ON_C3 flag (and then we don't use the "c2_ok" thing either. But this is still pretty damn ugly. Maybe a field in "struct acpi_processor" for C2/C3 problems? Linus --- diff --git a/arch/x86_64/kernel/apic.c b/arch/x86_64/kernel/apic.c index 723417d..46acf4f 100644 --- a/arch/x86_64/kernel/apic.c +++ b/arch/x86_64/kernel/apic.c @@ -47,6 +47,10 @@ int apic_calibrate_pmtmr __initdata; int disable_apic_timer __initdata; +/* Local APIC timer works in C2? */ +int local_apic_timer_c2_ok; +EXPORT_SYMBOL_GPL(local_apic_timer_c2_ok); + static struct resource *ioapic_resources; static struct resource lapic_resource = { .name = "Local APIC", @@ -1192,6 +1196,13 @@ static __init int setup_nolapic(char *str) } early_param("nolapic", setup_nolapic); +static int __init parse_lapic_timer_c2_ok(char *arg) +{ + local_apic_timer_c2_ok = 1; + return 0; +} +early_param("lapic_timer_c2_ok", parse_lapic_timer_c2_ok); + static __init int setup_noapictimer(char *str) { if (str[0] != ' ' && str[0] != 0) diff --git a/include/asm-x86_64/apic.h b/include/asm-x86_64/apic.h index e81d0f2..7cfb39c 100644 --- a/include/asm-x86_64/apic.h +++ b/include/asm-x86_64/apic.h @@ -102,5 +102,6 @@ void switch_ipi_to_APIC_timer(void *cpumask); #define ARCH_APICTIMER_STOPS_ON_C3 1 extern unsigned boot_cpu_id; +extern int local_apic_timer_c2_ok; #endif /* __ASM_APIC_H */