diff options
47 files changed, 216 insertions, 119 deletions
diff --git a/arch/x86/ia32/ia32_signal.c b/arch/x86/ia32/ia32_signal.c index b195f85526e..9dabd00e980 100644 --- a/arch/x86/ia32/ia32_signal.c +++ b/arch/x86/ia32/ia32_signal.c | |||
@@ -24,15 +24,14 @@ | |||
24 | #include <asm/ucontext.h> | 24 | #include <asm/ucontext.h> |
25 | #include <asm/uaccess.h> | 25 | #include <asm/uaccess.h> |
26 | #include <asm/i387.h> | 26 | #include <asm/i387.h> |
27 | #include <asm/ia32.h> | ||
28 | #include <asm/ptrace.h> | 27 | #include <asm/ptrace.h> |
29 | #include <asm/ia32_unistd.h> | 28 | #include <asm/ia32_unistd.h> |
30 | #include <asm/user32.h> | 29 | #include <asm/user32.h> |
31 | #include <asm/sigcontext32.h> | 30 | #include <asm/sigcontext32.h> |
32 | #include <asm/proto.h> | 31 | #include <asm/proto.h> |
33 | #include <asm/vdso.h> | 32 | #include <asm/vdso.h> |
34 | |||
35 | #include <asm/sigframe.h> | 33 | #include <asm/sigframe.h> |
34 | #include <asm/sys_ia32.h> | ||
36 | 35 | ||
37 | #define DEBUG_SIG 0 | 36 | #define DEBUG_SIG 0 |
38 | 37 | ||
diff --git a/arch/x86/ia32/ipc32.c b/arch/x86/ia32/ipc32.c index d21991ce606..29cdcd02ead 100644 --- a/arch/x86/ia32/ipc32.c +++ b/arch/x86/ia32/ipc32.c | |||
@@ -8,6 +8,7 @@ | |||
8 | #include <linux/shm.h> | 8 | #include <linux/shm.h> |
9 | #include <linux/ipc.h> | 9 | #include <linux/ipc.h> |
10 | #include <linux/compat.h> | 10 | #include <linux/compat.h> |
11 | #include <asm/sys_ia32.h> | ||
11 | 12 | ||
12 | asmlinkage long sys32_ipc(u32 call, int first, int second, int third, | 13 | asmlinkage long sys32_ipc(u32 call, int first, int second, int third, |
13 | compat_uptr_t ptr, u32 fifth) | 14 | compat_uptr_t ptr, u32 fifth) |
diff --git a/arch/x86/ia32/sys_ia32.c b/arch/x86/ia32/sys_ia32.c index 2e09dcd3c0a..6c0d7f6231a 100644 --- a/arch/x86/ia32/sys_ia32.c +++ b/arch/x86/ia32/sys_ia32.c | |||
@@ -44,8 +44,8 @@ | |||
44 | #include <asm/types.h> | 44 | #include <asm/types.h> |
45 | #include <asm/uaccess.h> | 45 | #include <asm/uaccess.h> |
46 | #include <asm/atomic.h> | 46 | #include <asm/atomic.h> |
47 | #include <asm/ia32.h> | ||
48 | #include <asm/vgtod.h> | 47 | #include <asm/vgtod.h> |
48 | #include <asm/sys_ia32.h> | ||
49 | 49 | ||
50 | #define AA(__x) ((unsigned long)(__x)) | 50 | #define AA(__x) ((unsigned long)(__x)) |
51 | 51 | ||
diff --git a/arch/x86/include/asm/apic.h b/arch/x86/include/asm/apic.h index 25caa0738af..ab1d51a8855 100644 --- a/arch/x86/include/asm/apic.h +++ b/arch/x86/include/asm/apic.h | |||
@@ -54,7 +54,6 @@ extern int disable_apic; | |||
54 | extern int is_vsmp_box(void); | 54 | extern int is_vsmp_box(void); |
55 | extern void xapic_wait_icr_idle(void); | 55 | extern void xapic_wait_icr_idle(void); |
56 | extern u32 safe_xapic_wait_icr_idle(void); | 56 | extern u32 safe_xapic_wait_icr_idle(void); |
57 | extern u64 xapic_icr_read(void); | ||
58 | extern void xapic_icr_write(u32, u32); | 57 | extern void xapic_icr_write(u32, u32); |
59 | extern int setup_profiling_timer(unsigned int); | 58 | extern int setup_profiling_timer(unsigned int); |
60 | 59 | ||
@@ -93,7 +92,7 @@ static inline u32 native_apic_msr_read(u32 reg) | |||
93 | } | 92 | } |
94 | 93 | ||
95 | #ifndef CONFIG_X86_32 | 94 | #ifndef CONFIG_X86_32 |
96 | extern int x2apic, x2apic_preenabled; | 95 | extern int x2apic; |
97 | extern void check_x2apic(void); | 96 | extern void check_x2apic(void); |
98 | extern void enable_x2apic(void); | 97 | extern void enable_x2apic(void); |
99 | extern void enable_IR_x2apic(void); | 98 | extern void enable_IR_x2apic(void); |
diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h index a2e545c91c3..ca5ffb2856b 100644 --- a/arch/x86/include/asm/efi.h +++ b/arch/x86/include/asm/efi.h | |||
@@ -90,6 +90,7 @@ extern void __iomem *efi_ioremap(unsigned long addr, unsigned long size); | |||
90 | 90 | ||
91 | #endif /* CONFIG_X86_32 */ | 91 | #endif /* CONFIG_X86_32 */ |
92 | 92 | ||
93 | extern int add_efi_memmap; | ||
93 | extern void efi_reserve_early(void); | 94 | extern void efi_reserve_early(void); |
94 | extern void efi_call_phys_prelog(void); | 95 | extern void efi_call_phys_prelog(void); |
95 | extern void efi_call_phys_epilog(void); | 96 | extern void efi_call_phys_epilog(void); |
diff --git a/arch/x86/include/asm/mpspec.h b/arch/x86/include/asm/mpspec.h index 91885c28f66..62d14ce3cd0 100644 --- a/arch/x86/include/asm/mpspec.h +++ b/arch/x86/include/asm/mpspec.h | |||
@@ -6,13 +6,13 @@ | |||
6 | #include <asm/mpspec_def.h> | 6 | #include <asm/mpspec_def.h> |
7 | 7 | ||
8 | extern int apic_version[MAX_APICS]; | 8 | extern int apic_version[MAX_APICS]; |
9 | extern int pic_mode; | ||
9 | 10 | ||
10 | #ifdef CONFIG_X86_32 | 11 | #ifdef CONFIG_X86_32 |
11 | #include <mach_mpspec.h> | 12 | #include <mach_mpspec.h> |
12 | 13 | ||
13 | extern unsigned int def_to_bigsmp; | 14 | extern unsigned int def_to_bigsmp; |
14 | extern u8 apicid_2_node[]; | 15 | extern u8 apicid_2_node[]; |
15 | extern int pic_mode; | ||
16 | 16 | ||
17 | #ifdef CONFIG_X86_NUMAQ | 17 | #ifdef CONFIG_X86_NUMAQ |
18 | extern int mp_bus_id_to_node[MAX_MP_BUSSES]; | 18 | extern int mp_bus_id_to_node[MAX_MP_BUSSES]; |
diff --git a/arch/x86/pci/pci.h b/arch/x86/include/asm/pci_x86.h index 1959018aac0..e60fd3e14bd 100644 --- a/arch/x86/pci/pci.h +++ b/arch/x86/include/asm/pci_x86.h | |||
@@ -57,7 +57,8 @@ extern struct pci_ops pci_root_ops; | |||
57 | struct irq_info { | 57 | struct irq_info { |
58 | u8 bus, devfn; /* Bus, device and function */ | 58 | u8 bus, devfn; /* Bus, device and function */ |
59 | struct { | 59 | struct { |
60 | u8 link; /* IRQ line ID, chipset dependent, 0=not routed */ | 60 | u8 link; /* IRQ line ID, chipset dependent, |
61 | 0 = not routed */ | ||
61 | u16 bitmap; /* Available IRQs */ | 62 | u16 bitmap; /* Available IRQs */ |
62 | } __attribute__((packed)) irq[4]; | 63 | } __attribute__((packed)) irq[4]; |
63 | u8 slot; /* Slot number, 0=onboard */ | 64 | u8 slot; /* Slot number, 0=onboard */ |
@@ -69,11 +70,13 @@ struct irq_routing_table { | |||
69 | u16 version; /* PIRQ_VERSION */ | 70 | u16 version; /* PIRQ_VERSION */ |
70 | u16 size; /* Table size in bytes */ | 71 | u16 size; /* Table size in bytes */ |
71 | u8 rtr_bus, rtr_devfn; /* Where the interrupt router lies */ | 72 | u8 rtr_bus, rtr_devfn; /* Where the interrupt router lies */ |
72 | u16 exclusive_irqs; /* IRQs devoted exclusively to PCI usage */ | 73 | u16 exclusive_irqs; /* IRQs devoted exclusively to |
73 | u16 rtr_vendor, rtr_device; /* Vendor and device ID of interrupt router */ | 74 | PCI usage */ |
75 | u16 rtr_vendor, rtr_device; /* Vendor and device ID of | ||
76 | interrupt router */ | ||
74 | u32 miniport_data; /* Crap */ | 77 | u32 miniport_data; /* Crap */ |
75 | u8 rfu[11]; | 78 | u8 rfu[11]; |
76 | u8 checksum; /* Modulo 256 checksum must give zero */ | 79 | u8 checksum; /* Modulo 256 checksum must give 0 */ |
77 | struct irq_info slots[0]; | 80 | struct irq_info slots[0]; |
78 | } __attribute__((packed)); | 81 | } __attribute__((packed)); |
79 | 82 | ||
@@ -148,15 +151,15 @@ static inline unsigned int mmio_config_readl(void __iomem *pos) | |||
148 | 151 | ||
149 | static inline void mmio_config_writeb(void __iomem *pos, u8 val) | 152 | static inline void mmio_config_writeb(void __iomem *pos, u8 val) |
150 | { | 153 | { |
151 | asm volatile("movb %%al,(%1)" :: "a" (val), "r" (pos) : "memory"); | 154 | asm volatile("movb %%al,(%1)" : : "a" (val), "r" (pos) : "memory"); |
152 | } | 155 | } |
153 | 156 | ||
154 | static inline void mmio_config_writew(void __iomem *pos, u16 val) | 157 | static inline void mmio_config_writew(void __iomem *pos, u16 val) |
155 | { | 158 | { |
156 | asm volatile("movw %%ax,(%1)" :: "a" (val), "r" (pos) : "memory"); | 159 | asm volatile("movw %%ax,(%1)" : : "a" (val), "r" (pos) : "memory"); |
157 | } | 160 | } |
158 | 161 | ||
159 | static inline void mmio_config_writel(void __iomem *pos, u32 val) | 162 | static inline void mmio_config_writel(void __iomem *pos, u32 val) |
160 | { | 163 | { |
161 | asm volatile("movl %%eax,(%1)" :: "a" (val), "r" (pos) : "memory"); | 164 | asm volatile("movl %%eax,(%1)" : : "a" (val), "r" (pos) : "memory"); |
162 | } | 165 | } |
diff --git a/arch/x86/include/asm/sys_ia32.h b/arch/x86/include/asm/sys_ia32.h new file mode 100644 index 00000000000..ffb08be2a53 --- /dev/null +++ b/arch/x86/include/asm/sys_ia32.h | |||
@@ -0,0 +1,101 @@ | |||
1 | /* | ||
2 | * sys_ia32.h - Linux ia32 syscall interfaces | ||
3 | * | ||
4 | * Copyright (c) 2008 Jaswinder Singh Rajput | ||
5 | * | ||
6 | * This file is released under the GPLv2. | ||
7 | * See the file COPYING for more details. | ||
8 | */ | ||
9 | |||
10 | #ifndef _ASM_X86_SYS_IA32_H | ||
11 | #define _ASM_X86_SYS_IA32_H | ||
12 | |||
13 | #include <linux/compiler.h> | ||
14 | #include <linux/linkage.h> | ||
15 | #include <linux/types.h> | ||
16 | #include <linux/signal.h> | ||
17 | #include <asm/compat.h> | ||
18 | #include <asm/ia32.h> | ||
19 | |||
20 | /* ia32/sys_ia32.c */ | ||
21 | asmlinkage long sys32_truncate64(char __user *, unsigned long, unsigned long); | ||
22 | asmlinkage long sys32_ftruncate64(unsigned int, unsigned long, unsigned long); | ||
23 | |||
24 | asmlinkage long sys32_stat64(char __user *, struct stat64 __user *); | ||
25 | asmlinkage long sys32_lstat64(char __user *, struct stat64 __user *); | ||
26 | asmlinkage long sys32_fstat64(unsigned int, struct stat64 __user *); | ||
27 | asmlinkage long sys32_fstatat(unsigned int, char __user *, | ||
28 | struct stat64 __user *, int); | ||
29 | struct mmap_arg_struct; | ||
30 | asmlinkage long sys32_mmap(struct mmap_arg_struct __user *); | ||
31 | asmlinkage long sys32_mprotect(unsigned long, size_t, unsigned long); | ||
32 | |||
33 | asmlinkage long sys32_pipe(int __user *); | ||
34 | struct sigaction32; | ||
35 | struct old_sigaction32; | ||
36 | asmlinkage long sys32_rt_sigaction(int, struct sigaction32 __user *, | ||
37 | struct sigaction32 __user *, unsigned int); | ||
38 | asmlinkage long sys32_sigaction(int, struct old_sigaction32 __user *, | ||
39 | struct old_sigaction32 __user *); | ||
40 | asmlinkage long sys32_rt_sigprocmask(int, compat_sigset_t __user *, | ||
41 | compat_sigset_t __user *, unsigned int); | ||
42 | asmlinkage long sys32_alarm(unsigned int); | ||
43 | |||
44 | struct sel_arg_struct; | ||
45 | asmlinkage long sys32_old_select(struct sel_arg_struct __user *); | ||
46 | asmlinkage long sys32_waitpid(compat_pid_t, unsigned int *, int); | ||
47 | asmlinkage long sys32_sysfs(int, u32, u32); | ||
48 | |||
49 | asmlinkage long sys32_sched_rr_get_interval(compat_pid_t, | ||
50 | struct compat_timespec __user *); | ||
51 | asmlinkage long sys32_rt_sigpending(compat_sigset_t __user *, compat_size_t); | ||
52 | asmlinkage long sys32_rt_sigqueueinfo(int, int, compat_siginfo_t __user *); | ||
53 | |||
54 | #ifdef CONFIG_SYSCTL_SYSCALL | ||
55 | struct sysctl_ia32; | ||
56 | asmlinkage long sys32_sysctl(struct sysctl_ia32 __user *); | ||
57 | #endif | ||
58 | |||
59 | asmlinkage long sys32_pread(unsigned int, char __user *, u32, u32, u32); | ||
60 | asmlinkage long sys32_pwrite(unsigned int, char __user *, u32, u32, u32); | ||
61 | |||
62 | asmlinkage long sys32_personality(unsigned long); | ||
63 | asmlinkage long sys32_sendfile(int, int, compat_off_t __user *, s32); | ||
64 | |||
65 | asmlinkage long sys32_mmap2(unsigned long, unsigned long, unsigned long, | ||
66 | unsigned long, unsigned long, unsigned long); | ||
67 | |||
68 | struct oldold_utsname; | ||
69 | struct old_utsname; | ||
70 | asmlinkage long sys32_olduname(struct oldold_utsname __user *); | ||
71 | long sys32_uname(struct old_utsname __user *); | ||
72 | |||
73 | long sys32_ustat(unsigned, struct ustat32 __user *); | ||
74 | |||
75 | asmlinkage long sys32_execve(char __user *, compat_uptr_t __user *, | ||
76 | compat_uptr_t __user *, struct pt_regs *); | ||
77 | asmlinkage long sys32_clone(unsigned int, unsigned int, struct pt_regs *); | ||
78 | |||
79 | long sys32_lseek(unsigned int, int, unsigned int); | ||
80 | long sys32_kill(int, int); | ||
81 | long sys32_fadvise64_64(int, __u32, __u32, __u32, __u32, int); | ||
82 | long sys32_vm86_warning(void); | ||
83 | long sys32_lookup_dcookie(u32, u32, char __user *, size_t); | ||
84 | |||
85 | asmlinkage ssize_t sys32_readahead(int, unsigned, unsigned, size_t); | ||
86 | asmlinkage long sys32_sync_file_range(int, unsigned, unsigned, | ||
87 | unsigned, unsigned, int); | ||
88 | asmlinkage long sys32_fadvise64(int, unsigned, unsigned, size_t, int); | ||
89 | asmlinkage long sys32_fallocate(int, int, unsigned, | ||
90 | unsigned, unsigned, unsigned); | ||
91 | |||
92 | /* ia32/ia32_signal.c */ | ||
93 | asmlinkage long sys32_sigsuspend(int, int, old_sigset_t); | ||
94 | asmlinkage long sys32_sigaltstack(const stack_ia32_t __user *, | ||
95 | stack_ia32_t __user *, struct pt_regs *); | ||
96 | asmlinkage long sys32_sigreturn(struct pt_regs *); | ||
97 | asmlinkage long sys32_rt_sigreturn(struct pt_regs *); | ||
98 | |||
99 | /* ia32/ipc32.c */ | ||
100 | asmlinkage long sys32_ipc(u32, int, int, int, compat_uptr_t, u32); | ||
101 | #endif /* _ASM_X86_SYS_IA32_H */ | ||
diff --git a/arch/x86/include/asm/uv/uv_bau.h b/arch/x86/include/asm/uv/uv_bau.h index e2363253bbb..50423c7b56b 100644 --- a/arch/x86/include/asm/uv/uv_bau.h +++ b/arch/x86/include/asm/uv/uv_bau.h | |||
@@ -133,61 +133,61 @@ struct bau_msg_payload { | |||
133 | * see table 4.2.3.0.1 in broacast_assist spec. | 133 | * see table 4.2.3.0.1 in broacast_assist spec. |
134 | */ | 134 | */ |
135 | struct bau_msg_header { | 135 | struct bau_msg_header { |
136 | int dest_subnodeid:6; /* must be zero */ | 136 | unsigned int dest_subnodeid:6; /* must be zero */ |
137 | /* bits 5:0 */ | 137 | /* bits 5:0 */ |
138 | int base_dest_nodeid:15; /* nasid>>1 (pnode) of first bit in node_map */ | 138 | unsigned int base_dest_nodeid:15; /* nasid>>1 (pnode) of */ |
139 | /* bits 20:6 */ | 139 | /* bits 20:6 */ /* first bit in node_map */ |
140 | int command:8; /* message type */ | 140 | unsigned int command:8; /* message type */ |
141 | /* bits 28:21 */ | 141 | /* bits 28:21 */ |
142 | /* 0x38: SN3net EndPoint Message */ | 142 | /* 0x38: SN3net EndPoint Message */ |
143 | int rsvd_1:3; /* must be zero */ | 143 | unsigned int rsvd_1:3; /* must be zero */ |
144 | /* bits 31:29 */ | 144 | /* bits 31:29 */ |
145 | /* int will align on 32 bits */ | 145 | /* int will align on 32 bits */ |
146 | int rsvd_2:9; /* must be zero */ | 146 | unsigned int rsvd_2:9; /* must be zero */ |
147 | /* bits 40:32 */ | 147 | /* bits 40:32 */ |
148 | /* Suppl_A is 56-41 */ | 148 | /* Suppl_A is 56-41 */ |
149 | int payload_2a:8; /* becomes byte 16 of msg */ | 149 | unsigned int payload_2a:8;/* becomes byte 16 of msg */ |
150 | /* bits 48:41 */ /* not currently using */ | 150 | /* bits 48:41 */ /* not currently using */ |
151 | int payload_2b:8; /* becomes byte 17 of msg */ | 151 | unsigned int payload_2b:8;/* becomes byte 17 of msg */ |
152 | /* bits 56:49 */ /* not currently using */ | 152 | /* bits 56:49 */ /* not currently using */ |
153 | /* Address field (96:57) is never used as an | 153 | /* Address field (96:57) is never used as an |
154 | address (these are address bits 42:3) */ | 154 | address (these are address bits 42:3) */ |
155 | int rsvd_3:1; /* must be zero */ | 155 | unsigned int rsvd_3:1; /* must be zero */ |
156 | /* bit 57 */ | 156 | /* bit 57 */ |
157 | /* address bits 27:4 are payload */ | 157 | /* address bits 27:4 are payload */ |
158 | /* these 24 bits become bytes 12-14 of msg */ | 158 | /* these 24 bits become bytes 12-14 of msg */ |
159 | int replied_to:1; /* sent as 0 by the source to byte 12 */ | 159 | unsigned int replied_to:1;/* sent as 0 by the source to byte 12 */ |
160 | /* bit 58 */ | 160 | /* bit 58 */ |
161 | 161 | ||
162 | int payload_1a:5; /* not currently used */ | 162 | unsigned int payload_1a:5;/* not currently used */ |
163 | /* bits 63:59 */ | 163 | /* bits 63:59 */ |
164 | int payload_1b:8; /* not currently used */ | 164 | unsigned int payload_1b:8;/* not currently used */ |
165 | /* bits 71:64 */ | 165 | /* bits 71:64 */ |
166 | int payload_1c:8; /* not currently used */ | 166 | unsigned int payload_1c:8;/* not currently used */ |
167 | /* bits 79:72 */ | 167 | /* bits 79:72 */ |
168 | int payload_1d:2; /* not currently used */ | 168 | unsigned int payload_1d:2;/* not currently used */ |
169 | /* bits 81:80 */ | 169 | /* bits 81:80 */ |
170 | 170 | ||
171 | int rsvd_4:7; /* must be zero */ | 171 | unsigned int rsvd_4:7; /* must be zero */ |
172 | /* bits 88:82 */ | 172 | /* bits 88:82 */ |
173 | int sw_ack_flag:1; /* software acknowledge flag */ | 173 | unsigned int sw_ack_flag:1;/* software acknowledge flag */ |
174 | /* bit 89 */ | 174 | /* bit 89 */ |
175 | /* INTD trasactions at destination are to | 175 | /* INTD trasactions at destination are to |
176 | wait for software acknowledge */ | 176 | wait for software acknowledge */ |
177 | int rsvd_5:6; /* must be zero */ | 177 | unsigned int rsvd_5:6; /* must be zero */ |
178 | /* bits 95:90 */ | 178 | /* bits 95:90 */ |
179 | int rsvd_6:5; /* must be zero */ | 179 | unsigned int rsvd_6:5; /* must be zero */ |
180 | /* bits 100:96 */ | 180 | /* bits 100:96 */ |
181 | int int_both:1; /* if 1, interrupt both sockets on the blade */ | 181 | unsigned int int_both:1;/* if 1, interrupt both sockets on the blade */ |
182 | /* bit 101*/ | 182 | /* bit 101*/ |
183 | int fairness:3; /* usually zero */ | 183 | unsigned int fairness:3;/* usually zero */ |
184 | /* bits 104:102 */ | 184 | /* bits 104:102 */ |
185 | int multilevel:1; /* multi-level multicast format */ | 185 | unsigned int multilevel:1; /* multi-level multicast format */ |
186 | /* bit 105 */ | 186 | /* bit 105 */ |
187 | /* 0 for TLB: endpoint multi-unicast messages */ | 187 | /* 0 for TLB: endpoint multi-unicast messages */ |
188 | int chaining:1; /* next descriptor is part of this activation*/ | 188 | unsigned int chaining:1;/* next descriptor is part of this activation*/ |
189 | /* bit 106 */ | 189 | /* bit 106 */ |
190 | int rsvd_7:21; /* must be zero */ | 190 | unsigned int rsvd_7:21; /* must be zero */ |
191 | /* bits 127:107 */ | 191 | /* bits 127:107 */ |
192 | }; | 192 | }; |
193 | 193 | ||
diff --git a/arch/x86/kernel/amd_iommu.c b/arch/x86/kernel/amd_iommu.c index 2e2da717b35..658e29e0f49 100644 --- a/arch/x86/kernel/amd_iommu.c +++ b/arch/x86/kernel/amd_iommu.c | |||
@@ -1296,7 +1296,7 @@ static int amd_iommu_dma_supported(struct device *dev, u64 mask) | |||
1296 | * we don't need to preallocate the protection domains anymore. | 1296 | * we don't need to preallocate the protection domains anymore. |
1297 | * For now we have to. | 1297 | * For now we have to. |
1298 | */ | 1298 | */ |
1299 | void prealloc_protection_domains(void) | 1299 | static void prealloc_protection_domains(void) |
1300 | { | 1300 | { |
1301 | struct pci_dev *dev = NULL; | 1301 | struct pci_dev *dev = NULL; |
1302 | struct dma_ops_domain *dma_dom; | 1302 | struct dma_ops_domain *dma_dom; |
diff --git a/arch/x86/kernel/amd_iommu_init.c b/arch/x86/kernel/amd_iommu_init.c index c625800c55c..fb85e8d466c 100644 --- a/arch/x86/kernel/amd_iommu_init.c +++ b/arch/x86/kernel/amd_iommu_init.c | |||
@@ -243,7 +243,7 @@ static void __init iommu_feature_disable(struct amd_iommu *iommu, u8 bit) | |||
243 | } | 243 | } |
244 | 244 | ||
245 | /* Function to enable the hardware */ | 245 | /* Function to enable the hardware */ |
246 | void __init iommu_enable(struct amd_iommu *iommu) | 246 | static void __init iommu_enable(struct amd_iommu *iommu) |
247 | { | 247 | { |
248 | printk(KERN_INFO "AMD IOMMU: Enabling IOMMU " | 248 | printk(KERN_INFO "AMD IOMMU: Enabling IOMMU " |
249 | "at %02x:%02x.%x cap 0x%hx\n", | 249 | "at %02x:%02x.%x cap 0x%hx\n", |
@@ -256,7 +256,7 @@ void __init iommu_enable(struct amd_iommu *iommu) | |||
256 | } | 256 | } |
257 | 257 | ||
258 | /* Function to enable IOMMU event logging and event interrupts */ | 258 | /* Function to enable IOMMU event logging and event interrupts */ |
259 | void __init iommu_enable_event_logging(struct amd_iommu *iommu) | 259 | static void __init iommu_enable_event_logging(struct amd_iommu *iommu) |
260 | { | 260 | { |
261 | iommu_feature_enable(iommu, CONTROL_EVT_LOG_EN); | 261 | iommu_feature_enable(iommu, CONTROL_EVT_LOG_EN); |
262 | iommu_feature_enable(iommu, CONTROL_EVT_INT_EN); | 262 | iommu_feature_enable(iommu, CONTROL_EVT_INT_EN); |
diff --git a/arch/x86/kernel/apic.c b/arch/x86/kernel/apic.c index 6b7f824db16..d652515e285 100644 --- a/arch/x86/kernel/apic.c +++ b/arch/x86/kernel/apic.c | |||
@@ -98,8 +98,8 @@ __setup("apicpmtimer", setup_apicpmtimer); | |||
98 | #ifdef HAVE_X2APIC | 98 | #ifdef HAVE_X2APIC |
99 | int x2apic; | 99 | int x2apic; |
100 | /* x2apic enabled before OS handover */ | 100 | /* x2apic enabled before OS handover */ |
101 | int x2apic_preenabled; | 101 | static int x2apic_preenabled; |
102 | int disable_x2apic; | 102 | static int disable_x2apic; |
103 | static __init int setup_nox2apic(char *str) | 103 | static __init int setup_nox2apic(char *str) |
104 | { | 104 | { |
105 | disable_x2apic = 1; | 105 | disable_x2apic = 1; |
@@ -226,7 +226,7 @@ void xapic_icr_write(u32 low, u32 id) | |||
226 | apic_write(APIC_ICR, low); | 226 | apic_write(APIC_ICR, low); |
227 | } | 227 | } |
228 | 228 | ||
229 | u64 xapic_icr_read(void) | 229 | static u64 xapic_icr_read(void) |
230 | { | 230 | { |
231 | u32 icr1, icr2; | 231 | u32 icr1, icr2; |
232 | 232 | ||
@@ -266,7 +266,7 @@ void x2apic_icr_write(u32 low, u32 id) | |||
266 | wrmsrl(APIC_BASE_MSR + (APIC_ICR >> 4), ((__u64) id) << 32 | low); | 266 | wrmsrl(APIC_BASE_MSR + (APIC_ICR >> 4), ((__u64) id) << 32 | low); |
267 | } | 267 | } |
268 | 268 | ||
269 | u64 x2apic_icr_read(void) | 269 | static u64 x2apic_icr_read(void) |
270 | { | 270 | { |
271 | unsigned long val; | 271 | unsigned long val; |
272 | 272 | ||
diff --git a/arch/x86/kernel/bios_uv.c b/arch/x86/kernel/bios_uv.c index 2a0a2a3cac2..f63882728d9 100644 --- a/arch/x86/kernel/bios_uv.c +++ b/arch/x86/kernel/bios_uv.c | |||
@@ -25,7 +25,7 @@ | |||
25 | #include <asm/uv/bios.h> | 25 | #include <asm/uv/bios.h> |
26 | #include <asm/uv/uv_hub.h> | 26 | #include <asm/uv/uv_hub.h> |
27 | 27 | ||
28 | struct uv_systab uv_systab; | 28 | static struct uv_systab uv_systab; |
29 | 29 | ||
30 | s64 uv_bios_call(enum uv_bios_cmd which, u64 a1, u64 a2, u64 a3, u64 a4, u64 a5) | 30 | s64 uv_bios_call(enum uv_bios_cmd which, u64 a1, u64 a2, u64 a3, u64 a4, u64 a5) |
31 | { | 31 | { |
diff --git a/arch/x86/kernel/cpu/mtrr/main.c b/arch/x86/kernel/cpu/mtrr/main.c index d6ec7ec3027..d259e5d2e05 100644 --- a/arch/x86/kernel/cpu/mtrr/main.c +++ b/arch/x86/kernel/cpu/mtrr/main.c | |||
@@ -824,16 +824,14 @@ static int enable_mtrr_cleanup __initdata = | |||
824 | 824 | ||
825 | static int __init disable_mtrr_cleanup_setup(char *str) | 825 | static int __init disable_mtrr_cleanup_setup(char *str) |
826 | { | 826 | { |
827 | if (enable_mtrr_cleanup != -1) | 827 | enable_mtrr_cleanup = 0; |
828 | enable_mtrr_cleanup = 0; | ||
829 | return 0; | 828 | return 0; |
830 | } | 829 | } |
831 | early_param("disable_mtrr_cleanup", disable_mtrr_cleanup_setup); | 830 | early_param("disable_mtrr_cleanup", disable_mtrr_cleanup_setup); |
832 | 831 | ||
833 | static int __init enable_mtrr_cleanup_setup(char *str) | 832 | static int __init enable_mtrr_cleanup_setup(char *str) |
834 | { | 833 | { |
835 | if (enable_mtrr_cleanup != -1) | 834 | enable_mtrr_cleanup = 1; |
836 | enable_mtrr_cleanup = 1; | ||
837 | return 0; | 835 | return 0; |
838 | } | 836 | } |
839 | early_param("enable_mtrr_cleanup", enable_mtrr_cleanup_setup); | 837 | early_param("enable_mtrr_cleanup", enable_mtrr_cleanup_setup); |
diff --git a/arch/x86/kernel/cpuid.c b/arch/x86/kernel/cpuid.c index 72cefd1e649..85d28d53f5d 100644 --- a/arch/x86/kernel/cpuid.c +++ b/arch/x86/kernel/cpuid.c | |||
@@ -39,10 +39,10 @@ | |||
39 | #include <linux/device.h> | 39 | #include <linux/device.h> |
40 | #include <linux/cpu.h> | 40 | #include <linux/cpu.h> |
41 | #include <linux/notifier.h> | 41 | #include <linux/notifier.h> |
42 | #include <linux/uaccess.h> | ||
42 | 43 | ||
43 | #include <asm/processor.h> | 44 | #include <asm/processor.h> |
44 | #include <asm/msr.h> | 45 | #include <asm/msr.h> |
45 | #include <asm/uaccess.h> | ||
46 | #include <asm/system.h> | 46 | #include <asm/system.h> |
47 | 47 | ||
48 | static struct class *cpuid_class; | 48 | static struct class *cpuid_class; |
@@ -82,7 +82,7 @@ static loff_t cpuid_seek(struct file *file, loff_t offset, int orig) | |||
82 | } | 82 | } |
83 | 83 | ||
84 | static ssize_t cpuid_read(struct file *file, char __user *buf, | 84 | static ssize_t cpuid_read(struct file *file, char __user *buf, |
85 | size_t count, loff_t * ppos) | 85 | size_t count, loff_t *ppos) |
86 | { | 86 | { |
87 | char __user *tmp = buf; | 87 | char __user *tmp = buf; |
88 | struct cpuid_regs cmd; | 88 | struct cpuid_regs cmd; |
@@ -117,7 +117,7 @@ static int cpuid_open(struct inode *inode, struct file *file) | |||
117 | unsigned int cpu; | 117 | unsigned int cpu; |
118 | struct cpuinfo_x86 *c; | 118 | struct cpuinfo_x86 *c; |
119 | int ret = 0; | 119 | int ret = 0; |
120 | 120 | ||
121 | lock_kernel(); | 121 | lock_kernel(); |
122 | 122 | ||
123 | cpu = iminor(file->f_path.dentry->d_inode); | 123 | cpu = iminor(file->f_path.dentry->d_inode); |
diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_printk.c index 23b138e31e9..504ad198e4a 100644 --- a/arch/x86/kernel/early_printk.c +++ b/arch/x86/kernel/early_printk.c | |||
@@ -886,7 +886,7 @@ asmlinkage void early_printk(const char *fmt, ...) | |||
886 | va_list ap; | 886 | va_list ap; |
887 | 887 | ||
888 | va_start(ap, fmt); | 888 | va_start(ap, fmt); |
889 | n = vscnprintf(buf, 512, fmt, ap); | 889 | n = vscnprintf(buf, sizeof(buf), fmt, ap); |
890 | early_console->write(early_console, buf, n); | 890 | early_console->write(early_console, buf, n); |
891 | va_end(ap); | 891 | va_end(ap); |
892 | } | 892 | } |
diff --git a/arch/x86/kernel/genx2apic_phys.c b/arch/x86/kernel/genx2apic_phys.c index 62895cf315f..21bcc0e098b 100644 --- a/arch/x86/kernel/genx2apic_phys.c +++ b/arch/x86/kernel/genx2apic_phys.c | |||
@@ -161,12 +161,12 @@ static unsigned int phys_pkg_id(int index_msb) | |||
161 | return current_cpu_data.initial_apicid >> index_msb; | 161 | return current_cpu_data.initial_apicid >> index_msb; |
162 | } | 162 | } |
163 | 163 | ||
164 | void x2apic_send_IPI_self(int vector) | 164 | static void x2apic_send_IPI_self(int vector) |
165 | { | 165 | { |
166 | apic_write(APIC_SELF_IPI, vector); | 166 | apic_write(APIC_SELF_IPI, vector); |
167 | } | 167 | } |
168 | 168 | ||
169 | void init_x2apic_ldr(void) | 169 | static void init_x2apic_ldr(void) |
170 | { | 170 | { |
171 | return; | 171 | return; |
172 | } | 172 | } |
diff --git a/arch/x86/kernel/io_apic.c b/arch/x86/kernel/io_apic.c index 62ecfc991e1..69911722b9d 100644 --- a/arch/x86/kernel/io_apic.c +++ b/arch/x86/kernel/io_apic.c | |||
@@ -706,7 +706,7 @@ static void __unmask_IO_APIC_irq(struct irq_cfg *cfg) | |||
706 | } | 706 | } |
707 | 707 | ||
708 | #ifdef CONFIG_X86_64 | 708 | #ifdef CONFIG_X86_64 |
709 | void io_apic_sync(struct irq_pin_list *entry) | 709 | static void io_apic_sync(struct irq_pin_list *entry) |
710 | { | 710 | { |
711 | /* | 711 | /* |
712 | * Synchronize the IO-APIC and the CPU by doing | 712 | * Synchronize the IO-APIC and the CPU by doing |
diff --git a/arch/x86/kernel/ldt.c b/arch/x86/kernel/ldt.c index eee32b43fee..71f1d99a635 100644 --- a/arch/x86/kernel/ldt.c +++ b/arch/x86/kernel/ldt.c | |||
@@ -12,8 +12,8 @@ | |||
12 | #include <linux/mm.h> | 12 | #include <linux/mm.h> |
13 | #include <linux/smp.h> | 13 | #include <linux/smp.h> |
14 | #include <linux/vmalloc.h> | 14 | #include <linux/vmalloc.h> |
15 | #include <linux/uaccess.h> | ||
15 | 16 | ||
16 | #include <asm/uaccess.h> | ||
17 | #include <asm/system.h> | 17 | #include <asm/system.h> |
18 | #include <asm/ldt.h> | 18 | #include <asm/ldt.h> |
19 | #include <asm/desc.h> | 19 | #include <asm/desc.h> |
@@ -93,7 +93,7 @@ static inline int copy_ldt(mm_context_t *new, mm_context_t *old) | |||
93 | if (err < 0) | 93 | if (err < 0) |
94 | return err; | 94 | return err; |
95 | 95 | ||
96 | for(i = 0; i < old->size; i++) | 96 | for (i = 0; i < old->size; i++) |
97 | write_ldt_entry(new->ldt, i, old->ldt + i * LDT_ENTRY_SIZE); | 97 | write_ldt_entry(new->ldt, i, old->ldt + i * LDT_ENTRY_SIZE); |
98 | return 0; | 98 | return 0; |
99 | } | 99 | } |
diff --git a/arch/x86/kernel/mmconf-fam10h_64.c b/arch/x86/kernel/mmconf-fam10h_64.c index efc2f361fe8..666e43df51f 100644 --- a/arch/x86/kernel/mmconf-fam10h_64.c +++ b/arch/x86/kernel/mmconf-fam10h_64.c | |||
@@ -13,8 +13,7 @@ | |||
13 | #include <asm/msr.h> | 13 | #include <asm/msr.h> |
14 | #include <asm/acpi.h> | 14 | #include <asm/acpi.h> |
15 | #include <asm/mmconfig.h> | 15 | #include <asm/mmconfig.h> |
16 | 16 | #include <asm/pci_x86.h> | |
17 | #include "../pci/pci.h" | ||
18 | 17 | ||
19 | struct pci_hostbridge_probe { | 18 | struct pci_hostbridge_probe { |
20 | u32 bus; | 19 | u32 bus; |
diff --git a/arch/x86/kernel/mpparse.c b/arch/x86/kernel/mpparse.c index 45e3b69808b..c5c5b8df1db 100644 --- a/arch/x86/kernel/mpparse.c +++ b/arch/x86/kernel/mpparse.c | |||
@@ -16,14 +16,14 @@ | |||
16 | #include <linux/bitops.h> | 16 | #include <linux/bitops.h> |
17 | #include <linux/acpi.h> | 17 | #include <linux/acpi.h> |
18 | #include <linux/module.h> | 18 | #include <linux/module.h> |
19 | #include <linux/smp.h> | ||
20 | #include <linux/acpi.h> | ||
19 | 21 | ||
20 | #include <asm/smp.h> | ||
21 | #include <asm/mtrr.h> | 22 | #include <asm/mtrr.h> |
22 | #include <asm/mpspec.h> | 23 | #include <asm/mpspec.h> |
23 | #include <asm/pgalloc.h> | 24 | #include <asm/pgalloc.h> |
24 | #include <asm/io_apic.h> | 25 | #include <asm/io_apic.h> |
25 | #include <asm/proto.h> | 26 | #include <asm/proto.h> |
26 | #include <asm/acpi.h> | ||
27 | #include <asm/bios_ebda.h> | 27 | #include <asm/bios_ebda.h> |
28 | #include <asm/e820.h> | 28 | #include <asm/e820.h> |
29 | #include <asm/trampoline.h> | 29 | #include <asm/trampoline.h> |
@@ -95,8 +95,8 @@ static void __init MP_bus_info(struct mpc_config_bus *m) | |||
95 | #endif | 95 | #endif |
96 | 96 | ||
97 | if (strncmp(str, BUSTYPE_ISA, sizeof(BUSTYPE_ISA) - 1) == 0) { | 97 | if (strncmp(str, BUSTYPE_ISA, sizeof(BUSTYPE_ISA) - 1) == 0) { |
98 | set_bit(m->mpc_busid, mp_bus_not_pci); | 98 | set_bit(m->mpc_busid, mp_bus_not_pci); |
99 | #if defined(CONFIG_EISA) || defined (CONFIG_MCA) | 99 | #if defined(CONFIG_EISA) || defined(CONFIG_MCA) |
100 | mp_bus_id_to_type[m->mpc_busid] = MP_BUS_ISA; | 100 | mp_bus_id_to_type[m->mpc_busid] = MP_BUS_ISA; |
101 | #endif | 101 | #endif |
102 | } else if (strncmp(str, BUSTYPE_PCI, sizeof(BUSTYPE_PCI) - 1) == 0) { | 102 | } else if (strncmp(str, BUSTYPE_PCI, sizeof(BUSTYPE_PCI) - 1) == 0) { |
@@ -104,7 +104,7 @@ static void __init MP_bus_info(struct mpc_config_bus *m) | |||
104 | x86_quirks->mpc_oem_pci_bus(m); | 104 | x86_quirks->mpc_oem_pci_bus(m); |
105 | 105 | ||
106 | clear_bit(m->mpc_busid, mp_bus_not_pci); | 106 | clear_bit(m->mpc_busid, mp_bus_not_pci); |
107 | #if defined(CONFIG_EISA) || defined (CONFIG_MCA) | 107 | #if defined(CONFIG_EISA) || defined(CONFIG_MCA) |
108 | mp_bus_id_to_type[m->mpc_busid] = MP_BUS_PCI; | 108 | mp_bus_id_to_type[m->mpc_busid] = MP_BUS_PCI; |
109 | } else if (strncmp(str, BUSTYPE_EISA, sizeof(BUSTYPE_EISA) - 1) == 0) { | 109 | } else if (strncmp(str, BUSTYPE_EISA, sizeof(BUSTYPE_EISA) - 1) == 0) { |
110 | mp_bus_id_to_type[m->mpc_busid] = MP_BUS_EISA; | 110 | mp_bus_id_to_type[m->mpc_busid] = MP_BUS_EISA; |
diff --git a/arch/x86/kernel/nmi.c b/arch/x86/kernel/nmi.c index 8bd1bf9622a..45a09ccdc21 100644 --- a/arch/x86/kernel/nmi.c +++ b/arch/x86/kernel/nmi.c | |||
@@ -26,11 +26,10 @@ | |||
26 | #include <linux/kernel_stat.h> | 26 | #include <linux/kernel_stat.h> |
27 | #include <linux/kdebug.h> | 27 | #include <linux/kdebug.h> |
28 | #include <linux/smp.h> | 28 | #include <linux/smp.h> |
29 | #include <linux/nmi.h> | ||
29 | 30 | ||
30 | #include <asm/i8259.h> | 31 | #include <asm/i8259.h> |
31 | #include <asm/io_apic.h> | 32 | #include <asm/io_apic.h> |
32 | #include <asm/smp.h> | ||
33 | #include <asm/nmi.h> | ||
34 | #include <asm/proto.h> | 33 | #include <asm/proto.h> |
35 | #include <asm/timer.h> | 34 | #include <asm/timer.h> |
36 | 35 | ||
diff --git a/arch/x86/kernel/pci-gart_64.c b/arch/x86/kernel/pci-gart_64.c index a35eaa379ff..00c2bcd4146 100644 --- a/arch/x86/kernel/pci-gart_64.c +++ b/arch/x86/kernel/pci-gart_64.c | |||
@@ -52,7 +52,7 @@ static u32 *iommu_gatt_base; /* Remapping table */ | |||
52 | * to trigger bugs with some popular PCI cards, in particular 3ware (but | 52 | * to trigger bugs with some popular PCI cards, in particular 3ware (but |
53 | * has been also also seen with Qlogic at least). | 53 | * has been also also seen with Qlogic at least). |
54 | */ | 54 | */ |
55 | int iommu_fullflush = 1; | 55 | static int iommu_fullflush = 1; |
56 | 56 | ||
57 | /* Allocation bitmap for the remapping area: */ | 57 | /* Allocation bitmap for the remapping area: */ |
58 | static DEFINE_SPINLOCK(iommu_bitmap_lock); | 58 | static DEFINE_SPINLOCK(iommu_bitmap_lock); |
diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c index 39643b1df06..bf088c61fa4 100644 --- a/arch/x86/kernel/reboot.c +++ b/arch/x86/kernel/reboot.c | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <asm/proto.h> | 12 | #include <asm/proto.h> |
13 | #include <asm/reboot_fixups.h> | 13 | #include <asm/reboot_fixups.h> |
14 | #include <asm/reboot.h> | 14 | #include <asm/reboot.h> |
15 | #include <asm/pci_x86.h> | ||
15 | #include <asm/virtext.h> | 16 | #include <asm/virtext.h> |
16 | 17 | ||
17 | #ifdef CONFIG_X86_32 | 18 | #ifdef CONFIG_X86_32 |
@@ -24,7 +25,6 @@ | |||
24 | 25 | ||
25 | #include <mach_ipi.h> | 26 | #include <mach_ipi.h> |
26 | 27 | ||
27 | |||
28 | /* | 28 | /* |
29 | * Power off function, if any | 29 | * Power off function, if any |
30 | */ | 30 | */ |
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index 2d1f4c7e405..ce6650eb64e 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c | |||
@@ -292,8 +292,10 @@ dotraplinkage void do_double_fault(struct pt_regs *regs, long error_code) | |||
292 | tsk->thread.error_code = error_code; | 292 | tsk->thread.error_code = error_code; |
293 | tsk->thread.trap_no = 8; | 293 | tsk->thread.trap_no = 8; |
294 | 294 | ||
295 | /* This is always a kernel trap and never fixable (and thus must | 295 | /* |
296 | never return). */ | 296 | * This is always a kernel trap and never fixable (and thus must |
297 | * never return). | ||
298 | */ | ||
297 | for (;;) | 299 | for (;;) |
298 | die(str, regs, error_code); | 300 | die(str, regs, error_code); |
299 | } | 301 | } |
@@ -520,9 +522,11 @@ dotraplinkage void __kprobes do_int3(struct pt_regs *regs, long error_code) | |||
520 | } | 522 | } |
521 | 523 | ||
522 | #ifdef CONFIG_X86_64 | 524 | #ifdef CONFIG_X86_64 |
523 | /* Help handler running on IST stack to switch back to user stack | 525 | /* |
524 | for scheduling or signal handling. The actual stack switch is done in | 526 | * Help handler running on IST stack to switch back to user stack |
525 | entry.S */ | 527 | * for scheduling or signal handling. The actual stack switch is done in |
528 | * entry.S | ||
529 | */ | ||
526 | asmlinkage __kprobes struct pt_regs *sync_regs(struct pt_regs *eregs) | 530 | asmlinkage __kprobes struct pt_regs *sync_regs(struct pt_regs *eregs) |
527 | { | 531 | { |
528 | struct pt_regs *regs = eregs; | 532 | struct pt_regs *regs = eregs; |
@@ -532,8 +536,10 @@ asmlinkage __kprobes struct pt_regs *sync_regs(struct pt_regs *eregs) | |||
532 | /* Exception from user space */ | 536 | /* Exception from user space */ |
533 | else if (user_mode(eregs)) | 537 | else if (user_mode(eregs)) |
534 | regs = task_pt_regs(current); | 538 | regs = task_pt_regs(current); |
535 | /* Exception from kernel and interrupts are enabled. Move to | 539 | /* |
536 | kernel process stack. */ | 540 | * Exception from kernel and interrupts are enabled. Move to |
541 | * kernel process stack. | ||
542 | */ | ||
537 | else if (eregs->flags & X86_EFLAGS_IF) | 543 | else if (eregs->flags & X86_EFLAGS_IF) |
538 | regs = (struct pt_regs *)(eregs->sp -= sizeof(struct pt_regs)); | 544 | regs = (struct pt_regs *)(eregs->sp -= sizeof(struct pt_regs)); |
539 | if (eregs != regs) | 545 | if (eregs != regs) |
@@ -685,12 +691,7 @@ void math_error(void __user *ip) | |||
685 | cwd = get_fpu_cwd(task); | 691 | cwd = get_fpu_cwd(task); |
686 | swd = get_fpu_swd(task); | 692 | swd = get_fpu_swd(task); |
687 | 693 | ||
688 | err = swd & ~cwd & 0x3f; | 694 | err = swd & ~cwd; |
689 | |||
690 | #ifdef CONFIG_X86_32 | ||
691 | if (!err) | ||
692 | return; | ||
693 | #endif | ||
694 | 695 | ||
695 | if (err & 0x001) { /* Invalid op */ | 696 | if (err & 0x001) { /* Invalid op */ |
696 | /* | 697 | /* |
@@ -708,7 +709,11 @@ void math_error(void __user *ip) | |||
708 | } else if (err & 0x020) { /* Precision */ | 709 | } else if (err & 0x020) { /* Precision */ |
709 | info.si_code = FPE_FLTRES; | 710 | info.si_code = FPE_FLTRES; |
710 | } else { | 711 | } else { |
711 | info.si_code = __SI_FAULT|SI_KERNEL; /* WTF? */ | 712 | /* |
713 | * If we're using IRQ 13, or supposedly even some trap 16 | ||
714 | * implementations, it's possible we get a spurious trap... | ||
715 | */ | ||
716 | return; /* Spurious trap, no error */ | ||
712 | } | 717 | } |
713 | force_sig_info(SIGFPE, &info, task); | 718 | force_sig_info(SIGFPE, &info, task); |
714 | } | 719 | } |
diff --git a/arch/x86/kernel/xsave.c b/arch/x86/kernel/xsave.c index 15c3e699918..2b54fe002e9 100644 --- a/arch/x86/kernel/xsave.c +++ b/arch/x86/kernel/xsave.c | |||
@@ -159,7 +159,7 @@ int save_i387_xstate(void __user *buf) | |||
159 | * Restore the extended state if present. Otherwise, restore the FP/SSE | 159 | * Restore the extended state if present. Otherwise, restore the FP/SSE |
160 | * state. | 160 | * state. |
161 | */ | 161 | */ |
162 | int restore_user_xstate(void __user *buf) | 162 | static int restore_user_xstate(void __user *buf) |
163 | { | 163 | { |
164 | struct _fpx_sw_bytes fx_sw_user; | 164 | struct _fpx_sw_bytes fx_sw_user; |
165 | u64 mask; | 165 | u64 mask; |
diff --git a/arch/x86/mach-default/setup.c b/arch/x86/mach-default/setup.c index 37b9ae4d44c..df167f26562 100644 --- a/arch/x86/mach-default/setup.c +++ b/arch/x86/mach-default/setup.c | |||
@@ -133,29 +133,28 @@ void __init time_init_hook(void) | |||
133 | **/ | 133 | **/ |
134 | void mca_nmi_hook(void) | 134 | void mca_nmi_hook(void) |
135 | { | 135 | { |
136 | /* If I recall correctly, there's a whole bunch of other things that | 136 | /* |
137 | * If I recall correctly, there's a whole bunch of other things that | ||
137 | * we can do to check for NMI problems, but that's all I know about | 138 | * we can do to check for NMI problems, but that's all I know about |
138 | * at the moment. | 139 | * at the moment. |
139 | */ | 140 | */ |
140 | 141 | pr_warning("NMI generated from unknown source!\n"); | |
141 | printk("NMI generated from unknown source!\n"); | ||
142 | } | 142 | } |
143 | #endif | 143 | #endif |
144 | 144 | ||
145 | static __init int no_ipi_broadcast(char *str) | 145 | static __init int no_ipi_broadcast(char *str) |
146 | { | 146 | { |
147 | get_option(&str, &no_broadcast); | 147 | get_option(&str, &no_broadcast); |
148 | printk ("Using %s mode\n", no_broadcast ? "No IPI Broadcast" : | 148 | pr_info("Using %s mode\n", |
149 | "IPI Broadcast"); | 149 | no_broadcast ? "No IPI Broadcast" : "IPI Broadcast"); |
150 | return 1; | 150 | return 1; |
151 | } | 151 | } |
152 | |||
153 | __setup("no_ipi_broadcast=", no_ipi_broadcast); | 152 | __setup("no_ipi_broadcast=", no_ipi_broadcast); |
154 | 153 | ||
155 | static int __init print_ipi_mode(void) | 154 | static int __init print_ipi_mode(void) |
156 | { | 155 | { |
157 | printk ("Using IPI %s mode\n", no_broadcast ? "No-Shortcut" : | 156 | pr_info("Using IPI %s mode\n", |
158 | "Shortcut"); | 157 | no_broadcast ? "No-Shortcut" : "Shortcut"); |
159 | return 0; | 158 | return 0; |
160 | } | 159 | } |
161 | 160 | ||
diff --git a/arch/x86/pci/acpi.c b/arch/x86/pci/acpi.c index 1d88d2b3977..9e5752fe4d1 100644 --- a/arch/x86/pci/acpi.c +++ b/arch/x86/pci/acpi.c | |||
@@ -4,7 +4,7 @@ | |||
4 | #include <linux/irq.h> | 4 | #include <linux/irq.h> |
5 | #include <linux/dmi.h> | 5 | #include <linux/dmi.h> |
6 | #include <asm/numa.h> | 6 | #include <asm/numa.h> |
7 | #include "pci.h" | 7 | #include <asm/pci_x86.h> |
8 | 8 | ||
9 | struct pci_root_info { | 9 | struct pci_root_info { |
10 | char *name; | 10 | char *name; |
diff --git a/arch/x86/pci/amd_bus.c b/arch/x86/pci/amd_bus.c index 22e057665e5..9bb09823b36 100644 --- a/arch/x86/pci/amd_bus.c +++ b/arch/x86/pci/amd_bus.c | |||
@@ -2,7 +2,7 @@ | |||
2 | #include <linux/pci.h> | 2 | #include <linux/pci.h> |
3 | #include <linux/topology.h> | 3 | #include <linux/topology.h> |
4 | #include <linux/cpu.h> | 4 | #include <linux/cpu.h> |
5 | #include "pci.h" | 5 | #include <asm/pci_x86.h> |
6 | 6 | ||
7 | #ifdef CONFIG_X86_64 | 7 | #ifdef CONFIG_X86_64 |
8 | #include <asm/pci-direct.h> | 8 | #include <asm/pci-direct.h> |
diff --git a/arch/x86/pci/common.c b/arch/x86/pci/common.c index bb1a01f089e..62ddb73e09e 100644 --- a/arch/x86/pci/common.c +++ b/arch/x86/pci/common.c | |||
@@ -14,8 +14,7 @@ | |||
14 | #include <asm/segment.h> | 14 | #include <asm/segment.h> |
15 | #include <asm/io.h> | 15 | #include <asm/io.h> |
16 | #include <asm/smp.h> | 16 | #include <asm/smp.h> |
17 | 17 | #include <asm/pci_x86.h> | |
18 | #include "pci.h" | ||
19 | 18 | ||
20 | unsigned int pci_probe = PCI_PROBE_BIOS | PCI_PROBE_CONF1 | PCI_PROBE_CONF2 | | 19 | unsigned int pci_probe = PCI_PROBE_BIOS | PCI_PROBE_CONF1 | PCI_PROBE_CONF2 | |
21 | PCI_PROBE_MMCONF; | 20 | PCI_PROBE_MMCONF; |
diff --git a/arch/x86/pci/direct.c b/arch/x86/pci/direct.c index 9a5af6c8fbe..bd13c3e4c6d 100644 --- a/arch/x86/pci/direct.c +++ b/arch/x86/pci/direct.c | |||
@@ -5,7 +5,7 @@ | |||
5 | #include <linux/pci.h> | 5 | #include <linux/pci.h> |
6 | #include <linux/init.h> | 6 | #include <linux/init.h> |
7 | #include <linux/dmi.h> | 7 | #include <linux/dmi.h> |
8 | #include "pci.h" | 8 | #include <asm/pci_x86.h> |
9 | 9 | ||
10 | /* | 10 | /* |
11 | * Functions for accessing PCI base (first 256 bytes) and extended | 11 | * Functions for accessing PCI base (first 256 bytes) and extended |
diff --git a/arch/x86/pci/early.c b/arch/x86/pci/early.c index 86631ccbc25..f6adf2c6d75 100644 --- a/arch/x86/pci/early.c +++ b/arch/x86/pci/early.c | |||
@@ -2,7 +2,7 @@ | |||
2 | #include <linux/pci.h> | 2 | #include <linux/pci.h> |
3 | #include <asm/pci-direct.h> | 3 | #include <asm/pci-direct.h> |
4 | #include <asm/io.h> | 4 | #include <asm/io.h> |
5 | #include "pci.h" | 5 | #include <asm/pci_x86.h> |
6 | 6 | ||
7 | /* Direct PCI access. This is used for PCI accesses in early boot before | 7 | /* Direct PCI access. This is used for PCI accesses in early boot before |
8 | the PCI subsystem works. */ | 8 | the PCI subsystem works. */ |
diff --git a/arch/x86/pci/fixup.c b/arch/x86/pci/fixup.c index 2051dc96b8e..7d388d5cf54 100644 --- a/arch/x86/pci/fixup.c +++ b/arch/x86/pci/fixup.c | |||
@@ -6,8 +6,7 @@ | |||
6 | #include <linux/dmi.h> | 6 | #include <linux/dmi.h> |
7 | #include <linux/pci.h> | 7 | #include <linux/pci.h> |
8 | #include <linux/init.h> | 8 | #include <linux/init.h> |
9 | #include "pci.h" | 9 | #include <asm/pci_x86.h> |
10 | |||
11 | 10 | ||
12 | static void __devinit pci_fixup_i450nx(struct pci_dev *d) | 11 | static void __devinit pci_fixup_i450nx(struct pci_dev *d) |
13 | { | 12 | { |
diff --git a/arch/x86/pci/i386.c b/arch/x86/pci/i386.c index 844df0cbbd3..e51bf2cda4b 100644 --- a/arch/x86/pci/i386.c +++ b/arch/x86/pci/i386.c | |||
@@ -34,8 +34,8 @@ | |||
34 | 34 | ||
35 | #include <asm/pat.h> | 35 | #include <asm/pat.h> |
36 | #include <asm/e820.h> | 36 | #include <asm/e820.h> |
37 | #include <asm/pci_x86.h> | ||
37 | 38 | ||
38 | #include "pci.h" | ||
39 | 39 | ||
40 | static int | 40 | static int |
41 | skip_isa_ioresource_align(struct pci_dev *dev) { | 41 | skip_isa_ioresource_align(struct pci_dev *dev) { |
diff --git a/arch/x86/pci/init.c b/arch/x86/pci/init.c index d6c950f8185..bec3b048e72 100644 --- a/arch/x86/pci/init.c +++ b/arch/x86/pci/init.c | |||
@@ -1,6 +1,6 @@ | |||
1 | #include <linux/pci.h> | 1 | #include <linux/pci.h> |
2 | #include <linux/init.h> | 2 | #include <linux/init.h> |
3 | #include "pci.h" | 3 | #include <asm/pci_x86.h> |
4 | 4 | ||
5 | /* arch_initcall has too random ordering, so call the initializers | 5 | /* arch_initcall has too random ordering, so call the initializers |
6 | in the right sequence from here. */ | 6 | in the right sequence from here. */ |
diff --git a/arch/x86/pci/irq.c b/arch/x86/pci/irq.c index bf69dbe08bf..373b9afe6d4 100644 --- a/arch/x86/pci/irq.c +++ b/arch/x86/pci/irq.c | |||
@@ -16,8 +16,7 @@ | |||
16 | #include <asm/io_apic.h> | 16 | #include <asm/io_apic.h> |
17 | #include <linux/irq.h> | 17 | #include <linux/irq.h> |
18 | #include <linux/acpi.h> | 18 | #include <linux/acpi.h> |
19 | 19 | #include <asm/pci_x86.h> | |
20 | #include "pci.h" | ||
21 | 20 | ||
22 | #define PIRQ_SIGNATURE (('$' << 0) + ('P' << 8) + ('I' << 16) + ('R' << 24)) | 21 | #define PIRQ_SIGNATURE (('$' << 0) + ('P' << 8) + ('I' << 16) + ('R' << 24)) |
23 | #define PIRQ_VERSION 0x0100 | 22 | #define PIRQ_VERSION 0x0100 |
diff --git a/arch/x86/pci/legacy.c b/arch/x86/pci/legacy.c index b722dd481b3..f1065b129e9 100644 --- a/arch/x86/pci/legacy.c +++ b/arch/x86/pci/legacy.c | |||
@@ -3,7 +3,7 @@ | |||
3 | */ | 3 | */ |
4 | #include <linux/init.h> | 4 | #include <linux/init.h> |
5 | #include <linux/pci.h> | 5 | #include <linux/pci.h> |
6 | #include "pci.h" | 6 | #include <asm/pci_x86.h> |
7 | 7 | ||
8 | /* | 8 | /* |
9 | * Discover remaining PCI buses in case there are peer host bridges. | 9 | * Discover remaining PCI buses in case there are peer host bridges. |
diff --git a/arch/x86/pci/mmconfig-shared.c b/arch/x86/pci/mmconfig-shared.c index 654a2234f8f..89bf9242c80 100644 --- a/arch/x86/pci/mmconfig-shared.c +++ b/arch/x86/pci/mmconfig-shared.c | |||
@@ -15,8 +15,7 @@ | |||
15 | #include <linux/acpi.h> | 15 | #include <linux/acpi.h> |
16 | #include <linux/bitmap.h> | 16 | #include <linux/bitmap.h> |
17 | #include <asm/e820.h> | 17 | #include <asm/e820.h> |
18 | 18 | #include <asm/pci_x86.h> | |
19 | #include "pci.h" | ||
20 | 19 | ||
21 | /* aperture is up to 256MB but BIOS may reserve less */ | 20 | /* aperture is up to 256MB but BIOS may reserve less */ |
22 | #define MMCONFIG_APER_MIN (2 * 1024*1024) | 21 | #define MMCONFIG_APER_MIN (2 * 1024*1024) |
diff --git a/arch/x86/pci/mmconfig_32.c b/arch/x86/pci/mmconfig_32.c index f3c761dce69..8b2d561046a 100644 --- a/arch/x86/pci/mmconfig_32.c +++ b/arch/x86/pci/mmconfig_32.c | |||
@@ -13,7 +13,7 @@ | |||
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/acpi.h> | 14 | #include <linux/acpi.h> |
15 | #include <asm/e820.h> | 15 | #include <asm/e820.h> |
16 | #include "pci.h" | 16 | #include <asm/pci_x86.h> |
17 | 17 | ||
18 | /* Assume systems with more busses have correct MCFG */ | 18 | /* Assume systems with more busses have correct MCFG */ |
19 | #define mmcfg_virt_addr ((void __iomem *) fix_to_virt(FIX_PCIE_MCFG)) | 19 | #define mmcfg_virt_addr ((void __iomem *) fix_to_virt(FIX_PCIE_MCFG)) |
diff --git a/arch/x86/pci/mmconfig_64.c b/arch/x86/pci/mmconfig_64.c index a1994163c99..30007ffc8e1 100644 --- a/arch/x86/pci/mmconfig_64.c +++ b/arch/x86/pci/mmconfig_64.c | |||
@@ -10,8 +10,7 @@ | |||
10 | #include <linux/acpi.h> | 10 | #include <linux/acpi.h> |
11 | #include <linux/bitmap.h> | 11 | #include <linux/bitmap.h> |
12 | #include <asm/e820.h> | 12 | #include <asm/e820.h> |
13 | 13 | #include <asm/pci_x86.h> | |
14 | #include "pci.h" | ||
15 | 14 | ||
16 | /* Static virtual mapping of the MMCONFIG aperture */ | 15 | /* Static virtual mapping of the MMCONFIG aperture */ |
17 | struct mmcfg_virt { | 16 | struct mmcfg_virt { |
diff --git a/arch/x86/pci/numaq_32.c b/arch/x86/pci/numaq_32.c index 1177845d318..2089354968a 100644 --- a/arch/x86/pci/numaq_32.c +++ b/arch/x86/pci/numaq_32.c | |||
@@ -7,7 +7,7 @@ | |||
7 | #include <linux/nodemask.h> | 7 | #include <linux/nodemask.h> |
8 | #include <mach_apic.h> | 8 | #include <mach_apic.h> |
9 | #include <asm/mpspec.h> | 9 | #include <asm/mpspec.h> |
10 | #include "pci.h" | 10 | #include <asm/pci_x86.h> |
11 | 11 | ||
12 | #define XQUAD_PORTIO_BASE 0xfe400000 | 12 | #define XQUAD_PORTIO_BASE 0xfe400000 |
13 | #define XQUAD_PORTIO_QUAD 0x40000 /* 256k per quad. */ | 13 | #define XQUAD_PORTIO_QUAD 0x40000 /* 256k per quad. */ |
diff --git a/arch/x86/pci/olpc.c b/arch/x86/pci/olpc.c index e11e9e803d5..b889d824f7c 100644 --- a/arch/x86/pci/olpc.c +++ b/arch/x86/pci/olpc.c | |||
@@ -29,7 +29,7 @@ | |||
29 | #include <linux/init.h> | 29 | #include <linux/init.h> |
30 | #include <asm/olpc.h> | 30 | #include <asm/olpc.h> |
31 | #include <asm/geode.h> | 31 | #include <asm/geode.h> |
32 | #include "pci.h" | 32 | #include <asm/pci_x86.h> |
33 | 33 | ||
34 | /* | 34 | /* |
35 | * In the tables below, the first two line (8 longwords) are the | 35 | * In the tables below, the first two line (8 longwords) are the |
diff --git a/arch/x86/pci/pcbios.c b/arch/x86/pci/pcbios.c index 37472fc6f72..b82cae970df 100644 --- a/arch/x86/pci/pcbios.c +++ b/arch/x86/pci/pcbios.c | |||
@@ -6,9 +6,8 @@ | |||
6 | #include <linux/init.h> | 6 | #include <linux/init.h> |
7 | #include <linux/module.h> | 7 | #include <linux/module.h> |
8 | #include <linux/uaccess.h> | 8 | #include <linux/uaccess.h> |
9 | #include "pci.h" | 9 | #include <asm/pci_x86.h> |
10 | #include "pci-functions.h" | 10 | #include <asm/mach-default/pci-functions.h> |
11 | |||
12 | 11 | ||
13 | /* BIOS32 signature: "_32_" */ | 12 | /* BIOS32 signature: "_32_" */ |
14 | #define BIOS32_SIGNATURE (('_' << 0) + ('3' << 8) + ('2' << 16) + ('_' << 24)) | 13 | #define BIOS32_SIGNATURE (('_' << 0) + ('3' << 8) + ('2' << 16) + ('_' << 24)) |
diff --git a/arch/x86/pci/visws.c b/arch/x86/pci/visws.c index 42f4cb19fac..16d0c0eb0d1 100644 --- a/arch/x86/pci/visws.c +++ b/arch/x86/pci/visws.c | |||
@@ -9,11 +9,10 @@ | |||
9 | #include <linux/init.h> | 9 | #include <linux/init.h> |
10 | 10 | ||
11 | #include <asm/setup.h> | 11 | #include <asm/setup.h> |
12 | #include <asm/pci_x86.h> | ||
12 | #include <asm/visws/cobalt.h> | 13 | #include <asm/visws/cobalt.h> |
13 | #include <asm/visws/lithium.h> | 14 | #include <asm/visws/lithium.h> |
14 | 15 | ||
15 | #include "pci.h" | ||
16 | |||
17 | static int pci_visws_enable_irq(struct pci_dev *dev) { return 0; } | 16 | static int pci_visws_enable_irq(struct pci_dev *dev) { return 0; } |
18 | static void pci_visws_disable_irq(struct pci_dev *dev) { } | 17 | static void pci_visws_disable_irq(struct pci_dev *dev) { } |
19 | 18 | ||
diff --git a/drivers/pci/hotplug/cpqphp_core.c b/drivers/pci/hotplug/cpqphp_core.c index 8514c3a1746..c2e1bcbb28a 100644 --- a/drivers/pci/hotplug/cpqphp_core.c +++ b/drivers/pci/hotplug/cpqphp_core.c | |||
@@ -45,7 +45,7 @@ | |||
45 | 45 | ||
46 | #include "cpqphp.h" | 46 | #include "cpqphp.h" |
47 | #include "cpqphp_nvram.h" | 47 | #include "cpqphp_nvram.h" |
48 | #include "../../../arch/x86/pci/pci.h" /* horrible hack showing how processor dependent we are... */ | 48 | #include <asm/pci_x86.h> |
49 | 49 | ||
50 | 50 | ||
51 | /* Global variables */ | 51 | /* Global variables */ |
diff --git a/drivers/pci/hotplug/cpqphp_pci.c b/drivers/pci/hotplug/cpqphp_pci.c index 09021930589..df146be9d2e 100644 --- a/drivers/pci/hotplug/cpqphp_pci.c +++ b/drivers/pci/hotplug/cpqphp_pci.c | |||
@@ -37,7 +37,7 @@ | |||
37 | #include "../pci.h" | 37 | #include "../pci.h" |
38 | #include "cpqphp.h" | 38 | #include "cpqphp.h" |
39 | #include "cpqphp_nvram.h" | 39 | #include "cpqphp_nvram.h" |
40 | #include "../../../arch/x86/pci/pci.h" /* horrible hack showing how processor dependent we are... */ | 40 | #include <asm/pci_x86.h> |
41 | 41 | ||
42 | 42 | ||
43 | u8 cpqhp_nic_irq; | 43 | u8 cpqhp_nic_irq; |
diff --git a/drivers/pci/hotplug/ibmphp_core.c b/drivers/pci/hotplug/ibmphp_core.c index 633e743442a..dd18f857dfb 100644 --- a/drivers/pci/hotplug/ibmphp_core.c +++ b/drivers/pci/hotplug/ibmphp_core.c | |||
@@ -35,7 +35,7 @@ | |||
35 | #include <linux/delay.h> | 35 | #include <linux/delay.h> |
36 | #include <linux/wait.h> | 36 | #include <linux/wait.h> |
37 | #include "../pci.h" | 37 | #include "../pci.h" |
38 | #include "../../../arch/x86/pci/pci.h" /* for struct irq_routing_table */ | 38 | #include <asm/pci_x86.h> /* for struct irq_routing_table */ |
39 | #include "ibmphp.h" | 39 | #include "ibmphp.h" |
40 | 40 | ||
41 | #define attn_on(sl) ibmphp_hpc_writeslot (sl, HPC_SLOT_ATTNON) | 41 | #define attn_on(sl) ibmphp_hpc_writeslot (sl, HPC_SLOT_ATTNON) |