diff options
-rw-r--r-- | arch/x86/include/asm/arch_hooks.h | 26 | ||||
-rw-r--r-- | arch/x86/include/asm/i8259.h | 4 | ||||
-rw-r--r-- | arch/x86/include/asm/setup.h | 9 | ||||
-rw-r--r-- | arch/x86/include/asm/timer.h | 2 | ||||
-rw-r--r-- | arch/x86/kernel/apic/apic.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/apic/probe_32.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/i8259.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/irqinit_32.c | 13 | ||||
-rw-r--r-- | arch/x86/kernel/kvmclock.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/mca_32.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/paravirt.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/setup.c | 23 | ||||
-rw-r--r-- | arch/x86/kernel/time_32.c | 6 | ||||
-rw-r--r-- | arch/x86/kernel/traps.c | 4 | ||||
-rw-r--r-- | arch/x86/kernel/visws_quirks.c | 1 | ||||
-rw-r--r-- | arch/x86/kernel/vmiclock_32.c | 1 |
16 files changed, 39 insertions, 56 deletions
diff --git a/arch/x86/include/asm/arch_hooks.h b/arch/x86/include/asm/arch_hooks.h deleted file mode 100644 index 54248172be1..00000000000 --- a/arch/x86/include/asm/arch_hooks.h +++ /dev/null | |||
@@ -1,26 +0,0 @@ | |||
1 | #ifndef _ASM_X86_ARCH_HOOKS_H | ||
2 | #define _ASM_X86_ARCH_HOOKS_H | ||
3 | |||
4 | #include <linux/interrupt.h> | ||
5 | |||
6 | /* | ||
7 | * linux/include/asm/arch_hooks.h | ||
8 | * | ||
9 | * define the architecture specific hooks | ||
10 | */ | ||
11 | |||
12 | /* these aren't arch hooks, they are generic routines | ||
13 | * that can be used by the hooks */ | ||
14 | extern void init_ISA_irqs(void); | ||
15 | extern irqreturn_t timer_interrupt(int irq, void *dev_id); | ||
16 | |||
17 | /* these are the defined hooks */ | ||
18 | extern void pre_intr_init_hook(void); | ||
19 | extern void intr_init_hook(void); | ||
20 | |||
21 | extern void trap_init_hook(void); | ||
22 | |||
23 | extern void pre_time_init_hook(void); | ||
24 | extern void time_init_hook(void); | ||
25 | |||
26 | #endif /* _ASM_X86_ARCH_HOOKS_H */ | ||
diff --git a/arch/x86/include/asm/i8259.h b/arch/x86/include/asm/i8259.h index 58d7091eeb1..1a99e6c092a 100644 --- a/arch/x86/include/asm/i8259.h +++ b/arch/x86/include/asm/i8259.h | |||
@@ -60,4 +60,8 @@ extern struct irq_chip i8259A_chip; | |||
60 | extern void mask_8259A(void); | 60 | extern void mask_8259A(void); |
61 | extern void unmask_8259A(void); | 61 | extern void unmask_8259A(void); |
62 | 62 | ||
63 | #ifdef CONFIG_X86_32 | ||
64 | extern void init_ISA_irqs(void); | ||
65 | #endif | ||
66 | |||
63 | #endif /* _ASM_X86_I8259_H */ | 67 | #endif /* _ASM_X86_I8259_H */ |
diff --git a/arch/x86/include/asm/setup.h b/arch/x86/include/asm/setup.h index 8029369cd6f..66801cb72f6 100644 --- a/arch/x86/include/asm/setup.h +++ b/arch/x86/include/asm/setup.h | |||
@@ -13,6 +13,7 @@ | |||
13 | struct mpc_cpu; | 13 | struct mpc_cpu; |
14 | struct mpc_bus; | 14 | struct mpc_bus; |
15 | struct mpc_oemtable; | 15 | struct mpc_oemtable; |
16 | |||
16 | struct x86_quirks { | 17 | struct x86_quirks { |
17 | int (*arch_pre_time_init)(void); | 18 | int (*arch_pre_time_init)(void); |
18 | int (*arch_time_init)(void); | 19 | int (*arch_time_init)(void); |
@@ -33,6 +34,14 @@ struct x86_quirks { | |||
33 | int (*update_apic)(void); | 34 | int (*update_apic)(void); |
34 | }; | 35 | }; |
35 | 36 | ||
37 | extern void x86_quirk_pre_intr_init(void); | ||
38 | extern void x86_quirk_intr_init(void); | ||
39 | |||
40 | extern void x86_quirk_trap_init(void); | ||
41 | |||
42 | extern void x86_quirk_pre_time_init(void); | ||
43 | extern void x86_quirk_time_init(void); | ||
44 | |||
36 | #endif /* __ASSEMBLY__ */ | 45 | #endif /* __ASSEMBLY__ */ |
37 | 46 | ||
38 | #ifdef __i386__ | 47 | #ifdef __i386__ |
diff --git a/arch/x86/include/asm/timer.h b/arch/x86/include/asm/timer.h index 2bb6a835c45..a81195eaa2b 100644 --- a/arch/x86/include/asm/timer.h +++ b/arch/x86/include/asm/timer.h | |||
@@ -3,6 +3,7 @@ | |||
3 | #include <linux/init.h> | 3 | #include <linux/init.h> |
4 | #include <linux/pm.h> | 4 | #include <linux/pm.h> |
5 | #include <linux/percpu.h> | 5 | #include <linux/percpu.h> |
6 | #include <linux/interrupt.h> | ||
6 | 7 | ||
7 | #define TICK_SIZE (tick_nsec / 1000) | 8 | #define TICK_SIZE (tick_nsec / 1000) |
8 | 9 | ||
@@ -12,6 +13,7 @@ unsigned long native_calibrate_tsc(void); | |||
12 | #ifdef CONFIG_X86_32 | 13 | #ifdef CONFIG_X86_32 |
13 | extern int timer_ack; | 14 | extern int timer_ack; |
14 | extern int recalibrate_cpu_khz(void); | 15 | extern int recalibrate_cpu_khz(void); |
16 | extern irqreturn_t timer_interrupt(int irq, void *dev_id); | ||
15 | #endif /* CONFIG_X86_32 */ | 17 | #endif /* CONFIG_X86_32 */ |
16 | 18 | ||
17 | extern int no_timer_check; | 19 | extern int no_timer_check; |
diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index c6bd7710585..f9cecdfd05c 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c | |||
@@ -34,7 +34,6 @@ | |||
34 | #include <linux/smp.h> | 34 | #include <linux/smp.h> |
35 | #include <linux/mm.h> | 35 | #include <linux/mm.h> |
36 | 36 | ||
37 | #include <asm/arch_hooks.h> | ||
38 | #include <asm/pgalloc.h> | 37 | #include <asm/pgalloc.h> |
39 | #include <asm/atomic.h> | 38 | #include <asm/atomic.h> |
40 | #include <asm/mpspec.h> | 39 | #include <asm/mpspec.h> |
diff --git a/arch/x86/kernel/apic/probe_32.c b/arch/x86/kernel/apic/probe_32.c index c9ec90742e9..3a730fa574b 100644 --- a/arch/x86/kernel/apic/probe_32.c +++ b/arch/x86/kernel/apic/probe_32.c | |||
@@ -35,7 +35,6 @@ | |||
35 | #include <linux/init.h> | 35 | #include <linux/init.h> |
36 | #include <linux/interrupt.h> | 36 | #include <linux/interrupt.h> |
37 | #include <asm/acpi.h> | 37 | #include <asm/acpi.h> |
38 | #include <asm/arch_hooks.h> | ||
39 | #include <asm/e820.h> | 38 | #include <asm/e820.h> |
40 | #include <asm/setup.h> | 39 | #include <asm/setup.h> |
41 | 40 | ||
diff --git a/arch/x86/kernel/i8259.c b/arch/x86/kernel/i8259.c index 11d5093eb28..df89102bef8 100644 --- a/arch/x86/kernel/i8259.c +++ b/arch/x86/kernel/i8259.c | |||
@@ -22,7 +22,6 @@ | |||
22 | #include <asm/pgtable.h> | 22 | #include <asm/pgtable.h> |
23 | #include <asm/desc.h> | 23 | #include <asm/desc.h> |
24 | #include <asm/apic.h> | 24 | #include <asm/apic.h> |
25 | #include <asm/arch_hooks.h> | ||
26 | #include <asm/i8259.h> | 25 | #include <asm/i8259.h> |
27 | 26 | ||
28 | /* | 27 | /* |
diff --git a/arch/x86/kernel/irqinit_32.c b/arch/x86/kernel/irqinit_32.c index bf629cadec1..50b8c3a3006 100644 --- a/arch/x86/kernel/irqinit_32.c +++ b/arch/x86/kernel/irqinit_32.c | |||
@@ -18,7 +18,7 @@ | |||
18 | #include <asm/pgtable.h> | 18 | #include <asm/pgtable.h> |
19 | #include <asm/desc.h> | 19 | #include <asm/desc.h> |
20 | #include <asm/apic.h> | 20 | #include <asm/apic.h> |
21 | #include <asm/arch_hooks.h> | 21 | #include <asm/setup.h> |
22 | #include <asm/i8259.h> | 22 | #include <asm/i8259.h> |
23 | #include <asm/traps.h> | 23 | #include <asm/traps.h> |
24 | 24 | ||
@@ -127,8 +127,8 @@ void __init native_init_IRQ(void) | |||
127 | { | 127 | { |
128 | int i; | 128 | int i; |
129 | 129 | ||
130 | /* all the set up before the call gates are initialised */ | 130 | /* Execute any quirks before the call gates are initialised: */ |
131 | pre_intr_init_hook(); | 131 | x86_quirk_pre_intr_init(); |
132 | 132 | ||
133 | /* | 133 | /* |
134 | * Cover the whole vector space, no vector can escape | 134 | * Cover the whole vector space, no vector can escape |
@@ -188,10 +188,11 @@ void __init native_init_IRQ(void) | |||
188 | if (!acpi_ioapic) | 188 | if (!acpi_ioapic) |
189 | setup_irq(2, &irq2); | 189 | setup_irq(2, &irq2); |
190 | 190 | ||
191 | /* setup after call gates are initialised (usually add in | 191 | /* |
192 | * the architecture specific gates) | 192 | * Call quirks after call gates are initialised (usually add in |
193 | * the architecture specific gates): | ||
193 | */ | 194 | */ |
194 | intr_init_hook(); | 195 | x86_quirk_intr_init(); |
195 | 196 | ||
196 | /* | 197 | /* |
197 | * External FPU? Set up irq13 if so, for | 198 | * External FPU? Set up irq13 if so, for |
diff --git a/arch/x86/kernel/kvmclock.c b/arch/x86/kernel/kvmclock.c index 652fce6d2cc..137f2e8132d 100644 --- a/arch/x86/kernel/kvmclock.c +++ b/arch/x86/kernel/kvmclock.c | |||
@@ -19,7 +19,6 @@ | |||
19 | #include <linux/clocksource.h> | 19 | #include <linux/clocksource.h> |
20 | #include <linux/kvm_para.h> | 20 | #include <linux/kvm_para.h> |
21 | #include <asm/pvclock.h> | 21 | #include <asm/pvclock.h> |
22 | #include <asm/arch_hooks.h> | ||
23 | #include <asm/msr.h> | 22 | #include <asm/msr.h> |
24 | #include <asm/apic.h> | 23 | #include <asm/apic.h> |
25 | #include <linux/percpu.h> | 24 | #include <linux/percpu.h> |
diff --git a/arch/x86/kernel/mca_32.c b/arch/x86/kernel/mca_32.c index f74eef52ab5..845d80ce1ef 100644 --- a/arch/x86/kernel/mca_32.c +++ b/arch/x86/kernel/mca_32.c | |||
@@ -51,7 +51,6 @@ | |||
51 | #include <linux/ioport.h> | 51 | #include <linux/ioport.h> |
52 | #include <asm/uaccess.h> | 52 | #include <asm/uaccess.h> |
53 | #include <linux/init.h> | 53 | #include <linux/init.h> |
54 | #include <asm/arch_hooks.h> | ||
55 | 54 | ||
56 | static unsigned char which_scsi; | 55 | static unsigned char which_scsi; |
57 | 56 | ||
diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c index 6dc4dca255e..63dd358d8ee 100644 --- a/arch/x86/kernel/paravirt.c +++ b/arch/x86/kernel/paravirt.c | |||
@@ -28,7 +28,6 @@ | |||
28 | #include <asm/paravirt.h> | 28 | #include <asm/paravirt.h> |
29 | #include <asm/desc.h> | 29 | #include <asm/desc.h> |
30 | #include <asm/setup.h> | 30 | #include <asm/setup.h> |
31 | #include <asm/arch_hooks.h> | ||
32 | #include <asm/pgtable.h> | 31 | #include <asm/pgtable.h> |
33 | #include <asm/time.h> | 32 | #include <asm/time.h> |
34 | #include <asm/pgalloc.h> | 33 | #include <asm/pgalloc.h> |
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c index d4de1e4c204..5b85759e797 100644 --- a/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c | |||
@@ -74,8 +74,9 @@ | |||
74 | #include <asm/e820.h> | 74 | #include <asm/e820.h> |
75 | #include <asm/mpspec.h> | 75 | #include <asm/mpspec.h> |
76 | #include <asm/setup.h> | 76 | #include <asm/setup.h> |
77 | #include <asm/arch_hooks.h> | ||
78 | #include <asm/efi.h> | 77 | #include <asm/efi.h> |
78 | #include <asm/timer.h> | ||
79 | #include <asm/i8259.h> | ||
79 | #include <asm/sections.h> | 80 | #include <asm/sections.h> |
80 | #include <asm/dmi.h> | 81 | #include <asm/dmi.h> |
81 | #include <asm/io_apic.h> | 82 | #include <asm/io_apic.h> |
@@ -987,7 +988,7 @@ void __init setup_arch(char **cmdline_p) | |||
987 | #ifdef CONFIG_X86_32 | 988 | #ifdef CONFIG_X86_32 |
988 | 989 | ||
989 | /** | 990 | /** |
990 | * pre_intr_init_hook - initialisation prior to setting up interrupt vectors | 991 | * x86_quirk_pre_intr_init - initialisation prior to setting up interrupt vectors |
991 | * | 992 | * |
992 | * Description: | 993 | * Description: |
993 | * Perform any necessary interrupt initialisation prior to setting up | 994 | * Perform any necessary interrupt initialisation prior to setting up |
@@ -995,7 +996,7 @@ void __init setup_arch(char **cmdline_p) | |||
995 | * interrupts should be initialised here if the machine emulates a PC | 996 | * interrupts should be initialised here if the machine emulates a PC |
996 | * in any way. | 997 | * in any way. |
997 | **/ | 998 | **/ |
998 | void __init pre_intr_init_hook(void) | 999 | void __init x86_quirk_pre_intr_init(void) |
999 | { | 1000 | { |
1000 | if (x86_quirks->arch_pre_intr_init) { | 1001 | if (x86_quirks->arch_pre_intr_init) { |
1001 | if (x86_quirks->arch_pre_intr_init()) | 1002 | if (x86_quirks->arch_pre_intr_init()) |
@@ -1005,7 +1006,7 @@ void __init pre_intr_init_hook(void) | |||
1005 | } | 1006 | } |
1006 | 1007 | ||
1007 | /** | 1008 | /** |
1008 | * intr_init_hook - post gate setup interrupt initialisation | 1009 | * x86_quirk_intr_init - post gate setup interrupt initialisation |
1009 | * | 1010 | * |
1010 | * Description: | 1011 | * Description: |
1011 | * Fill in any interrupts that may have been left out by the general | 1012 | * Fill in any interrupts that may have been left out by the general |
@@ -1013,7 +1014,7 @@ void __init pre_intr_init_hook(void) | |||
1013 | * than the devices on the I/O bus (like APIC interrupts in intel MP | 1014 | * than the devices on the I/O bus (like APIC interrupts in intel MP |
1014 | * systems) are started here. | 1015 | * systems) are started here. |
1015 | **/ | 1016 | **/ |
1016 | void __init intr_init_hook(void) | 1017 | void __init x86_quirk_intr_init(void) |
1017 | { | 1018 | { |
1018 | if (x86_quirks->arch_intr_init) { | 1019 | if (x86_quirks->arch_intr_init) { |
1019 | if (x86_quirks->arch_intr_init()) | 1020 | if (x86_quirks->arch_intr_init()) |
@@ -1022,13 +1023,13 @@ void __init intr_init_hook(void) | |||
1022 | } | 1023 | } |
1023 | 1024 | ||
1024 | /** | 1025 | /** |
1025 | * trap_init_hook - initialise system specific traps | 1026 | * x86_quirk_trap_init - initialise system specific traps |
1026 | * | 1027 | * |
1027 | * Description: | 1028 | * Description: |
1028 | * Called as the final act of trap_init(). Used in VISWS to initialise | 1029 | * Called as the final act of trap_init(). Used in VISWS to initialise |
1029 | * the various board specific APIC traps. | 1030 | * the various board specific APIC traps. |
1030 | **/ | 1031 | **/ |
1031 | void __init trap_init_hook(void) | 1032 | void __init x86_quirk_trap_init(void) |
1032 | { | 1033 | { |
1033 | if (x86_quirks->arch_trap_init) { | 1034 | if (x86_quirks->arch_trap_init) { |
1034 | if (x86_quirks->arch_trap_init()) | 1035 | if (x86_quirks->arch_trap_init()) |
@@ -1044,23 +1045,23 @@ static struct irqaction irq0 = { | |||
1044 | }; | 1045 | }; |
1045 | 1046 | ||
1046 | /** | 1047 | /** |
1047 | * pre_time_init_hook - do any specific initialisations before. | 1048 | * x86_quirk_pre_time_init - do any specific initialisations before. |
1048 | * | 1049 | * |
1049 | **/ | 1050 | **/ |
1050 | void __init pre_time_init_hook(void) | 1051 | void __init x86_quirk_pre_time_init(void) |
1051 | { | 1052 | { |
1052 | if (x86_quirks->arch_pre_time_init) | 1053 | if (x86_quirks->arch_pre_time_init) |
1053 | x86_quirks->arch_pre_time_init(); | 1054 | x86_quirks->arch_pre_time_init(); |
1054 | } | 1055 | } |
1055 | 1056 | ||
1056 | /** | 1057 | /** |
1057 | * time_init_hook - do any specific initialisations for the system timer. | 1058 | * x86_quirk_time_init - do any specific initialisations for the system timer. |
1058 | * | 1059 | * |
1059 | * Description: | 1060 | * Description: |
1060 | * Must plug the system timer interrupt source at HZ into the IRQ listed | 1061 | * Must plug the system timer interrupt source at HZ into the IRQ listed |
1061 | * in irq_vectors.h:TIMER_IRQ | 1062 | * in irq_vectors.h:TIMER_IRQ |
1062 | **/ | 1063 | **/ |
1063 | void __init time_init_hook(void) | 1064 | void __init x86_quirk_time_init(void) |
1064 | { | 1065 | { |
1065 | if (x86_quirks->arch_time_init) { | 1066 | if (x86_quirks->arch_time_init) { |
1066 | /* | 1067 | /* |
diff --git a/arch/x86/kernel/time_32.c b/arch/x86/kernel/time_32.c index 764c74e871f..5c5d87f0b2e 100644 --- a/arch/x86/kernel/time_32.c +++ b/arch/x86/kernel/time_32.c | |||
@@ -33,7 +33,7 @@ | |||
33 | #include <linux/time.h> | 33 | #include <linux/time.h> |
34 | #include <linux/mca.h> | 34 | #include <linux/mca.h> |
35 | 35 | ||
36 | #include <asm/arch_hooks.h> | 36 | #include <asm/setup.h> |
37 | #include <asm/hpet.h> | 37 | #include <asm/hpet.h> |
38 | #include <asm/time.h> | 38 | #include <asm/time.h> |
39 | #include <asm/timer.h> | 39 | #include <asm/timer.h> |
@@ -118,7 +118,7 @@ void __init hpet_time_init(void) | |||
118 | { | 118 | { |
119 | if (!hpet_enable()) | 119 | if (!hpet_enable()) |
120 | setup_pit_timer(); | 120 | setup_pit_timer(); |
121 | time_init_hook(); | 121 | x86_quirk_time_init(); |
122 | } | 122 | } |
123 | 123 | ||
124 | /* | 124 | /* |
@@ -131,7 +131,7 @@ void __init hpet_time_init(void) | |||
131 | */ | 131 | */ |
132 | void __init time_init(void) | 132 | void __init time_init(void) |
133 | { | 133 | { |
134 | pre_time_init_hook(); | 134 | x86_quirk_pre_time_init(); |
135 | tsc_init(); | 135 | tsc_init(); |
136 | late_time_init = choose_time_init(); | 136 | late_time_init = choose_time_init(); |
137 | } | 137 | } |
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index acb8c0585ab..c8c0a7e530b 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c | |||
@@ -61,7 +61,7 @@ | |||
61 | #include <asm/proto.h> | 61 | #include <asm/proto.h> |
62 | #else | 62 | #else |
63 | #include <asm/processor-flags.h> | 63 | #include <asm/processor-flags.h> |
64 | #include <asm/arch_hooks.h> | 64 | #include <asm/setup.h> |
65 | #include <asm/traps.h> | 65 | #include <asm/traps.h> |
66 | 66 | ||
67 | #include "cpu/mcheck/mce.h" | 67 | #include "cpu/mcheck/mce.h" |
@@ -1026,6 +1026,6 @@ void __init trap_init(void) | |||
1026 | cpu_init(); | 1026 | cpu_init(); |
1027 | 1027 | ||
1028 | #ifdef CONFIG_X86_32 | 1028 | #ifdef CONFIG_X86_32 |
1029 | trap_init_hook(); | 1029 | x86_quirk_trap_init(); |
1030 | #endif | 1030 | #endif |
1031 | } | 1031 | } |
diff --git a/arch/x86/kernel/visws_quirks.c b/arch/x86/kernel/visws_quirks.c index 34199d30ff4..191a876e9e8 100644 --- a/arch/x86/kernel/visws_quirks.c +++ b/arch/x86/kernel/visws_quirks.c | |||
@@ -24,7 +24,6 @@ | |||
24 | 24 | ||
25 | #include <asm/visws/cobalt.h> | 25 | #include <asm/visws/cobalt.h> |
26 | #include <asm/visws/piix4.h> | 26 | #include <asm/visws/piix4.h> |
27 | #include <asm/arch_hooks.h> | ||
28 | #include <asm/io_apic.h> | 27 | #include <asm/io_apic.h> |
29 | #include <asm/fixmap.h> | 28 | #include <asm/fixmap.h> |
30 | #include <asm/reboot.h> | 29 | #include <asm/reboot.h> |
diff --git a/arch/x86/kernel/vmiclock_32.c b/arch/x86/kernel/vmiclock_32.c index 8c48b465059..49b4cd6707f 100644 --- a/arch/x86/kernel/vmiclock_32.c +++ b/arch/x86/kernel/vmiclock_32.c | |||
@@ -28,7 +28,6 @@ | |||
28 | 28 | ||
29 | #include <asm/vmi.h> | 29 | #include <asm/vmi.h> |
30 | #include <asm/vmi_time.h> | 30 | #include <asm/vmi_time.h> |
31 | #include <asm/arch_hooks.h> | ||
32 | #include <asm/apicdef.h> | 31 | #include <asm/apicdef.h> |
33 | #include <asm/apic.h> | 32 | #include <asm/apic.h> |
34 | #include <asm/timer.h> | 33 | #include <asm/timer.h> |