aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel
diff options
context:
space:
mode:
authorCyrill Gorcunov <gorcunov@gmail.com>2008-08-15 07:51:20 -0400
committerIngo Molnar <mingo@elte.hu>2008-08-15 07:51:20 -0400
commit36fef0949c14445d231a68663e8a01860f7caca3 (patch)
treeaced44fef8f87fdbcf2ed8dd57e4658473276edb /arch/x86/kernel
parented4e5ec177d20504c51aebb93db12d57716cde9c (diff)
x86: apic - unify disable_apic_timer
Get rid of local_apic_timer_disabled and use disable_apic_timer instead. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r--arch/x86/kernel/apic_32.c17
-rw-r--r--arch/x86/kernel/apic_64.c16
2 files changed, 23 insertions, 10 deletions
diff --git a/arch/x86/kernel/apic_32.c b/arch/x86/kernel/apic_32.c
index 12b154822bce..6af20dd12c96 100644
--- a/arch/x86/kernel/apic_32.c
+++ b/arch/x86/kernel/apic_32.c
@@ -63,7 +63,7 @@ int disable_apic;
63/* Local APIC timer verification ok */ 63/* Local APIC timer verification ok */
64static int local_apic_timer_verify_ok; 64static int local_apic_timer_verify_ok;
65/* Disable local APIC timer from the kernel commandline or via dmi quirk */ 65/* Disable local APIC timer from the kernel commandline or via dmi quirk */
66static int local_apic_timer_disabled; 66static int disable_apic_timer __cpuinitdata;
67/* Local APIC timer works in C2 */ 67/* Local APIC timer works in C2 */
68int local_apic_timer_c2_ok; 68int local_apic_timer_c2_ok;
69EXPORT_SYMBOL_GPL(local_apic_timer_c2_ok); 69EXPORT_SYMBOL_GPL(local_apic_timer_c2_ok);
@@ -574,7 +574,7 @@ void __init setup_boot_APIC_clock(void)
574 * timer as a dummy clock event source on SMP systems, so the 574 * timer as a dummy clock event source on SMP systems, so the
575 * broadcast mechanism is used. On UP systems simply ignore it. 575 * broadcast mechanism is used. On UP systems simply ignore it.
576 */ 576 */
577 if (local_apic_timer_disabled) { 577 if (disable_apic_timer) {
578 /* No broadcast on UP ! */ 578 /* No broadcast on UP ! */
579 if (num_possible_cpus() > 1) { 579 if (num_possible_cpus() > 1) {
580 lapic_clockevent.mult = 1; 580 lapic_clockevent.mult = 1;
@@ -1699,12 +1699,19 @@ static int __init parse_nolapic(char *arg)
1699} 1699}
1700early_param("nolapic", parse_nolapic); 1700early_param("nolapic", parse_nolapic);
1701 1701
1702static int __init parse_disable_lapic_timer(char *arg) 1702static int __init parse_disable_apic_timer(char *arg)
1703{ 1703{
1704 local_apic_timer_disabled = 1; 1704 disable_apic_timer = 1;
1705 return 0; 1705 return 0;
1706} 1706}
1707early_param("nolapic_timer", parse_disable_lapic_timer); 1707early_param("noapictimer", parse_disable_apic_timer);
1708
1709static int __init parse_nolapic_timer(char *arg)
1710{
1711 disable_apic_timer = 1;
1712 return 0;
1713}
1714early_param("nolapic_timer", parse_nolapic_timer);
1708 1715
1709static int __init parse_lapic_timer_c2_ok(char *arg) 1716static int __init parse_lapic_timer_c2_ok(char *arg)
1710{ 1717{
diff --git a/arch/x86/kernel/apic_64.c b/arch/x86/kernel/apic_64.c
index 77c5e5eb820e..1e925be861e4 100644
--- a/arch/x86/kernel/apic_64.c
+++ b/arch/x86/kernel/apic_64.c
@@ -45,6 +45,7 @@
45#include <mach_ipi.h> 45#include <mach_ipi.h>
46#include <mach_apic.h> 46#include <mach_apic.h>
47 47
48/* Disable local APIC timer from the kernel commandline or via dmi quirk */
48static int disable_apic_timer __cpuinitdata; 49static int disable_apic_timer __cpuinitdata;
49static int apic_calibrate_pmtmr __initdata; 50static int apic_calibrate_pmtmr __initdata;
50int disable_apic; 51int disable_apic;
@@ -1583,14 +1584,19 @@ static int __init parse_lapic_timer_c2_ok(char *arg)
1583} 1584}
1584early_param("lapic_timer_c2_ok", parse_lapic_timer_c2_ok); 1585early_param("lapic_timer_c2_ok", parse_lapic_timer_c2_ok);
1585 1586
1586static __init int setup_noapictimer(char *str) 1587static int __init parse_disable_apic_timer(char *arg)
1587{ 1588{
1588 if (str[0] != ' ' && str[0] != 0)
1589 return 0;
1590 disable_apic_timer = 1; 1589 disable_apic_timer = 1;
1591 return 1; 1590 return 0;
1591}
1592early_param("noapictimer", parse_disable_apic_timer);
1593
1594static int __init parse_nolapic_timer(char *arg)
1595{
1596 disable_apic_timer = 1;
1597 return 0;
1592} 1598}
1593__setup("noapictimer", setup_noapictimer); 1599early_param("nolapic_timer", parse_nolapic_timer);
1594 1600
1595static __init int setup_apicpmtimer(char *s) 1601static __init int setup_apicpmtimer(char *s)
1596{ 1602{