Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (36 commits)
x86: fix section mismatch warnings in mcheck/mce_amd_64.c
x86: offer frame pointers in all build modes
x86: remove duplicated #include's
x86: k8 numa register active regions later
x86: update Alan Cox's email addresses
x86: rename all fields of mpc_table mpc_X to X
x86: rename all fields of mpc_oemtable oem_X to X
x86: rename all fields of mpc_bus mpc_X to X
x86: rename all fields of mpc_cpu mpc_X to X
x86: rename all fields of mpc_intsrc mpc_X to X
x86: rename all fields of mpc_lintsrc mpc_X to X
x86: rename all fields of mpc_iopic mpc_X to X
x86: irqinit_64.c init_ISA_irqs should be static
Documentation/x86/boot.txt: payload length was changed to payload_length
x86: setup_percpu.c fix style problems
x86: irqinit_64.c fix style problems
x86: irqinit_32.c fix style problems
x86: i8259.c fix style problems
x86: irq_32.c fix style problems
x86: ioport.c fix style problems
...

+362 -398
+1 -1
Documentation/x86/boot.txt
··· 44 44 and KEEP_SEGMENTS flag in load_flags. 45 45 46 46 Protocol 2.08: (Kernel 2.6.26) Added crc32 checksum and ELF format 47 - payload. Introduced payload_offset and payload length 47 + payload. Introduced payload_offset and payload_length 48 48 fields to aid in locating the payload. 49 49 50 50 Protocol 2.09: (Kernel 2.6.26) Added a field of 64-bit physical
+1
arch/x86/Kconfig
··· 27 27 select HAVE_IOREMAP_PROT 28 28 select HAVE_KPROBES 29 29 select ARCH_WANT_OPTIONAL_GPIOLIB 30 + select ARCH_WANT_FRAME_POINTERS 30 31 select HAVE_KRETPROBES 31 32 select HAVE_FTRACE_MCOUNT_RECORD 32 33 select HAVE_DYNAMIC_FTRACE
+1 -2
arch/x86/include/asm/es7000/mpparse.h
··· 10 10 11 11 #ifndef CONFIG_X86_GENERICARCH 12 12 extern int acpi_madt_oem_check(char *oem_id, char *oem_table_id); 13 - extern int mps_oem_check(struct mp_config_table *mpc, char *oem, 14 - char *productid); 13 + extern int mps_oem_check(struct mpc_table *mpc, char *oem, char *productid); 15 14 #endif 16 15 17 16 #ifdef CONFIG_ACPI
+4 -4
arch/x86/include/asm/genapic_32.h
··· 15 15 * Copyright 2003 Andi Kleen, SuSE Labs. 16 16 */ 17 17 18 - struct mpc_config_bus; 19 - struct mp_config_table; 20 - struct mpc_config_processor; 18 + struct mpc_bus; 19 + struct mpc_table; 20 + struct mpc_cpu; 21 21 22 22 struct genapic { 23 23 char *name; ··· 51 51 /* When one of the next two hooks returns 1 the genapic 52 52 is switched to this. Essentially they are additional probe 53 53 functions. */ 54 - int (*mps_oem_check)(struct mp_config_table *mpc, char *oem, 54 + int (*mps_oem_check)(struct mpc_table *mpc, char *oem, 55 55 char *productid); 56 56 int (*acpi_madt_oem_check)(char *oem_id, char *oem_table_id); 57 57
+2 -2
arch/x86/include/asm/mach-default/mach_mpparse.h
··· 1 1 #ifndef _ASM_X86_MACH_DEFAULT_MACH_MPPARSE_H 2 2 #define _ASM_X86_MACH_DEFAULT_MACH_MPPARSE_H 3 3 4 - static inline int mps_oem_check(struct mp_config_table *mpc, char *oem, 5 - char *productid) 4 + static inline int 5 + mps_oem_check(struct mpc_table *mpc, char *oem, char *productid) 6 6 { 7 7 return 0; 8 8 }
+2 -3
arch/x86/include/asm/mach-generic/mach_mpparse.h
··· 2 2 #define _ASM_X86_MACH_GENERIC_MACH_MPPARSE_H 3 3 4 4 5 - extern int mps_oem_check(struct mp_config_table *mpc, char *oem, 6 - char *productid); 5 + extern int mps_oem_check(struct mpc_table *, char *, char *); 7 6 8 - extern int acpi_madt_oem_check(char *oem_id, char *oem_table_id); 7 + extern int acpi_madt_oem_check(char *, char *); 9 8 10 9 #endif /* _ASM_X86_MACH_GENERIC_MACH_MPPARSE_H */
+2 -2
arch/x86/include/asm/mach-generic/mach_mpspec.h
··· 7 7 /* Maximum 256 PCI busses, plus 1 ISA bus in each of 4 cabinets. */ 8 8 #define MAX_MP_BUSSES 260 9 9 10 - extern void numaq_mps_oem_check(struct mp_config_table *mpc, char *oem, 11 - char *productid); 10 + extern void numaq_mps_oem_check(struct mpc_table *, char *, char *); 11 + 12 12 #endif /* _ASM_X86_MACH_GENERIC_MACH_MPSPEC_H */
+51 -51
arch/x86/include/asm/mpspec_def.h
··· 39 39 40 40 #define MPC_SIGNATURE "PCMP" 41 41 42 - struct mp_config_table { 43 - char mpc_signature[4]; 44 - unsigned short mpc_length; /* Size of table */ 45 - char mpc_spec; /* 0x01 */ 46 - char mpc_checksum; 47 - char mpc_oem[8]; 48 - char mpc_productid[12]; 49 - unsigned int mpc_oemptr; /* 0 if not present */ 50 - unsigned short mpc_oemsize; /* 0 if not present */ 51 - unsigned short mpc_oemcount; 52 - unsigned int mpc_lapic; /* APIC address */ 42 + struct mpc_table { 43 + char signature[4]; 44 + unsigned short length; /* Size of table */ 45 + char spec; /* 0x01 */ 46 + char checksum; 47 + char oem[8]; 48 + char productid[12]; 49 + unsigned int oemptr; /* 0 if not present */ 50 + unsigned short oemsize; /* 0 if not present */ 51 + unsigned short oemcount; 52 + unsigned int lapic; /* APIC address */ 53 53 unsigned int reserved; 54 54 }; 55 55 ··· 70 70 #define CPU_MODEL_MASK 0x00F0 71 71 #define CPU_FAMILY_MASK 0x0F00 72 72 73 - struct mpc_config_processor { 74 - unsigned char mpc_type; 75 - unsigned char mpc_apicid; /* Local APIC number */ 76 - unsigned char mpc_apicver; /* Its versions */ 77 - unsigned char mpc_cpuflag; 78 - unsigned int mpc_cpufeature; 79 - unsigned int mpc_featureflag; /* CPUID feature value */ 80 - unsigned int mpc_reserved[2]; 73 + struct mpc_cpu { 74 + unsigned char type; 75 + unsigned char apicid; /* Local APIC number */ 76 + unsigned char apicver; /* Its versions */ 77 + unsigned char cpuflag; 78 + unsigned int cpufeature; 79 + unsigned int featureflag; /* CPUID feature value */ 80 + unsigned int reserved[2]; 81 81 }; 82 82 83 - struct mpc_config_bus { 84 - unsigned char mpc_type; 85 - unsigned char mpc_busid; 86 - unsigned char mpc_bustype[6]; 83 + struct mpc_bus { 84 + unsigned char type; 85 + unsigned char busid; 86 + unsigned char bustype[6]; 87 87 }; 88 88 89 89 /* List of Bus Type string values, Intel MP Spec. */ ··· 108 108 109 109 #define MPC_APIC_USABLE 0x01 110 110 111 - struct mpc_config_ioapic { 112 - unsigned char mpc_type; 113 - unsigned char mpc_apicid; 114 - unsigned char mpc_apicver; 115 - unsigned char mpc_flags; 116 - unsigned int mpc_apicaddr; 111 + struct mpc_ioapic { 112 + unsigned char type; 113 + unsigned char apicid; 114 + unsigned char apicver; 115 + unsigned char flags; 116 + unsigned int apicaddr; 117 117 }; 118 118 119 - struct mpc_config_intsrc { 120 - unsigned char mpc_type; 121 - unsigned char mpc_irqtype; 122 - unsigned short mpc_irqflag; 123 - unsigned char mpc_srcbus; 124 - unsigned char mpc_srcbusirq; 125 - unsigned char mpc_dstapic; 126 - unsigned char mpc_dstirq; 119 + struct mpc_intsrc { 120 + unsigned char type; 121 + unsigned char irqtype; 122 + unsigned short irqflag; 123 + unsigned char srcbus; 124 + unsigned char srcbusirq; 125 + unsigned char dstapic; 126 + unsigned char dstirq; 127 127 }; 128 128 129 129 enum mp_irq_source_types { ··· 139 139 140 140 #define MP_APIC_ALL 0xFF 141 141 142 - struct mpc_config_lintsrc { 143 - unsigned char mpc_type; 144 - unsigned char mpc_irqtype; 145 - unsigned short mpc_irqflag; 146 - unsigned char mpc_srcbusid; 147 - unsigned char mpc_srcbusirq; 148 - unsigned char mpc_destapic; 149 - unsigned char mpc_destapiclint; 142 + struct mpc_lintsrc { 143 + unsigned char type; 144 + unsigned char irqtype; 145 + unsigned short irqflag; 146 + unsigned char srcbusid; 147 + unsigned char srcbusirq; 148 + unsigned char destapic; 149 + unsigned char destapiclint; 150 150 }; 151 151 152 152 #define MPC_OEM_SIGNATURE "_OEM" 153 153 154 - struct mp_config_oemtable { 155 - char oem_signature[4]; 156 - unsigned short oem_length; /* Size of table */ 157 - char oem_rev; /* 0x01 */ 158 - char oem_checksum; 159 - char mpc_oem[8]; 154 + struct mpc_oemtable { 155 + char signature[4]; 156 + unsigned short length; /* Size of table */ 157 + char rev; /* 0x01 */ 158 + char checksum; 159 + char mpc[8]; 160 160 }; 161 161 162 162 /*
+1 -2
arch/x86/include/asm/numaq/mpparse.h
··· 1 1 #ifndef __ASM_NUMAQ_MPPARSE_H 2 2 #define __ASM_NUMAQ_MPPARSE_H 3 3 4 - extern void numaq_mps_oem_check(struct mp_config_table *mpc, char *oem, 5 - char *productid); 4 + extern void numaq_mps_oem_check(struct mpc_table *, char *, char *); 6 5 7 6 #endif /* __ASM_NUMAQ_MPPARSE_H */
+7 -7
arch/x86/include/asm/setup.h
··· 25 25 /* 26 26 * Any setup quirks to be performed? 27 27 */ 28 - struct mpc_config_processor; 29 - struct mpc_config_bus; 30 - struct mp_config_oemtable; 28 + struct mpc_cpu; 29 + struct mpc_bus; 30 + struct mpc_oemtable; 31 31 struct x86_quirks { 32 32 int (*arch_pre_time_init)(void); 33 33 int (*arch_time_init)(void); ··· 39 39 int (*mach_find_smp_config)(unsigned int reserve); 40 40 41 41 int *mpc_record; 42 - int (*mpc_apic_id)(struct mpc_config_processor *m); 43 - void (*mpc_oem_bus_info)(struct mpc_config_bus *m, char *name); 44 - void (*mpc_oem_pci_bus)(struct mpc_config_bus *m); 45 - void (*smp_read_mpc_oem)(struct mp_config_oemtable *oemtable, 42 + int (*mpc_apic_id)(struct mpc_cpu *m); 43 + void (*mpc_oem_bus_info)(struct mpc_bus *m, char *name); 44 + void (*mpc_oem_pci_bus)(struct mpc_bus *m); 45 + void (*smp_read_mpc_oem)(struct mpc_oemtable *oemtable, 46 46 unsigned short oemsize); 47 47 int (*setup_ioapic_ids)(void); 48 48 int (*update_genapic)(void);
+1 -1
arch/x86/include/asm/summit/mpparse.h
··· 11 11 #define setup_summit() {} 12 12 #endif 13 13 14 - static inline int mps_oem_check(struct mp_config_table *mpc, char *oem, 14 + static inline int mps_oem_check(struct mpc_table *mpc, char *oem, 15 15 char *productid) 16 16 { 17 17 if (!strncmp(oem, "IBM ENSW", 8) &&
+6 -8
arch/x86/kernel/apic.c
··· 31 31 #include <linux/dmi.h> 32 32 #include <linux/dmar.h> 33 33 #include <linux/ftrace.h> 34 + #include <linux/smp.h> 35 + #include <linux/nmi.h> 36 + #include <linux/timex.h> 34 37 35 38 #include <asm/atomic.h> 36 - #include <asm/smp.h> 37 39 #include <asm/mtrr.h> 38 40 #include <asm/mpspec.h> 39 41 #include <asm/desc.h> ··· 43 41 #include <asm/hpet.h> 44 42 #include <asm/pgalloc.h> 45 43 #include <asm/i8253.h> 46 - #include <asm/nmi.h> 47 44 #include <asm/idle.h> 48 45 #include <asm/proto.h> 49 - #include <asm/timex.h> 50 46 #include <asm/apic.h> 51 47 #include <asm/i8259.h> 52 48 ··· 687 687 local_irq_enable(); 688 688 689 689 if (levt->features & CLOCK_EVT_FEAT_DUMMY) { 690 - pr_warning("APIC timer disabled due to verification failure.\n"); 690 + pr_warning("APIC timer disabled due to verification failure\n"); 691 691 return -1; 692 692 } 693 693 ··· 2087 2087 /* are we being called early in kernel startup? */ 2088 2088 if (bios_cpu_apicid) { 2089 2089 id = bios_cpu_apicid[i]; 2090 - } 2091 - else if (i < nr_cpu_ids) { 2090 + } else if (i < nr_cpu_ids) { 2092 2091 if (cpu_present(i)) 2093 2092 id = per_cpu(x86_bios_cpu_apicid, i); 2094 2093 else 2095 2094 continue; 2096 - } 2097 - else 2095 + } else 2098 2096 break; 2099 2097 2100 2098 if (id != BAD_APICID)
+2 -2
arch/x86/kernel/apm_32.c
··· 160 160 * Work around byte swap bug in one of the Vaio's BIOS's 161 161 * (Marc Boucher <marc@mbsi.ca>). 162 162 * Exposed the disable flag to dmi so that we can handle known 163 - * broken APM (Alan Cox <alan@redhat.com>). 163 + * broken APM (Alan Cox <alan@lxorguk.ukuu.org.uk>). 164 164 * 1.14ac: If the BIOS says "I slowed the CPU down" then don't spin 165 - * calling it - instead idle. (Alan Cox <alan@redhat.com>) 165 + * calling it - instead idle. (Alan Cox <alan@lxorguk.ukuu.org.uk>) 166 166 * If an APM idle fails log it and idle sensibly 167 167 * 1.15: Don't queue events to clients who open the device O_WRONLY. 168 168 * Don't expect replies from clients who open the device O_RDONLY.
+1 -1
arch/x86/kernel/cpu/mcheck/mce_32.c
··· 1 1 /* 2 2 * mce.c - x86 Machine Check Exception Reporting 3 - * (c) 2002 Alan Cox <alan@redhat.com>, Dave Jones <davej@redhat.com> 3 + * (c) 2002 Alan Cox <alan@lxorguk.ukuu.org.uk>, Dave Jones <davej@redhat.com> 4 4 */ 5 5 6 6 #include <linux/init.h>
+1 -1
arch/x86/kernel/cpu/mcheck/mce_amd_64.c
··· 462 462 return err; 463 463 } 464 464 465 - static long local_allocate_threshold_blocks(void *_bank) 465 + static __cpuinit long local_allocate_threshold_blocks(void *_bank) 466 466 { 467 467 unsigned int *bank = _bank; 468 468
+1 -1
arch/x86/kernel/cpu/mcheck/p5.c
··· 1 1 /* 2 2 * P5 specific Machine Check Exception Reporting 3 - * (C) Copyright 2002 Alan Cox <alan@redhat.com> 3 + * (C) Copyright 2002 Alan Cox <alan@lxorguk.ukuu.org.uk> 4 4 */ 5 5 6 6 #include <linux/init.h>
+1 -1
arch/x86/kernel/cpu/mcheck/p6.c
··· 1 1 /* 2 2 * P6 specific Machine Check Exception Reporting 3 - * (C) Copyright 2002 Alan Cox <alan@redhat.com> 3 + * (C) Copyright 2002 Alan Cox <alan@lxorguk.ukuu.org.uk> 4 4 */ 5 5 6 6 #include <linux/init.h>
+1 -1
arch/x86/kernel/cpu/mcheck/winchip.c
··· 1 1 /* 2 2 * IDT Winchip specific Machine Check Exception Reporting 3 - * (C) Copyright 2002 Alan Cox <alan@redhat.com> 3 + * (C) Copyright 2002 Alan Cox <alan@lxorguk.ukuu.org.uk> 4 4 */ 5 5 6 6 #include <linux/init.h>
+1 -1
arch/x86/kernel/head_64.S
··· 305 305 call dump_stack 306 306 #ifdef CONFIG_KALLSYMS 307 307 leaq early_idt_ripmsg(%rip),%rdi 308 - movq 8(%rsp),%rsi # get rip again 308 + movq 0(%rsp),%rsi # get rip again 309 309 call __print_symbol 310 310 #endif 311 311 #endif /* EARLY_PRINTK */
+4 -4
arch/x86/kernel/i8259.c
··· 11 11 #include <linux/kernel_stat.h> 12 12 #include <linux/sysdev.h> 13 13 #include <linux/bitops.h> 14 + #include <linux/acpi.h> 15 + #include <linux/io.h> 16 + #include <linux/delay.h> 14 17 15 - #include <asm/acpi.h> 16 18 #include <asm/atomic.h> 17 19 #include <asm/system.h> 18 - #include <asm/io.h> 19 20 #include <asm/timer.h> 20 21 #include <asm/hw_irq.h> 21 22 #include <asm/pgtable.h> 22 - #include <asm/delay.h> 23 23 #include <asm/desc.h> 24 24 #include <asm/apic.h> 25 25 #include <asm/arch_hooks.h> ··· 323 323 outb_pic(0x11, PIC_MASTER_CMD); /* ICW1: select 8259A-1 init */ 324 324 325 325 /* ICW2: 8259A-1 IR0-7 mapped to 0x30-0x37 on x86-64, 326 - to 0x20-0x27 on i386 */ 326 + to 0x20-0x27 on i386 */ 327 327 outb_pic(IRQ0_VECTOR, PIC_MASTER_IMR); 328 328 329 329 /* 8259A-1 (the master) has a slave on IR2 */
-2
arch/x86/kernel/io_apic.c
··· 129 129 node = cpu_to_node(cpu); 130 130 131 131 pin = kzalloc_node(sizeof(*pin), GFP_ATOMIC, node); 132 - printk(KERN_DEBUG " alloc irq_2_pin on cpu %d node %d\n", cpu, node); 133 132 134 133 return pin; 135 134 } ··· 226 227 cpumask_clear(cfg->old_domain); 227 228 } 228 229 } 229 - printk(KERN_DEBUG " alloc irq_cfg on cpu %d node %d\n", cpu, node); 230 230 231 231 return cfg; 232 232 }
+2 -2
arch/x86/kernel/ioport.c
··· 35 35 */ 36 36 asmlinkage long sys_ioperm(unsigned long from, unsigned long num, int turn_on) 37 37 { 38 - struct thread_struct * t = &current->thread; 39 - struct tss_struct * tss; 38 + struct thread_struct *t = &current->thread; 39 + struct tss_struct *tss; 40 40 unsigned int i, max_long, bytes, bytes_updated; 41 41 42 42 if ((from + num <= from) || (from + num > IO_BITMAP_BITS))
+1 -1
arch/x86/kernel/irq.c
··· 5 5 #include <linux/interrupt.h> 6 6 #include <linux/kernel_stat.h> 7 7 #include <linux/seq_file.h> 8 + #include <linux/smp.h> 8 9 9 10 #include <asm/apic.h> 10 11 #include <asm/io_apic.h> 11 - #include <asm/smp.h> 12 12 #include <asm/irq.h> 13 13 14 14 atomic_t irq_err_count;
+5 -5
arch/x86/kernel/irq_32.c
··· 15 15 #include <linux/notifier.h> 16 16 #include <linux/cpu.h> 17 17 #include <linux/delay.h> 18 + #include <linux/uaccess.h> 18 19 19 20 #include <asm/apic.h> 20 - #include <asm/uaccess.h> 21 21 22 22 DEFINE_PER_CPU_SHARED_ALIGNED(irq_cpustat_t, irq_stat); 23 23 EXPORT_PER_CPU_SYMBOL(irq_stat); ··· 93 93 return 0; 94 94 95 95 /* build the stack frame on the IRQ stack */ 96 - isp = (u32 *) ((char*)irqctx + sizeof(*irqctx)); 96 + isp = (u32 *) ((char *)irqctx + sizeof(*irqctx)); 97 97 irqctx->tinfo.task = curctx->tinfo.task; 98 98 irqctx->tinfo.previous_esp = current_stack_pointer; 99 99 ··· 137 137 138 138 hardirq_ctx[cpu] = irqctx; 139 139 140 - irqctx = (union irq_ctx*) &softirq_stack[cpu*THREAD_SIZE]; 140 + irqctx = (union irq_ctx *) &softirq_stack[cpu*THREAD_SIZE]; 141 141 irqctx->tinfo.task = NULL; 142 142 irqctx->tinfo.exec_domain = NULL; 143 143 irqctx->tinfo.cpu = cpu; ··· 147 147 softirq_ctx[cpu] = irqctx; 148 148 149 149 printk(KERN_DEBUG "CPU %u irqstacks, hard=%p soft=%p\n", 150 - cpu,hardirq_ctx[cpu],softirq_ctx[cpu]); 150 + cpu, hardirq_ctx[cpu], softirq_ctx[cpu]); 151 151 } 152 152 153 153 void irq_ctx_exit(int cpu) ··· 174 174 irqctx->tinfo.previous_esp = current_stack_pointer; 175 175 176 176 /* build the stack frame on the softirq stack */ 177 - isp = (u32*) ((char*)irqctx + sizeof(*irqctx)); 177 + isp = (u32 *) ((char *)irqctx + sizeof(*irqctx)); 178 178 179 179 call_on_stack(__do_softirq, isp); 180 180 /*
+11 -11
arch/x86/kernel/irq_64.c
··· 14 14 #include <linux/module.h> 15 15 #include <linux/delay.h> 16 16 #include <linux/ftrace.h> 17 - #include <asm/uaccess.h> 17 + #include <linux/uaccess.h> 18 + #include <linux/smp.h> 18 19 #include <asm/io_apic.h> 19 20 #include <asm/idle.h> 20 - #include <asm/smp.h> 21 21 22 22 /* 23 23 * Probabilistic stack overflow check: ··· 142 142 143 143 asmlinkage void do_softirq(void) 144 144 { 145 - __u32 pending; 146 - unsigned long flags; 145 + __u32 pending; 146 + unsigned long flags; 147 147 148 - if (in_interrupt()) 149 - return; 148 + if (in_interrupt()) 149 + return; 150 150 151 - local_irq_save(flags); 152 - pending = local_softirq_pending(); 153 - /* Switch to interrupt stack */ 154 - if (pending) { 151 + local_irq_save(flags); 152 + pending = local_softirq_pending(); 153 + /* Switch to interrupt stack */ 154 + if (pending) { 155 155 call_softirq(); 156 156 WARN_ON_ONCE(softirq_count()); 157 157 } 158 - local_irq_restore(flags); 158 + local_irq_restore(flags); 159 159 }
+5 -7
arch/x86/kernel/irqinit_32.c
··· 9 9 #include <linux/kernel_stat.h> 10 10 #include <linux/sysdev.h> 11 11 #include <linux/bitops.h> 12 + #include <linux/io.h> 13 + #include <linux/delay.h> 12 14 13 15 #include <asm/atomic.h> 14 16 #include <asm/system.h> 15 - #include <asm/io.h> 16 17 #include <asm/timer.h> 17 18 #include <asm/pgtable.h> 18 - #include <asm/delay.h> 19 19 #include <asm/desc.h> 20 20 #include <asm/apic.h> 21 21 #include <asm/arch_hooks.h> 22 22 #include <asm/i8259.h> 23 - 23 + #include <asm/traps.h> 24 24 25 25 26 26 /* ··· 34 34 * leads to races. IBM designers who came up with it should 35 35 * be shot. 36 36 */ 37 - 38 37 39 38 static irqreturn_t math_error_irq(int cpl, void *dev_id) 40 39 { 41 - extern void math_error(void __user *); 42 - outb(0,0xF0); 40 + outb(0, 0xF0); 43 41 if (ignore_fpu_irq || !boot_cpu_data.hard_math) 44 42 return IRQ_NONE; 45 43 math_error((void __user *)get_irq_regs()->ip); ··· 54 56 .name = "fpu", 55 57 }; 56 58 57 - void __init init_ISA_irqs (void) 59 + void __init init_ISA_irqs(void) 58 60 { 59 61 int i; 60 62
+4 -4
arch/x86/kernel/irqinit_64.c
··· 11 11 #include <linux/kernel_stat.h> 12 12 #include <linux/sysdev.h> 13 13 #include <linux/bitops.h> 14 + #include <linux/acpi.h> 15 + #include <linux/io.h> 16 + #include <linux/delay.h> 14 17 15 - #include <asm/acpi.h> 16 18 #include <asm/atomic.h> 17 19 #include <asm/system.h> 18 - #include <asm/io.h> 19 20 #include <asm/hw_irq.h> 20 21 #include <asm/pgtable.h> 21 - #include <asm/delay.h> 22 22 #include <asm/desc.h> 23 23 #include <asm/apic.h> 24 24 #include <asm/i8259.h> ··· 81 81 return 0; 82 82 } 83 83 84 - void __init init_ISA_irqs(void) 84 + static void __init init_ISA_irqs(void) 85 85 { 86 86 int i; 87 87
+168 -182
arch/x86/kernel/mpparse.c
··· 2 2 * Intel Multiprocessor Specification 1.1 and 1.4 3 3 * compliant MP-table parsing routines. 4 4 * 5 - * (c) 1995 Alan Cox, Building #3 <alan@redhat.com> 5 + * (c) 1995 Alan Cox, Building #3 <alan@lxorguk.ukuu.org.uk> 6 6 * (c) 1998, 1999, 2000 Ingo Molnar <mingo@redhat.com> 7 7 * (c) 2008 Alexey Starikovskiy <astarikovskiy@suse.de> 8 8 */ ··· 17 17 #include <linux/acpi.h> 18 18 #include <linux/module.h> 19 19 #include <linux/smp.h> 20 - #include <linux/acpi.h> 21 20 22 21 #include <asm/mtrr.h> 23 22 #include <asm/mpspec.h> ··· 48 49 return sum & 0xFF; 49 50 } 50 51 51 - static void __init MP_processor_info(struct mpc_config_processor *m) 52 + static void __init MP_processor_info(struct mpc_cpu *m) 52 53 { 53 54 int apicid; 54 55 char *bootup_cpu = ""; 55 56 56 - if (!(m->mpc_cpuflag & CPU_ENABLED)) { 57 + if (!(m->cpuflag & CPU_ENABLED)) { 57 58 disabled_cpus++; 58 59 return; 59 60 } ··· 61 62 if (x86_quirks->mpc_apic_id) 62 63 apicid = x86_quirks->mpc_apic_id(m); 63 64 else 64 - apicid = m->mpc_apicid; 65 + apicid = m->apicid; 65 66 66 - if (m->mpc_cpuflag & CPU_BOOTPROCESSOR) { 67 + if (m->cpuflag & CPU_BOOTPROCESSOR) { 67 68 bootup_cpu = " (Bootup-CPU)"; 68 - boot_cpu_physical_apicid = m->mpc_apicid; 69 + boot_cpu_physical_apicid = m->apicid; 69 70 } 70 71 71 - printk(KERN_INFO "Processor #%d%s\n", m->mpc_apicid, bootup_cpu); 72 - generic_processor_info(apicid, m->mpc_apicver); 72 + printk(KERN_INFO "Processor #%d%s\n", m->apicid, bootup_cpu); 73 + generic_processor_info(apicid, m->apicver); 73 74 } 74 75 75 76 #ifdef CONFIG_X86_IO_APIC 76 - static void __init MP_bus_info(struct mpc_config_bus *m) 77 + static void __init MP_bus_info(struct mpc_bus *m) 77 78 { 78 79 char str[7]; 79 - memcpy(str, m->mpc_bustype, 6); 80 + memcpy(str, m->bustype, 6); 80 81 str[6] = 0; 81 82 82 83 if (x86_quirks->mpc_oem_bus_info) 83 84 x86_quirks->mpc_oem_bus_info(m, str); 84 85 else 85 - apic_printk(APIC_VERBOSE, "Bus #%d is %s\n", m->mpc_busid, str); 86 + apic_printk(APIC_VERBOSE, "Bus #%d is %s\n", m->busid, str); 86 87 87 88 #if MAX_MP_BUSSES < 256 88 - if (m->mpc_busid >= MAX_MP_BUSSES) { 89 + if (m->busid >= MAX_MP_BUSSES) { 89 90 printk(KERN_WARNING "MP table busid value (%d) for bustype %s " 90 91 " is too large, max. supported is %d\n", 91 - m->mpc_busid, str, MAX_MP_BUSSES - 1); 92 + m->busid, str, MAX_MP_BUSSES - 1); 92 93 return; 93 94 } 94 95 #endif 95 96 96 97 if (strncmp(str, BUSTYPE_ISA, sizeof(BUSTYPE_ISA) - 1) == 0) { 97 - set_bit(m->mpc_busid, mp_bus_not_pci); 98 + set_bit(m->busid, mp_bus_not_pci); 98 99 #if defined(CONFIG_EISA) || defined(CONFIG_MCA) 99 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_ISA; 100 + mp_bus_id_to_type[m->busid] = MP_BUS_ISA; 100 101 #endif 101 102 } else if (strncmp(str, BUSTYPE_PCI, sizeof(BUSTYPE_PCI) - 1) == 0) { 102 103 if (x86_quirks->mpc_oem_pci_bus) 103 104 x86_quirks->mpc_oem_pci_bus(m); 104 105 105 - clear_bit(m->mpc_busid, mp_bus_not_pci); 106 + clear_bit(m->busid, mp_bus_not_pci); 106 107 #if defined(CONFIG_EISA) || defined(CONFIG_MCA) 107 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_PCI; 108 + mp_bus_id_to_type[m->busid] = MP_BUS_PCI; 108 109 } else if (strncmp(str, BUSTYPE_EISA, sizeof(BUSTYPE_EISA) - 1) == 0) { 109 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_EISA; 110 + mp_bus_id_to_type[m->busid] = MP_BUS_EISA; 110 111 } else if (strncmp(str, BUSTYPE_MCA, sizeof(BUSTYPE_MCA) - 1) == 0) { 111 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_MCA; 112 + mp_bus_id_to_type[m->busid] = MP_BUS_MCA; 112 113 #endif 113 114 } else 114 115 printk(KERN_WARNING "Unknown bustype %s - ignoring\n", str); ··· 132 133 return 0; 133 134 } 134 135 135 - static void __init MP_ioapic_info(struct mpc_config_ioapic *m) 136 + static void __init MP_ioapic_info(struct mpc_ioapic *m) 136 137 { 137 - if (!(m->mpc_flags & MPC_APIC_USABLE)) 138 + if (!(m->flags & MPC_APIC_USABLE)) 138 139 return; 139 140 140 141 printk(KERN_INFO "I/O APIC #%d Version %d at 0x%X.\n", 141 - m->mpc_apicid, m->mpc_apicver, m->mpc_apicaddr); 142 + m->apicid, m->apicver, m->apicaddr); 142 143 143 - if (bad_ioapic(m->mpc_apicaddr)) 144 + if (bad_ioapic(m->apicaddr)) 144 145 return; 145 146 146 - mp_ioapics[nr_ioapics].mp_apicaddr = m->mpc_apicaddr; 147 - mp_ioapics[nr_ioapics].mp_apicid = m->mpc_apicid; 148 - mp_ioapics[nr_ioapics].mp_type = m->mpc_type; 149 - mp_ioapics[nr_ioapics].mp_apicver = m->mpc_apicver; 150 - mp_ioapics[nr_ioapics].mp_flags = m->mpc_flags; 147 + mp_ioapics[nr_ioapics].mp_apicaddr = m->apicaddr; 148 + mp_ioapics[nr_ioapics].mp_apicid = m->apicid; 149 + mp_ioapics[nr_ioapics].mp_type = m->type; 150 + mp_ioapics[nr_ioapics].mp_apicver = m->apicver; 151 + mp_ioapics[nr_ioapics].mp_flags = m->flags; 151 152 nr_ioapics++; 152 153 } 153 154 154 - static void print_MP_intsrc_info(struct mpc_config_intsrc *m) 155 + static void print_MP_intsrc_info(struct mpc_intsrc *m) 155 156 { 156 157 apic_printk(APIC_VERBOSE, "Int: type %d, pol %d, trig %d, bus %02x," 157 158 " IRQ %02x, APIC ID %x, APIC INT %02x\n", 158 - m->mpc_irqtype, m->mpc_irqflag & 3, 159 - (m->mpc_irqflag >> 2) & 3, m->mpc_srcbus, 160 - m->mpc_srcbusirq, m->mpc_dstapic, m->mpc_dstirq); 159 + m->irqtype, m->irqflag & 3, (m->irqflag >> 2) & 3, m->srcbus, 160 + m->srcbusirq, m->dstapic, m->dstirq); 161 161 } 162 162 163 163 static void __init print_mp_irq_info(struct mp_config_intsrc *mp_irq) ··· 168 170 mp_irq->mp_srcbusirq, mp_irq->mp_dstapic, mp_irq->mp_dstirq); 169 171 } 170 172 171 - static void __init assign_to_mp_irq(struct mpc_config_intsrc *m, 173 + static void __init assign_to_mp_irq(struct mpc_intsrc *m, 172 174 struct mp_config_intsrc *mp_irq) 173 175 { 174 - mp_irq->mp_dstapic = m->mpc_dstapic; 175 - mp_irq->mp_type = m->mpc_type; 176 - mp_irq->mp_irqtype = m->mpc_irqtype; 177 - mp_irq->mp_irqflag = m->mpc_irqflag; 178 - mp_irq->mp_srcbus = m->mpc_srcbus; 179 - mp_irq->mp_srcbusirq = m->mpc_srcbusirq; 180 - mp_irq->mp_dstirq = m->mpc_dstirq; 176 + mp_irq->mp_dstapic = m->dstapic; 177 + mp_irq->mp_type = m->type; 178 + mp_irq->mp_irqtype = m->irqtype; 179 + mp_irq->mp_irqflag = m->irqflag; 180 + mp_irq->mp_srcbus = m->srcbus; 181 + mp_irq->mp_srcbusirq = m->srcbusirq; 182 + mp_irq->mp_dstirq = m->dstirq; 181 183 } 182 184 183 185 static void __init assign_to_mpc_intsrc(struct mp_config_intsrc *mp_irq, 184 - struct mpc_config_intsrc *m) 186 + struct mpc_intsrc *m) 185 187 { 186 - m->mpc_dstapic = mp_irq->mp_dstapic; 187 - m->mpc_type = mp_irq->mp_type; 188 - m->mpc_irqtype = mp_irq->mp_irqtype; 189 - m->mpc_irqflag = mp_irq->mp_irqflag; 190 - m->mpc_srcbus = mp_irq->mp_srcbus; 191 - m->mpc_srcbusirq = mp_irq->mp_srcbusirq; 192 - m->mpc_dstirq = mp_irq->mp_dstirq; 188 + m->dstapic = mp_irq->mp_dstapic; 189 + m->type = mp_irq->mp_type; 190 + m->irqtype = mp_irq->mp_irqtype; 191 + m->irqflag = mp_irq->mp_irqflag; 192 + m->srcbus = mp_irq->mp_srcbus; 193 + m->srcbusirq = mp_irq->mp_srcbusirq; 194 + m->dstirq = mp_irq->mp_dstirq; 193 195 } 194 196 195 197 static int __init mp_irq_mpc_intsrc_cmp(struct mp_config_intsrc *mp_irq, 196 - struct mpc_config_intsrc *m) 198 + struct mpc_intsrc *m) 197 199 { 198 - if (mp_irq->mp_dstapic != m->mpc_dstapic) 200 + if (mp_irq->mp_dstapic != m->dstapic) 199 201 return 1; 200 - if (mp_irq->mp_type != m->mpc_type) 202 + if (mp_irq->mp_type != m->type) 201 203 return 2; 202 - if (mp_irq->mp_irqtype != m->mpc_irqtype) 204 + if (mp_irq->mp_irqtype != m->irqtype) 203 205 return 3; 204 - if (mp_irq->mp_irqflag != m->mpc_irqflag) 206 + if (mp_irq->mp_irqflag != m->irqflag) 205 207 return 4; 206 - if (mp_irq->mp_srcbus != m->mpc_srcbus) 208 + if (mp_irq->mp_srcbus != m->srcbus) 207 209 return 5; 208 - if (mp_irq->mp_srcbusirq != m->mpc_srcbusirq) 210 + if (mp_irq->mp_srcbusirq != m->srcbusirq) 209 211 return 6; 210 - if (mp_irq->mp_dstirq != m->mpc_dstirq) 212 + if (mp_irq->mp_dstirq != m->dstirq) 211 213 return 7; 212 214 213 215 return 0; 214 216 } 215 217 216 - static void __init MP_intsrc_info(struct mpc_config_intsrc *m) 218 + static void __init MP_intsrc_info(struct mpc_intsrc *m) 217 219 { 218 220 int i; 219 221 ··· 231 233 232 234 #endif 233 235 234 - static void __init MP_lintsrc_info(struct mpc_config_lintsrc *m) 236 + static void __init MP_lintsrc_info(struct mpc_lintsrc *m) 235 237 { 236 238 apic_printk(APIC_VERBOSE, "Lint: type %d, pol %d, trig %d, bus %02x," 237 239 " IRQ %02x, APIC ID %x, APIC LINT %02x\n", 238 - m->mpc_irqtype, m->mpc_irqflag & 3, 239 - (m->mpc_irqflag >> 2) & 3, m->mpc_srcbusid, 240 - m->mpc_srcbusirq, m->mpc_destapic, m->mpc_destapiclint); 240 + m->irqtype, m->irqflag & 3, (m->irqflag >> 2) & 3, m->srcbusid, 241 + m->srcbusirq, m->destapic, m->destapiclint); 241 242 } 242 243 243 244 /* 244 245 * Read/parse the MPC 245 246 */ 246 247 247 - static int __init smp_check_mpc(struct mp_config_table *mpc, char *oem, 248 - char *str) 248 + static int __init smp_check_mpc(struct mpc_table *mpc, char *oem, char *str) 249 249 { 250 250 251 - if (memcmp(mpc->mpc_signature, MPC_SIGNATURE, 4)) { 251 + if (memcmp(mpc->signature, MPC_SIGNATURE, 4)) { 252 252 printk(KERN_ERR "MPTABLE: bad signature [%c%c%c%c]!\n", 253 - mpc->mpc_signature[0], mpc->mpc_signature[1], 254 - mpc->mpc_signature[2], mpc->mpc_signature[3]); 253 + mpc->signature[0], mpc->signature[1], 254 + mpc->signature[2], mpc->signature[3]); 255 255 return 0; 256 256 } 257 - if (mpf_checksum((unsigned char *)mpc, mpc->mpc_length)) { 257 + if (mpf_checksum((unsigned char *)mpc, mpc->length)) { 258 258 printk(KERN_ERR "MPTABLE: checksum error!\n"); 259 259 return 0; 260 260 } 261 - if (mpc->mpc_spec != 0x01 && mpc->mpc_spec != 0x04) { 261 + if (mpc->spec != 0x01 && mpc->spec != 0x04) { 262 262 printk(KERN_ERR "MPTABLE: bad table version (%d)!!\n", 263 - mpc->mpc_spec); 263 + mpc->spec); 264 264 return 0; 265 265 } 266 - if (!mpc->mpc_lapic) { 266 + if (!mpc->lapic) { 267 267 printk(KERN_ERR "MPTABLE: null local APIC address!\n"); 268 268 return 0; 269 269 } 270 - memcpy(oem, mpc->mpc_oem, 8); 270 + memcpy(oem, mpc->oem, 8); 271 271 oem[8] = 0; 272 272 printk(KERN_INFO "MPTABLE: OEM ID: %s\n", oem); 273 273 274 - memcpy(str, mpc->mpc_productid, 12); 274 + memcpy(str, mpc->productid, 12); 275 275 str[12] = 0; 276 276 277 277 printk(KERN_INFO "MPTABLE: Product ID: %s\n", str); 278 278 279 - printk(KERN_INFO "MPTABLE: APIC at: 0x%X\n", mpc->mpc_lapic); 279 + printk(KERN_INFO "MPTABLE: APIC at: 0x%X\n", mpc->lapic); 280 280 281 281 return 1; 282 282 } 283 283 284 - static int __init smp_read_mpc(struct mp_config_table *mpc, unsigned early) 284 + static int __init smp_read_mpc(struct mpc_table *mpc, unsigned early) 285 285 { 286 286 char str[16]; 287 287 char oem[10]; ··· 304 308 #endif 305 309 /* save the local APIC address, it might be non-default */ 306 310 if (!acpi_lapic) 307 - mp_lapic_addr = mpc->mpc_lapic; 311 + mp_lapic_addr = mpc->lapic; 308 312 309 313 if (early) 310 314 return 1; 311 315 312 - if (mpc->mpc_oemptr && x86_quirks->smp_read_mpc_oem) { 313 - struct mp_config_oemtable *oem_table = (struct mp_config_oemtable *)(unsigned long)mpc->mpc_oemptr; 314 - x86_quirks->smp_read_mpc_oem(oem_table, mpc->mpc_oemsize); 316 + if (mpc->oemptr && x86_quirks->smp_read_mpc_oem) { 317 + struct mpc_oemtable *oem_table = (void *)(long)mpc->oemptr; 318 + x86_quirks->smp_read_mpc_oem(oem_table, mpc->oemsize); 315 319 } 316 320 317 321 /* ··· 320 324 if (x86_quirks->mpc_record) 321 325 *x86_quirks->mpc_record = 0; 322 326 323 - while (count < mpc->mpc_length) { 327 + while (count < mpc->length) { 324 328 switch (*mpt) { 325 329 case MP_PROCESSOR: 326 330 { 327 - struct mpc_config_processor *m = 328 - (struct mpc_config_processor *)mpt; 331 + struct mpc_cpu *m = (struct mpc_cpu *)mpt; 329 332 /* ACPI may have already provided this data */ 330 333 if (!acpi_lapic) 331 334 MP_processor_info(m); ··· 334 339 } 335 340 case MP_BUS: 336 341 { 337 - struct mpc_config_bus *m = 338 - (struct mpc_config_bus *)mpt; 342 + struct mpc_bus *m = (struct mpc_bus *)mpt; 339 343 #ifdef CONFIG_X86_IO_APIC 340 344 MP_bus_info(m); 341 345 #endif ··· 345 351 case MP_IOAPIC: 346 352 { 347 353 #ifdef CONFIG_X86_IO_APIC 348 - struct mpc_config_ioapic *m = 349 - (struct mpc_config_ioapic *)mpt; 354 + struct mpc_ioapic *m = (struct mpc_ioapic *)mpt; 350 355 MP_ioapic_info(m); 351 356 #endif 352 - mpt += sizeof(struct mpc_config_ioapic); 353 - count += sizeof(struct mpc_config_ioapic); 357 + mpt += sizeof(struct mpc_ioapic); 358 + count += sizeof(struct mpc_ioapic); 354 359 break; 355 360 } 356 361 case MP_INTSRC: 357 362 { 358 363 #ifdef CONFIG_X86_IO_APIC 359 - struct mpc_config_intsrc *m = 360 - (struct mpc_config_intsrc *)mpt; 364 + struct mpc_intsrc *m = (struct mpc_intsrc *)mpt; 361 365 362 366 MP_intsrc_info(m); 363 367 #endif 364 - mpt += sizeof(struct mpc_config_intsrc); 365 - count += sizeof(struct mpc_config_intsrc); 368 + mpt += sizeof(struct mpc_intsrc); 369 + count += sizeof(struct mpc_intsrc); 366 370 break; 367 371 } 368 372 case MP_LINTSRC: 369 373 { 370 - struct mpc_config_lintsrc *m = 371 - (struct mpc_config_lintsrc *)mpt; 374 + struct mpc_lintsrc *m = 375 + (struct mpc_lintsrc *)mpt; 372 376 MP_lintsrc_info(m); 373 377 mpt += sizeof(*m); 374 378 count += sizeof(*m); ··· 377 385 printk(KERN_ERR "Your mptable is wrong, contact your HW vendor!\n"); 378 386 printk(KERN_ERR "type %x\n", *mpt); 379 387 print_hex_dump(KERN_ERR, " ", DUMP_PREFIX_ADDRESS, 16, 380 - 1, mpc, mpc->mpc_length, 1); 381 - count = mpc->mpc_length; 388 + 1, mpc, mpc->length, 1); 389 + count = mpc->length; 382 390 break; 383 391 } 384 392 if (x86_quirks->mpc_record) ··· 409 417 410 418 static void __init construct_default_ioirq_mptable(int mpc_default_type) 411 419 { 412 - struct mpc_config_intsrc intsrc; 420 + struct mpc_intsrc intsrc; 413 421 int i; 414 422 int ELCR_fallback = 0; 415 423 416 - intsrc.mpc_type = MP_INTSRC; 417 - intsrc.mpc_irqflag = 0; /* conforming */ 418 - intsrc.mpc_srcbus = 0; 419 - intsrc.mpc_dstapic = mp_ioapics[0].mp_apicid; 424 + intsrc.type = MP_INTSRC; 425 + intsrc.irqflag = 0; /* conforming */ 426 + intsrc.srcbus = 0; 427 + intsrc.dstapic = mp_ioapics[0].mp_apicid; 420 428 421 - intsrc.mpc_irqtype = mp_INT; 429 + intsrc.irqtype = mp_INT; 422 430 423 431 /* 424 432 * If true, we have an ISA/PCI system with no IRQ entries ··· 461 469 * irqflag field (level sensitive, active high polarity). 462 470 */ 463 471 if (ELCR_trigger(i)) 464 - intsrc.mpc_irqflag = 13; 472 + intsrc.irqflag = 13; 465 473 else 466 - intsrc.mpc_irqflag = 0; 474 + intsrc.irqflag = 0; 467 475 } 468 476 469 - intsrc.mpc_srcbusirq = i; 470 - intsrc.mpc_dstirq = i ? i : 2; /* IRQ0 to INTIN2 */ 477 + intsrc.srcbusirq = i; 478 + intsrc.dstirq = i ? i : 2; /* IRQ0 to INTIN2 */ 471 479 MP_intsrc_info(&intsrc); 472 480 } 473 481 474 - intsrc.mpc_irqtype = mp_ExtINT; 475 - intsrc.mpc_srcbusirq = 0; 476 - intsrc.mpc_dstirq = 0; /* 8259A to INTIN0 */ 482 + intsrc.irqtype = mp_ExtINT; 483 + intsrc.srcbusirq = 0; 484 + intsrc.dstirq = 0; /* 8259A to INTIN0 */ 477 485 MP_intsrc_info(&intsrc); 478 486 } 479 487 480 488 481 489 static void __init construct_ioapic_table(int mpc_default_type) 482 490 { 483 - struct mpc_config_ioapic ioapic; 484 - struct mpc_config_bus bus; 491 + struct mpc_ioapic ioapic; 492 + struct mpc_bus bus; 485 493 486 - bus.mpc_type = MP_BUS; 487 - bus.mpc_busid = 0; 494 + bus.type = MP_BUS; 495 + bus.busid = 0; 488 496 switch (mpc_default_type) { 489 497 default: 490 498 printk(KERN_ERR "???\nUnknown standard configuration %d\n", ··· 492 500 /* fall through */ 493 501 case 1: 494 502 case 5: 495 - memcpy(bus.mpc_bustype, "ISA ", 6); 503 + memcpy(bus.bustype, "ISA ", 6); 496 504 break; 497 505 case 2: 498 506 case 6: 499 507 case 3: 500 - memcpy(bus.mpc_bustype, "EISA ", 6); 508 + memcpy(bus.bustype, "EISA ", 6); 501 509 break; 502 510 case 4: 503 511 case 7: 504 - memcpy(bus.mpc_bustype, "MCA ", 6); 512 + memcpy(bus.bustype, "MCA ", 6); 505 513 } 506 514 MP_bus_info(&bus); 507 515 if (mpc_default_type > 4) { 508 - bus.mpc_busid = 1; 509 - memcpy(bus.mpc_bustype, "PCI ", 6); 516 + bus.busid = 1; 517 + memcpy(bus.bustype, "PCI ", 6); 510 518 MP_bus_info(&bus); 511 519 } 512 520 513 - ioapic.mpc_type = MP_IOAPIC; 514 - ioapic.mpc_apicid = 2; 515 - ioapic.mpc_apicver = mpc_default_type > 4 ? 0x10 : 0x01; 516 - ioapic.mpc_flags = MPC_APIC_USABLE; 517 - ioapic.mpc_apicaddr = 0xFEC00000; 521 + ioapic.type = MP_IOAPIC; 522 + ioapic.apicid = 2; 523 + ioapic.apicver = mpc_default_type > 4 ? 0x10 : 0x01; 524 + ioapic.flags = MPC_APIC_USABLE; 525 + ioapic.apicaddr = 0xFEC00000; 518 526 MP_ioapic_info(&ioapic); 519 527 520 528 /* ··· 528 536 529 537 static inline void __init construct_default_ISA_mptable(int mpc_default_type) 530 538 { 531 - struct mpc_config_processor processor; 532 - struct mpc_config_lintsrc lintsrc; 539 + struct mpc_cpu processor; 540 + struct mpc_lintsrc lintsrc; 533 541 int linttypes[2] = { mp_ExtINT, mp_NMI }; 534 542 int i; 535 543 ··· 541 549 /* 542 550 * 2 CPUs, numbered 0 & 1. 543 551 */ 544 - processor.mpc_type = MP_PROCESSOR; 552 + processor.type = MP_PROCESSOR; 545 553 /* Either an integrated APIC or a discrete 82489DX. */ 546 - processor.mpc_apicver = mpc_default_type > 4 ? 0x10 : 0x01; 547 - processor.mpc_cpuflag = CPU_ENABLED; 548 - processor.mpc_cpufeature = (boot_cpu_data.x86 << 8) | 554 + processor.apicver = mpc_default_type > 4 ? 0x10 : 0x01; 555 + processor.cpuflag = CPU_ENABLED; 556 + processor.cpufeature = (boot_cpu_data.x86 << 8) | 549 557 (boot_cpu_data.x86_model << 4) | boot_cpu_data.x86_mask; 550 - processor.mpc_featureflag = boot_cpu_data.x86_capability[0]; 551 - processor.mpc_reserved[0] = 0; 552 - processor.mpc_reserved[1] = 0; 558 + processor.featureflag = boot_cpu_data.x86_capability[0]; 559 + processor.reserved[0] = 0; 560 + processor.reserved[1] = 0; 553 561 for (i = 0; i < 2; i++) { 554 - processor.mpc_apicid = i; 562 + processor.apicid = i; 555 563 MP_processor_info(&processor); 556 564 } 557 565 558 566 construct_ioapic_table(mpc_default_type); 559 567 560 - lintsrc.mpc_type = MP_LINTSRC; 561 - lintsrc.mpc_irqflag = 0; /* conforming */ 562 - lintsrc.mpc_srcbusid = 0; 563 - lintsrc.mpc_srcbusirq = 0; 564 - lintsrc.mpc_destapic = MP_APIC_ALL; 568 + lintsrc.type = MP_LINTSRC; 569 + lintsrc.irqflag = 0; /* conforming */ 570 + lintsrc.srcbusid = 0; 571 + lintsrc.srcbusirq = 0; 572 + lintsrc.destapic = MP_APIC_ALL; 565 573 for (i = 0; i < 2; i++) { 566 - lintsrc.mpc_irqtype = linttypes[i]; 567 - lintsrc.mpc_destapiclint = i; 574 + lintsrc.irqtype = linttypes[i]; 575 + lintsrc.destapiclint = i; 568 576 MP_lintsrc_info(&lintsrc); 569 577 } 570 578 } ··· 649 657 * ISA defaults and hope it will work. 650 658 */ 651 659 if (!mp_irq_entries) { 652 - struct mpc_config_bus bus; 660 + struct mpc_bus bus; 653 661 654 662 printk(KERN_ERR "BIOS bug, no explicit IRQ entries, " 655 663 "using default mptable. " 656 664 "(tell your hw vendor)\n"); 657 665 658 - bus.mpc_type = MP_BUS; 659 - bus.mpc_busid = 0; 660 - memcpy(bus.mpc_bustype, "ISA ", 6); 666 + bus.type = MP_BUS; 667 + bus.busid = 0; 668 + memcpy(bus.bustype, "ISA ", 6); 661 669 MP_bus_info(&bus); 662 670 663 671 construct_default_ioirq_mptable(0); ··· 795 803 #ifdef CONFIG_X86_IO_APIC 796 804 static u8 __initdata irq_used[MAX_IRQ_SOURCES]; 797 805 798 - static int __init get_MP_intsrc_index(struct mpc_config_intsrc *m) 806 + static int __init get_MP_intsrc_index(struct mpc_intsrc *m) 799 807 { 800 808 int i; 801 809 802 - if (m->mpc_irqtype != mp_INT) 810 + if (m->irqtype != mp_INT) 803 811 return 0; 804 812 805 - if (m->mpc_irqflag != 0x0f) 813 + if (m->irqflag != 0x0f) 806 814 return 0; 807 815 808 816 /* not legacy */ ··· 814 822 if (mp_irqs[i].mp_irqflag != 0x0f) 815 823 continue; 816 824 817 - if (mp_irqs[i].mp_srcbus != m->mpc_srcbus) 825 + if (mp_irqs[i].mp_srcbus != m->srcbus) 818 826 continue; 819 - if (mp_irqs[i].mp_srcbusirq != m->mpc_srcbusirq) 827 + if (mp_irqs[i].mp_srcbusirq != m->srcbusirq) 820 828 continue; 821 829 if (irq_used[i]) { 822 830 /* already claimed */ ··· 832 840 833 841 #define SPARE_SLOT_NUM 20 834 842 835 - static struct mpc_config_intsrc __initdata *m_spare[SPARE_SLOT_NUM]; 843 + static struct mpc_intsrc __initdata *m_spare[SPARE_SLOT_NUM]; 836 844 #endif 837 845 838 - static int __init replace_intsrc_all(struct mp_config_table *mpc, 846 + static int __init replace_intsrc_all(struct mpc_table *mpc, 839 847 unsigned long mpc_new_phys, 840 848 unsigned long mpc_new_length) 841 849 { ··· 847 855 int count = sizeof(*mpc); 848 856 unsigned char *mpt = ((unsigned char *)mpc) + count; 849 857 850 - printk(KERN_INFO "mpc_length %x\n", mpc->mpc_length); 851 - while (count < mpc->mpc_length) { 858 + printk(KERN_INFO "mpc_length %x\n", mpc->length); 859 + while (count < mpc->length) { 852 860 switch (*mpt) { 853 861 case MP_PROCESSOR: 854 862 { 855 - struct mpc_config_processor *m = 856 - (struct mpc_config_processor *)mpt; 863 + struct mpc_cpu *m = (struct mpc_cpu *)mpt; 857 864 mpt += sizeof(*m); 858 865 count += sizeof(*m); 859 866 break; 860 867 } 861 868 case MP_BUS: 862 869 { 863 - struct mpc_config_bus *m = 864 - (struct mpc_config_bus *)mpt; 870 + struct mpc_bus *m = (struct mpc_bus *)mpt; 865 871 mpt += sizeof(*m); 866 872 count += sizeof(*m); 867 873 break; 868 874 } 869 875 case MP_IOAPIC: 870 876 { 871 - mpt += sizeof(struct mpc_config_ioapic); 872 - count += sizeof(struct mpc_config_ioapic); 877 + mpt += sizeof(struct mpc_ioapic); 878 + count += sizeof(struct mpc_ioapic); 873 879 break; 874 880 } 875 881 case MP_INTSRC: 876 882 { 877 883 #ifdef CONFIG_X86_IO_APIC 878 - struct mpc_config_intsrc *m = 879 - (struct mpc_config_intsrc *)mpt; 884 + struct mpc_intsrc *m = (struct mpc_intsrc *)mpt; 880 885 881 886 printk(KERN_INFO "OLD "); 882 887 print_MP_intsrc_info(m); ··· 894 905 nr_m_spare++; 895 906 } 896 907 #endif 897 - mpt += sizeof(struct mpc_config_intsrc); 898 - count += sizeof(struct mpc_config_intsrc); 908 + mpt += sizeof(struct mpc_intsrc); 909 + count += sizeof(struct mpc_intsrc); 899 910 break; 900 911 } 901 912 case MP_LINTSRC: 902 913 { 903 - struct mpc_config_lintsrc *m = 904 - (struct mpc_config_lintsrc *)mpt; 914 + struct mpc_lintsrc *m = 915 + (struct mpc_lintsrc *)mpt; 905 916 mpt += sizeof(*m); 906 917 count += sizeof(*m); 907 918 break; ··· 911 922 printk(KERN_ERR "Your mptable is wrong, contact your HW vendor!\n"); 912 923 printk(KERN_ERR "type %x\n", *mpt); 913 924 print_hex_dump(KERN_ERR, " ", DUMP_PREFIX_ADDRESS, 16, 914 - 1, mpc, mpc->mpc_length, 1); 925 + 1, mpc, mpc->length, 1); 915 926 goto out; 916 927 } 917 928 } ··· 933 944 assign_to_mpc_intsrc(&mp_irqs[i], m_spare[nr_m_spare]); 934 945 m_spare[nr_m_spare] = NULL; 935 946 } else { 936 - struct mpc_config_intsrc *m = 937 - (struct mpc_config_intsrc *)mpt; 938 - count += sizeof(struct mpc_config_intsrc); 947 + struct mpc_intsrc *m = (struct mpc_intsrc *)mpt; 948 + count += sizeof(struct mpc_intsrc); 939 949 if (!mpc_new_phys) { 940 950 printk(KERN_INFO "No spare slots, try to append...take your risk, new mpc_length %x\n", count); 941 951 } else { ··· 946 958 } 947 959 } 948 960 assign_to_mpc_intsrc(&mp_irqs[i], m); 949 - mpc->mpc_length = count; 950 - mpt += sizeof(struct mpc_config_intsrc); 961 + mpc->length = count; 962 + mpt += sizeof(struct mpc_intsrc); 951 963 } 952 964 print_mp_irq_info(&mp_irqs[i]); 953 965 } 954 966 #endif 955 967 out: 956 968 /* update checksum */ 957 - mpc->mpc_checksum = 0; 958 - mpc->mpc_checksum -= mpf_checksum((unsigned char *)mpc, 959 - mpc->mpc_length); 969 + mpc->checksum = 0; 970 + mpc->checksum -= mpf_checksum((unsigned char *)mpc, mpc->length); 960 971 961 972 return 0; 962 973 } ··· 1001 1014 char str[16]; 1002 1015 char oem[10]; 1003 1016 struct intel_mp_floating *mpf; 1004 - struct mp_config_table *mpc; 1005 - struct mp_config_table *mpc_new; 1017 + struct mpc_table *mpc, *mpc_new; 1006 1018 1007 1019 if (!enable_update_mptable) 1008 1020 return 0; ··· 1027 1041 printk(KERN_INFO "mpf: %lx\n", virt_to_phys(mpf)); 1028 1042 printk(KERN_INFO "mpf_physptr: %x\n", mpf->mpf_physptr); 1029 1043 1030 - if (mpc_new_phys && mpc->mpc_length > mpc_new_length) { 1044 + if (mpc_new_phys && mpc->length > mpc_new_length) { 1031 1045 mpc_new_phys = 0; 1032 1046 printk(KERN_INFO "mpc_new_length is %ld, please use alloc_mptable=8k\n", 1033 1047 mpc_new_length); ··· 1036 1050 if (!mpc_new_phys) { 1037 1051 unsigned char old, new; 1038 1052 /* check if we can change the postion */ 1039 - mpc->mpc_checksum = 0; 1040 - old = mpf_checksum((unsigned char *)mpc, mpc->mpc_length); 1041 - mpc->mpc_checksum = 0xff; 1042 - new = mpf_checksum((unsigned char *)mpc, mpc->mpc_length); 1053 + mpc->checksum = 0; 1054 + old = mpf_checksum((unsigned char *)mpc, mpc->length); 1055 + mpc->checksum = 0xff; 1056 + new = mpf_checksum((unsigned char *)mpc, mpc->length); 1043 1057 if (old == new) { 1044 1058 printk(KERN_INFO "mpc is readonly, please try alloc_mptable instead\n"); 1045 1059 return 0; ··· 1048 1062 } else { 1049 1063 mpf->mpf_physptr = mpc_new_phys; 1050 1064 mpc_new = phys_to_virt(mpc_new_phys); 1051 - memcpy(mpc_new, mpc, mpc->mpc_length); 1065 + memcpy(mpc_new, mpc, mpc->length); 1052 1066 mpc = mpc_new; 1053 1067 /* check if we can modify that */ 1054 1068 if (mpc_new_phys - mpf->mpf_physptr) {
-1
arch/x86/kernel/nmi.c
··· 26 26 #include <linux/kernel_stat.h> 27 27 #include <linux/kdebug.h> 28 28 #include <linux/smp.h> 29 - #include <linux/nmi.h> 30 29 31 30 #include <asm/i8259.h> 32 31 #include <asm/io_apic.h>
+18 -20
arch/x86/kernel/numaq_32.c
··· 117 117 } 118 118 119 119 /* x86_quirks member */ 120 - static int mpc_apic_id(struct mpc_config_processor *m) 120 + static int mpc_apic_id(struct mpc_cpu *m) 121 121 { 122 122 int quad = translation_table[mpc_record]->trans_quad; 123 - int logical_apicid = generate_logical_apicid(quad, m->mpc_apicid); 123 + int logical_apicid = generate_logical_apicid(quad, m->apicid); 124 124 125 125 printk(KERN_DEBUG "Processor #%d %u:%u APIC version %d (quad %d, apic %d)\n", 126 - m->mpc_apicid, 127 - (m->mpc_cpufeature & CPU_FAMILY_MASK) >> 8, 128 - (m->mpc_cpufeature & CPU_MODEL_MASK) >> 4, 129 - m->mpc_apicver, quad, logical_apicid); 126 + m->apicid, (m->cpufeature & CPU_FAMILY_MASK) >> 8, 127 + (m->cpufeature & CPU_MODEL_MASK) >> 4, 128 + m->apicver, quad, logical_apicid); 130 129 return logical_apicid; 131 130 } 132 131 ··· 134 135 int mp_bus_id_to_local[MAX_MP_BUSSES]; 135 136 136 137 /* x86_quirks member */ 137 - static void mpc_oem_bus_info(struct mpc_config_bus *m, char *name) 138 + static void mpc_oem_bus_info(struct mpc_bus *m, char *name) 138 139 { 139 140 int quad = translation_table[mpc_record]->trans_quad; 140 141 int local = translation_table[mpc_record]->trans_local; 141 142 142 - mp_bus_id_to_node[m->mpc_busid] = quad; 143 - mp_bus_id_to_local[m->mpc_busid] = local; 143 + mp_bus_id_to_node[m->busid] = quad; 144 + mp_bus_id_to_local[m->busid] = local; 144 145 printk(KERN_INFO "Bus #%d is %s (node %d)\n", 145 - m->mpc_busid, name, quad); 146 + m->busid, name, quad); 146 147 } 147 148 148 149 int quad_local_to_mp_bus_id [NR_CPUS/4][4]; 149 150 150 151 /* x86_quirks member */ 151 - static void mpc_oem_pci_bus(struct mpc_config_bus *m) 152 + static void mpc_oem_pci_bus(struct mpc_bus *m) 152 153 { 153 154 int quad = translation_table[mpc_record]->trans_quad; 154 155 int local = translation_table[mpc_record]->trans_local; 155 156 156 - quad_local_to_mp_bus_id[quad][local] = m->mpc_busid; 157 + quad_local_to_mp_bus_id[quad][local] = m->busid; 157 158 } 158 159 159 160 static void __init MP_translation_info(struct mpc_config_translation *m) ··· 185 186 * Read/parse the MPC oem tables 186 187 */ 187 188 188 - static void __init smp_read_mpc_oem(struct mp_config_oemtable *oemtable, 189 + static void __init smp_read_mpc_oem(struct mpc_oemtable *oemtable, 189 190 unsigned short oemsize) 190 191 { 191 192 int count = sizeof(*oemtable); /* the header size */ ··· 194 195 mpc_record = 0; 195 196 printk(KERN_INFO "Found an OEM MPC table at %8p - parsing it ... \n", 196 197 oemtable); 197 - if (memcmp(oemtable->oem_signature, MPC_OEM_SIGNATURE, 4)) { 198 + if (memcmp(oemtable->signature, MPC_OEM_SIGNATURE, 4)) { 198 199 printk(KERN_WARNING 199 200 "SMP mpc oemtable: bad signature [%c%c%c%c]!\n", 200 - oemtable->oem_signature[0], oemtable->oem_signature[1], 201 - oemtable->oem_signature[2], oemtable->oem_signature[3]); 201 + oemtable->signature[0], oemtable->signature[1], 202 + oemtable->signature[2], oemtable->signature[3]); 202 203 return; 203 204 } 204 - if (mpf_checksum((unsigned char *)oemtable, oemtable->oem_length)) { 205 + if (mpf_checksum((unsigned char *)oemtable, oemtable->length)) { 205 206 printk(KERN_WARNING "SMP oem mptable: checksum error!\n"); 206 207 return; 207 208 } 208 - while (count < oemtable->oem_length) { 209 + while (count < oemtable->length) { 209 210 switch (*oemptr) { 210 211 case MP_TRANSLATION: 211 212 { ··· 259 260 .update_genapic = numaq_update_genapic, 260 261 }; 261 262 262 - void numaq_mps_oem_check(struct mp_config_table *mpc, char *oem, 263 - char *productid) 263 + void numaq_mps_oem_check(struct mpc_table *mpc, char *oem, char *productid) 264 264 { 265 265 if (strncmp(oem, "IBM NUMA", 8)) 266 266 printk("Warning! Not a NUMA-Q system!\n");
+9 -10
arch/x86/kernel/process_32.c
··· 39 39 #include <linux/prctl.h> 40 40 #include <linux/dmi.h> 41 41 #include <linux/ftrace.h> 42 + #include <linux/uaccess.h> 43 + #include <linux/io.h> 44 + #include <linux/kdebug.h> 42 45 43 - #include <asm/uaccess.h> 44 46 #include <asm/pgtable.h> 45 47 #include <asm/system.h> 46 - #include <asm/io.h> 47 48 #include <asm/ldt.h> 48 49 #include <asm/processor.h> 49 50 #include <asm/i387.h> ··· 57 56 58 57 #include <asm/tlbflush.h> 59 58 #include <asm/cpu.h> 60 - #include <asm/kdebug.h> 61 59 #include <asm/idle.h> 62 60 #include <asm/syscalls.h> 63 - #include <asm/smp.h> 64 61 #include <asm/ds.h> 65 62 66 63 asmlinkage void ret_from_fork(void) __asm__("ret_from_fork"); ··· 204 205 /* 205 206 * Create a kernel thread 206 207 */ 207 - int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags) 208 + int kernel_thread(int (*fn)(void *), void *arg, unsigned long flags) 208 209 { 209 210 struct pt_regs regs; 210 211 ··· 265 266 tsk->thread.debugreg3 = 0; 266 267 tsk->thread.debugreg6 = 0; 267 268 tsk->thread.debugreg7 = 0; 268 - memset(tsk->thread.tls_array, 0, sizeof(tsk->thread.tls_array)); 269 + memset(tsk->thread.tls_array, 0, sizeof(tsk->thread.tls_array)); 269 270 clear_tsk_thread_flag(tsk, TIF_DEBUG); 270 271 /* 271 272 * Forget coprocessor state.. ··· 292 293 293 294 int copy_thread(int nr, unsigned long clone_flags, unsigned long sp, 294 295 unsigned long unused, 295 - struct task_struct * p, struct pt_regs * regs) 296 + struct task_struct *p, struct pt_regs *regs) 296 297 { 297 - struct pt_regs * childregs; 298 + struct pt_regs *childregs; 298 299 struct task_struct *tsk; 299 300 int err; 300 301 ··· 346 347 void 347 348 start_thread(struct pt_regs *regs, unsigned long new_ip, unsigned long new_sp) 348 349 { 349 - __asm__("movl %0, %%gs" :: "r"(0)); 350 + __asm__("movl %0, %%gs" : : "r"(0)); 350 351 regs->fs = 0; 351 352 set_fs(USER_DS); 352 353 regs->ds = __USER_DS; ··· 637 638 asmlinkage int sys_execve(struct pt_regs regs) 638 639 { 639 640 int error; 640 - char * filename; 641 + char *filename; 641 642 642 643 filename = getname((char __user *) regs.bx); 643 644 error = PTR_ERR(filename);
+5 -6
arch/x86/kernel/setup_percpu.c
··· 5 5 #include <linux/percpu.h> 6 6 #include <linux/kexec.h> 7 7 #include <linux/crash_dump.h> 8 - #include <asm/smp.h> 9 - #include <asm/percpu.h> 8 + #include <linux/smp.h> 9 + #include <linux/topology.h> 10 10 #include <asm/sections.h> 11 11 #include <asm/processor.h> 12 12 #include <asm/setup.h> 13 - #include <asm/topology.h> 14 13 #include <asm/mpspec.h> 15 14 #include <asm/apicdef.h> 16 15 #include <asm/highmem.h> ··· 19 20 unsigned disabled_cpus __cpuinitdata; 20 21 /* Processor that is doing the boot up */ 21 22 unsigned int boot_cpu_physical_apicid = -1U; 22 - unsigned int max_physical_apicid; 23 23 EXPORT_SYMBOL(boot_cpu_physical_apicid); 24 + unsigned int max_physical_apicid; 24 25 25 26 /* Bitmask of physically existing CPUs */ 26 27 physid_mask_t phys_cpu_present_map; ··· 302 303 303 304 cpulist_scnprintf(buf, sizeof(buf), mask); 304 305 printk(KERN_DEBUG "%s cpu %d node %d: mask now %s\n", 305 - enable? "numa_add_cpu":"numa_remove_cpu", cpu, node, buf); 306 - } 306 + enable ? "numa_add_cpu" : "numa_remove_cpu", cpu, node, buf); 307 + } 307 308 308 309 void __cpuinit numa_add_cpu(int cpu) 309 310 {
+1 -1
arch/x86/kernel/smp.c
··· 1 1 /* 2 2 * Intel SMP support routines. 3 3 * 4 - * (c) 1995 Alan Cox, Building #3 <alan@redhat.com> 4 + * (c) 1995 Alan Cox, Building #3 <alan@lxorguk.ukuu.org.uk> 5 5 * (c) 1998-99, 2000 Ingo Molnar <mingo@redhat.com> 6 6 * (c) 2002,2003 Andi Kleen, SuSE Labs. 7 7 *
+1 -1
arch/x86/kernel/smpboot.c
··· 1 1 /* 2 2 * x86 SMP booting functions 3 3 * 4 - * (c) 1995 Alan Cox, Building #3 <alan@redhat.com> 4 + * (c) 1995 Alan Cox, Building #3 <alan@lxorguk.ukuu.org.uk> 5 5 * (c) 1998, 1999, 2000 Ingo Molnar <mingo@redhat.com> 6 6 * Copyright 2001 Andi Kleen, SuSE Labs. 7 7 *
+2 -2
arch/x86/kernel/time_32.c
··· 105 105 high bit of the PPI port B (0x61). Note that some PS/2s, 106 106 notably the 55SX, work fine if this is removed. */ 107 107 108 - u8 irq_v = inb_p( 0x61 ); /* read the current state */ 109 - outb_p( irq_v|0x80, 0x61 ); /* reset the IRQ */ 108 + u8 irq_v = inb_p(0x61); /* read the current state */ 109 + outb_p(irq_v | 0x80, 0x61); /* reset the IRQ */ 110 110 } 111 111 #endif 112 112
+1 -1
arch/x86/kernel/time_64.c
··· 17 17 #include <linux/module.h> 18 18 #include <linux/time.h> 19 19 #include <linux/mca.h> 20 + #include <linux/nmi.h> 20 21 21 22 #include <asm/i8253.h> 22 23 #include <asm/hpet.h> 23 - #include <asm/nmi.h> 24 24 #include <asm/vgtod.h> 25 25 #include <asm/time.h> 26 26 #include <asm/timer.h>
-3
arch/x86/kernel/traps.c
··· 63 63 #else 64 64 #include <asm/processor-flags.h> 65 65 #include <asm/arch_hooks.h> 66 - #include <asm/nmi.h> 67 - #include <asm/smp.h> 68 - #include <asm/io.h> 69 66 #include <asm/traps.h> 70 67 71 68 #include "cpu/mcheck/mce.h"
+15 -17
arch/x86/kernel/visws_quirks.c
··· 176 176 * No problem for Linux. 177 177 */ 178 178 179 - static void __init MP_processor_info(struct mpc_config_processor *m) 179 + static void __init MP_processor_info(struct mpc_cpu *m) 180 180 { 181 181 int ver, logical_apicid; 182 182 physid_mask_t apic_cpus; 183 183 184 - if (!(m->mpc_cpuflag & CPU_ENABLED)) 184 + if (!(m->cpuflag & CPU_ENABLED)) 185 185 return; 186 186 187 - logical_apicid = m->mpc_apicid; 187 + logical_apicid = m->apicid; 188 188 printk(KERN_INFO "%sCPU #%d %u:%u APIC version %d\n", 189 - m->mpc_cpuflag & CPU_BOOTPROCESSOR ? "Bootup " : "", 190 - m->mpc_apicid, 191 - (m->mpc_cpufeature & CPU_FAMILY_MASK) >> 8, 192 - (m->mpc_cpufeature & CPU_MODEL_MASK) >> 4, 193 - m->mpc_apicver); 189 + m->cpuflag & CPU_BOOTPROCESSOR ? "Bootup " : "", 190 + m->apicid, (m->cpufeature & CPU_FAMILY_MASK) >> 8, 191 + (m->cpufeature & CPU_MODEL_MASK) >> 4, m->apicver); 194 192 195 - if (m->mpc_cpuflag & CPU_BOOTPROCESSOR) 196 - boot_cpu_physical_apicid = m->mpc_apicid; 193 + if (m->cpuflag & CPU_BOOTPROCESSOR) 194 + boot_cpu_physical_apicid = m->apicid; 197 195 198 - ver = m->mpc_apicver; 199 - if ((ver >= 0x14 && m->mpc_apicid >= 0xff) || m->mpc_apicid >= 0xf) { 196 + ver = m->apicver; 197 + if ((ver >= 0x14 && m->apicid >= 0xff) || m->apicid >= 0xf) { 200 198 printk(KERN_ERR "Processor #%d INVALID. (Max ID: %d).\n", 201 - m->mpc_apicid, MAX_APICS); 199 + m->apicid, MAX_APICS); 202 200 return; 203 201 } 204 202 205 - apic_cpus = apicid_to_cpu_present(m->mpc_apicid); 203 + apic_cpus = apicid_to_cpu_present(m->apicid); 206 204 physids_or(phys_cpu_present_map, phys_cpu_present_map, apic_cpus); 207 205 /* 208 206 * Validate version ··· 208 210 if (ver == 0x0) { 209 211 printk(KERN_ERR "BIOS bug, APIC version is 0 for CPU#%d! " 210 212 "fixing up to 0x10. (tell your hw vendor)\n", 211 - m->mpc_apicid); 213 + m->apicid); 212 214 ver = 0x10; 213 215 } 214 - apic_version[m->mpc_apicid] = ver; 216 + apic_version[m->apicid] = ver; 215 217 } 216 218 217 219 static int __init visws_find_smp_config(unsigned int reserve) 218 220 { 219 - struct mpc_config_processor *mp = phys_to_virt(CO_CPU_TAB_PHYS); 221 + struct mpc_cpu *mp = phys_to_virt(CO_CPU_TAB_PHYS); 220 222 unsigned short ncpus = readw(phys_to_virt(CO_CPU_NUM_PHYS)); 221 223 222 224 if (ncpus > CO_CPU_MAX) {
+5 -5
arch/x86/mach-generic/es7000.c
··· 43 43 return; 44 44 } 45 45 46 - static __init int mps_oem_check(struct mp_config_table *mpc, char *oem, 47 - char *productid) 46 + static __init int 47 + mps_oem_check(struct mpc_table *mpc, char *oem, char *productid) 48 48 { 49 - if (mpc->mpc_oemptr) { 50 - struct mp_config_oemtable *oem_table = 51 - (struct mp_config_oemtable *)mpc->mpc_oemptr; 49 + if (mpc->oemptr) { 50 + struct mpc_oemtable *oem_table = 51 + (struct mpc_oemtable *)mpc->oemptr; 52 52 if (!strncmp(oem, "UNISYS", 6)) 53 53 return parse_unisys_oem((char *)oem_table); 54 54 }
+1 -2
arch/x86/mach-generic/numaq.c
··· 19 19 #include <asm/numaq/wakecpu.h> 20 20 #include <asm/numaq.h> 21 21 22 - static int mps_oem_check(struct mp_config_table *mpc, char *oem, 23 - char *productid) 22 + static int mps_oem_check(struct mpc_table *mpc, char *oem, char *productid) 24 23 { 25 24 numaq_mps_oem_check(mpc, oem, productid); 26 25 return found_numaq;
+1 -2
arch/x86/mach-generic/probe.c
··· 110 110 111 111 /* These functions can switch the APIC even after the initial ->probe() */ 112 112 113 - int __init mps_oem_check(struct mp_config_table *mpc, char *oem, 114 - char *productid) 113 + int __init mps_oem_check(struct mpc_table *mpc, char *oem, char *productid) 115 114 { 116 115 int i; 117 116 for (i = 0; apic_probe[i]; ++i) {
+9 -11
arch/x86/mm/k8topology_64.c
··· 81 81 unsigned numnodes, cores, bits, apicid_base; 82 82 unsigned long prevbase; 83 83 struct bootnode nodes[8]; 84 - unsigned char nodeids[8]; 85 84 int i, j, nb, found = 0; 86 85 u32 nodeid, reg; 87 86 ··· 109 110 limit = read_pci_config(0, nb, 1, 0x44 + i*8); 110 111 111 112 nodeid = limit & 7; 112 - nodeids[i] = nodeid; 113 113 if ((base & 3) == 0) { 114 114 if (i < numnodes) 115 115 printk("Skipping disabled node %d\n", i); ··· 177 179 178 180 nodes[nodeid].start = base; 179 181 nodes[nodeid].end = limit; 180 - e820_register_active_regions(nodeid, 181 - nodes[nodeid].start >> PAGE_SHIFT, 182 - nodes[nodeid].end >> PAGE_SHIFT); 183 182 184 183 prevbase = base; 185 184 ··· 206 211 } 207 212 208 213 for (i = 0; i < 8; i++) { 209 - if (nodes[i].start != nodes[i].end) { 210 - nodeid = nodeids[i]; 211 - for (j = apicid_base; j < cores + apicid_base; j++) 212 - apicid_to_node[(nodeid << bits) + j] = i; 213 - setup_node_bootmem(i, nodes[i].start, nodes[i].end); 214 - } 214 + if (nodes[i].start == nodes[i].end) 215 + continue; 216 + 217 + e820_register_active_regions(i, 218 + nodes[i].start >> PAGE_SHIFT, 219 + nodes[i].end >> PAGE_SHIFT); 220 + for (j = apicid_base; j < cores + apicid_base; j++) 221 + apicid_to_node[(i << bits) + j] = i; 222 + setup_node_bootmem(i, nodes[i].start, nodes[i].end); 215 223 } 216 224 217 225 numa_init_array();
+7 -7
lib/Kconfig.debug
··· 573 573 config FRAME_POINTER 574 574 bool "Compile the kernel with frame pointers" 575 575 depends on DEBUG_KERNEL && \ 576 - (X86 || CRIS || M68K || M68KNOMMU || FRV || UML || S390 || \ 577 - AVR32 || SUPERH || BLACKFIN || MN10300) 578 - default y if DEBUG_INFO && UML 576 + (CRIS || M68K || M68KNOMMU || FRV || UML || S390 || \ 577 + AVR32 || SUPERH || BLACKFIN || MN10300) || \ 578 + ARCH_WANT_FRAME_POINTERS 579 + default y if (DEBUG_INFO && UML) || ARCH_WANT_FRAME_POINTERS 579 580 help 580 - If you say Y here the resulting kernel image will be slightly larger 581 - and slower, but it might give very useful debugging information on 582 - some architectures or if you use external debuggers. 583 - If you don't debug the kernel, you can say N. 581 + If you say Y here the resulting kernel image will be slightly 582 + larger and slower, but it gives very useful debugging information 583 + in case of kernel bugs. (precise oopses/stacktraces/warnings) 584 584 585 585 config BOOT_PRINTK_DELAY 586 586 bool "Delay each boot printk message by N milliseconds"