diff options
-rw-r--r-- | Documentation/kernel-parameters.txt | 6 | ||||
-rw-r--r-- | arch/i386/kernel/Makefile | 2 | ||||
-rw-r--r-- | arch/i386/kernel/acpi/Makefile | 2 | ||||
-rw-r--r-- | arch/i386/kernel/acpi/boot.c | 3 | ||||
-rw-r--r-- | arch/i386/kernel/acpi/earlyquirk.c | 8 | ||||
-rw-r--r-- | arch/i386/kernel/io_apic.c | 19 | ||||
-rw-r--r-- | arch/i386/kernel/setup.c | 4 | ||||
-rw-r--r-- | include/asm-i386/apic.h | 2 |
8 files changed, 40 insertions, 6 deletions
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index bad5987c4727..fc99075e0af4 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt | |||
@@ -335,6 +335,12 @@ running once the system is up. | |||
335 | timesource is not avalible, it defaults to PIT. | 335 | timesource is not avalible, it defaults to PIT. |
336 | Format: { pit | tsc | cyclone | pmtmr } | 336 | Format: { pit | tsc | cyclone | pmtmr } |
337 | 337 | ||
338 | disable_8254_timer | ||
339 | enable_8254_timer | ||
340 | [IA32/X86_64] Disable/Enable interrupt 0 timer routing | ||
341 | over the 8254 in addition to over the IO-APIC. The | ||
342 | kernel tries to set a sensible default. | ||
343 | |||
338 | hpet= [IA-32,HPET] option to disable HPET and use PIT. | 344 | hpet= [IA-32,HPET] option to disable HPET and use PIT. |
339 | Format: disable | 345 | Format: disable |
340 | 346 | ||
diff --git a/arch/i386/kernel/Makefile b/arch/i386/kernel/Makefile index 53bb9a79e274..65656c033d70 100644 --- a/arch/i386/kernel/Makefile +++ b/arch/i386/kernel/Makefile | |||
@@ -11,7 +11,7 @@ obj-y := process.o semaphore.o signal.o entry.o traps.o irq.o \ | |||
11 | 11 | ||
12 | obj-y += cpu/ | 12 | obj-y += cpu/ |
13 | obj-y += timers/ | 13 | obj-y += timers/ |
14 | obj-$(CONFIG_ACPI) += acpi/ | 14 | obj-y += acpi/ |
15 | obj-$(CONFIG_X86_BIOS_REBOOT) += reboot.o | 15 | obj-$(CONFIG_X86_BIOS_REBOOT) += reboot.o |
16 | obj-$(CONFIG_MCA) += mca.o | 16 | obj-$(CONFIG_MCA) += mca.o |
17 | obj-$(CONFIG_X86_MSR) += msr.o | 17 | obj-$(CONFIG_X86_MSR) += msr.o |
diff --git a/arch/i386/kernel/acpi/Makefile b/arch/i386/kernel/acpi/Makefile index d51c7313cae8..7e9ac99354f4 100644 --- a/arch/i386/kernel/acpi/Makefile +++ b/arch/i386/kernel/acpi/Makefile | |||
@@ -1,4 +1,4 @@ | |||
1 | obj-y := boot.o | 1 | obj-$(CONFIG_ACPI) += boot.o |
2 | obj-$(CONFIG_X86_IO_APIC) += earlyquirk.o | 2 | obj-$(CONFIG_X86_IO_APIC) += earlyquirk.o |
3 | obj-$(CONFIG_ACPI_SLEEP) += sleep.o wakeup.o | 3 | obj-$(CONFIG_ACPI_SLEEP) += sleep.o wakeup.o |
4 | 4 | ||
diff --git a/arch/i386/kernel/acpi/boot.c b/arch/i386/kernel/acpi/boot.c index 79577f0ace98..f1a21945963d 100644 --- a/arch/i386/kernel/acpi/boot.c +++ b/arch/i386/kernel/acpi/boot.c | |||
@@ -1111,9 +1111,6 @@ int __init acpi_boot_table_init(void) | |||
1111 | disable_acpi(); | 1111 | disable_acpi(); |
1112 | return error; | 1112 | return error; |
1113 | } | 1113 | } |
1114 | #ifdef __i386__ | ||
1115 | check_acpi_pci(); | ||
1116 | #endif | ||
1117 | 1114 | ||
1118 | acpi_table_parse(ACPI_BOOT, acpi_parse_sbf); | 1115 | acpi_table_parse(ACPI_BOOT, acpi_parse_sbf); |
1119 | 1116 | ||
diff --git a/arch/i386/kernel/acpi/earlyquirk.c b/arch/i386/kernel/acpi/earlyquirk.c index f1b9d2a46dab..2e3b643a4dc4 100644 --- a/arch/i386/kernel/acpi/earlyquirk.c +++ b/arch/i386/kernel/acpi/earlyquirk.c | |||
@@ -7,14 +7,22 @@ | |||
7 | #include <linux/pci.h> | 7 | #include <linux/pci.h> |
8 | #include <asm/pci-direct.h> | 8 | #include <asm/pci-direct.h> |
9 | #include <asm/acpi.h> | 9 | #include <asm/acpi.h> |
10 | #include <asm/apic.h> | ||
10 | 11 | ||
11 | static int __init check_bridge(int vendor, int device) | 12 | static int __init check_bridge(int vendor, int device) |
12 | { | 13 | { |
14 | #ifdef CONFIG_ACPI | ||
13 | /* According to Nvidia all timer overrides are bogus. Just ignore | 15 | /* According to Nvidia all timer overrides are bogus. Just ignore |
14 | them all. */ | 16 | them all. */ |
15 | if (vendor == PCI_VENDOR_ID_NVIDIA) { | 17 | if (vendor == PCI_VENDOR_ID_NVIDIA) { |
16 | acpi_skip_timer_override = 1; | 18 | acpi_skip_timer_override = 1; |
17 | } | 19 | } |
20 | #endif | ||
21 | if (vendor == PCI_VENDOR_ID_ATI && timer_over_8254 == 1) { | ||
22 | timer_over_8254 = 0; | ||
23 | printk(KERN_INFO "ATI board detected. Disabling timer routing " | ||
24 | "over 8254.\n"); | ||
25 | } | ||
18 | return 0; | 26 | return 0; |
19 | } | 27 | } |
20 | 28 | ||
diff --git a/arch/i386/kernel/io_apic.c b/arch/i386/kernel/io_apic.c index 235822b3f41b..39d9a5fa907e 100644 --- a/arch/i386/kernel/io_apic.c +++ b/arch/i386/kernel/io_apic.c | |||
@@ -51,6 +51,8 @@ static struct { int pin, apic; } ioapic_i8259 = { -1, -1 }; | |||
51 | 51 | ||
52 | static DEFINE_SPINLOCK(ioapic_lock); | 52 | static DEFINE_SPINLOCK(ioapic_lock); |
53 | 53 | ||
54 | int timer_over_8254 __initdata = 1; | ||
55 | |||
54 | /* | 56 | /* |
55 | * Is the SiS APIC rmw bug present ? | 57 | * Is the SiS APIC rmw bug present ? |
56 | * -1 = don't know, 0 = no, 1 = yes | 58 | * -1 = don't know, 0 = no, 1 = yes |
@@ -2267,7 +2269,8 @@ static inline void check_timer(void) | |||
2267 | apic_write_around(APIC_LVT0, APIC_LVT_MASKED | APIC_DM_EXTINT); | 2269 | apic_write_around(APIC_LVT0, APIC_LVT_MASKED | APIC_DM_EXTINT); |
2268 | init_8259A(1); | 2270 | init_8259A(1); |
2269 | timer_ack = 1; | 2271 | timer_ack = 1; |
2270 | enable_8259A_irq(0); | 2272 | if (timer_over_8254 > 0) |
2273 | enable_8259A_irq(0); | ||
2271 | 2274 | ||
2272 | pin1 = find_isa_irq_pin(0, mp_INT); | 2275 | pin1 = find_isa_irq_pin(0, mp_INT); |
2273 | apic1 = find_isa_irq_apic(0, mp_INT); | 2276 | apic1 = find_isa_irq_apic(0, mp_INT); |
@@ -2392,6 +2395,20 @@ void __init setup_IO_APIC(void) | |||
2392 | print_IO_APIC(); | 2395 | print_IO_APIC(); |
2393 | } | 2396 | } |
2394 | 2397 | ||
2398 | static int __init setup_disable_8254_timer(char *s) | ||
2399 | { | ||
2400 | timer_over_8254 = -1; | ||
2401 | return 1; | ||
2402 | } | ||
2403 | static int __init setup_enable_8254_timer(char *s) | ||
2404 | { | ||
2405 | timer_over_8254 = 2; | ||
2406 | return 1; | ||
2407 | } | ||
2408 | |||
2409 | __setup("disable_8254_timer", setup_disable_8254_timer); | ||
2410 | __setup("enable_8254_timer", setup_enable_8254_timer); | ||
2411 | |||
2395 | /* | 2412 | /* |
2396 | * Called after all the initialization is done. If we didnt find any | 2413 | * Called after all the initialization is done. If we didnt find any |
2397 | * APIC bugs then we can allow the modify fast path | 2414 | * APIC bugs then we can allow the modify fast path |
diff --git a/arch/i386/kernel/setup.c b/arch/i386/kernel/setup.c index 51e513b4f72d..ab62a9f4701e 100644 --- a/arch/i386/kernel/setup.c +++ b/arch/i386/kernel/setup.c | |||
@@ -1599,6 +1599,10 @@ void __init setup_arch(char **cmdline_p) | |||
1599 | if (efi_enabled) | 1599 | if (efi_enabled) |
1600 | efi_map_memmap(); | 1600 | efi_map_memmap(); |
1601 | 1601 | ||
1602 | #ifdef CONFIG_X86_IO_APIC | ||
1603 | check_acpi_pci(); /* Checks more than just ACPI actually */ | ||
1604 | #endif | ||
1605 | |||
1602 | #ifdef CONFIG_ACPI | 1606 | #ifdef CONFIG_ACPI |
1603 | /* | 1607 | /* |
1604 | * Parse the ACPI tables for possible boot-time SMP configuration. | 1608 | * Parse the ACPI tables for possible boot-time SMP configuration. |
diff --git a/include/asm-i386/apic.h b/include/asm-i386/apic.h index d30b8571573f..ff9ac8d19eb2 100644 --- a/include/asm-i386/apic.h +++ b/include/asm-i386/apic.h | |||
@@ -137,6 +137,8 @@ void switch_APIC_timer_to_ipi(void *cpumask); | |||
137 | void switch_ipi_to_APIC_timer(void *cpumask); | 137 | void switch_ipi_to_APIC_timer(void *cpumask); |
138 | #define ARCH_APICTIMER_STOPS_ON_C3 1 | 138 | #define ARCH_APICTIMER_STOPS_ON_C3 1 |
139 | 139 | ||
140 | extern int timer_over_8254; | ||
141 | |||
140 | #else /* !CONFIG_X86_LOCAL_APIC */ | 142 | #else /* !CONFIG_X86_LOCAL_APIC */ |
141 | static inline void lapic_shutdown(void) { } | 143 | static inline void lapic_shutdown(void) { } |
142 | 144 | ||