diff options
Diffstat (limited to 'arch')
95 files changed, 690 insertions, 478 deletions
diff --git a/arch/alpha/include/asm/bug.h b/arch/alpha/include/asm/bug.h index 7b85b7c93709..1720c8ad86fe 100644 --- a/arch/alpha/include/asm/bug.h +++ b/arch/alpha/include/asm/bug.h | |||
@@ -8,12 +8,12 @@ | |||
8 | 8 | ||
9 | /* ??? Would be nice to use .gprel32 here, but we can't be sure that the | 9 | /* ??? Would be nice to use .gprel32 here, but we can't be sure that the |
10 | function loaded the GP, so this could fail in modules. */ | 10 | function loaded the GP, so this could fail in modules. */ |
11 | #define BUG() { \ | 11 | #define BUG() do { \ |
12 | __asm__ __volatile__( \ | 12 | __asm__ __volatile__( \ |
13 | "call_pal %0 # bugchk\n\t" \ | 13 | "call_pal %0 # bugchk\n\t" \ |
14 | ".long %1\n\t.8byte %2" \ | 14 | ".long %1\n\t.8byte %2" \ |
15 | : : "i"(PAL_bugchk), "i"(__LINE__), "i"(__FILE__)); \ | 15 | : : "i"(PAL_bugchk), "i"(__LINE__), "i"(__FILE__)); \ |
16 | for ( ; ; ); } | 16 | for ( ; ; ); } while (0) |
17 | 17 | ||
18 | #define HAVE_ARCH_BUG | 18 | #define HAVE_ARCH_BUG |
19 | #endif | 19 | #endif |
diff --git a/arch/arm/kernel/machine_kexec.c b/arch/arm/kernel/machine_kexec.c index 440dc62cdc3a..598ca61e7bca 100644 --- a/arch/arm/kernel/machine_kexec.c +++ b/arch/arm/kernel/machine_kexec.c | |||
@@ -13,8 +13,8 @@ | |||
13 | #include <asm/cacheflush.h> | 13 | #include <asm/cacheflush.h> |
14 | #include <asm/mach-types.h> | 14 | #include <asm/mach-types.h> |
15 | 15 | ||
16 | const extern unsigned char relocate_new_kernel[]; | 16 | extern const unsigned char relocate_new_kernel[]; |
17 | const extern unsigned int relocate_new_kernel_size; | 17 | extern const unsigned int relocate_new_kernel_size; |
18 | 18 | ||
19 | extern void setup_mm_for_reboot(char mode); | 19 | extern void setup_mm_for_reboot(char mode); |
20 | 20 | ||
diff --git a/arch/arm/mach-pxa/dma.c b/arch/arm/mach-pxa/dma.c index b1514fb20d3a..7de17fc5d54b 100644 --- a/arch/arm/mach-pxa/dma.c +++ b/arch/arm/mach-pxa/dma.c | |||
@@ -121,20 +121,22 @@ int __init pxa_init_dma(int num_ch) | |||
121 | if (dma_channels == NULL) | 121 | if (dma_channels == NULL) |
122 | return -ENOMEM; | 122 | return -ENOMEM; |
123 | 123 | ||
124 | ret = request_irq(IRQ_DMA, dma_irq_handler, IRQF_DISABLED, "DMA", NULL); | ||
125 | if (ret) { | ||
126 | printk (KERN_CRIT "Wow! Can't register IRQ for DMA\n"); | ||
127 | kfree(dma_channels); | ||
128 | return ret; | ||
129 | } | ||
130 | |||
131 | /* dma channel priorities on pxa2xx processors: | 124 | /* dma channel priorities on pxa2xx processors: |
132 | * ch 0 - 3, 16 - 19 <--> (0) DMA_PRIO_HIGH | 125 | * ch 0 - 3, 16 - 19 <--> (0) DMA_PRIO_HIGH |
133 | * ch 4 - 7, 20 - 23 <--> (1) DMA_PRIO_MEDIUM | 126 | * ch 4 - 7, 20 - 23 <--> (1) DMA_PRIO_MEDIUM |
134 | * ch 8 - 15, 24 - 31 <--> (2) DMA_PRIO_LOW | 127 | * ch 8 - 15, 24 - 31 <--> (2) DMA_PRIO_LOW |
135 | */ | 128 | */ |
136 | for (i = 0; i < num_ch; i++) | 129 | for (i = 0; i < num_ch; i++) { |
130 | DCSR(i) = 0; | ||
137 | dma_channels[i].prio = min((i & 0xf) >> 2, DMA_PRIO_LOW); | 131 | dma_channels[i].prio = min((i & 0xf) >> 2, DMA_PRIO_LOW); |
132 | } | ||
133 | |||
134 | ret = request_irq(IRQ_DMA, dma_irq_handler, IRQF_DISABLED, "DMA", NULL); | ||
135 | if (ret) { | ||
136 | printk (KERN_CRIT "Wow! Can't register IRQ for DMA\n"); | ||
137 | kfree(dma_channels); | ||
138 | return ret; | ||
139 | } | ||
138 | 140 | ||
139 | num_dma_channels = num_ch; | 141 | num_dma_channels = num_ch; |
140 | return 0; | 142 | return 0; |
diff --git a/arch/arm/mach-pxa/include/mach/regs-ac97.h b/arch/arm/mach-pxa/include/mach/regs-ac97.h index e41b9d202b8c..b8d14bd9ae59 100644 --- a/arch/arm/mach-pxa/include/mach/regs-ac97.h +++ b/arch/arm/mach-pxa/include/mach/regs-ac97.h | |||
@@ -1,6 +1,8 @@ | |||
1 | #ifndef __ASM_ARCH_REGS_AC97_H | 1 | #ifndef __ASM_ARCH_REGS_AC97_H |
2 | #define __ASM_ARCH_REGS_AC97_H | 2 | #define __ASM_ARCH_REGS_AC97_H |
3 | 3 | ||
4 | #include <mach/hardware.h> | ||
5 | |||
4 | /* | 6 | /* |
5 | * AC97 Controller registers | 7 | * AC97 Controller registers |
6 | */ | 8 | */ |
diff --git a/arch/arm/mach-pxa/include/mach/regs-ssp.h b/arch/arm/mach-pxa/include/mach/regs-ssp.h index 3c04cde2cf1f..cf31986f6f05 100644 --- a/arch/arm/mach-pxa/include/mach/regs-ssp.h +++ b/arch/arm/mach-pxa/include/mach/regs-ssp.h | |||
@@ -41,6 +41,9 @@ | |||
41 | #elif defined(CONFIG_PXA27x) || defined(CONFIG_PXA3xx) | 41 | #elif defined(CONFIG_PXA27x) || defined(CONFIG_PXA3xx) |
42 | #define SSCR0_SCR (0x000fff00) /* Serial Clock Rate (mask) */ | 42 | #define SSCR0_SCR (0x000fff00) /* Serial Clock Rate (mask) */ |
43 | #define SSCR0_SerClkDiv(x) (((x) - 1) << 8) /* Divisor [1..4096] */ | 43 | #define SSCR0_SerClkDiv(x) (((x) - 1) << 8) /* Divisor [1..4096] */ |
44 | #endif | ||
45 | |||
46 | #if defined(CONFIG_PXA27x) || defined(CONFIG_PXA3xx) | ||
44 | #define SSCR0_EDSS (1 << 20) /* Extended data size select */ | 47 | #define SSCR0_EDSS (1 << 20) /* Extended data size select */ |
45 | #define SSCR0_NCS (1 << 21) /* Network clock select */ | 48 | #define SSCR0_NCS (1 << 21) /* Network clock select */ |
46 | #define SSCR0_RIM (1 << 22) /* Receive FIFO overrrun interrupt mask */ | 49 | #define SSCR0_RIM (1 << 22) /* Receive FIFO overrrun interrupt mask */ |
diff --git a/arch/arm/mach-pxa/pxa300.c b/arch/arm/mach-pxa/pxa300.c index f735e58e6669..83fb609b6eb7 100644 --- a/arch/arm/mach-pxa/pxa300.c +++ b/arch/arm/mach-pxa/pxa300.c | |||
@@ -88,13 +88,13 @@ static struct pxa3xx_mfp_addr_map pxa310_mfp_addr_map[] __initdata = { | |||
88 | static DEFINE_PXA3_CKEN(common_nand, NAND, 156000000, 0); | 88 | static DEFINE_PXA3_CKEN(common_nand, NAND, 156000000, 0); |
89 | 89 | ||
90 | static struct clk_lookup common_clkregs[] = { | 90 | static struct clk_lookup common_clkregs[] = { |
91 | INIT_CLKREG(&clk_common_nand, "pxa3xx-nand", "NANDCLK"), | 91 | INIT_CLKREG(&clk_common_nand, "pxa3xx-nand", NULL), |
92 | }; | 92 | }; |
93 | 93 | ||
94 | static DEFINE_PXA3_CKEN(pxa310_mmc3, MMC3, 19500000, 0); | 94 | static DEFINE_PXA3_CKEN(pxa310_mmc3, MMC3, 19500000, 0); |
95 | 95 | ||
96 | static struct clk_lookup pxa310_clkregs[] = { | 96 | static struct clk_lookup pxa310_clkregs[] = { |
97 | INIT_CLKREG(&clk_pxa310_mmc3, "pxa2xx-mci.2", "MMCCLK"), | 97 | INIT_CLKREG(&clk_pxa310_mmc3, "pxa2xx-mci.2", NULL), |
98 | }; | 98 | }; |
99 | 99 | ||
100 | static int __init pxa300_init(void) | 100 | static int __init pxa300_init(void) |
diff --git a/arch/arm/mach-pxa/pxa320.c b/arch/arm/mach-pxa/pxa320.c index effe408c186f..36f066196fa2 100644 --- a/arch/arm/mach-pxa/pxa320.c +++ b/arch/arm/mach-pxa/pxa320.c | |||
@@ -83,7 +83,7 @@ static struct pxa3xx_mfp_addr_map pxa320_mfp_addr_map[] __initdata = { | |||
83 | static DEFINE_PXA3_CKEN(pxa320_nand, NAND, 104000000, 0); | 83 | static DEFINE_PXA3_CKEN(pxa320_nand, NAND, 104000000, 0); |
84 | 84 | ||
85 | static struct clk_lookup pxa320_clkregs[] = { | 85 | static struct clk_lookup pxa320_clkregs[] = { |
86 | INIT_CLKREG(&clk_pxa320_nand, "pxa3xx-nand", "NANDCLK"), | 86 | INIT_CLKREG(&clk_pxa320_nand, "pxa3xx-nand", NULL), |
87 | }; | 87 | }; |
88 | 88 | ||
89 | static int __init pxa320_init(void) | 89 | static int __init pxa320_init(void) |
diff --git a/arch/frv/mm/dma-alloc.c b/arch/frv/mm/dma-alloc.c index dc6522c464d4..44840e73e907 100644 --- a/arch/frv/mm/dma-alloc.c +++ b/arch/frv/mm/dma-alloc.c | |||
@@ -36,10 +36,10 @@ | |||
36 | #include <linux/vmalloc.h> | 36 | #include <linux/vmalloc.h> |
37 | #include <linux/init.h> | 37 | #include <linux/init.h> |
38 | #include <linux/pci.h> | 38 | #include <linux/pci.h> |
39 | #include <linux/hardirq.h> | ||
39 | 40 | ||
40 | #include <asm/pgalloc.h> | 41 | #include <asm/pgalloc.h> |
41 | #include <asm/io.h> | 42 | #include <asm/io.h> |
42 | #include <asm/hardirq.h> | ||
43 | #include <asm/mmu_context.h> | 43 | #include <asm/mmu_context.h> |
44 | #include <asm/pgtable.h> | 44 | #include <asm/pgtable.h> |
45 | #include <asm/mmu.h> | 45 | #include <asm/mmu.h> |
diff --git a/arch/ia64/sn/kernel/io_acpi_init.c b/arch/ia64/sn/kernel/io_acpi_init.c index c5a214026a77..d0223abbbbd4 100644 --- a/arch/ia64/sn/kernel/io_acpi_init.c +++ b/arch/ia64/sn/kernel/io_acpi_init.c | |||
@@ -443,7 +443,7 @@ sn_acpi_slot_fixup(struct pci_dev *dev) | |||
443 | size = pci_resource_len(dev, PCI_ROM_RESOURCE); | 443 | size = pci_resource_len(dev, PCI_ROM_RESOURCE); |
444 | addr = ioremap(pcidev_info->pdi_pio_mapped_addr[PCI_ROM_RESOURCE], | 444 | addr = ioremap(pcidev_info->pdi_pio_mapped_addr[PCI_ROM_RESOURCE], |
445 | size); | 445 | size); |
446 | image_size = pci_get_rom_size(addr, size); | 446 | image_size = pci_get_rom_size(dev, addr, size); |
447 | dev->resource[PCI_ROM_RESOURCE].start = (unsigned long) addr; | 447 | dev->resource[PCI_ROM_RESOURCE].start = (unsigned long) addr; |
448 | dev->resource[PCI_ROM_RESOURCE].end = | 448 | dev->resource[PCI_ROM_RESOURCE].end = |
449 | (unsigned long) addr + image_size - 1; | 449 | (unsigned long) addr + image_size - 1; |
diff --git a/arch/ia64/sn/kernel/io_init.c b/arch/ia64/sn/kernel/io_init.c index 4e1801bad83a..e2eb2da60f96 100644 --- a/arch/ia64/sn/kernel/io_init.c +++ b/arch/ia64/sn/kernel/io_init.c | |||
@@ -269,7 +269,7 @@ sn_io_slot_fixup(struct pci_dev *dev) | |||
269 | 269 | ||
270 | rom = ioremap(pci_resource_start(dev, PCI_ROM_RESOURCE), | 270 | rom = ioremap(pci_resource_start(dev, PCI_ROM_RESOURCE), |
271 | size + 1); | 271 | size + 1); |
272 | image_size = pci_get_rom_size(rom, size + 1); | 272 | image_size = pci_get_rom_size(dev, rom, size + 1); |
273 | dev->resource[PCI_ROM_RESOURCE].end = | 273 | dev->resource[PCI_ROM_RESOURCE].end = |
274 | dev->resource[PCI_ROM_RESOURCE].start + | 274 | dev->resource[PCI_ROM_RESOURCE].start + |
275 | image_size - 1; | 275 | image_size - 1; |
diff --git a/arch/mips/include/asm/spinlock.h b/arch/mips/include/asm/spinlock.h index 1a1f320c30d8..0884947ebe27 100644 --- a/arch/mips/include/asm/spinlock.h +++ b/arch/mips/include/asm/spinlock.h | |||
@@ -51,6 +51,7 @@ static inline int __raw_spin_is_contended(raw_spinlock_t *lock) | |||
51 | 51 | ||
52 | return (((counters >> 14) - counters) & 0x1fff) > 1; | 52 | return (((counters >> 14) - counters) & 0x1fff) > 1; |
53 | } | 53 | } |
54 | #define __raw_spin_is_contended __raw_spin_is_contended | ||
54 | 55 | ||
55 | static inline void __raw_spin_lock(raw_spinlock_t *lock) | 56 | static inline void __raw_spin_lock(raw_spinlock_t *lock) |
56 | { | 57 | { |
diff --git a/arch/powerpc/boot/dts/mpc8313erdb.dts b/arch/powerpc/boot/dts/mpc8313erdb.dts index 909a89cab9ac..3ebf7ec0484c 100644 --- a/arch/powerpc/boot/dts/mpc8313erdb.dts +++ b/arch/powerpc/boot/dts/mpc8313erdb.dts | |||
@@ -191,7 +191,8 @@ | |||
191 | interrupts = <37 0x8 36 0x8 35 0x8>; | 191 | interrupts = <37 0x8 36 0x8 35 0x8>; |
192 | interrupt-parent = <&ipic>; | 192 | interrupt-parent = <&ipic>; |
193 | tbi-handle = < &tbi0 >; | 193 | tbi-handle = < &tbi0 >; |
194 | phy-handle = < &phy1 >; | 194 | /* Vitesse 7385 isn't on the MDIO bus */ |
195 | fixed-link = <1 1 1000 0 0>; | ||
195 | fsl,magic-packet; | 196 | fsl,magic-packet; |
196 | 197 | ||
197 | mdio@24520 { | 198 | mdio@24520 { |
@@ -199,12 +200,6 @@ | |||
199 | #size-cells = <0>; | 200 | #size-cells = <0>; |
200 | compatible = "fsl,gianfar-mdio"; | 201 | compatible = "fsl,gianfar-mdio"; |
201 | reg = <0x24520 0x20>; | 202 | reg = <0x24520 0x20>; |
202 | phy1: ethernet-phy@1 { | ||
203 | interrupt-parent = <&ipic>; | ||
204 | interrupts = <19 0x8>; | ||
205 | reg = <0x1>; | ||
206 | device_type = "ethernet-phy"; | ||
207 | }; | ||
208 | phy4: ethernet-phy@4 { | 203 | phy4: ethernet-phy@4 { |
209 | interrupt-parent = <&ipic>; | 204 | interrupt-parent = <&ipic>; |
210 | interrupts = <20 0x8>; | 205 | interrupts = <20 0x8>; |
@@ -219,6 +214,8 @@ | |||
219 | }; | 214 | }; |
220 | 215 | ||
221 | enet1: ethernet@25000 { | 216 | enet1: ethernet@25000 { |
217 | #address-cells = <1>; | ||
218 | #size-cells = <1>; | ||
222 | cell-index = <1>; | 219 | cell-index = <1>; |
223 | device_type = "network"; | 220 | device_type = "network"; |
224 | model = "eTSEC"; | 221 | model = "eTSEC"; |
diff --git a/arch/powerpc/configs/83xx/mpc8313_rdb_defconfig b/arch/powerpc/configs/83xx/mpc8313_rdb_defconfig index 9e47ae957e2e..409d017621a8 100644 --- a/arch/powerpc/configs/83xx/mpc8313_rdb_defconfig +++ b/arch/powerpc/configs/83xx/mpc8313_rdb_defconfig | |||
@@ -651,7 +651,7 @@ CONFIG_CICADA_PHY=y | |||
651 | # CONFIG_NATIONAL_PHY is not set | 651 | # CONFIG_NATIONAL_PHY is not set |
652 | # CONFIG_STE10XP is not set | 652 | # CONFIG_STE10XP is not set |
653 | # CONFIG_LSI_ET1011C_PHY is not set | 653 | # CONFIG_LSI_ET1011C_PHY is not set |
654 | # CONFIG_FIXED_PHY is not set | 654 | CONFIG_FIXED_PHY=y |
655 | # CONFIG_MDIO_BITBANG is not set | 655 | # CONFIG_MDIO_BITBANG is not set |
656 | CONFIG_NET_ETHERNET=y | 656 | CONFIG_NET_ETHERNET=y |
657 | CONFIG_MII=y | 657 | CONFIG_MII=y |
diff --git a/arch/powerpc/kernel/ftrace.c b/arch/powerpc/kernel/ftrace.c index 5355244c99ff..60c60ccf5e3c 100644 --- a/arch/powerpc/kernel/ftrace.c +++ b/arch/powerpc/kernel/ftrace.c | |||
@@ -195,8 +195,9 @@ __ftrace_make_nop(struct module *mod, | |||
195 | return -EINVAL; | 195 | return -EINVAL; |
196 | } | 196 | } |
197 | 197 | ||
198 | offset = (unsigned)((unsigned short)jmp[0]) << 16 | | 198 | /* The bottom half is signed extended */ |
199 | (unsigned)((unsigned short)jmp[1]); | 199 | offset = ((unsigned)((unsigned short)jmp[0]) << 16) + |
200 | (int)((short)jmp[1]); | ||
200 | 201 | ||
201 | DEBUGP(" %x ", offset); | 202 | DEBUGP(" %x ", offset); |
202 | 203 | ||
diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c index 19b12d2cbb4b..0f4181272311 100644 --- a/arch/powerpc/kernel/pci-common.c +++ b/arch/powerpc/kernel/pci-common.c | |||
@@ -561,8 +561,21 @@ int pci_mmap_legacy_page_range(struct pci_bus *bus, | |||
561 | (unsigned long long)(offset + size - 1)); | 561 | (unsigned long long)(offset + size - 1)); |
562 | 562 | ||
563 | if (mmap_state == pci_mmap_mem) { | 563 | if (mmap_state == pci_mmap_mem) { |
564 | if ((offset + size) > hose->isa_mem_size) | 564 | /* Hack alert ! |
565 | return -ENXIO; | 565 | * |
566 | * Because X is lame and can fail starting if it gets an error trying | ||
567 | * to mmap legacy_mem (instead of just moving on without legacy memory | ||
568 | * access) we fake it here by giving it anonymous memory, effectively | ||
569 | * behaving just like /dev/zero | ||
570 | */ | ||
571 | if ((offset + size) > hose->isa_mem_size) { | ||
572 | printk(KERN_DEBUG | ||
573 | "Process %s (pid:%d) mapped non-existing PCI legacy memory for 0%04x:%02x\n", | ||
574 | current->comm, current->pid, pci_domain_nr(bus), bus->number); | ||
575 | if (vma->vm_flags & VM_SHARED) | ||
576 | return shmem_zero_setup(vma); | ||
577 | return 0; | ||
578 | } | ||
566 | offset += hose->isa_mem_phys; | 579 | offset += hose->isa_mem_phys; |
567 | } else { | 580 | } else { |
568 | unsigned long io_offset = (unsigned long)hose->io_base_virt - _IO_BASE; | 581 | unsigned long io_offset = (unsigned long)hose->io_base_virt - _IO_BASE; |
diff --git a/arch/powerpc/lib/sstep.c b/arch/powerpc/lib/sstep.c index 4aae0c387645..13b7d54f185b 100644 --- a/arch/powerpc/lib/sstep.c +++ b/arch/powerpc/lib/sstep.c | |||
@@ -172,6 +172,8 @@ int __kprobes emulate_step(struct pt_regs *regs, unsigned int instr) | |||
172 | } | 172 | } |
173 | break; | 173 | break; |
174 | case 0x378: /* orx */ | 174 | case 0x378: /* orx */ |
175 | if (instr & 1) | ||
176 | break; | ||
175 | rs = (instr >> 21) & 0x1f; | 177 | rs = (instr >> 21) & 0x1f; |
176 | rb = (instr >> 11) & 0x1f; | 178 | rb = (instr >> 11) & 0x1f; |
177 | if (rs == rb) { /* mr */ | 179 | if (rs == rb) { /* mr */ |
diff --git a/arch/powerpc/mm/fsl_booke_mmu.c b/arch/powerpc/mm/fsl_booke_mmu.c index 1971e4ee3d6e..ea6e41e39d9f 100644 --- a/arch/powerpc/mm/fsl_booke_mmu.c +++ b/arch/powerpc/mm/fsl_booke_mmu.c | |||
@@ -73,7 +73,7 @@ extern unsigned int tlbcam_index; | |||
73 | /* | 73 | /* |
74 | * Return PA for this VA if it is mapped by a CAM, or 0 | 74 | * Return PA for this VA if it is mapped by a CAM, or 0 |
75 | */ | 75 | */ |
76 | unsigned long v_mapped_by_tlbcam(unsigned long va) | 76 | phys_addr_t v_mapped_by_tlbcam(unsigned long va) |
77 | { | 77 | { |
78 | int b; | 78 | int b; |
79 | for (b = 0; b < tlbcam_index; ++b) | 79 | for (b = 0; b < tlbcam_index; ++b) |
@@ -85,7 +85,7 @@ unsigned long v_mapped_by_tlbcam(unsigned long va) | |||
85 | /* | 85 | /* |
86 | * Return VA for a given PA or 0 if not mapped | 86 | * Return VA for a given PA or 0 if not mapped |
87 | */ | 87 | */ |
88 | unsigned long p_mapped_by_tlbcam(unsigned long pa) | 88 | unsigned long p_mapped_by_tlbcam(phys_addr_t pa) |
89 | { | 89 | { |
90 | int b; | 90 | int b; |
91 | for (b = 0; b < tlbcam_index; ++b) | 91 | for (b = 0; b < tlbcam_index; ++b) |
diff --git a/arch/powerpc/mm/hash_low_32.S b/arch/powerpc/mm/hash_low_32.S index 67850ec9feb3..14af8cedab70 100644 --- a/arch/powerpc/mm/hash_low_32.S +++ b/arch/powerpc/mm/hash_low_32.S | |||
@@ -320,7 +320,7 @@ _GLOBAL(create_hpte) | |||
320 | and r8,r8,r0 /* writable if _RW & _DIRTY */ | 320 | and r8,r8,r0 /* writable if _RW & _DIRTY */ |
321 | rlwimi r5,r5,32-1,30,30 /* _PAGE_USER -> PP msb */ | 321 | rlwimi r5,r5,32-1,30,30 /* _PAGE_USER -> PP msb */ |
322 | rlwimi r5,r5,32-2,31,31 /* _PAGE_USER -> PP lsb */ | 322 | rlwimi r5,r5,32-2,31,31 /* _PAGE_USER -> PP lsb */ |
323 | ori r8,r8,0xe14 /* clear out reserved bits and M */ | 323 | ori r8,r8,0xe04 /* clear out reserved bits */ |
324 | andc r8,r5,r8 /* PP = user? (rw&dirty? 2: 3): 0 */ | 324 | andc r8,r5,r8 /* PP = user? (rw&dirty? 2: 3): 0 */ |
325 | BEGIN_FTR_SECTION | 325 | BEGIN_FTR_SECTION |
326 | rlwinm r8,r8,0,~_PAGE_COHERENT /* clear M (coherence not required) */ | 326 | rlwinm r8,r8,0,~_PAGE_COHERENT /* clear M (coherence not required) */ |
diff --git a/arch/powerpc/mm/pgtable_32.c b/arch/powerpc/mm/pgtable_32.c index 22972cd83cc9..58bcaeba728d 100644 --- a/arch/powerpc/mm/pgtable_32.c +++ b/arch/powerpc/mm/pgtable_32.c | |||
@@ -61,8 +61,8 @@ void setbat(int index, unsigned long virt, phys_addr_t phys, | |||
61 | 61 | ||
62 | #ifdef HAVE_TLBCAM | 62 | #ifdef HAVE_TLBCAM |
63 | extern unsigned int tlbcam_index; | 63 | extern unsigned int tlbcam_index; |
64 | extern unsigned long v_mapped_by_tlbcam(unsigned long va); | 64 | extern phys_addr_t v_mapped_by_tlbcam(unsigned long va); |
65 | extern unsigned long p_mapped_by_tlbcam(unsigned long pa); | 65 | extern unsigned long p_mapped_by_tlbcam(phys_addr_t pa); |
66 | #else /* !HAVE_TLBCAM */ | 66 | #else /* !HAVE_TLBCAM */ |
67 | #define v_mapped_by_tlbcam(x) (0UL) | 67 | #define v_mapped_by_tlbcam(x) (0UL) |
68 | #define p_mapped_by_tlbcam(x) (0UL) | 68 | #define p_mapped_by_tlbcam(x) (0UL) |
diff --git a/arch/powerpc/oprofile/cell/spu_profiler.c b/arch/powerpc/oprofile/cell/spu_profiler.c index 9305ddaac512..b129d007e7fe 100644 --- a/arch/powerpc/oprofile/cell/spu_profiler.c +++ b/arch/powerpc/oprofile/cell/spu_profiler.c | |||
@@ -16,6 +16,7 @@ | |||
16 | #include <linux/smp.h> | 16 | #include <linux/smp.h> |
17 | #include <linux/slab.h> | 17 | #include <linux/slab.h> |
18 | #include <asm/cell-pmu.h> | 18 | #include <asm/cell-pmu.h> |
19 | #include <asm/time.h> | ||
19 | #include "pr_util.h" | 20 | #include "pr_util.h" |
20 | 21 | ||
21 | #define SCALE_SHIFT 14 | 22 | #define SCALE_SHIFT 14 |
diff --git a/arch/powerpc/platforms/82xx/pq2ads-pci-pic.c b/arch/powerpc/platforms/82xx/pq2ads-pci-pic.c index 9876d7e072f4..ddf0bdc0fc8b 100644 --- a/arch/powerpc/platforms/82xx/pq2ads-pci-pic.c +++ b/arch/powerpc/platforms/82xx/pq2ads-pci-pic.c | |||
@@ -186,7 +186,7 @@ out_unmap_regs: | |||
186 | iounmap(priv->regs); | 186 | iounmap(priv->regs); |
187 | out_free_bootmem: | 187 | out_free_bootmem: |
188 | free_bootmem((unsigned long)priv, | 188 | free_bootmem((unsigned long)priv, |
189 | sizeof(sizeof(struct pq2ads_pci_pic))); | 189 | sizeof(struct pq2ads_pci_pic)); |
190 | of_node_put(np); | 190 | of_node_put(np); |
191 | out_unmap_irq: | 191 | out_unmap_irq: |
192 | irq_dispose_mapping(irq); | 192 | irq_dispose_mapping(irq); |
diff --git a/arch/powerpc/platforms/pseries/hotplug-memory.c b/arch/powerpc/platforms/pseries/hotplug-memory.c index a623ad256e9e..9b21ee68ea50 100644 --- a/arch/powerpc/platforms/pseries/hotplug-memory.c +++ b/arch/powerpc/platforms/pseries/hotplug-memory.c | |||
@@ -14,6 +14,7 @@ | |||
14 | #include <asm/firmware.h> | 14 | #include <asm/firmware.h> |
15 | #include <asm/machdep.h> | 15 | #include <asm/machdep.h> |
16 | #include <asm/pSeries_reconfig.h> | 16 | #include <asm/pSeries_reconfig.h> |
17 | #include <asm/sparsemem.h> | ||
17 | 18 | ||
18 | static int pseries_remove_lmb(unsigned long base, unsigned int lmb_size) | 19 | static int pseries_remove_lmb(unsigned long base, unsigned int lmb_size) |
19 | { | 20 | { |
diff --git a/arch/powerpc/sysdev/cpm2_pic.c b/arch/powerpc/sysdev/cpm2_pic.c index b16ca3ed65d2..78f1f7cca0a0 100644 --- a/arch/powerpc/sysdev/cpm2_pic.c +++ b/arch/powerpc/sysdev/cpm2_pic.c | |||
@@ -165,7 +165,7 @@ static int cpm2_set_irq_type(unsigned int virq, unsigned int flow_type) | |||
165 | edibit = (14 - (src - CPM2_IRQ_EXT1)); | 165 | edibit = (14 - (src - CPM2_IRQ_EXT1)); |
166 | else | 166 | else |
167 | if (src >= CPM2_IRQ_PORTC15 && src <= CPM2_IRQ_PORTC0) | 167 | if (src >= CPM2_IRQ_PORTC15 && src <= CPM2_IRQ_PORTC0) |
168 | edibit = (31 - (src - CPM2_IRQ_PORTC15)); | 168 | edibit = (31 - (CPM2_IRQ_PORTC0 - src)); |
169 | else | 169 | else |
170 | return (flow_type & IRQ_TYPE_LEVEL_LOW) ? 0 : -EINVAL; | 170 | return (flow_type & IRQ_TYPE_LEVEL_LOW) ? 0 : -EINVAL; |
171 | 171 | ||
diff --git a/arch/powerpc/sysdev/ipic.c b/arch/powerpc/sysdev/ipic.c index 88a983ece5c9..9a89cd3e80a2 100644 --- a/arch/powerpc/sysdev/ipic.c +++ b/arch/powerpc/sysdev/ipic.c | |||
@@ -890,7 +890,7 @@ unsigned int ipic_get_irq(void) | |||
890 | return irq_linear_revmap(primary_ipic->irqhost, irq); | 890 | return irq_linear_revmap(primary_ipic->irqhost, irq); |
891 | } | 891 | } |
892 | 892 | ||
893 | #ifdef CONFIG_PM | 893 | #ifdef CONFIG_SUSPEND |
894 | static struct { | 894 | static struct { |
895 | u32 sicfr; | 895 | u32 sicfr; |
896 | u32 siprr[2]; | 896 | u32 siprr[2]; |
diff --git a/arch/s390/defconfig b/arch/s390/defconfig index a0e748da9909..31e809c77790 100644 --- a/arch/s390/defconfig +++ b/arch/s390/defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.28-rc6 | 3 | # Linux kernel version: 2.6.29-rc4 |
4 | # Thu Nov 27 11:00:49 2008 | 4 | # Wed Feb 11 10:07:16 2009 |
5 | # | 5 | # |
6 | CONFIG_SCHED_MC=y | 6 | CONFIG_SCHED_MC=y |
7 | CONFIG_MMU=y | 7 | CONFIG_MMU=y |
@@ -14,12 +14,14 @@ CONFIG_RWSEM_XCHGADD_ALGORITHM=y | |||
14 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | 14 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set |
15 | CONFIG_GENERIC_HWEIGHT=y | 15 | CONFIG_GENERIC_HWEIGHT=y |
16 | CONFIG_GENERIC_TIME=y | 16 | CONFIG_GENERIC_TIME=y |
17 | CONFIG_GENERIC_TIME_VSYSCALL=y | ||
17 | CONFIG_GENERIC_CLOCKEVENTS=y | 18 | CONFIG_GENERIC_CLOCKEVENTS=y |
18 | CONFIG_GENERIC_BUG=y | 19 | CONFIG_GENERIC_BUG=y |
19 | CONFIG_NO_IOMEM=y | 20 | CONFIG_NO_IOMEM=y |
20 | CONFIG_NO_DMA=y | 21 | CONFIG_NO_DMA=y |
21 | CONFIG_GENERIC_LOCKBREAK=y | 22 | CONFIG_GENERIC_LOCKBREAK=y |
22 | CONFIG_PGSTE=y | 23 | CONFIG_PGSTE=y |
24 | CONFIG_VIRT_CPU_ACCOUNTING=y | ||
23 | CONFIG_S390=y | 25 | CONFIG_S390=y |
24 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | 26 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" |
25 | 27 | ||
@@ -39,20 +41,29 @@ CONFIG_POSIX_MQUEUE=y | |||
39 | # CONFIG_TASKSTATS is not set | 41 | # CONFIG_TASKSTATS is not set |
40 | CONFIG_AUDIT=y | 42 | CONFIG_AUDIT=y |
41 | # CONFIG_AUDITSYSCALL is not set | 43 | # CONFIG_AUDITSYSCALL is not set |
44 | |||
45 | # | ||
46 | # RCU Subsystem | ||
47 | # | ||
48 | CONFIG_CLASSIC_RCU=y | ||
49 | # CONFIG_TREE_RCU is not set | ||
50 | # CONFIG_PREEMPT_RCU is not set | ||
51 | # CONFIG_TREE_RCU_TRACE is not set | ||
52 | # CONFIG_PREEMPT_RCU_TRACE is not set | ||
42 | CONFIG_IKCONFIG=y | 53 | CONFIG_IKCONFIG=y |
43 | CONFIG_IKCONFIG_PROC=y | 54 | CONFIG_IKCONFIG_PROC=y |
44 | CONFIG_LOG_BUF_SHIFT=17 | 55 | CONFIG_LOG_BUF_SHIFT=17 |
56 | CONFIG_GROUP_SCHED=y | ||
57 | CONFIG_FAIR_GROUP_SCHED=y | ||
58 | # CONFIG_RT_GROUP_SCHED is not set | ||
59 | CONFIG_USER_SCHED=y | ||
60 | # CONFIG_CGROUP_SCHED is not set | ||
45 | CONFIG_CGROUPS=y | 61 | CONFIG_CGROUPS=y |
46 | # CONFIG_CGROUP_DEBUG is not set | 62 | # CONFIG_CGROUP_DEBUG is not set |
47 | CONFIG_CGROUP_NS=y | 63 | CONFIG_CGROUP_NS=y |
48 | # CONFIG_CGROUP_FREEZER is not set | 64 | # CONFIG_CGROUP_FREEZER is not set |
49 | # CONFIG_CGROUP_DEVICE is not set | 65 | # CONFIG_CGROUP_DEVICE is not set |
50 | # CONFIG_CPUSETS is not set | 66 | # CONFIG_CPUSETS is not set |
51 | CONFIG_GROUP_SCHED=y | ||
52 | CONFIG_FAIR_GROUP_SCHED=y | ||
53 | # CONFIG_RT_GROUP_SCHED is not set | ||
54 | CONFIG_USER_SCHED=y | ||
55 | # CONFIG_CGROUP_SCHED is not set | ||
56 | # CONFIG_CGROUP_CPUACCT is not set | 67 | # CONFIG_CGROUP_CPUACCT is not set |
57 | # CONFIG_RESOURCE_COUNTERS is not set | 68 | # CONFIG_RESOURCE_COUNTERS is not set |
58 | CONFIG_SYSFS_DEPRECATED=y | 69 | CONFIG_SYSFS_DEPRECATED=y |
@@ -63,6 +74,7 @@ CONFIG_UTS_NS=y | |||
63 | CONFIG_IPC_NS=y | 74 | CONFIG_IPC_NS=y |
64 | # CONFIG_USER_NS is not set | 75 | # CONFIG_USER_NS is not set |
65 | # CONFIG_PID_NS is not set | 76 | # CONFIG_PID_NS is not set |
77 | # CONFIG_NET_NS is not set | ||
66 | CONFIG_BLK_DEV_INITRD=y | 78 | CONFIG_BLK_DEV_INITRD=y |
67 | CONFIG_INITRAMFS_SOURCE="" | 79 | CONFIG_INITRAMFS_SOURCE="" |
68 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 80 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set |
@@ -91,17 +103,17 @@ CONFIG_SLAB=y | |||
91 | # CONFIG_SLUB is not set | 103 | # CONFIG_SLUB is not set |
92 | # CONFIG_SLOB is not set | 104 | # CONFIG_SLOB is not set |
93 | # CONFIG_PROFILING is not set | 105 | # CONFIG_PROFILING is not set |
94 | # CONFIG_MARKERS is not set | ||
95 | CONFIG_HAVE_OPROFILE=y | 106 | CONFIG_HAVE_OPROFILE=y |
96 | CONFIG_KPROBES=y | 107 | CONFIG_KPROBES=y |
108 | CONFIG_HAVE_SYSCALL_WRAPPERS=y | ||
97 | CONFIG_KRETPROBES=y | 109 | CONFIG_KRETPROBES=y |
98 | CONFIG_HAVE_KPROBES=y | 110 | CONFIG_HAVE_KPROBES=y |
99 | CONFIG_HAVE_KRETPROBES=y | 111 | CONFIG_HAVE_KRETPROBES=y |
100 | CONFIG_HAVE_ARCH_TRACEHOOK=y | 112 | CONFIG_HAVE_ARCH_TRACEHOOK=y |
113 | CONFIG_USE_GENERIC_SMP_HELPERS=y | ||
101 | # CONFIG_HAVE_GENERIC_DMA_COHERENT is not set | 114 | # CONFIG_HAVE_GENERIC_DMA_COHERENT is not set |
102 | CONFIG_SLABINFO=y | 115 | CONFIG_SLABINFO=y |
103 | CONFIG_RT_MUTEXES=y | 116 | CONFIG_RT_MUTEXES=y |
104 | # CONFIG_TINY_SHMEM is not set | ||
105 | CONFIG_BASE_SMALL=0 | 117 | CONFIG_BASE_SMALL=0 |
106 | CONFIG_MODULES=y | 118 | CONFIG_MODULES=y |
107 | # CONFIG_MODULE_FORCE_LOAD is not set | 119 | # CONFIG_MODULE_FORCE_LOAD is not set |
@@ -109,7 +121,7 @@ CONFIG_MODULE_UNLOAD=y | |||
109 | # CONFIG_MODULE_FORCE_UNLOAD is not set | 121 | # CONFIG_MODULE_FORCE_UNLOAD is not set |
110 | CONFIG_MODVERSIONS=y | 122 | CONFIG_MODVERSIONS=y |
111 | # CONFIG_MODULE_SRCVERSION_ALL is not set | 123 | # CONFIG_MODULE_SRCVERSION_ALL is not set |
112 | CONFIG_KMOD=y | 124 | CONFIG_INIT_ALL_POSSIBLE=y |
113 | CONFIG_STOP_MACHINE=y | 125 | CONFIG_STOP_MACHINE=y |
114 | CONFIG_BLOCK=y | 126 | CONFIG_BLOCK=y |
115 | # CONFIG_BLK_DEV_IO_TRACE is not set | 127 | # CONFIG_BLK_DEV_IO_TRACE is not set |
@@ -130,7 +142,6 @@ CONFIG_DEFAULT_DEADLINE=y | |||
130 | # CONFIG_DEFAULT_NOOP is not set | 142 | # CONFIG_DEFAULT_NOOP is not set |
131 | CONFIG_DEFAULT_IOSCHED="deadline" | 143 | CONFIG_DEFAULT_IOSCHED="deadline" |
132 | CONFIG_PREEMPT_NOTIFIERS=y | 144 | CONFIG_PREEMPT_NOTIFIERS=y |
133 | CONFIG_CLASSIC_RCU=y | ||
134 | # CONFIG_FREEZER is not set | 145 | # CONFIG_FREEZER is not set |
135 | 146 | ||
136 | # | 147 | # |
@@ -161,6 +172,7 @@ CONFIG_S390_EXEC_PROTECT=y | |||
161 | CONFIG_MARCH_Z900=y | 172 | CONFIG_MARCH_Z900=y |
162 | # CONFIG_MARCH_Z990 is not set | 173 | # CONFIG_MARCH_Z990 is not set |
163 | # CONFIG_MARCH_Z9_109 is not set | 174 | # CONFIG_MARCH_Z9_109 is not set |
175 | # CONFIG_MARCH_Z10 is not set | ||
164 | CONFIG_PACK_STACK=y | 176 | CONFIG_PACK_STACK=y |
165 | # CONFIG_SMALL_STACK is not set | 177 | # CONFIG_SMALL_STACK is not set |
166 | CONFIG_CHECK_STACK=y | 178 | CONFIG_CHECK_STACK=y |
@@ -174,7 +186,6 @@ CONFIG_ARCH_POPULATES_NODE_MAP=y | |||
174 | # CONFIG_PREEMPT_NONE is not set | 186 | # CONFIG_PREEMPT_NONE is not set |
175 | # CONFIG_PREEMPT_VOLUNTARY is not set | 187 | # CONFIG_PREEMPT_VOLUNTARY is not set |
176 | CONFIG_PREEMPT=y | 188 | CONFIG_PREEMPT=y |
177 | # CONFIG_PREEMPT_RCU is not set | ||
178 | CONFIG_ARCH_SPARSEMEM_ENABLE=y | 189 | CONFIG_ARCH_SPARSEMEM_ENABLE=y |
179 | CONFIG_ARCH_SPARSEMEM_DEFAULT=y | 190 | CONFIG_ARCH_SPARSEMEM_DEFAULT=y |
180 | CONFIG_ARCH_SELECT_MEMORY_MODEL=y | 191 | CONFIG_ARCH_SELECT_MEMORY_MODEL=y |
@@ -195,7 +206,6 @@ CONFIG_MEMORY_HOTREMOVE=y | |||
195 | CONFIG_PAGEFLAGS_EXTENDED=y | 206 | CONFIG_PAGEFLAGS_EXTENDED=y |
196 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 207 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
197 | CONFIG_MIGRATION=y | 208 | CONFIG_MIGRATION=y |
198 | CONFIG_RESOURCES_64BIT=y | ||
199 | CONFIG_PHYS_ADDR_T_64BIT=y | 209 | CONFIG_PHYS_ADDR_T_64BIT=y |
200 | CONFIG_ZONE_DMA_FLAG=1 | 210 | CONFIG_ZONE_DMA_FLAG=1 |
201 | CONFIG_BOUNCE=y | 211 | CONFIG_BOUNCE=y |
@@ -207,7 +217,6 @@ CONFIG_UNEVICTABLE_LRU=y | |||
207 | # | 217 | # |
208 | CONFIG_MACHCHK_WARNING=y | 218 | CONFIG_MACHCHK_WARNING=y |
209 | CONFIG_QDIO=y | 219 | CONFIG_QDIO=y |
210 | # CONFIG_QDIO_DEBUG is not set | ||
211 | CONFIG_CHSC_SCH=m | 220 | CONFIG_CHSC_SCH=m |
212 | 221 | ||
213 | # | 222 | # |
@@ -227,15 +236,13 @@ CONFIG_PFAULT=y | |||
227 | # CONFIG_SHARED_KERNEL is not set | 236 | # CONFIG_SHARED_KERNEL is not set |
228 | # CONFIG_CMM is not set | 237 | # CONFIG_CMM is not set |
229 | # CONFIG_PAGE_STATES is not set | 238 | # CONFIG_PAGE_STATES is not set |
230 | CONFIG_VIRT_TIMER=y | ||
231 | CONFIG_VIRT_CPU_ACCOUNTING=y | ||
232 | # CONFIG_APPLDATA_BASE is not set | 239 | # CONFIG_APPLDATA_BASE is not set |
233 | CONFIG_HZ_100=y | 240 | CONFIG_HZ_100=y |
234 | # CONFIG_HZ_250 is not set | 241 | # CONFIG_HZ_250 is not set |
235 | # CONFIG_HZ_300 is not set | 242 | # CONFIG_HZ_300 is not set |
236 | # CONFIG_HZ_1000 is not set | 243 | # CONFIG_HZ_1000 is not set |
237 | CONFIG_HZ=100 | 244 | CONFIG_HZ=100 |
238 | # CONFIG_SCHED_HRTICK is not set | 245 | CONFIG_SCHED_HRTICK=y |
239 | CONFIG_S390_HYPFS_FS=y | 246 | CONFIG_S390_HYPFS_FS=y |
240 | CONFIG_KEXEC=y | 247 | CONFIG_KEXEC=y |
241 | # CONFIG_ZFCPDUMP is not set | 248 | # CONFIG_ZFCPDUMP is not set |
@@ -245,6 +252,7 @@ CONFIG_NET=y | |||
245 | # | 252 | # |
246 | # Networking options | 253 | # Networking options |
247 | # | 254 | # |
255 | CONFIG_COMPAT_NET_DEV_OPS=y | ||
248 | CONFIG_PACKET=y | 256 | CONFIG_PACKET=y |
249 | # CONFIG_PACKET_MMAP is not set | 257 | # CONFIG_PACKET_MMAP is not set |
250 | CONFIG_UNIX=y | 258 | CONFIG_UNIX=y |
@@ -383,6 +391,7 @@ CONFIG_NET_SCH_TBF=m | |||
383 | CONFIG_NET_SCH_GRED=m | 391 | CONFIG_NET_SCH_GRED=m |
384 | CONFIG_NET_SCH_DSMARK=m | 392 | CONFIG_NET_SCH_DSMARK=m |
385 | # CONFIG_NET_SCH_NETEM is not set | 393 | # CONFIG_NET_SCH_NETEM is not set |
394 | # CONFIG_NET_SCH_DRR is not set | ||
386 | # CONFIG_NET_SCH_INGRESS is not set | 395 | # CONFIG_NET_SCH_INGRESS is not set |
387 | 396 | ||
388 | # | 397 | # |
@@ -400,6 +409,7 @@ CONFIG_CLS_U32_MARK=y | |||
400 | CONFIG_NET_CLS_RSVP=m | 409 | CONFIG_NET_CLS_RSVP=m |
401 | CONFIG_NET_CLS_RSVP6=m | 410 | CONFIG_NET_CLS_RSVP6=m |
402 | CONFIG_NET_CLS_FLOW=m | 411 | CONFIG_NET_CLS_FLOW=m |
412 | # CONFIG_NET_CLS_CGROUP is not set | ||
403 | # CONFIG_NET_EMATCH is not set | 413 | # CONFIG_NET_EMATCH is not set |
404 | CONFIG_NET_CLS_ACT=y | 414 | CONFIG_NET_CLS_ACT=y |
405 | CONFIG_NET_ACT_POLICE=y | 415 | CONFIG_NET_ACT_POLICE=y |
@@ -411,6 +421,7 @@ CONFIG_NET_ACT_NAT=m | |||
411 | # CONFIG_NET_ACT_SKBEDIT is not set | 421 | # CONFIG_NET_ACT_SKBEDIT is not set |
412 | # CONFIG_NET_CLS_IND is not set | 422 | # CONFIG_NET_CLS_IND is not set |
413 | CONFIG_NET_SCH_FIFO=y | 423 | CONFIG_NET_SCH_FIFO=y |
424 | # CONFIG_DCB is not set | ||
414 | 425 | ||
415 | # | 426 | # |
416 | # Network testing | 427 | # Network testing |
@@ -428,6 +439,7 @@ CONFIG_CAN_VCAN=m | |||
428 | # CONFIG_CAN_DEBUG_DEVICES is not set | 439 | # CONFIG_CAN_DEBUG_DEVICES is not set |
429 | # CONFIG_AF_RXRPC is not set | 440 | # CONFIG_AF_RXRPC is not set |
430 | # CONFIG_PHONET is not set | 441 | # CONFIG_PHONET is not set |
442 | # CONFIG_WIMAX is not set | ||
431 | # CONFIG_RFKILL is not set | 443 | # CONFIG_RFKILL is not set |
432 | # CONFIG_NET_9P is not set | 444 | # CONFIG_NET_9P is not set |
433 | # CONFIG_PCMCIA is not set | 445 | # CONFIG_PCMCIA is not set |
@@ -475,11 +487,15 @@ CONFIG_DASD_DIAG=y | |||
475 | CONFIG_DASD_EER=y | 487 | CONFIG_DASD_EER=y |
476 | CONFIG_VIRTIO_BLK=m | 488 | CONFIG_VIRTIO_BLK=m |
477 | CONFIG_MISC_DEVICES=y | 489 | CONFIG_MISC_DEVICES=y |
478 | # CONFIG_EEPROM_93CX6 is not set | ||
479 | # CONFIG_ENCLOSURE_SERVICES is not set | 490 | # CONFIG_ENCLOSURE_SERVICES is not set |
480 | # CONFIG_C2PORT is not set | 491 | # CONFIG_C2PORT is not set |
481 | 492 | ||
482 | # | 493 | # |
494 | # EEPROM support | ||
495 | # | ||
496 | # CONFIG_EEPROM_93CX6 is not set | ||
497 | |||
498 | # | ||
483 | # SCSI device support | 499 | # SCSI device support |
484 | # | 500 | # |
485 | # CONFIG_RAID_ATTRS is not set | 501 | # CONFIG_RAID_ATTRS is not set |
@@ -520,6 +536,7 @@ CONFIG_SCSI_FC_ATTRS=y | |||
520 | # CONFIG_SCSI_SRP_ATTRS is not set | 536 | # CONFIG_SCSI_SRP_ATTRS is not set |
521 | CONFIG_SCSI_LOWLEVEL=y | 537 | CONFIG_SCSI_LOWLEVEL=y |
522 | # CONFIG_ISCSI_TCP is not set | 538 | # CONFIG_ISCSI_TCP is not set |
539 | # CONFIG_LIBFC is not set | ||
523 | # CONFIG_SCSI_DEBUG is not set | 540 | # CONFIG_SCSI_DEBUG is not set |
524 | CONFIG_ZFCP=y | 541 | CONFIG_ZFCP=y |
525 | CONFIG_SCSI_DH=m | 542 | CONFIG_SCSI_DH=m |
@@ -566,6 +583,10 @@ CONFIG_NET_ETHERNET=y | |||
566 | CONFIG_NETDEV_1000=y | 583 | CONFIG_NETDEV_1000=y |
567 | CONFIG_NETDEV_10000=y | 584 | CONFIG_NETDEV_10000=y |
568 | # CONFIG_TR is not set | 585 | # CONFIG_TR is not set |
586 | |||
587 | # | ||
588 | # Enable WiMAX (Networking options) to see the WiMAX drivers | ||
589 | # | ||
569 | # CONFIG_WAN is not set | 590 | # CONFIG_WAN is not set |
570 | 591 | ||
571 | # | 592 | # |
@@ -593,9 +614,11 @@ CONFIG_VIRTIO_NET=m | |||
593 | # | 614 | # |
594 | CONFIG_DEVKMEM=y | 615 | CONFIG_DEVKMEM=y |
595 | CONFIG_UNIX98_PTYS=y | 616 | CONFIG_UNIX98_PTYS=y |
617 | # CONFIG_DEVPTS_MULTIPLE_INSTANCES is not set | ||
596 | CONFIG_LEGACY_PTYS=y | 618 | CONFIG_LEGACY_PTYS=y |
597 | CONFIG_LEGACY_PTY_COUNT=256 | 619 | CONFIG_LEGACY_PTY_COUNT=256 |
598 | CONFIG_HVC_DRIVER=y | 620 | CONFIG_HVC_DRIVER=y |
621 | CONFIG_HVC_IUCV=y | ||
599 | CONFIG_VIRTIO_CONSOLE=y | 622 | CONFIG_VIRTIO_CONSOLE=y |
600 | CONFIG_HW_RANDOM=m | 623 | CONFIG_HW_RANDOM=m |
601 | CONFIG_HW_RANDOM_VIRTIO=m | 624 | CONFIG_HW_RANDOM_VIRTIO=m |
@@ -645,7 +668,6 @@ CONFIG_S390_VMUR=m | |||
645 | # CONFIG_NEW_LEDS is not set | 668 | # CONFIG_NEW_LEDS is not set |
646 | CONFIG_ACCESSIBILITY=y | 669 | CONFIG_ACCESSIBILITY=y |
647 | # CONFIG_STAGING is not set | 670 | # CONFIG_STAGING is not set |
648 | CONFIG_STAGING_EXCLUDE_BUILD=y | ||
649 | 671 | ||
650 | # | 672 | # |
651 | # File systems | 673 | # File systems |
@@ -668,6 +690,7 @@ CONFIG_FILE_LOCKING=y | |||
668 | # CONFIG_XFS_FS is not set | 690 | # CONFIG_XFS_FS is not set |
669 | # CONFIG_GFS2_FS is not set | 691 | # CONFIG_GFS2_FS is not set |
670 | # CONFIG_OCFS2_FS is not set | 692 | # CONFIG_OCFS2_FS is not set |
693 | # CONFIG_BTRFS_FS is not set | ||
671 | CONFIG_DNOTIFY=y | 694 | CONFIG_DNOTIFY=y |
672 | CONFIG_INOTIFY=y | 695 | CONFIG_INOTIFY=y |
673 | CONFIG_INOTIFY_USER=y | 696 | CONFIG_INOTIFY_USER=y |
@@ -703,10 +726,7 @@ CONFIG_TMPFS_POSIX_ACL=y | |||
703 | # CONFIG_HUGETLBFS is not set | 726 | # CONFIG_HUGETLBFS is not set |
704 | # CONFIG_HUGETLB_PAGE is not set | 727 | # CONFIG_HUGETLB_PAGE is not set |
705 | CONFIG_CONFIGFS_FS=m | 728 | CONFIG_CONFIGFS_FS=m |
706 | 729 | CONFIG_MISC_FILESYSTEMS=y | |
707 | # | ||
708 | # Miscellaneous filesystems | ||
709 | # | ||
710 | # CONFIG_ADFS_FS is not set | 730 | # CONFIG_ADFS_FS is not set |
711 | # CONFIG_AFFS_FS is not set | 731 | # CONFIG_AFFS_FS is not set |
712 | # CONFIG_HFS_FS is not set | 732 | # CONFIG_HFS_FS is not set |
@@ -715,6 +735,7 @@ CONFIG_CONFIGFS_FS=m | |||
715 | # CONFIG_BFS_FS is not set | 735 | # CONFIG_BFS_FS is not set |
716 | # CONFIG_EFS_FS is not set | 736 | # CONFIG_EFS_FS is not set |
717 | # CONFIG_CRAMFS is not set | 737 | # CONFIG_CRAMFS is not set |
738 | # CONFIG_SQUASHFS is not set | ||
718 | # CONFIG_VXFS_FS is not set | 739 | # CONFIG_VXFS_FS is not set |
719 | # CONFIG_MINIX_FS is not set | 740 | # CONFIG_MINIX_FS is not set |
720 | # CONFIG_OMFS_FS is not set | 741 | # CONFIG_OMFS_FS is not set |
@@ -808,6 +829,7 @@ CONFIG_DEBUG_BUGVERBOSE=y | |||
808 | CONFIG_DEBUG_MEMORY_INIT=y | 829 | CONFIG_DEBUG_MEMORY_INIT=y |
809 | # CONFIG_DEBUG_LIST is not set | 830 | # CONFIG_DEBUG_LIST is not set |
810 | # CONFIG_DEBUG_SG is not set | 831 | # CONFIG_DEBUG_SG is not set |
832 | # CONFIG_DEBUG_NOTIFIERS is not set | ||
811 | # CONFIG_FRAME_POINTER is not set | 833 | # CONFIG_FRAME_POINTER is not set |
812 | # CONFIG_RCU_TORTURE_TEST is not set | 834 | # CONFIG_RCU_TORTURE_TEST is not set |
813 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set | 835 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set |
@@ -818,15 +840,19 @@ CONFIG_DEBUG_MEMORY_INIT=y | |||
818 | # CONFIG_FAULT_INJECTION is not set | 840 | # CONFIG_FAULT_INJECTION is not set |
819 | # CONFIG_LATENCYTOP is not set | 841 | # CONFIG_LATENCYTOP is not set |
820 | CONFIG_SYSCTL_SYSCALL_CHECK=y | 842 | CONFIG_SYSCTL_SYSCALL_CHECK=y |
843 | CONFIG_HAVE_FUNCTION_TRACER=y | ||
821 | 844 | ||
822 | # | 845 | # |
823 | # Tracers | 846 | # Tracers |
824 | # | 847 | # |
848 | # CONFIG_FUNCTION_TRACER is not set | ||
825 | # CONFIG_IRQSOFF_TRACER is not set | 849 | # CONFIG_IRQSOFF_TRACER is not set |
826 | # CONFIG_PREEMPT_TRACER is not set | 850 | # CONFIG_PREEMPT_TRACER is not set |
827 | # CONFIG_SCHED_TRACER is not set | 851 | # CONFIG_SCHED_TRACER is not set |
828 | # CONFIG_CONTEXT_SWITCH_TRACER is not set | 852 | # CONFIG_CONTEXT_SWITCH_TRACER is not set |
829 | # CONFIG_BOOT_TRACER is not set | 853 | # CONFIG_BOOT_TRACER is not set |
854 | # CONFIG_TRACE_BRANCH_PROFILING is not set | ||
855 | # CONFIG_STACK_TRACER is not set | ||
830 | # CONFIG_DYNAMIC_PRINTK_DEBUG is not set | 856 | # CONFIG_DYNAMIC_PRINTK_DEBUG is not set |
831 | CONFIG_SAMPLES=y | 857 | CONFIG_SAMPLES=y |
832 | # CONFIG_SAMPLE_KOBJECT is not set | 858 | # CONFIG_SAMPLE_KOBJECT is not set |
@@ -847,11 +873,17 @@ CONFIG_CRYPTO=y | |||
847 | # | 873 | # |
848 | CONFIG_CRYPTO_FIPS=y | 874 | CONFIG_CRYPTO_FIPS=y |
849 | CONFIG_CRYPTO_ALGAPI=y | 875 | CONFIG_CRYPTO_ALGAPI=y |
850 | CONFIG_CRYPTO_AEAD=y | 876 | CONFIG_CRYPTO_ALGAPI2=y |
877 | CONFIG_CRYPTO_AEAD=m | ||
878 | CONFIG_CRYPTO_AEAD2=y | ||
851 | CONFIG_CRYPTO_BLKCIPHER=y | 879 | CONFIG_CRYPTO_BLKCIPHER=y |
852 | CONFIG_CRYPTO_HASH=y | 880 | CONFIG_CRYPTO_BLKCIPHER2=y |
853 | CONFIG_CRYPTO_RNG=y | 881 | CONFIG_CRYPTO_HASH=m |
882 | CONFIG_CRYPTO_HASH2=y | ||
883 | CONFIG_CRYPTO_RNG=m | ||
884 | CONFIG_CRYPTO_RNG2=y | ||
854 | CONFIG_CRYPTO_MANAGER=y | 885 | CONFIG_CRYPTO_MANAGER=y |
886 | CONFIG_CRYPTO_MANAGER2=y | ||
855 | CONFIG_CRYPTO_GF128MUL=m | 887 | CONFIG_CRYPTO_GF128MUL=m |
856 | # CONFIG_CRYPTO_NULL is not set | 888 | # CONFIG_CRYPTO_NULL is not set |
857 | # CONFIG_CRYPTO_CRYPTD is not set | 889 | # CONFIG_CRYPTO_CRYPTD is not set |
@@ -885,7 +917,7 @@ CONFIG_CRYPTO_HMAC=m | |||
885 | # | 917 | # |
886 | # Digest | 918 | # Digest |
887 | # | 919 | # |
888 | # CONFIG_CRYPTO_CRC32C is not set | 920 | CONFIG_CRYPTO_CRC32C=m |
889 | # CONFIG_CRYPTO_MD4 is not set | 921 | # CONFIG_CRYPTO_MD4 is not set |
890 | CONFIG_CRYPTO_MD5=m | 922 | CONFIG_CRYPTO_MD5=m |
891 | # CONFIG_CRYPTO_MICHAEL_MIC is not set | 923 | # CONFIG_CRYPTO_MICHAEL_MIC is not set |
@@ -942,6 +974,7 @@ CONFIG_S390_PRNG=m | |||
942 | # Library routines | 974 | # Library routines |
943 | # | 975 | # |
944 | CONFIG_BITREVERSE=m | 976 | CONFIG_BITREVERSE=m |
977 | CONFIG_GENERIC_FIND_LAST_BIT=y | ||
945 | # CONFIG_CRC_CCITT is not set | 978 | # CONFIG_CRC_CCITT is not set |
946 | # CONFIG_CRC16 is not set | 979 | # CONFIG_CRC16 is not set |
947 | CONFIG_CRC_T10DIF=y | 980 | CONFIG_CRC_T10DIF=y |
diff --git a/arch/s390/include/asm/lowcore.h b/arch/s390/include/asm/lowcore.h index ffdef5fe8587..f3720defdd16 100644 --- a/arch/s390/include/asm/lowcore.h +++ b/arch/s390/include/asm/lowcore.h | |||
@@ -384,8 +384,8 @@ struct _lowcore | |||
384 | __u32 panic_magic; /* 0xe00 */ | 384 | __u32 panic_magic; /* 0xe00 */ |
385 | 385 | ||
386 | /* Per cpu primary space access list */ | 386 | /* Per cpu primary space access list */ |
387 | __u8 pad_0xe04[0xe3c-0xe04]; /* 0xe04 */ | 387 | __u8 pad_0xe04[0xe38-0xe04]; /* 0xe04 */ |
388 | __u32 vdso_per_cpu_data; /* 0xe3c */ | 388 | __u64 vdso_per_cpu_data; /* 0xe38 */ |
389 | __u32 paste[16]; /* 0xe40 */ | 389 | __u32 paste[16]; /* 0xe40 */ |
390 | 390 | ||
391 | __u8 pad13[0x11b8-0xe80]; /* 0xe80 */ | 391 | __u8 pad13[0x11b8-0xe80]; /* 0xe80 */ |
diff --git a/arch/s390/kernel/irq.c b/arch/s390/kernel/irq.c index e7c5bfb7c755..026a37a94fc9 100644 --- a/arch/s390/kernel/irq.c +++ b/arch/s390/kernel/irq.c | |||
@@ -95,6 +95,7 @@ asmlinkage void do_softirq(void) | |||
95 | local_irq_restore(flags); | 95 | local_irq_restore(flags); |
96 | } | 96 | } |
97 | 97 | ||
98 | #ifdef CONFIG_PROC_FS | ||
98 | void init_irq_proc(void) | 99 | void init_irq_proc(void) |
99 | { | 100 | { |
100 | struct proc_dir_entry *root_irq_dir; | 101 | struct proc_dir_entry *root_irq_dir; |
@@ -102,3 +103,4 @@ void init_irq_proc(void) | |||
102 | root_irq_dir = proc_mkdir("irq", NULL); | 103 | root_irq_dir = proc_mkdir("irq", NULL); |
103 | create_prof_cpu_mask(root_irq_dir); | 104 | create_prof_cpu_mask(root_irq_dir); |
104 | } | 105 | } |
106 | #endif | ||
diff --git a/arch/sh/boards/board-ap325rxa.c b/arch/sh/boards/board-ap325rxa.c index caf4c33f4e84..7c35787d29b4 100644 --- a/arch/sh/boards/board-ap325rxa.c +++ b/arch/sh/boards/board-ap325rxa.c | |||
@@ -22,6 +22,7 @@ | |||
22 | #include <linux/gpio.h> | 22 | #include <linux/gpio.h> |
23 | #include <linux/spi/spi.h> | 23 | #include <linux/spi/spi.h> |
24 | #include <linux/spi/spi_gpio.h> | 24 | #include <linux/spi/spi_gpio.h> |
25 | #include <media/ov772x.h> | ||
25 | #include <media/soc_camera_platform.h> | 26 | #include <media/soc_camera_platform.h> |
26 | #include <media/sh_mobile_ceu.h> | 27 | #include <media/sh_mobile_ceu.h> |
27 | #include <video/sh_mobile_lcdc.h> | 28 | #include <video/sh_mobile_lcdc.h> |
@@ -216,7 +217,14 @@ static struct platform_device lcdc_device = { | |||
216 | }, | 217 | }, |
217 | }; | 218 | }; |
218 | 219 | ||
220 | static void camera_power(int val) | ||
221 | { | ||
222 | gpio_set_value(GPIO_PTZ5, val); /* RST_CAM/RSTB */ | ||
223 | mdelay(10); | ||
224 | } | ||
225 | |||
219 | #ifdef CONFIG_I2C | 226 | #ifdef CONFIG_I2C |
227 | /* support for the old ncm03j camera */ | ||
220 | static unsigned char camera_ncm03j_magic[] = | 228 | static unsigned char camera_ncm03j_magic[] = |
221 | { | 229 | { |
222 | 0x87, 0x00, 0x88, 0x08, 0x89, 0x01, 0x8A, 0xE8, | 230 | 0x87, 0x00, 0x88, 0x08, 0x89, 0x01, 0x8A, 0xE8, |
@@ -237,6 +245,23 @@ static unsigned char camera_ncm03j_magic[] = | |||
237 | 0x63, 0xD4, 0x64, 0xEA, 0xD6, 0x0F, | 245 | 0x63, 0xD4, 0x64, 0xEA, 0xD6, 0x0F, |
238 | }; | 246 | }; |
239 | 247 | ||
248 | static int camera_probe(void) | ||
249 | { | ||
250 | struct i2c_adapter *a = i2c_get_adapter(0); | ||
251 | struct i2c_msg msg; | ||
252 | int ret; | ||
253 | |||
254 | camera_power(1); | ||
255 | msg.addr = 0x6e; | ||
256 | msg.buf = camera_ncm03j_magic; | ||
257 | msg.len = 2; | ||
258 | msg.flags = 0; | ||
259 | ret = i2c_transfer(a, &msg, 1); | ||
260 | camera_power(0); | ||
261 | |||
262 | return ret; | ||
263 | } | ||
264 | |||
240 | static int camera_set_capture(struct soc_camera_platform_info *info, | 265 | static int camera_set_capture(struct soc_camera_platform_info *info, |
241 | int enable) | 266 | int enable) |
242 | { | 267 | { |
@@ -245,9 +270,11 @@ static int camera_set_capture(struct soc_camera_platform_info *info, | |||
245 | int ret = 0; | 270 | int ret = 0; |
246 | int i; | 271 | int i; |
247 | 272 | ||
273 | camera_power(0); | ||
248 | if (!enable) | 274 | if (!enable) |
249 | return 0; /* no disable for now */ | 275 | return 0; /* no disable for now */ |
250 | 276 | ||
277 | camera_power(1); | ||
251 | for (i = 0; i < ARRAY_SIZE(camera_ncm03j_magic); i += 2) { | 278 | for (i = 0; i < ARRAY_SIZE(camera_ncm03j_magic); i += 2) { |
252 | u_int8_t buf[8]; | 279 | u_int8_t buf[8]; |
253 | 280 | ||
@@ -286,8 +313,35 @@ static struct platform_device camera_device = { | |||
286 | .platform_data = &camera_info, | 313 | .platform_data = &camera_info, |
287 | }, | 314 | }, |
288 | }; | 315 | }; |
316 | |||
317 | static int __init camera_setup(void) | ||
318 | { | ||
319 | if (camera_probe() > 0) | ||
320 | platform_device_register(&camera_device); | ||
321 | |||
322 | return 0; | ||
323 | } | ||
324 | late_initcall(camera_setup); | ||
325 | |||
289 | #endif /* CONFIG_I2C */ | 326 | #endif /* CONFIG_I2C */ |
290 | 327 | ||
328 | static int ov7725_power(struct device *dev, int mode) | ||
329 | { | ||
330 | camera_power(0); | ||
331 | if (mode) | ||
332 | camera_power(1); | ||
333 | |||
334 | return 0; | ||
335 | } | ||
336 | |||
337 | static struct ov772x_camera_info ov7725_info = { | ||
338 | .buswidth = SOCAM_DATAWIDTH_8, | ||
339 | .flags = OV772X_FLAG_VFLIP | OV772X_FLAG_HFLIP, | ||
340 | .link = { | ||
341 | .power = ov7725_power, | ||
342 | }, | ||
343 | }; | ||
344 | |||
291 | static struct sh_mobile_ceu_info sh_mobile_ceu_info = { | 345 | static struct sh_mobile_ceu_info sh_mobile_ceu_info = { |
292 | .flags = SOCAM_PCLK_SAMPLE_RISING | SOCAM_HSYNC_ACTIVE_HIGH | | 346 | .flags = SOCAM_PCLK_SAMPLE_RISING | SOCAM_HSYNC_ACTIVE_HIGH | |
293 | SOCAM_VSYNC_ACTIVE_HIGH | SOCAM_MASTER | SOCAM_DATAWIDTH_8, | 347 | SOCAM_VSYNC_ACTIVE_HIGH | SOCAM_MASTER | SOCAM_DATAWIDTH_8, |
@@ -338,9 +392,6 @@ static struct platform_device *ap325rxa_devices[] __initdata = { | |||
338 | &ap325rxa_nor_flash_device, | 392 | &ap325rxa_nor_flash_device, |
339 | &lcdc_device, | 393 | &lcdc_device, |
340 | &ceu_device, | 394 | &ceu_device, |
341 | #ifdef CONFIG_I2C | ||
342 | &camera_device, | ||
343 | #endif | ||
344 | &nand_flash_device, | 395 | &nand_flash_device, |
345 | &sdcard_cn3_device, | 396 | &sdcard_cn3_device, |
346 | }; | 397 | }; |
@@ -349,6 +400,10 @@ static struct i2c_board_info __initdata ap325rxa_i2c_devices[] = { | |||
349 | { | 400 | { |
350 | I2C_BOARD_INFO("pcf8563", 0x51), | 401 | I2C_BOARD_INFO("pcf8563", 0x51), |
351 | }, | 402 | }, |
403 | { | ||
404 | I2C_BOARD_INFO("ov772x", 0x21), | ||
405 | .platform_data = &ov7725_info, | ||
406 | }, | ||
352 | }; | 407 | }; |
353 | 408 | ||
354 | static struct spi_board_info ap325rxa_spi_devices[] = { | 409 | static struct spi_board_info ap325rxa_spi_devices[] = { |
@@ -426,7 +481,7 @@ static int __init ap325rxa_devices_setup(void) | |||
426 | gpio_request(GPIO_PTZ6, NULL); | 481 | gpio_request(GPIO_PTZ6, NULL); |
427 | gpio_direction_output(GPIO_PTZ6, 0); /* STBY_CAM */ | 482 | gpio_direction_output(GPIO_PTZ6, 0); /* STBY_CAM */ |
428 | gpio_request(GPIO_PTZ5, NULL); | 483 | gpio_request(GPIO_PTZ5, NULL); |
429 | gpio_direction_output(GPIO_PTZ5, 1); /* RST_CAM */ | 484 | gpio_direction_output(GPIO_PTZ5, 0); /* RST_CAM */ |
430 | gpio_request(GPIO_PTZ4, NULL); | 485 | gpio_request(GPIO_PTZ4, NULL); |
431 | gpio_direction_output(GPIO_PTZ4, 0); /* SADDR */ | 486 | gpio_direction_output(GPIO_PTZ4, 0); /* SADDR */ |
432 | 487 | ||
diff --git a/arch/sh/configs/ap325rxa_defconfig b/arch/sh/configs/ap325rxa_defconfig index 5c423fa8e6b8..352f87d50fdc 100644 --- a/arch/sh/configs/ap325rxa_defconfig +++ b/arch/sh/configs/ap325rxa_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.28 | 3 | # Linux kernel version: 2.6.29-rc2 |
4 | # Fri Jan 9 16:54:19 2009 | 4 | # Tue Jan 27 11:45:08 2009 |
5 | # | 5 | # |
6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
7 | CONFIG_SUPERH32=y | 7 | CONFIG_SUPERH32=y |
@@ -45,12 +45,12 @@ CONFIG_BSD_PROCESS_ACCT=y | |||
45 | # CONFIG_AUDIT is not set | 45 | # CONFIG_AUDIT is not set |
46 | # CONFIG_IKCONFIG is not set | 46 | # CONFIG_IKCONFIG is not set |
47 | CONFIG_LOG_BUF_SHIFT=14 | 47 | CONFIG_LOG_BUF_SHIFT=14 |
48 | # CONFIG_CGROUPS is not set | ||
49 | CONFIG_GROUP_SCHED=y | 48 | CONFIG_GROUP_SCHED=y |
50 | CONFIG_FAIR_GROUP_SCHED=y | 49 | CONFIG_FAIR_GROUP_SCHED=y |
51 | # CONFIG_RT_GROUP_SCHED is not set | 50 | # CONFIG_RT_GROUP_SCHED is not set |
52 | CONFIG_USER_SCHED=y | 51 | CONFIG_USER_SCHED=y |
53 | # CONFIG_CGROUP_SCHED is not set | 52 | # CONFIG_CGROUP_SCHED is not set |
53 | # CONFIG_CGROUPS is not set | ||
54 | CONFIG_SYSFS_DEPRECATED=y | 54 | CONFIG_SYSFS_DEPRECATED=y |
55 | CONFIG_SYSFS_DEPRECATED_V2=y | 55 | CONFIG_SYSFS_DEPRECATED_V2=y |
56 | # CONFIG_RELAY is not set | 56 | # CONFIG_RELAY is not set |
@@ -378,6 +378,7 @@ CONFIG_WIRELESS=y | |||
378 | # CONFIG_WIRELESS_EXT is not set | 378 | # CONFIG_WIRELESS_EXT is not set |
379 | # CONFIG_LIB80211 is not set | 379 | # CONFIG_LIB80211 is not set |
380 | # CONFIG_MAC80211 is not set | 380 | # CONFIG_MAC80211 is not set |
381 | # CONFIG_WIMAX is not set | ||
381 | # CONFIG_RFKILL is not set | 382 | # CONFIG_RFKILL is not set |
382 | # CONFIG_NET_9P is not set | 383 | # CONFIG_NET_9P is not set |
383 | 384 | ||
@@ -400,6 +401,7 @@ CONFIG_MTD=y | |||
400 | # CONFIG_MTD_DEBUG is not set | 401 | # CONFIG_MTD_DEBUG is not set |
401 | CONFIG_MTD_CONCAT=y | 402 | CONFIG_MTD_CONCAT=y |
402 | CONFIG_MTD_PARTITIONS=y | 403 | CONFIG_MTD_PARTITIONS=y |
404 | # CONFIG_MTD_TESTS is not set | ||
403 | # CONFIG_MTD_REDBOOT_PARTS is not set | 405 | # CONFIG_MTD_REDBOOT_PARTS is not set |
404 | CONFIG_MTD_CMDLINE_PARTS=y | 406 | CONFIG_MTD_CMDLINE_PARTS=y |
405 | # CONFIG_MTD_AR7_PARTS is not set | 407 | # CONFIG_MTD_AR7_PARTS is not set |
@@ -447,9 +449,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
447 | # | 449 | # |
448 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | 450 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set |
449 | CONFIG_MTD_PHYSMAP=y | 451 | CONFIG_MTD_PHYSMAP=y |
450 | CONFIG_MTD_PHYSMAP_START=0xffffffff | 452 | # CONFIG_MTD_PHYSMAP_COMPAT is not set |
451 | CONFIG_MTD_PHYSMAP_LEN=0 | ||
452 | CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | ||
453 | # CONFIG_MTD_PLATRAM is not set | 453 | # CONFIG_MTD_PLATRAM is not set |
454 | 454 | ||
455 | # | 455 | # |
@@ -480,6 +480,12 @@ CONFIG_MTD_NAND_SH_FLCTL=y | |||
480 | # CONFIG_MTD_ONENAND is not set | 480 | # CONFIG_MTD_ONENAND is not set |
481 | 481 | ||
482 | # | 482 | # |
483 | # LPDDR flash memory drivers | ||
484 | # | ||
485 | # CONFIG_MTD_LPDDR is not set | ||
486 | # CONFIG_MTD_QINFO_PROBE is not set | ||
487 | |||
488 | # | ||
483 | # UBI - Unsorted block images | 489 | # UBI - Unsorted block images |
484 | # | 490 | # |
485 | CONFIG_MTD_UBI=y | 491 | CONFIG_MTD_UBI=y |
@@ -607,6 +613,10 @@ CONFIG_SMSC911X=y | |||
607 | # CONFIG_WLAN_PRE80211 is not set | 613 | # CONFIG_WLAN_PRE80211 is not set |
608 | # CONFIG_WLAN_80211 is not set | 614 | # CONFIG_WLAN_80211 is not set |
609 | # CONFIG_IWLWIFI_LEDS is not set | 615 | # CONFIG_IWLWIFI_LEDS is not set |
616 | |||
617 | # | ||
618 | # Enable WiMAX (Networking options) to see the WiMAX drivers | ||
619 | # | ||
610 | # CONFIG_WAN is not set | 620 | # CONFIG_WAN is not set |
611 | # CONFIG_PPP is not set | 621 | # CONFIG_PPP is not set |
612 | # CONFIG_SLIP is not set | 622 | # CONFIG_SLIP is not set |
@@ -790,6 +800,7 @@ CONFIG_SSB_POSSIBLE=y | |||
790 | # CONFIG_PMIC_DA903X is not set | 800 | # CONFIG_PMIC_DA903X is not set |
791 | # CONFIG_MFD_WM8400 is not set | 801 | # CONFIG_MFD_WM8400 is not set |
792 | # CONFIG_MFD_WM8350_I2C is not set | 802 | # CONFIG_MFD_WM8350_I2C is not set |
803 | # CONFIG_MFD_PCF50633 is not set | ||
793 | # CONFIG_REGULATOR is not set | 804 | # CONFIG_REGULATOR is not set |
794 | 805 | ||
795 | # | 806 | # |
@@ -837,7 +848,7 @@ CONFIG_SOC_CAMERA=y | |||
837 | # CONFIG_SOC_CAMERA_MT9V022 is not set | 848 | # CONFIG_SOC_CAMERA_MT9V022 is not set |
838 | # CONFIG_SOC_CAMERA_TW9910 is not set | 849 | # CONFIG_SOC_CAMERA_TW9910 is not set |
839 | CONFIG_SOC_CAMERA_PLATFORM=y | 850 | CONFIG_SOC_CAMERA_PLATFORM=y |
840 | # CONFIG_SOC_CAMERA_OV772X is not set | 851 | CONFIG_SOC_CAMERA_OV772X=y |
841 | CONFIG_VIDEO_SH_MOBILE_CEU=y | 852 | CONFIG_VIDEO_SH_MOBILE_CEU=y |
842 | # CONFIG_RADIO_ADAPTERS is not set | 853 | # CONFIG_RADIO_ADAPTERS is not set |
843 | # CONFIG_DAB is not set | 854 | # CONFIG_DAB is not set |
@@ -1012,6 +1023,7 @@ CONFIG_FS_POSIX_ACL=y | |||
1012 | CONFIG_FILE_LOCKING=y | 1023 | CONFIG_FILE_LOCKING=y |
1013 | # CONFIG_XFS_FS is not set | 1024 | # CONFIG_XFS_FS is not set |
1014 | # CONFIG_OCFS2_FS is not set | 1025 | # CONFIG_OCFS2_FS is not set |
1026 | # CONFIG_BTRFS_FS is not set | ||
1015 | CONFIG_DNOTIFY=y | 1027 | CONFIG_DNOTIFY=y |
1016 | CONFIG_INOTIFY=y | 1028 | CONFIG_INOTIFY=y |
1017 | CONFIG_INOTIFY_USER=y | 1029 | CONFIG_INOTIFY_USER=y |
@@ -1060,6 +1072,7 @@ CONFIG_MISC_FILESYSTEMS=y | |||
1060 | # CONFIG_JFFS2_FS is not set | 1072 | # CONFIG_JFFS2_FS is not set |
1061 | # CONFIG_UBIFS_FS is not set | 1073 | # CONFIG_UBIFS_FS is not set |
1062 | # CONFIG_CRAMFS is not set | 1074 | # CONFIG_CRAMFS is not set |
1075 | # CONFIG_SQUASHFS is not set | ||
1063 | # CONFIG_VXFS_FS is not set | 1076 | # CONFIG_VXFS_FS is not set |
1064 | # CONFIG_MINIX_FS is not set | 1077 | # CONFIG_MINIX_FS is not set |
1065 | # CONFIG_OMFS_FS is not set | 1078 | # CONFIG_OMFS_FS is not set |
diff --git a/arch/sh/configs/migor_defconfig b/arch/sh/configs/migor_defconfig index 7758263514bc..678576796bdf 100644 --- a/arch/sh/configs/migor_defconfig +++ b/arch/sh/configs/migor_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.28 | 3 | # Linux kernel version: 2.6.29-rc1 |
4 | # Fri Jan 9 17:09:35 2009 | 4 | # Thu Jan 22 09:16:16 2009 |
5 | # | 5 | # |
6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
7 | CONFIG_SUPERH32=y | 7 | CONFIG_SUPERH32=y |
@@ -45,8 +45,12 @@ CONFIG_SYSVIPC_SYSCTL=y | |||
45 | CONFIG_IKCONFIG=y | 45 | CONFIG_IKCONFIG=y |
46 | CONFIG_IKCONFIG_PROC=y | 46 | CONFIG_IKCONFIG_PROC=y |
47 | CONFIG_LOG_BUF_SHIFT=14 | 47 | CONFIG_LOG_BUF_SHIFT=14 |
48 | # CONFIG_CGROUPS is not set | ||
49 | # CONFIG_GROUP_SCHED is not set | 48 | # CONFIG_GROUP_SCHED is not set |
49 | |||
50 | # | ||
51 | # Control Group support | ||
52 | # | ||
53 | # CONFIG_CGROUPS is not set | ||
50 | CONFIG_SYSFS_DEPRECATED=y | 54 | CONFIG_SYSFS_DEPRECATED=y |
51 | CONFIG_SYSFS_DEPRECATED_V2=y | 55 | CONFIG_SYSFS_DEPRECATED_V2=y |
52 | # CONFIG_RELAY is not set | 56 | # CONFIG_RELAY is not set |
@@ -389,6 +393,7 @@ CONFIG_WIRELESS_EXT=y | |||
389 | CONFIG_WIRELESS_EXT_SYSFS=y | 393 | CONFIG_WIRELESS_EXT_SYSFS=y |
390 | # CONFIG_LIB80211 is not set | 394 | # CONFIG_LIB80211 is not set |
391 | # CONFIG_MAC80211 is not set | 395 | # CONFIG_MAC80211 is not set |
396 | # CONFIG_WIMAX is not set | ||
392 | # CONFIG_RFKILL is not set | 397 | # CONFIG_RFKILL is not set |
393 | # CONFIG_NET_9P is not set | 398 | # CONFIG_NET_9P is not set |
394 | 399 | ||
@@ -411,6 +416,7 @@ CONFIG_MTD=y | |||
411 | # CONFIG_MTD_DEBUG is not set | 416 | # CONFIG_MTD_DEBUG is not set |
412 | CONFIG_MTD_CONCAT=y | 417 | CONFIG_MTD_CONCAT=y |
413 | CONFIG_MTD_PARTITIONS=y | 418 | CONFIG_MTD_PARTITIONS=y |
419 | # CONFIG_MTD_TESTS is not set | ||
414 | # CONFIG_MTD_REDBOOT_PARTS is not set | 420 | # CONFIG_MTD_REDBOOT_PARTS is not set |
415 | CONFIG_MTD_CMDLINE_PARTS=y | 421 | CONFIG_MTD_CMDLINE_PARTS=y |
416 | # CONFIG_MTD_AR7_PARTS is not set | 422 | # CONFIG_MTD_AR7_PARTS is not set |
@@ -458,9 +464,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
458 | # | 464 | # |
459 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | 465 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set |
460 | CONFIG_MTD_PHYSMAP=y | 466 | CONFIG_MTD_PHYSMAP=y |
461 | CONFIG_MTD_PHYSMAP_START=0xffffffff | 467 | # CONFIG_MTD_PHYSMAP_COMPAT is not set |
462 | CONFIG_MTD_PHYSMAP_LEN=0 | ||
463 | CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | ||
464 | # CONFIG_MTD_PLATRAM is not set | 468 | # CONFIG_MTD_PLATRAM is not set |
465 | 469 | ||
466 | # | 470 | # |
@@ -488,6 +492,12 @@ CONFIG_MTD_NAND_PLATFORM=y | |||
488 | # CONFIG_MTD_ONENAND is not set | 492 | # CONFIG_MTD_ONENAND is not set |
489 | 493 | ||
490 | # | 494 | # |
495 | # LPDDR flash memory drivers | ||
496 | # | ||
497 | # CONFIG_MTD_LPDDR is not set | ||
498 | # CONFIG_MTD_QINFO_PROBE is not set | ||
499 | |||
500 | # | ||
491 | # UBI - Unsorted block images | 501 | # UBI - Unsorted block images |
492 | # | 502 | # |
493 | # CONFIG_MTD_UBI is not set | 503 | # CONFIG_MTD_UBI is not set |
@@ -587,6 +597,10 @@ CONFIG_SMC91X=y | |||
587 | # CONFIG_WLAN_PRE80211 is not set | 597 | # CONFIG_WLAN_PRE80211 is not set |
588 | # CONFIG_WLAN_80211 is not set | 598 | # CONFIG_WLAN_80211 is not set |
589 | # CONFIG_IWLWIFI_LEDS is not set | 599 | # CONFIG_IWLWIFI_LEDS is not set |
600 | |||
601 | # | ||
602 | # Enable WiMAX (Networking options) to see the WiMAX drivers | ||
603 | # | ||
590 | # CONFIG_WAN is not set | 604 | # CONFIG_WAN is not set |
591 | # CONFIG_PPP is not set | 605 | # CONFIG_PPP is not set |
592 | # CONFIG_SLIP is not set | 606 | # CONFIG_SLIP is not set |
@@ -761,6 +775,7 @@ CONFIG_SSB_POSSIBLE=y | |||
761 | # CONFIG_PMIC_DA903X is not set | 775 | # CONFIG_PMIC_DA903X is not set |
762 | # CONFIG_MFD_WM8400 is not set | 776 | # CONFIG_MFD_WM8400 is not set |
763 | # CONFIG_MFD_WM8350_I2C is not set | 777 | # CONFIG_MFD_WM8350_I2C is not set |
778 | # CONFIG_MFD_PCF50633 is not set | ||
764 | # CONFIG_REGULATOR is not set | 779 | # CONFIG_REGULATOR is not set |
765 | 780 | ||
766 | # | 781 | # |
@@ -806,9 +821,9 @@ CONFIG_SOC_CAMERA=y | |||
806 | # CONFIG_SOC_CAMERA_MT9M111 is not set | 821 | # CONFIG_SOC_CAMERA_MT9M111 is not set |
807 | # CONFIG_SOC_CAMERA_MT9T031 is not set | 822 | # CONFIG_SOC_CAMERA_MT9T031 is not set |
808 | # CONFIG_SOC_CAMERA_MT9V022 is not set | 823 | # CONFIG_SOC_CAMERA_MT9V022 is not set |
809 | # CONFIG_SOC_CAMERA_TW9910 is not set | 824 | CONFIG_SOC_CAMERA_TW9910=y |
810 | CONFIG_SOC_CAMERA_PLATFORM=y | 825 | # CONFIG_SOC_CAMERA_PLATFORM is not set |
811 | # CONFIG_SOC_CAMERA_OV772X is not set | 826 | CONFIG_SOC_CAMERA_OV772X=y |
812 | CONFIG_VIDEO_SH_MOBILE_CEU=y | 827 | CONFIG_VIDEO_SH_MOBILE_CEU=y |
813 | # CONFIG_RADIO_ADAPTERS is not set | 828 | # CONFIG_RADIO_ADAPTERS is not set |
814 | # CONFIG_DAB is not set | 829 | # CONFIG_DAB is not set |
@@ -866,11 +881,13 @@ CONFIG_USB_GADGET_SELECTED=y | |||
866 | # CONFIG_USB_GADGET_PXA25X is not set | 881 | # CONFIG_USB_GADGET_PXA25X is not set |
867 | # CONFIG_USB_GADGET_PXA27X is not set | 882 | # CONFIG_USB_GADGET_PXA27X is not set |
868 | # CONFIG_USB_GADGET_S3C2410 is not set | 883 | # CONFIG_USB_GADGET_S3C2410 is not set |
884 | # CONFIG_USB_GADGET_IMX is not set | ||
869 | CONFIG_USB_GADGET_M66592=y | 885 | CONFIG_USB_GADGET_M66592=y |
870 | CONFIG_USB_M66592=y | 886 | CONFIG_USB_M66592=y |
871 | CONFIG_SUPERH_BUILT_IN_M66592=y | 887 | CONFIG_SUPERH_BUILT_IN_M66592=y |
872 | # CONFIG_USB_GADGET_AMD5536UDC is not set | 888 | # CONFIG_USB_GADGET_AMD5536UDC is not set |
873 | # CONFIG_USB_GADGET_FSL_QE is not set | 889 | # CONFIG_USB_GADGET_FSL_QE is not set |
890 | # CONFIG_USB_GADGET_CI13XXX is not set | ||
874 | # CONFIG_USB_GADGET_NET2280 is not set | 891 | # CONFIG_USB_GADGET_NET2280 is not set |
875 | # CONFIG_USB_GADGET_GOKU is not set | 892 | # CONFIG_USB_GADGET_GOKU is not set |
876 | # CONFIG_USB_GADGET_DUMMY_HCD is not set | 893 | # CONFIG_USB_GADGET_DUMMY_HCD is not set |
@@ -883,6 +900,11 @@ CONFIG_USB_G_SERIAL=y | |||
883 | # CONFIG_USB_MIDI_GADGET is not set | 900 | # CONFIG_USB_MIDI_GADGET is not set |
884 | # CONFIG_USB_G_PRINTER is not set | 901 | # CONFIG_USB_G_PRINTER is not set |
885 | # CONFIG_USB_CDC_COMPOSITE is not set | 902 | # CONFIG_USB_CDC_COMPOSITE is not set |
903 | |||
904 | # | ||
905 | # OTG and related infrastructure | ||
906 | # | ||
907 | # CONFIG_USB_GPIO_VBUS is not set | ||
886 | # CONFIG_MMC is not set | 908 | # CONFIG_MMC is not set |
887 | # CONFIG_MEMSTICK is not set | 909 | # CONFIG_MEMSTICK is not set |
888 | # CONFIG_NEW_LEDS is not set | 910 | # CONFIG_NEW_LEDS is not set |
@@ -961,6 +983,7 @@ CONFIG_UIO_PDRV_GENIRQ=y | |||
961 | CONFIG_FILE_LOCKING=y | 983 | CONFIG_FILE_LOCKING=y |
962 | # CONFIG_XFS_FS is not set | 984 | # CONFIG_XFS_FS is not set |
963 | # CONFIG_OCFS2_FS is not set | 985 | # CONFIG_OCFS2_FS is not set |
986 | # CONFIG_BTRFS_FS is not set | ||
964 | # CONFIG_DNOTIFY is not set | 987 | # CONFIG_DNOTIFY is not set |
965 | # CONFIG_INOTIFY is not set | 988 | # CONFIG_INOTIFY is not set |
966 | # CONFIG_QUOTA is not set | 989 | # CONFIG_QUOTA is not set |
@@ -1004,6 +1027,7 @@ CONFIG_MISC_FILESYSTEMS=y | |||
1004 | # CONFIG_EFS_FS is not set | 1027 | # CONFIG_EFS_FS is not set |
1005 | # CONFIG_JFFS2_FS is not set | 1028 | # CONFIG_JFFS2_FS is not set |
1006 | # CONFIG_CRAMFS is not set | 1029 | # CONFIG_CRAMFS is not set |
1030 | # CONFIG_SQUASHFS is not set | ||
1007 | # CONFIG_VXFS_FS is not set | 1031 | # CONFIG_VXFS_FS is not set |
1008 | # CONFIG_MINIX_FS is not set | 1032 | # CONFIG_MINIX_FS is not set |
1009 | # CONFIG_OMFS_FS is not set | 1033 | # CONFIG_OMFS_FS is not set |
diff --git a/arch/sh/include/asm/mutex-llsc.h b/arch/sh/include/asm/mutex-llsc.h index ee839ee58ac8..090358a7e1bb 100644 --- a/arch/sh/include/asm/mutex-llsc.h +++ b/arch/sh/include/asm/mutex-llsc.h | |||
@@ -21,38 +21,36 @@ | |||
21 | static inline void | 21 | static inline void |
22 | __mutex_fastpath_lock(atomic_t *count, void (*fail_fn)(atomic_t *)) | 22 | __mutex_fastpath_lock(atomic_t *count, void (*fail_fn)(atomic_t *)) |
23 | { | 23 | { |
24 | int __ex_flag, __res; | 24 | int __done, __res; |
25 | 25 | ||
26 | __asm__ __volatile__ ( | 26 | __asm__ __volatile__ ( |
27 | "movli.l @%2, %0 \n" | 27 | "movli.l @%2, %0 \n" |
28 | "add #-1, %0 \n" | 28 | "add #-1, %0 \n" |
29 | "movco.l %0, @%2 \n" | 29 | "movco.l %0, @%2 \n" |
30 | "movt %1 \n" | 30 | "movt %1 \n" |
31 | : "=&z" (__res), "=&r" (__ex_flag) | 31 | : "=&z" (__res), "=&r" (__done) |
32 | : "r" (&(count)->counter) | 32 | : "r" (&(count)->counter) |
33 | : "t"); | 33 | : "t"); |
34 | 34 | ||
35 | __res |= !__ex_flag; | 35 | if (unlikely(!__done || __res != 0)) |
36 | if (unlikely(__res != 0)) | ||
37 | fail_fn(count); | 36 | fail_fn(count); |
38 | } | 37 | } |
39 | 38 | ||
40 | static inline int | 39 | static inline int |
41 | __mutex_fastpath_lock_retval(atomic_t *count, int (*fail_fn)(atomic_t *)) | 40 | __mutex_fastpath_lock_retval(atomic_t *count, int (*fail_fn)(atomic_t *)) |
42 | { | 41 | { |
43 | int __ex_flag, __res; | 42 | int __done, __res; |
44 | 43 | ||
45 | __asm__ __volatile__ ( | 44 | __asm__ __volatile__ ( |
46 | "movli.l @%2, %0 \n" | 45 | "movli.l @%2, %0 \n" |
47 | "add #-1, %0 \n" | 46 | "add #-1, %0 \n" |
48 | "movco.l %0, @%2 \n" | 47 | "movco.l %0, @%2 \n" |
49 | "movt %1 \n" | 48 | "movt %1 \n" |
50 | : "=&z" (__res), "=&r" (__ex_flag) | 49 | : "=&z" (__res), "=&r" (__done) |
51 | : "r" (&(count)->counter) | 50 | : "r" (&(count)->counter) |
52 | : "t"); | 51 | : "t"); |
53 | 52 | ||
54 | __res |= !__ex_flag; | 53 | if (unlikely(!__done || __res != 0)) |
55 | if (unlikely(__res != 0)) | ||
56 | __res = fail_fn(count); | 54 | __res = fail_fn(count); |
57 | 55 | ||
58 | return __res; | 56 | return __res; |
@@ -61,19 +59,18 @@ __mutex_fastpath_lock_retval(atomic_t *count, int (*fail_fn)(atomic_t *)) | |||
61 | static inline void | 59 | static inline void |
62 | __mutex_fastpath_unlock(atomic_t *count, void (*fail_fn)(atomic_t *)) | 60 | __mutex_fastpath_unlock(atomic_t *count, void (*fail_fn)(atomic_t *)) |
63 | { | 61 | { |
64 | int __ex_flag, __res; | 62 | int __done, __res; |
65 | 63 | ||
66 | __asm__ __volatile__ ( | 64 | __asm__ __volatile__ ( |
67 | "movli.l @%2, %0 \n\t" | 65 | "movli.l @%2, %0 \n\t" |
68 | "add #1, %0 \n\t" | 66 | "add #1, %0 \n\t" |
69 | "movco.l %0, @%2 \n\t" | 67 | "movco.l %0, @%2 \n\t" |
70 | "movt %1 \n\t" | 68 | "movt %1 \n\t" |
71 | : "=&z" (__res), "=&r" (__ex_flag) | 69 | : "=&z" (__res), "=&r" (__done) |
72 | : "r" (&(count)->counter) | 70 | : "r" (&(count)->counter) |
73 | : "t"); | 71 | : "t"); |
74 | 72 | ||
75 | __res |= !__ex_flag; | 73 | if (unlikely(!__done || __res <= 0)) |
76 | if (unlikely(__res <= 0)) | ||
77 | fail_fn(count); | 74 | fail_fn(count); |
78 | } | 75 | } |
79 | 76 | ||
diff --git a/arch/sh/include/asm/syscall_32.h b/arch/sh/include/asm/syscall_32.h index 05a868a71ef5..5bc34681d994 100644 --- a/arch/sh/include/asm/syscall_32.h +++ b/arch/sh/include/asm/syscall_32.h | |||
@@ -21,23 +21,10 @@ static inline void syscall_rollback(struct task_struct *task, | |||
21 | */ | 21 | */ |
22 | } | 22 | } |
23 | 23 | ||
24 | static inline bool syscall_has_error(struct pt_regs *regs) | ||
25 | { | ||
26 | return (regs->sr & 0x1) ? true : false; | ||
27 | } | ||
28 | static inline void syscall_set_error(struct pt_regs *regs) | ||
29 | { | ||
30 | regs->sr |= 0x1; | ||
31 | } | ||
32 | static inline void syscall_clear_error(struct pt_regs *regs) | ||
33 | { | ||
34 | regs->sr &= ~0x1; | ||
35 | } | ||
36 | |||
37 | static inline long syscall_get_error(struct task_struct *task, | 24 | static inline long syscall_get_error(struct task_struct *task, |
38 | struct pt_regs *regs) | 25 | struct pt_regs *regs) |
39 | { | 26 | { |
40 | return syscall_has_error(regs) ? regs->regs[0] : 0; | 27 | return IS_ERR_VALUE(regs->regs[0]) ? regs->regs[0] : 0; |
41 | } | 28 | } |
42 | 29 | ||
43 | static inline long syscall_get_return_value(struct task_struct *task, | 30 | static inline long syscall_get_return_value(struct task_struct *task, |
@@ -50,13 +37,10 @@ static inline void syscall_set_return_value(struct task_struct *task, | |||
50 | struct pt_regs *regs, | 37 | struct pt_regs *regs, |
51 | int error, long val) | 38 | int error, long val) |
52 | { | 39 | { |
53 | if (error) { | 40 | if (error) |
54 | syscall_set_error(regs); | ||
55 | regs->regs[0] = -error; | 41 | regs->regs[0] = -error; |
56 | } else { | 42 | else |
57 | syscall_clear_error(regs); | ||
58 | regs->regs[0] = val; | 43 | regs->regs[0] = val; |
59 | } | ||
60 | } | 44 | } |
61 | 45 | ||
62 | static inline void syscall_get_arguments(struct task_struct *task, | 46 | static inline void syscall_get_arguments(struct task_struct *task, |
diff --git a/arch/sh/include/asm/syscall_64.h b/arch/sh/include/asm/syscall_64.h index e1143b9784d6..c3561ca72bee 100644 --- a/arch/sh/include/asm/syscall_64.h +++ b/arch/sh/include/asm/syscall_64.h | |||
@@ -21,23 +21,10 @@ static inline void syscall_rollback(struct task_struct *task, | |||
21 | */ | 21 | */ |
22 | } | 22 | } |
23 | 23 | ||
24 | static inline bool syscall_has_error(struct pt_regs *regs) | ||
25 | { | ||
26 | return (regs->sr & 0x1) ? true : false; | ||
27 | } | ||
28 | static inline void syscall_set_error(struct pt_regs *regs) | ||
29 | { | ||
30 | regs->sr |= 0x1; | ||
31 | } | ||
32 | static inline void syscall_clear_error(struct pt_regs *regs) | ||
33 | { | ||
34 | regs->sr &= ~0x1; | ||
35 | } | ||
36 | |||
37 | static inline long syscall_get_error(struct task_struct *task, | 24 | static inline long syscall_get_error(struct task_struct *task, |
38 | struct pt_regs *regs) | 25 | struct pt_regs *regs) |
39 | { | 26 | { |
40 | return syscall_has_error(regs) ? regs->regs[9] : 0; | 27 | return IS_ERR_VALUE(regs->regs[9]) ? regs->regs[9] : 0; |
41 | } | 28 | } |
42 | 29 | ||
43 | static inline long syscall_get_return_value(struct task_struct *task, | 30 | static inline long syscall_get_return_value(struct task_struct *task, |
@@ -50,13 +37,10 @@ static inline void syscall_set_return_value(struct task_struct *task, | |||
50 | struct pt_regs *regs, | 37 | struct pt_regs *regs, |
51 | int error, long val) | 38 | int error, long val) |
52 | { | 39 | { |
53 | if (error) { | 40 | if (error) |
54 | syscall_set_error(regs); | ||
55 | regs->regs[9] = -error; | 41 | regs->regs[9] = -error; |
56 | } else { | 42 | else |
57 | syscall_clear_error(regs); | ||
58 | regs->regs[9] = val; | 43 | regs->regs[9] = val; |
59 | } | ||
60 | } | 44 | } |
61 | 45 | ||
62 | static inline void syscall_get_arguments(struct task_struct *task, | 46 | static inline void syscall_get_arguments(struct task_struct *task, |
diff --git a/arch/sh/kernel/cpu/sh4/fpu.c b/arch/sh/kernel/cpu/sh4/fpu.c index 2780917c0088..e3ea5411da6d 100644 --- a/arch/sh/kernel/cpu/sh4/fpu.c +++ b/arch/sh/kernel/cpu/sh4/fpu.c | |||
@@ -423,7 +423,7 @@ static int ieee_fpe_handler(struct pt_regs *regs) | |||
423 | int m; | 423 | int m; |
424 | unsigned int hx; | 424 | unsigned int hx; |
425 | 425 | ||
426 | m = (finsn >> 9) & 0x7; | 426 | m = (finsn >> 8) & 0x7; |
427 | hx = tsk->thread.fpu.hard.fp_regs[m]; | 427 | hx = tsk->thread.fpu.hard.fp_regs[m]; |
428 | 428 | ||
429 | if ((tsk->thread.fpu.hard.fpscr & FPSCR_CAUSE_ERROR) | 429 | if ((tsk->thread.fpu.hard.fpscr & FPSCR_CAUSE_ERROR) |
diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index 534247508572..370d2cfa34eb 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c | |||
@@ -262,11 +262,11 @@ void __init setup_bootmem_allocator(unsigned long free_pfn) | |||
262 | BOOTMEM_DEFAULT); | 262 | BOOTMEM_DEFAULT); |
263 | 263 | ||
264 | /* | 264 | /* |
265 | * reserve physical page 0 - it's a special BIOS page on many boxes, | 265 | * Reserve physical pages below CONFIG_ZERO_PAGE_OFFSET. |
266 | * enabling clean reboots, SMP operation, laptop functions. | ||
267 | */ | 266 | */ |
268 | reserve_bootmem(__MEMORY_START, CONFIG_ZERO_PAGE_OFFSET, | 267 | if (CONFIG_ZERO_PAGE_OFFSET != 0) |
269 | BOOTMEM_DEFAULT); | 268 | reserve_bootmem(__MEMORY_START, CONFIG_ZERO_PAGE_OFFSET, |
269 | BOOTMEM_DEFAULT); | ||
270 | 270 | ||
271 | sparse_memory_present_with_active_regions(0); | 271 | sparse_memory_present_with_active_regions(0); |
272 | 272 | ||
diff --git a/arch/sh/kernel/signal_32.c b/arch/sh/kernel/signal_32.c index 77c21bde376a..17784e19ae34 100644 --- a/arch/sh/kernel/signal_32.c +++ b/arch/sh/kernel/signal_32.c | |||
@@ -510,7 +510,6 @@ handle_syscall_restart(unsigned long save_r0, struct pt_regs *regs, | |||
510 | case -ERESTARTNOHAND: | 510 | case -ERESTARTNOHAND: |
511 | no_system_call_restart: | 511 | no_system_call_restart: |
512 | regs->regs[0] = -EINTR; | 512 | regs->regs[0] = -EINTR; |
513 | regs->sr |= 1; | ||
514 | break; | 513 | break; |
515 | 514 | ||
516 | case -ERESTARTSYS: | 515 | case -ERESTARTSYS: |
@@ -589,8 +588,7 @@ static void do_signal(struct pt_regs *regs, unsigned int save_r0) | |||
589 | 588 | ||
590 | signr = get_signal_to_deliver(&info, &ka, regs, NULL); | 589 | signr = get_signal_to_deliver(&info, &ka, regs, NULL); |
591 | if (signr > 0) { | 590 | if (signr > 0) { |
592 | if (regs->sr & 1) | 591 | handle_syscall_restart(save_r0, regs, &ka.sa); |
593 | handle_syscall_restart(save_r0, regs, &ka.sa); | ||
594 | 592 | ||
595 | /* Whee! Actually deliver the signal. */ | 593 | /* Whee! Actually deliver the signal. */ |
596 | if (handle_signal(signr, &ka, &info, oldset, | 594 | if (handle_signal(signr, &ka, &info, oldset, |
diff --git a/arch/sh/kernel/signal_64.c b/arch/sh/kernel/signal_64.c index b22fdfaaa191..0663a0ee6021 100644 --- a/arch/sh/kernel/signal_64.c +++ b/arch/sh/kernel/signal_64.c | |||
@@ -60,7 +60,6 @@ handle_syscall_restart(struct pt_regs *regs, struct sigaction *sa) | |||
60 | case -ERESTARTNOHAND: | 60 | case -ERESTARTNOHAND: |
61 | no_system_call_restart: | 61 | no_system_call_restart: |
62 | regs->regs[REG_RET] = -EINTR; | 62 | regs->regs[REG_RET] = -EINTR; |
63 | regs->sr |= 1; | ||
64 | break; | 63 | break; |
65 | 64 | ||
66 | case -ERESTARTSYS: | 65 | case -ERESTARTSYS: |
@@ -109,8 +108,7 @@ static int do_signal(struct pt_regs *regs, sigset_t *oldset) | |||
109 | 108 | ||
110 | signr = get_signal_to_deliver(&info, &ka, regs, 0); | 109 | signr = get_signal_to_deliver(&info, &ka, regs, 0); |
111 | if (signr > 0) { | 110 | if (signr > 0) { |
112 | if (regs->sr & 1) | 111 | handle_syscall_restart(regs, &ka.sa); |
113 | handle_syscall_restart(regs, &ka.sa); | ||
114 | 112 | ||
115 | /* Whee! Actually deliver the signal. */ | 113 | /* Whee! Actually deliver the signal. */ |
116 | if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { | 114 | if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { |
diff --git a/arch/sh/lib/checksum.S b/arch/sh/lib/checksum.S index cbdd0d40e545..356c8ec92893 100644 --- a/arch/sh/lib/checksum.S +++ b/arch/sh/lib/checksum.S | |||
@@ -36,8 +36,7 @@ | |||
36 | */ | 36 | */ |
37 | 37 | ||
38 | /* | 38 | /* |
39 | * unsigned int csum_partial(const unsigned char *buf, int len, | 39 | * asmlinkage __wsum csum_partial(const void *buf, int len, __wsum sum); |
40 | * unsigned int sum); | ||
41 | */ | 40 | */ |
42 | 41 | ||
43 | .text | 42 | .text |
@@ -49,11 +48,31 @@ ENTRY(csum_partial) | |||
49 | * Fortunately, it is easy to convert 2-byte alignment to 4-byte | 48 | * Fortunately, it is easy to convert 2-byte alignment to 4-byte |
50 | * alignment for the unrolled loop. | 49 | * alignment for the unrolled loop. |
51 | */ | 50 | */ |
52 | mov r5, r1 | ||
53 | mov r4, r0 | 51 | mov r4, r0 |
54 | tst #2, r0 ! Check alignment. | 52 | tst #3, r0 ! Check alignment. |
55 | bt 2f ! Jump if alignment is ok. | 53 | bt/s 2f ! Jump if alignment is ok. |
54 | mov r4, r7 ! Keep a copy to check for alignment | ||
56 | ! | 55 | ! |
56 | tst #1, r0 ! Check alignment. | ||
57 | bt 21f ! Jump if alignment is boundary of 2bytes. | ||
58 | |||
59 | ! buf is odd | ||
60 | tst r5, r5 | ||
61 | add #-1, r5 | ||
62 | bt 9f | ||
63 | mov.b @r4+, r0 | ||
64 | extu.b r0, r0 | ||
65 | addc r0, r6 ! t=0 from previous tst | ||
66 | mov r6, r0 | ||
67 | shll8 r6 | ||
68 | shlr16 r0 | ||
69 | shlr8 r0 | ||
70 | or r0, r6 | ||
71 | mov r4, r0 | ||
72 | tst #2, r0 | ||
73 | bt 2f | ||
74 | 21: | ||
75 | ! buf is 2 byte aligned (len could be 0) | ||
57 | add #-2, r5 ! Alignment uses up two bytes. | 76 | add #-2, r5 ! Alignment uses up two bytes. |
58 | cmp/pz r5 ! | 77 | cmp/pz r5 ! |
59 | bt/s 1f ! Jump if we had at least two bytes. | 78 | bt/s 1f ! Jump if we had at least two bytes. |
@@ -61,16 +80,17 @@ ENTRY(csum_partial) | |||
61 | bra 6f | 80 | bra 6f |
62 | add #2, r5 ! r5 was < 2. Deal with it. | 81 | add #2, r5 ! r5 was < 2. Deal with it. |
63 | 1: | 82 | 1: |
64 | mov r5, r1 ! Save new len for later use. | ||
65 | mov.w @r4+, r0 | 83 | mov.w @r4+, r0 |
66 | extu.w r0, r0 | 84 | extu.w r0, r0 |
67 | addc r0, r6 | 85 | addc r0, r6 |
68 | bf 2f | 86 | bf 2f |
69 | add #1, r6 | 87 | add #1, r6 |
70 | 2: | 88 | 2: |
89 | ! buf is 4 byte aligned (len could be 0) | ||
90 | mov r5, r1 | ||
71 | mov #-5, r0 | 91 | mov #-5, r0 |
72 | shld r0, r5 | 92 | shld r0, r1 |
73 | tst r5, r5 | 93 | tst r1, r1 |
74 | bt/s 4f ! if it's =0, go to 4f | 94 | bt/s 4f ! if it's =0, go to 4f |
75 | clrt | 95 | clrt |
76 | .align 2 | 96 | .align 2 |
@@ -92,30 +112,31 @@ ENTRY(csum_partial) | |||
92 | addc r0, r6 | 112 | addc r0, r6 |
93 | addc r2, r6 | 113 | addc r2, r6 |
94 | movt r0 | 114 | movt r0 |
95 | dt r5 | 115 | dt r1 |
96 | bf/s 3b | 116 | bf/s 3b |
97 | cmp/eq #1, r0 | 117 | cmp/eq #1, r0 |
98 | ! here, we know r5==0 | 118 | ! here, we know r1==0 |
99 | addc r5, r6 ! add carry to r6 | 119 | addc r1, r6 ! add carry to r6 |
100 | 4: | 120 | 4: |
101 | mov r1, r0 | 121 | mov r5, r0 |
102 | and #0x1c, r0 | 122 | and #0x1c, r0 |
103 | tst r0, r0 | 123 | tst r0, r0 |
104 | bt/s 6f | 124 | bt 6f |
105 | mov r0, r5 | 125 | ! 4 bytes or more remaining |
106 | shlr2 r5 | 126 | mov r0, r1 |
127 | shlr2 r1 | ||
107 | mov #0, r2 | 128 | mov #0, r2 |
108 | 5: | 129 | 5: |
109 | addc r2, r6 | 130 | addc r2, r6 |
110 | mov.l @r4+, r2 | 131 | mov.l @r4+, r2 |
111 | movt r0 | 132 | movt r0 |
112 | dt r5 | 133 | dt r1 |
113 | bf/s 5b | 134 | bf/s 5b |
114 | cmp/eq #1, r0 | 135 | cmp/eq #1, r0 |
115 | addc r2, r6 | 136 | addc r2, r6 |
116 | addc r5, r6 ! r5==0 here, so it means add carry-bit | 137 | addc r1, r6 ! r1==0 here, so it means add carry-bit |
117 | 6: | 138 | 6: |
118 | mov r1, r5 | 139 | ! 3 bytes or less remaining |
119 | mov #3, r0 | 140 | mov #3, r0 |
120 | and r0, r5 | 141 | and r0, r5 |
121 | tst r5, r5 | 142 | tst r5, r5 |
@@ -139,8 +160,18 @@ ENTRY(csum_partial) | |||
139 | 8: | 160 | 8: |
140 | addc r0, r6 | 161 | addc r0, r6 |
141 | mov #0, r0 | 162 | mov #0, r0 |
142 | addc r0, r6 | 163 | addc r0, r6 |
143 | 9: | 164 | 9: |
165 | ! Check if the buffer was misaligned, if so realign sum | ||
166 | mov r7, r0 | ||
167 | tst #1, r0 | ||
168 | bt 10f | ||
169 | mov r6, r0 | ||
170 | shll8 r6 | ||
171 | shlr16 r0 | ||
172 | shlr8 r0 | ||
173 | or r0, r6 | ||
174 | 10: | ||
144 | rts | 175 | rts |
145 | mov r6, r0 | 176 | mov r6, r0 |
146 | 177 | ||
diff --git a/arch/sparc/kernel/head_64.S b/arch/sparc/kernel/head_64.S index 8ffee714f932..a46c3a21e26d 100644 --- a/arch/sparc/kernel/head_64.S +++ b/arch/sparc/kernel/head_64.S | |||
@@ -891,10 +891,35 @@ prom_tba: .xword 0 | |||
891 | tlb_type: .word 0 /* Must NOT end up in BSS */ | 891 | tlb_type: .word 0 /* Must NOT end up in BSS */ |
892 | .section ".fixup",#alloc,#execinstr | 892 | .section ".fixup",#alloc,#execinstr |
893 | 893 | ||
894 | .globl __ret_efault, __retl_efault | 894 | .globl __ret_efault, __retl_efault, __ret_one, __retl_one |
895 | __ret_efault: | 895 | ENTRY(__ret_efault) |
896 | ret | 896 | ret |
897 | restore %g0, -EFAULT, %o0 | 897 | restore %g0, -EFAULT, %o0 |
898 | __retl_efault: | 898 | ENDPROC(__ret_efault) |
899 | |||
900 | ENTRY(__retl_efault) | ||
899 | retl | 901 | retl |
900 | mov -EFAULT, %o0 | 902 | mov -EFAULT, %o0 |
903 | ENDPROC(__retl_efault) | ||
904 | |||
905 | ENTRY(__retl_one) | ||
906 | retl | ||
907 | mov 1, %o0 | ||
908 | ENDPROC(__retl_one) | ||
909 | |||
910 | ENTRY(__ret_one_asi) | ||
911 | wr %g0, ASI_AIUS, %asi | ||
912 | ret | ||
913 | restore %g0, 1, %o0 | ||
914 | ENDPROC(__ret_one_asi) | ||
915 | |||
916 | ENTRY(__retl_one_asi) | ||
917 | wr %g0, ASI_AIUS, %asi | ||
918 | retl | ||
919 | mov 1, %o0 | ||
920 | ENDPROC(__retl_one_asi) | ||
921 | |||
922 | ENTRY(__retl_o1) | ||
923 | retl | ||
924 | mov %o1, %o0 | ||
925 | ENDPROC(__retl_o1) | ||
diff --git a/arch/sparc/kernel/nmi.c b/arch/sparc/kernel/nmi.c index 09f088ed4a64..f3577223c863 100644 --- a/arch/sparc/kernel/nmi.c +++ b/arch/sparc/kernel/nmi.c | |||
@@ -70,6 +70,7 @@ static void die_nmi(const char *str, struct pt_regs *regs, int do_panic) | |||
70 | printk(" on CPU%d, ip %08lx, registers:\n", | 70 | printk(" on CPU%d, ip %08lx, registers:\n", |
71 | smp_processor_id(), regs->tpc); | 71 | smp_processor_id(), regs->tpc); |
72 | show_regs(regs); | 72 | show_regs(regs); |
73 | dump_stack(); | ||
73 | 74 | ||
74 | bust_spinlocks(0); | 75 | bust_spinlocks(0); |
75 | 76 | ||
diff --git a/arch/sparc/kernel/pcr.c b/arch/sparc/kernel/pcr.c index 92e0dda141a4..1ae8cdd7e703 100644 --- a/arch/sparc/kernel/pcr.c +++ b/arch/sparc/kernel/pcr.c | |||
@@ -133,11 +133,16 @@ int __init pcr_arch_init(void) | |||
133 | 133 | ||
134 | case cheetah: | 134 | case cheetah: |
135 | case cheetah_plus: | 135 | case cheetah_plus: |
136 | case spitfire: | ||
137 | pcr_ops = &direct_pcr_ops; | 136 | pcr_ops = &direct_pcr_ops; |
138 | pcr_enable = PCR_SUN4U_ENABLE; | 137 | pcr_enable = PCR_SUN4U_ENABLE; |
139 | break; | 138 | break; |
140 | 139 | ||
140 | case spitfire: | ||
141 | /* UltraSPARC-I/II and derivatives lack a profile | ||
142 | * counter overflow interrupt so we can't make use of | ||
143 | * their hardware currently. | ||
144 | */ | ||
145 | /* fallthrough */ | ||
141 | default: | 146 | default: |
142 | err = -ENODEV; | 147 | err = -ENODEV; |
143 | goto out_unregister; | 148 | goto out_unregister; |
diff --git a/arch/sparc/lib/GENbzero.S b/arch/sparc/lib/GENbzero.S index 6a4f956a2f7a..8e7a843ddd88 100644 --- a/arch/sparc/lib/GENbzero.S +++ b/arch/sparc/lib/GENbzero.S | |||
@@ -6,13 +6,9 @@ | |||
6 | 6 | ||
7 | #define EX_ST(x,y) \ | 7 | #define EX_ST(x,y) \ |
8 | 98: x,y; \ | 8 | 98: x,y; \ |
9 | .section .fixup; \ | ||
10 | .align 4; \ | ||
11 | 99: retl; \ | ||
12 | mov %o1, %o0; \ | ||
13 | .section __ex_table,"a";\ | 9 | .section __ex_table,"a";\ |
14 | .align 4; \ | 10 | .align 4; \ |
15 | .word 98b, 99b; \ | 11 | .word 98b, __retl_o1; \ |
16 | .text; \ | 12 | .text; \ |
17 | .align 4; | 13 | .align 4; |
18 | 14 | ||
diff --git a/arch/sparc/lib/GENcopy_from_user.S b/arch/sparc/lib/GENcopy_from_user.S index 2b9df99e87f9..b7d0bd6b1406 100644 --- a/arch/sparc/lib/GENcopy_from_user.S +++ b/arch/sparc/lib/GENcopy_from_user.S | |||
@@ -5,13 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_LD(x) \ | 6 | #define EX_LD(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: retl; \ | ||
11 | mov 1, %o0; \ | ||
12 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
13 | .align 4; \ | 9 | .align 4; \ |
14 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one; \ |
15 | .text; \ | 11 | .text; \ |
16 | .align 4; | 12 | .align 4; |
17 | 13 | ||
@@ -27,7 +23,7 @@ | |||
27 | #define PREAMBLE \ | 23 | #define PREAMBLE \ |
28 | rd %asi, %g1; \ | 24 | rd %asi, %g1; \ |
29 | cmp %g1, ASI_AIUS; \ | 25 | cmp %g1, ASI_AIUS; \ |
30 | bne,pn %icc, memcpy_user_stub; \ | 26 | bne,pn %icc, ___copy_in_user; \ |
31 | nop | 27 | nop |
32 | #endif | 28 | #endif |
33 | 29 | ||
diff --git a/arch/sparc/lib/GENcopy_to_user.S b/arch/sparc/lib/GENcopy_to_user.S index bb3f7084daf9..780550e1afc7 100644 --- a/arch/sparc/lib/GENcopy_to_user.S +++ b/arch/sparc/lib/GENcopy_to_user.S | |||
@@ -5,13 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_ST(x) \ | 6 | #define EX_ST(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: retl; \ | ||
11 | mov 1, %o0; \ | ||
12 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
13 | .align 4; \ | 9 | .align 4; \ |
14 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one; \ |
15 | .text; \ | 11 | .text; \ |
16 | .align 4; | 12 | .align 4; |
17 | 13 | ||
@@ -31,7 +27,7 @@ | |||
31 | #define PREAMBLE \ | 27 | #define PREAMBLE \ |
32 | rd %asi, %g1; \ | 28 | rd %asi, %g1; \ |
33 | cmp %g1, ASI_AIUS; \ | 29 | cmp %g1, ASI_AIUS; \ |
34 | bne,pn %icc, memcpy_user_stub; \ | 30 | bne,pn %icc, ___copy_in_user; \ |
35 | nop | 31 | nop |
36 | #endif | 32 | #endif |
37 | 33 | ||
diff --git a/arch/sparc/lib/NG2copy_from_user.S b/arch/sparc/lib/NG2copy_from_user.S index c77ef5f22102..119ccb9a54f4 100644 --- a/arch/sparc/lib/NG2copy_from_user.S +++ b/arch/sparc/lib/NG2copy_from_user.S | |||
@@ -5,14 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_LD(x) \ | 6 | #define EX_LD(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: wr %g0, ASI_AIUS, %asi;\ | ||
11 | retl; \ | ||
12 | mov 1, %o0; \ | ||
13 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
14 | .align 4; \ | 9 | .align 4; \ |
15 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one_asi;\ |
16 | .text; \ | 11 | .text; \ |
17 | .align 4; | 12 | .align 4; |
18 | 13 | ||
@@ -33,7 +28,7 @@ | |||
33 | #define PREAMBLE \ | 28 | #define PREAMBLE \ |
34 | rd %asi, %g1; \ | 29 | rd %asi, %g1; \ |
35 | cmp %g1, ASI_AIUS; \ | 30 | cmp %g1, ASI_AIUS; \ |
36 | bne,pn %icc, memcpy_user_stub; \ | 31 | bne,pn %icc, ___copy_in_user; \ |
37 | nop | 32 | nop |
38 | #endif | 33 | #endif |
39 | 34 | ||
diff --git a/arch/sparc/lib/NG2copy_to_user.S b/arch/sparc/lib/NG2copy_to_user.S index 4bd4093acbbd..7fe1ccefd9d0 100644 --- a/arch/sparc/lib/NG2copy_to_user.S +++ b/arch/sparc/lib/NG2copy_to_user.S | |||
@@ -5,14 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_ST(x) \ | 6 | #define EX_ST(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: wr %g0, ASI_AIUS, %asi;\ | ||
11 | retl; \ | ||
12 | mov 1, %o0; \ | ||
13 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
14 | .align 4; \ | 9 | .align 4; \ |
15 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one_asi;\ |
16 | .text; \ | 11 | .text; \ |
17 | .align 4; | 12 | .align 4; |
18 | 13 | ||
@@ -42,7 +37,7 @@ | |||
42 | #define PREAMBLE \ | 37 | #define PREAMBLE \ |
43 | rd %asi, %g1; \ | 38 | rd %asi, %g1; \ |
44 | cmp %g1, ASI_AIUS; \ | 39 | cmp %g1, ASI_AIUS; \ |
45 | bne,pn %icc, memcpy_user_stub; \ | 40 | bne,pn %icc, ___copy_in_user; \ |
46 | nop | 41 | nop |
47 | #endif | 42 | #endif |
48 | 43 | ||
diff --git a/arch/sparc/lib/NGbzero.S b/arch/sparc/lib/NGbzero.S index 814d5f7a45e1..beab29bf419b 100644 --- a/arch/sparc/lib/NGbzero.S +++ b/arch/sparc/lib/NGbzero.S | |||
@@ -6,13 +6,9 @@ | |||
6 | 6 | ||
7 | #define EX_ST(x,y) \ | 7 | #define EX_ST(x,y) \ |
8 | 98: x,y; \ | 8 | 98: x,y; \ |
9 | .section .fixup; \ | ||
10 | .align 4; \ | ||
11 | 99: retl; \ | ||
12 | mov %o1, %o0; \ | ||
13 | .section __ex_table,"a";\ | 9 | .section __ex_table,"a";\ |
14 | .align 4; \ | 10 | .align 4; \ |
15 | .word 98b, 99b; \ | 11 | .word 98b, __retl_o1; \ |
16 | .text; \ | 12 | .text; \ |
17 | .align 4; | 13 | .align 4; |
18 | 14 | ||
diff --git a/arch/sparc/lib/NGcopy_from_user.S b/arch/sparc/lib/NGcopy_from_user.S index e7f433f71b42..5d1e4d1ac21e 100644 --- a/arch/sparc/lib/NGcopy_from_user.S +++ b/arch/sparc/lib/NGcopy_from_user.S | |||
@@ -5,14 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_LD(x) \ | 6 | #define EX_LD(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: wr %g0, ASI_AIUS, %asi;\ | ||
11 | ret; \ | ||
12 | restore %g0, 1, %o0; \ | ||
13 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
14 | .align 4; \ | 9 | .align 4; \ |
15 | .word 98b, 99b; \ | 10 | .word 98b, __ret_one_asi;\ |
16 | .text; \ | 11 | .text; \ |
17 | .align 4; | 12 | .align 4; |
18 | 13 | ||
@@ -30,7 +25,7 @@ | |||
30 | #define PREAMBLE \ | 25 | #define PREAMBLE \ |
31 | rd %asi, %g1; \ | 26 | rd %asi, %g1; \ |
32 | cmp %g1, ASI_AIUS; \ | 27 | cmp %g1, ASI_AIUS; \ |
33 | bne,pn %icc, memcpy_user_stub; \ | 28 | bne,pn %icc, ___copy_in_user; \ |
34 | nop | 29 | nop |
35 | #endif | 30 | #endif |
36 | 31 | ||
diff --git a/arch/sparc/lib/NGcopy_to_user.S b/arch/sparc/lib/NGcopy_to_user.S index 6ea01c5532a0..ff630dcb273c 100644 --- a/arch/sparc/lib/NGcopy_to_user.S +++ b/arch/sparc/lib/NGcopy_to_user.S | |||
@@ -5,14 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_ST(x) \ | 6 | #define EX_ST(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: wr %g0, ASI_AIUS, %asi;\ | ||
11 | ret; \ | ||
12 | restore %g0, 1, %o0; \ | ||
13 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
14 | .align 4; \ | 9 | .align 4; \ |
15 | .word 98b, 99b; \ | 10 | .word 98b, __ret_one_asi;\ |
16 | .text; \ | 11 | .text; \ |
17 | .align 4; | 12 | .align 4; |
18 | 13 | ||
@@ -33,7 +28,7 @@ | |||
33 | #define PREAMBLE \ | 28 | #define PREAMBLE \ |
34 | rd %asi, %g1; \ | 29 | rd %asi, %g1; \ |
35 | cmp %g1, ASI_AIUS; \ | 30 | cmp %g1, ASI_AIUS; \ |
36 | bne,pn %icc, memcpy_user_stub; \ | 31 | bne,pn %icc, ___copy_in_user; \ |
37 | nop | 32 | nop |
38 | #endif | 33 | #endif |
39 | 34 | ||
diff --git a/arch/sparc/lib/U1copy_from_user.S b/arch/sparc/lib/U1copy_from_user.S index 3192b0bf4fab..a6ae2ea04bf5 100644 --- a/arch/sparc/lib/U1copy_from_user.S +++ b/arch/sparc/lib/U1copy_from_user.S | |||
@@ -5,13 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_LD(x) \ | 6 | #define EX_LD(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: retl; \ | ||
11 | mov 1, %o0; \ | ||
12 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
13 | .align 4; \ | 9 | .align 4; \ |
14 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one; \ |
15 | .text; \ | 11 | .text; \ |
16 | .align 4; | 12 | .align 4; |
17 | 13 | ||
@@ -27,7 +23,7 @@ | |||
27 | #define PREAMBLE \ | 23 | #define PREAMBLE \ |
28 | rd %asi, %g1; \ | 24 | rd %asi, %g1; \ |
29 | cmp %g1, ASI_AIUS; \ | 25 | cmp %g1, ASI_AIUS; \ |
30 | bne,pn %icc, memcpy_user_stub; \ | 26 | bne,pn %icc, ___copy_in_user; \ |
31 | nop; \ | 27 | nop; \ |
32 | 28 | ||
33 | #include "U1memcpy.S" | 29 | #include "U1memcpy.S" |
diff --git a/arch/sparc/lib/U1copy_to_user.S b/arch/sparc/lib/U1copy_to_user.S index d1210ffb0b82..f4b970eeb485 100644 --- a/arch/sparc/lib/U1copy_to_user.S +++ b/arch/sparc/lib/U1copy_to_user.S | |||
@@ -5,13 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_ST(x) \ | 6 | #define EX_ST(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: retl; \ | ||
11 | mov 1, %o0; \ | ||
12 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
13 | .align 4; \ | 9 | .align 4; \ |
14 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one; \ |
15 | .text; \ | 11 | .text; \ |
16 | .align 4; | 12 | .align 4; |
17 | 13 | ||
@@ -27,7 +23,7 @@ | |||
27 | #define PREAMBLE \ | 23 | #define PREAMBLE \ |
28 | rd %asi, %g1; \ | 24 | rd %asi, %g1; \ |
29 | cmp %g1, ASI_AIUS; \ | 25 | cmp %g1, ASI_AIUS; \ |
30 | bne,pn %icc, memcpy_user_stub; \ | 26 | bne,pn %icc, ___copy_in_user; \ |
31 | nop; \ | 27 | nop; \ |
32 | 28 | ||
33 | #include "U1memcpy.S" | 29 | #include "U1memcpy.S" |
diff --git a/arch/sparc/lib/U3copy_from_user.S b/arch/sparc/lib/U3copy_from_user.S index f5bfc8d9d216..b1acd1331c33 100644 --- a/arch/sparc/lib/U3copy_from_user.S +++ b/arch/sparc/lib/U3copy_from_user.S | |||
@@ -5,13 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_LD(x) \ | 6 | #define EX_LD(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: retl; \ | ||
11 | mov 1, %o0; \ | ||
12 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
13 | .align 4; \ | 9 | .align 4; \ |
14 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one; \ |
15 | .text; \ | 11 | .text; \ |
16 | .align 4; | 12 | .align 4; |
17 | 13 | ||
diff --git a/arch/sparc/lib/U3copy_to_user.S b/arch/sparc/lib/U3copy_to_user.S index 2334f111bb0c..ef1e493afdfa 100644 --- a/arch/sparc/lib/U3copy_to_user.S +++ b/arch/sparc/lib/U3copy_to_user.S | |||
@@ -5,13 +5,9 @@ | |||
5 | 5 | ||
6 | #define EX_ST(x) \ | 6 | #define EX_ST(x) \ |
7 | 98: x; \ | 7 | 98: x; \ |
8 | .section .fixup; \ | ||
9 | .align 4; \ | ||
10 | 99: retl; \ | ||
11 | mov 1, %o0; \ | ||
12 | .section __ex_table,"a";\ | 8 | .section __ex_table,"a";\ |
13 | .align 4; \ | 9 | .align 4; \ |
14 | .word 98b, 99b; \ | 10 | .word 98b, __retl_one; \ |
15 | .text; \ | 11 | .text; \ |
16 | .align 4; | 12 | .align 4; |
17 | 13 | ||
@@ -27,7 +23,7 @@ | |||
27 | #define PREAMBLE \ | 23 | #define PREAMBLE \ |
28 | rd %asi, %g1; \ | 24 | rd %asi, %g1; \ |
29 | cmp %g1, ASI_AIUS; \ | 25 | cmp %g1, ASI_AIUS; \ |
30 | bne,pn %icc, memcpy_user_stub; \ | 26 | bne,pn %icc, ___copy_in_user; \ |
31 | nop; \ | 27 | nop; \ |
32 | 28 | ||
33 | #include "U3memcpy.S" | 29 | #include "U3memcpy.S" |
diff --git a/arch/sparc/lib/bzero.S b/arch/sparc/lib/bzero.S index c7bbae8c590f..b6557297440f 100644 --- a/arch/sparc/lib/bzero.S +++ b/arch/sparc/lib/bzero.S | |||
@@ -88,13 +88,9 @@ __bzero_done: | |||
88 | 88 | ||
89 | #define EX_ST(x,y) \ | 89 | #define EX_ST(x,y) \ |
90 | 98: x,y; \ | 90 | 98: x,y; \ |
91 | .section .fixup; \ | ||
92 | .align 4; \ | ||
93 | 99: retl; \ | ||
94 | mov %o1, %o0; \ | ||
95 | .section __ex_table,"a";\ | 91 | .section __ex_table,"a";\ |
96 | .align 4; \ | 92 | .align 4; \ |
97 | .word 98b, 99b; \ | 93 | .word 98b, __retl_o1; \ |
98 | .text; \ | 94 | .text; \ |
99 | .align 4; | 95 | .align 4; |
100 | 96 | ||
diff --git a/arch/sparc/lib/copy_in_user.S b/arch/sparc/lib/copy_in_user.S index 650af3f21f78..302c0e60dc2c 100644 --- a/arch/sparc/lib/copy_in_user.S +++ b/arch/sparc/lib/copy_in_user.S | |||
@@ -3,19 +3,16 @@ | |||
3 | * Copyright (C) 1999, 2000, 2004 David S. Miller (davem@redhat.com) | 3 | * Copyright (C) 1999, 2000, 2004 David S. Miller (davem@redhat.com) |
4 | */ | 4 | */ |
5 | 5 | ||
6 | #include <linux/linkage.h> | ||
6 | #include <asm/asi.h> | 7 | #include <asm/asi.h> |
7 | 8 | ||
8 | #define XCC xcc | 9 | #define XCC xcc |
9 | 10 | ||
10 | #define EX(x,y) \ | 11 | #define EX(x,y) \ |
11 | 98: x,y; \ | 12 | 98: x,y; \ |
12 | .section .fixup; \ | ||
13 | .align 4; \ | ||
14 | 99: retl; \ | ||
15 | mov 1, %o0; \ | ||
16 | .section __ex_table,"a";\ | 13 | .section __ex_table,"a";\ |
17 | .align 4; \ | 14 | .align 4; \ |
18 | .word 98b, 99b; \ | 15 | .word 98b, __retl_one; \ |
19 | .text; \ | 16 | .text; \ |
20 | .align 4; | 17 | .align 4; |
21 | 18 | ||
@@ -31,18 +28,7 @@ | |||
31 | * to copy register windows around during thread cloning. | 28 | * to copy register windows around during thread cloning. |
32 | */ | 29 | */ |
33 | 30 | ||
34 | .globl ___copy_in_user | 31 | ENTRY(___copy_in_user) /* %o0=dst, %o1=src, %o2=len */ |
35 | .type ___copy_in_user,#function | ||
36 | ___copy_in_user: /* %o0=dst, %o1=src, %o2=len */ | ||
37 | /* Writing to %asi is _expensive_ so we hardcode it. | ||
38 | * Reading %asi to check for KERNEL_DS is comparatively | ||
39 | * cheap. | ||
40 | */ | ||
41 | rd %asi, %g1 | ||
42 | cmp %g1, ASI_AIUS | ||
43 | bne,pn %icc, memcpy_user_stub | ||
44 | nop | ||
45 | |||
46 | cmp %o2, 0 | 32 | cmp %o2, 0 |
47 | be,pn %XCC, 85f | 33 | be,pn %XCC, 85f |
48 | or %o0, %o1, %o3 | 34 | or %o0, %o1, %o3 |
@@ -53,22 +39,24 @@ ___copy_in_user: /* %o0=dst, %o1=src, %o2=len */ | |||
53 | /* 16 < len <= 64 */ | 39 | /* 16 < len <= 64 */ |
54 | andcc %o3, 0x7, %g0 | 40 | andcc %o3, 0x7, %g0 |
55 | bne,pn %XCC, 90f | 41 | bne,pn %XCC, 90f |
56 | sub %o0, %o1, %o3 | 42 | nop |
57 | 43 | ||
58 | andn %o2, 0x7, %o4 | 44 | andn %o2, 0x7, %o4 |
59 | and %o2, 0x7, %o2 | 45 | and %o2, 0x7, %o2 |
60 | 1: subcc %o4, 0x8, %o4 | 46 | 1: subcc %o4, 0x8, %o4 |
61 | EX(ldxa [%o1] %asi, %o5) | 47 | EX(ldxa [%o1] %asi, %o5) |
62 | EX(stxa %o5, [%o1 + %o3] ASI_AIUS) | 48 | EX(stxa %o5, [%o0] %asi) |
49 | add %o1, 0x8, %o1 | ||
63 | bgu,pt %XCC, 1b | 50 | bgu,pt %XCC, 1b |
64 | add %o1, 0x8, %o1 | 51 | add %o0, 0x8, %o0 |
65 | andcc %o2, 0x4, %g0 | 52 | andcc %o2, 0x4, %g0 |
66 | be,pt %XCC, 1f | 53 | be,pt %XCC, 1f |
67 | nop | 54 | nop |
68 | sub %o2, 0x4, %o2 | 55 | sub %o2, 0x4, %o2 |
69 | EX(lduwa [%o1] %asi, %o5) | 56 | EX(lduwa [%o1] %asi, %o5) |
70 | EX(stwa %o5, [%o1 + %o3] ASI_AIUS) | 57 | EX(stwa %o5, [%o0] %asi) |
71 | add %o1, 0x4, %o1 | 58 | add %o1, 0x4, %o1 |
59 | add %o0, 0x4, %o0 | ||
72 | 1: cmp %o2, 0 | 60 | 1: cmp %o2, 0 |
73 | be,pt %XCC, 85f | 61 | be,pt %XCC, 85f |
74 | nop | 62 | nop |
@@ -78,14 +66,15 @@ ___copy_in_user: /* %o0=dst, %o1=src, %o2=len */ | |||
78 | 80: /* 0 < len <= 16 */ | 66 | 80: /* 0 < len <= 16 */ |
79 | andcc %o3, 0x3, %g0 | 67 | andcc %o3, 0x3, %g0 |
80 | bne,pn %XCC, 90f | 68 | bne,pn %XCC, 90f |
81 | sub %o0, %o1, %o3 | 69 | nop |
82 | 70 | ||
83 | 82: | 71 | 82: |
84 | subcc %o2, 4, %o2 | 72 | subcc %o2, 4, %o2 |
85 | EX(lduwa [%o1] %asi, %g1) | 73 | EX(lduwa [%o1] %asi, %g1) |
86 | EX(stwa %g1, [%o1 + %o3] ASI_AIUS) | 74 | EX(stwa %g1, [%o0] %asi) |
75 | add %o1, 4, %o1 | ||
87 | bgu,pt %XCC, 82b | 76 | bgu,pt %XCC, 82b |
88 | add %o1, 4, %o1 | 77 | add %o0, 4, %o0 |
89 | 78 | ||
90 | 85: retl | 79 | 85: retl |
91 | clr %o0 | 80 | clr %o0 |
@@ -94,26 +83,10 @@ ___copy_in_user: /* %o0=dst, %o1=src, %o2=len */ | |||
94 | 90: | 83 | 90: |
95 | subcc %o2, 1, %o2 | 84 | subcc %o2, 1, %o2 |
96 | EX(lduba [%o1] %asi, %g1) | 85 | EX(lduba [%o1] %asi, %g1) |
97 | EX(stba %g1, [%o1 + %o3] ASI_AIUS) | 86 | EX(stba %g1, [%o0] %asi) |
87 | add %o1, 1, %o1 | ||
98 | bgu,pt %XCC, 90b | 88 | bgu,pt %XCC, 90b |
99 | add %o1, 1, %o1 | 89 | add %o0, 1, %o0 |
100 | retl | 90 | retl |
101 | clr %o0 | 91 | clr %o0 |
102 | 92 | ENDPROC(___copy_in_user) | |
103 | .size ___copy_in_user, .-___copy_in_user | ||
104 | |||
105 | /* Act like copy_{to,in}_user(), ie. return zero instead | ||
106 | * of original destination pointer. This is invoked when | ||
107 | * copy_{to,in}_user() finds that %asi is kernel space. | ||
108 | */ | ||
109 | .globl memcpy_user_stub | ||
110 | .type memcpy_user_stub,#function | ||
111 | memcpy_user_stub: | ||
112 | save %sp, -192, %sp | ||
113 | mov %i0, %o0 | ||
114 | mov %i1, %o1 | ||
115 | call memcpy | ||
116 | mov %i2, %o2 | ||
117 | ret | ||
118 | restore %g0, %g0, %o0 | ||
119 | .size memcpy_user_stub, .-memcpy_user_stub | ||
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index 73f7fe8fd4d1..9c39095b33fc 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig | |||
@@ -1802,6 +1802,17 @@ config DMAR | |||
1802 | and include PCI device scope covered by these DMA | 1802 | and include PCI device scope covered by these DMA |
1803 | remapping devices. | 1803 | remapping devices. |
1804 | 1804 | ||
1805 | config DMAR_DEFAULT_ON | ||
1806 | def_bool n | ||
1807 | prompt "Enable DMA Remapping Devices by default" | ||
1808 | depends on DMAR | ||
1809 | help | ||
1810 | Selecting this option will enable a DMAR device at boot time if | ||
1811 | one is found. If this option is not selected, DMAR support can | ||
1812 | be enabled by passing intel_iommu=on to the kernel. It is | ||
1813 | recommended you say N here while the DMAR code remains | ||
1814 | experimental. | ||
1815 | |||
1805 | config DMAR_GFX_WA | 1816 | config DMAR_GFX_WA |
1806 | def_bool y | 1817 | def_bool y |
1807 | prompt "Support for Graphics workaround" | 1818 | prompt "Support for Graphics workaround" |
diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu index 8078955845ae..c98d52e82966 100644 --- a/arch/x86/Kconfig.cpu +++ b/arch/x86/Kconfig.cpu | |||
@@ -167,9 +167,9 @@ config MK7 | |||
167 | config MK8 | 167 | config MK8 |
168 | bool "Opteron/Athlon64/Hammer/K8" | 168 | bool "Opteron/Athlon64/Hammer/K8" |
169 | help | 169 | help |
170 | Select this for an AMD Opteron or Athlon64 Hammer-family processor. Enables | 170 | Select this for an AMD Opteron or Athlon64 Hammer-family processor. |
171 | use of some extended instructions, and passes appropriate optimization | 171 | Enables use of some extended instructions, and passes appropriate |
172 | flags to GCC. | 172 | optimization flags to GCC. |
173 | 173 | ||
174 | config MCRUSOE | 174 | config MCRUSOE |
175 | bool "Crusoe" | 175 | bool "Crusoe" |
@@ -256,9 +256,11 @@ config MPSC | |||
256 | config MCORE2 | 256 | config MCORE2 |
257 | bool "Core 2/newer Xeon" | 257 | bool "Core 2/newer Xeon" |
258 | help | 258 | help |
259 | Select this for Intel Core 2 and newer Core 2 Xeons (Xeon 51xx and 53xx) | 259 | |
260 | CPUs. You can distinguish newer from older Xeons by the CPU family | 260 | Select this for Intel Core 2 and newer Core 2 Xeons (Xeon 51xx and |
261 | in /proc/cpuinfo. Newer ones have 6 and older ones 15 (not a typo) | 261 | 53xx) CPUs. You can distinguish newer from older Xeons by the CPU |
262 | family in /proc/cpuinfo. Newer ones have 6 and older ones 15 | ||
263 | (not a typo) | ||
262 | 264 | ||
263 | config GENERIC_CPU | 265 | config GENERIC_CPU |
264 | bool "Generic-x86-64" | 266 | bool "Generic-x86-64" |
@@ -320,14 +322,14 @@ config X86_PPRO_FENCE | |||
320 | bool "PentiumPro memory ordering errata workaround" | 322 | bool "PentiumPro memory ordering errata workaround" |
321 | depends on M686 || M586MMX || M586TSC || M586 || M486 || M386 || MGEODEGX1 | 323 | depends on M686 || M586MMX || M586TSC || M586 || M486 || M386 || MGEODEGX1 |
322 | help | 324 | help |
323 | Old PentiumPro multiprocessor systems had errata that could cause memory | 325 | Old PentiumPro multiprocessor systems had errata that could cause |
324 | operations to violate the x86 ordering standard in rare cases. Enabling this | 326 | memory operations to violate the x86 ordering standard in rare cases. |
325 | option will attempt to work around some (but not all) occurances of | 327 | Enabling this option will attempt to work around some (but not all) |
326 | this problem, at the cost of much heavier spinlock and memory barrier | 328 | occurances of this problem, at the cost of much heavier spinlock and |
327 | operations. | 329 | memory barrier operations. |
328 | 330 | ||
329 | If unsure, say n here. Even distro kernels should think twice before enabling | 331 | If unsure, say n here. Even distro kernels should think twice before |
330 | this: there are few systems, and an unlikely bug. | 332 | enabling this: there are few systems, and an unlikely bug. |
331 | 333 | ||
332 | config X86_F00F_BUG | 334 | config X86_F00F_BUG |
333 | def_bool y | 335 | def_bool y |
diff --git a/arch/x86/ia32/ia32entry.S b/arch/x86/ia32/ia32entry.S index 256b00b61892..5a0d76dc56a4 100644 --- a/arch/x86/ia32/ia32entry.S +++ b/arch/x86/ia32/ia32entry.S | |||
@@ -418,9 +418,9 @@ ENTRY(ia32_syscall) | |||
418 | orl $TS_COMPAT,TI_status(%r10) | 418 | orl $TS_COMPAT,TI_status(%r10) |
419 | testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r10) | 419 | testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r10) |
420 | jnz ia32_tracesys | 420 | jnz ia32_tracesys |
421 | ia32_do_syscall: | ||
422 | cmpl $(IA32_NR_syscalls-1),%eax | 421 | cmpl $(IA32_NR_syscalls-1),%eax |
423 | ja int_ret_from_sys_call /* ia32_tracesys has set RAX(%rsp) */ | 422 | ja ia32_badsys |
423 | ia32_do_call: | ||
424 | IA32_ARG_FIXUP | 424 | IA32_ARG_FIXUP |
425 | call *ia32_sys_call_table(,%rax,8) # xxx: rip relative | 425 | call *ia32_sys_call_table(,%rax,8) # xxx: rip relative |
426 | ia32_sysret: | 426 | ia32_sysret: |
@@ -435,7 +435,9 @@ ia32_tracesys: | |||
435 | call syscall_trace_enter | 435 | call syscall_trace_enter |
436 | LOAD_ARGS32 ARGOFFSET /* reload args from stack in case ptrace changed it */ | 436 | LOAD_ARGS32 ARGOFFSET /* reload args from stack in case ptrace changed it */ |
437 | RESTORE_REST | 437 | RESTORE_REST |
438 | jmp ia32_do_syscall | 438 | cmpl $(IA32_NR_syscalls-1),%eax |
439 | ja int_ret_from_sys_call /* ia32_tracesys has set RAX(%rsp) */ | ||
440 | jmp ia32_do_call | ||
439 | END(ia32_syscall) | 441 | END(ia32_syscall) |
440 | 442 | ||
441 | ia32_badsys: | 443 | ia32_badsys: |
diff --git a/arch/x86/include/asm/a.out-core.h b/arch/x86/include/asm/a.out-core.h index 37822206083e..3c601f8224be 100644 --- a/arch/x86/include/asm/a.out-core.h +++ b/arch/x86/include/asm/a.out-core.h | |||
@@ -23,8 +23,6 @@ | |||
23 | */ | 23 | */ |
24 | static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) | 24 | static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) |
25 | { | 25 | { |
26 | u16 gs; | ||
27 | |||
28 | /* changed the size calculations - should hopefully work better. lbt */ | 26 | /* changed the size calculations - should hopefully work better. lbt */ |
29 | dump->magic = CMAGIC; | 27 | dump->magic = CMAGIC; |
30 | dump->start_code = 0; | 28 | dump->start_code = 0; |
@@ -57,7 +55,7 @@ static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) | |||
57 | dump->regs.ds = (u16)regs->ds; | 55 | dump->regs.ds = (u16)regs->ds; |
58 | dump->regs.es = (u16)regs->es; | 56 | dump->regs.es = (u16)regs->es; |
59 | dump->regs.fs = (u16)regs->fs; | 57 | dump->regs.fs = (u16)regs->fs; |
60 | savesegment(gs, gs); | 58 | savesegment(gs, dump->regs.gs); |
61 | dump->regs.orig_ax = regs->orig_ax; | 59 | dump->regs.orig_ax = regs->orig_ax; |
62 | dump->regs.ip = regs->ip; | 60 | dump->regs.ip = regs->ip; |
63 | dump->regs.cs = (u16)regs->cs; | 61 | dump->regs.cs = (u16)regs->cs; |
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h index ea408dcba513..7301e60dc4a8 100644 --- a/arch/x86/include/asm/cpufeature.h +++ b/arch/x86/include/asm/cpufeature.h | |||
@@ -93,6 +93,7 @@ | |||
93 | #define X86_FEATURE_XTOPOLOGY (3*32+22) /* cpu topology enum extensions */ | 93 | #define X86_FEATURE_XTOPOLOGY (3*32+22) /* cpu topology enum extensions */ |
94 | #define X86_FEATURE_TSC_RELIABLE (3*32+23) /* TSC is known to be reliable */ | 94 | #define X86_FEATURE_TSC_RELIABLE (3*32+23) /* TSC is known to be reliable */ |
95 | #define X86_FEATURE_NONSTOP_TSC (3*32+24) /* TSC does not stop in C states */ | 95 | #define X86_FEATURE_NONSTOP_TSC (3*32+24) /* TSC does not stop in C states */ |
96 | #define X86_FEATURE_CLFLUSH_MONITOR (3*32+25) /* "" clflush reqd with monitor */ | ||
96 | 97 | ||
97 | /* Intel-defined CPU features, CPUID level 0x00000001 (ecx), word 4 */ | 98 | /* Intel-defined CPU features, CPUID level 0x00000001 (ecx), word 4 */ |
98 | #define X86_FEATURE_XMM3 (4*32+ 0) /* "pni" SSE-3 */ | 99 | #define X86_FEATURE_XMM3 (4*32+ 0) /* "pni" SSE-3 */ |
diff --git a/arch/x86/include/asm/math_emu.h b/arch/x86/include/asm/math_emu.h index 5a65b107ad58..031f6266f425 100644 --- a/arch/x86/include/asm/math_emu.h +++ b/arch/x86/include/asm/math_emu.h | |||
@@ -1,31 +1,18 @@ | |||
1 | #ifndef _ASM_X86_MATH_EMU_H | 1 | #ifndef _ASM_X86_MATH_EMU_H |
2 | #define _ASM_X86_MATH_EMU_H | 2 | #define _ASM_X86_MATH_EMU_H |
3 | 3 | ||
4 | #include <asm/ptrace.h> | ||
5 | #include <asm/vm86.h> | ||
6 | |||
4 | /* This structure matches the layout of the data saved to the stack | 7 | /* This structure matches the layout of the data saved to the stack |
5 | following a device-not-present interrupt, part of it saved | 8 | following a device-not-present interrupt, part of it saved |
6 | automatically by the 80386/80486. | 9 | automatically by the 80386/80486. |
7 | */ | 10 | */ |
8 | struct info { | 11 | struct math_emu_info { |
9 | long ___orig_eip; | 12 | long ___orig_eip; |
10 | long ___ebx; | 13 | union { |
11 | long ___ecx; | 14 | struct pt_regs *regs; |
12 | long ___edx; | 15 | struct kernel_vm86_regs *vm86; |
13 | long ___esi; | 16 | }; |
14 | long ___edi; | ||
15 | long ___ebp; | ||
16 | long ___eax; | ||
17 | long ___ds; | ||
18 | long ___es; | ||
19 | long ___fs; | ||
20 | long ___orig_eax; | ||
21 | long ___eip; | ||
22 | long ___cs; | ||
23 | long ___eflags; | ||
24 | long ___esp; | ||
25 | long ___ss; | ||
26 | long ___vm86_es; /* This and the following only in vm86 mode */ | ||
27 | long ___vm86_ds; | ||
28 | long ___vm86_fs; | ||
29 | long ___vm86_gs; | ||
30 | }; | 17 | }; |
31 | #endif /* _ASM_X86_MATH_EMU_H */ | 18 | #endif /* _ASM_X86_MATH_EMU_H */ |
diff --git a/arch/x86/include/asm/mpspec.h b/arch/x86/include/asm/mpspec.h index 62d14ce3cd00..bd22f2a3713f 100644 --- a/arch/x86/include/asm/mpspec.h +++ b/arch/x86/include/asm/mpspec.h | |||
@@ -60,6 +60,7 @@ extern void mp_override_legacy_irq(u8 bus_irq, u8 polarity, u8 trigger, | |||
60 | u32 gsi); | 60 | u32 gsi); |
61 | extern void mp_config_acpi_legacy_irqs(void); | 61 | extern void mp_config_acpi_legacy_irqs(void); |
62 | extern int mp_register_gsi(u32 gsi, int edge_level, int active_high_low); | 62 | extern int mp_register_gsi(u32 gsi, int edge_level, int active_high_low); |
63 | extern int acpi_probe_gsi(void); | ||
63 | #ifdef CONFIG_X86_IO_APIC | 64 | #ifdef CONFIG_X86_IO_APIC |
64 | extern int mp_config_acpi_gsi(unsigned char number, unsigned int devfn, u8 pin, | 65 | extern int mp_config_acpi_gsi(unsigned char number, unsigned int devfn, u8 pin, |
65 | u32 gsi, int triggering, int polarity); | 66 | u32 gsi, int triggering, int polarity); |
@@ -71,6 +72,11 @@ mp_config_acpi_gsi(unsigned char number, unsigned int devfn, u8 pin, | |||
71 | return 0; | 72 | return 0; |
72 | } | 73 | } |
73 | #endif | 74 | #endif |
75 | #else /* !CONFIG_ACPI: */ | ||
76 | static inline int acpi_probe_gsi(void) | ||
77 | { | ||
78 | return 0; | ||
79 | } | ||
74 | #endif /* CONFIG_ACPI */ | 80 | #endif /* CONFIG_ACPI */ |
75 | 81 | ||
76 | #define PHYSID_ARRAY_SIZE BITS_TO_LONGS(MAX_APICS) | 82 | #define PHYSID_ARRAY_SIZE BITS_TO_LONGS(MAX_APICS) |
diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/paravirt.h index ba3e2ff6aedc..c09a14127584 100644 --- a/arch/x86/include/asm/paravirt.h +++ b/arch/x86/include/asm/paravirt.h | |||
@@ -1402,6 +1402,7 @@ static inline int __raw_spin_is_contended(struct raw_spinlock *lock) | |||
1402 | { | 1402 | { |
1403 | return PVOP_CALL1(int, pv_lock_ops.spin_is_contended, lock); | 1403 | return PVOP_CALL1(int, pv_lock_ops.spin_is_contended, lock); |
1404 | } | 1404 | } |
1405 | #define __raw_spin_is_contended __raw_spin_is_contended | ||
1405 | 1406 | ||
1406 | static __always_inline void __raw_spin_lock(struct raw_spinlock *lock) | 1407 | static __always_inline void __raw_spin_lock(struct raw_spinlock *lock) |
1407 | { | 1408 | { |
diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index 06bbcbd66e9c..4f5af8447d54 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h | |||
@@ -302,16 +302,30 @@ static inline pte_t pte_mkspecial(pte_t pte) | |||
302 | 302 | ||
303 | extern pteval_t __supported_pte_mask; | 303 | extern pteval_t __supported_pte_mask; |
304 | 304 | ||
305 | /* | ||
306 | * Mask out unsupported bits in a present pgprot. Non-present pgprots | ||
307 | * can use those bits for other purposes, so leave them be. | ||
308 | */ | ||
309 | static inline pgprotval_t massage_pgprot(pgprot_t pgprot) | ||
310 | { | ||
311 | pgprotval_t protval = pgprot_val(pgprot); | ||
312 | |||
313 | if (protval & _PAGE_PRESENT) | ||
314 | protval &= __supported_pte_mask; | ||
315 | |||
316 | return protval; | ||
317 | } | ||
318 | |||
305 | static inline pte_t pfn_pte(unsigned long page_nr, pgprot_t pgprot) | 319 | static inline pte_t pfn_pte(unsigned long page_nr, pgprot_t pgprot) |
306 | { | 320 | { |
307 | return __pte((((phys_addr_t)page_nr << PAGE_SHIFT) | | 321 | return __pte(((phys_addr_t)page_nr << PAGE_SHIFT) | |
308 | pgprot_val(pgprot)) & __supported_pte_mask); | 322 | massage_pgprot(pgprot)); |
309 | } | 323 | } |
310 | 324 | ||
311 | static inline pmd_t pfn_pmd(unsigned long page_nr, pgprot_t pgprot) | 325 | static inline pmd_t pfn_pmd(unsigned long page_nr, pgprot_t pgprot) |
312 | { | 326 | { |
313 | return __pmd((((phys_addr_t)page_nr << PAGE_SHIFT) | | 327 | return __pmd(((phys_addr_t)page_nr << PAGE_SHIFT) | |
314 | pgprot_val(pgprot)) & __supported_pte_mask); | 328 | massage_pgprot(pgprot)); |
315 | } | 329 | } |
316 | 330 | ||
317 | static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) | 331 | static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) |
@@ -323,7 +337,7 @@ static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) | |||
323 | * the newprot (if present): | 337 | * the newprot (if present): |
324 | */ | 338 | */ |
325 | val &= _PAGE_CHG_MASK; | 339 | val &= _PAGE_CHG_MASK; |
326 | val |= pgprot_val(newprot) & (~_PAGE_CHG_MASK) & __supported_pte_mask; | 340 | val |= massage_pgprot(newprot) & ~_PAGE_CHG_MASK; |
327 | 341 | ||
328 | return __pte(val); | 342 | return __pte(val); |
329 | } | 343 | } |
@@ -339,7 +353,7 @@ static inline pgprot_t pgprot_modify(pgprot_t oldprot, pgprot_t newprot) | |||
339 | 353 | ||
340 | #define pte_pgprot(x) __pgprot(pte_flags(x) & PTE_FLAGS_MASK) | 354 | #define pte_pgprot(x) __pgprot(pte_flags(x) & PTE_FLAGS_MASK) |
341 | 355 | ||
342 | #define canon_pgprot(p) __pgprot(pgprot_val(p) & __supported_pte_mask) | 356 | #define canon_pgprot(p) __pgprot(massage_pgprot(p)) |
343 | 357 | ||
344 | static inline int is_new_memtype_allowed(unsigned long flags, | 358 | static inline int is_new_memtype_allowed(unsigned long flags, |
345 | unsigned long new_flags) | 359 | unsigned long new_flags) |
diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/processor.h index 091cd8855f2e..3bfd5235a9eb 100644 --- a/arch/x86/include/asm/processor.h +++ b/arch/x86/include/asm/processor.h | |||
@@ -353,7 +353,7 @@ struct i387_soft_struct { | |||
353 | u8 no_update; | 353 | u8 no_update; |
354 | u8 rm; | 354 | u8 rm; |
355 | u8 alimit; | 355 | u8 alimit; |
356 | struct info *info; | 356 | struct math_emu_info *info; |
357 | u32 entry_eip; | 357 | u32 entry_eip; |
358 | }; | 358 | }; |
359 | 359 | ||
diff --git a/arch/x86/include/asm/spinlock.h b/arch/x86/include/asm/spinlock.h index d17c91981da2..8247e94ac6b1 100644 --- a/arch/x86/include/asm/spinlock.h +++ b/arch/x86/include/asm/spinlock.h | |||
@@ -245,6 +245,7 @@ static inline int __raw_spin_is_contended(raw_spinlock_t *lock) | |||
245 | { | 245 | { |
246 | return __ticket_spin_is_contended(lock); | 246 | return __ticket_spin_is_contended(lock); |
247 | } | 247 | } |
248 | #define __raw_spin_is_contended __raw_spin_is_contended | ||
248 | 249 | ||
249 | static __always_inline void __raw_spin_lock(raw_spinlock_t *lock) | 250 | static __always_inline void __raw_spin_lock(raw_spinlock_t *lock) |
250 | { | 251 | { |
diff --git a/arch/x86/include/asm/traps.h b/arch/x86/include/asm/traps.h index 2ee0a3bceedf..cf3bb053da0b 100644 --- a/arch/x86/include/asm/traps.h +++ b/arch/x86/include/asm/traps.h | |||
@@ -41,7 +41,7 @@ dotraplinkage void do_int3(struct pt_regs *, long); | |||
41 | dotraplinkage void do_overflow(struct pt_regs *, long); | 41 | dotraplinkage void do_overflow(struct pt_regs *, long); |
42 | dotraplinkage void do_bounds(struct pt_regs *, long); | 42 | dotraplinkage void do_bounds(struct pt_regs *, long); |
43 | dotraplinkage void do_invalid_op(struct pt_regs *, long); | 43 | dotraplinkage void do_invalid_op(struct pt_regs *, long); |
44 | dotraplinkage void do_device_not_available(struct pt_regs *, long); | 44 | dotraplinkage void do_device_not_available(struct pt_regs); |
45 | dotraplinkage void do_coprocessor_segment_overrun(struct pt_regs *, long); | 45 | dotraplinkage void do_coprocessor_segment_overrun(struct pt_regs *, long); |
46 | dotraplinkage void do_invalid_TSS(struct pt_regs *, long); | 46 | dotraplinkage void do_invalid_TSS(struct pt_regs *, long); |
47 | dotraplinkage void do_segment_not_present(struct pt_regs *, long); | 47 | dotraplinkage void do_segment_not_present(struct pt_regs *, long); |
@@ -77,7 +77,7 @@ extern int panic_on_unrecovered_nmi; | |||
77 | extern int kstack_depth_to_print; | 77 | extern int kstack_depth_to_print; |
78 | 78 | ||
79 | void math_error(void __user *); | 79 | void math_error(void __user *); |
80 | asmlinkage void math_emulate(long); | 80 | void math_emulate(struct math_emu_info *); |
81 | #ifdef CONFIG_X86_32 | 81 | #ifdef CONFIG_X86_32 |
82 | unsigned long patch_espfix_desc(unsigned long, unsigned long); | 82 | unsigned long patch_espfix_desc(unsigned long, unsigned long); |
83 | #else | 83 | #else |
diff --git a/arch/x86/include/asm/xen/page.h b/arch/x86/include/asm/xen/page.h index 7ef617ef1df3..4bd990ee43df 100644 --- a/arch/x86/include/asm/xen/page.h +++ b/arch/x86/include/asm/xen/page.h | |||
@@ -137,7 +137,7 @@ static inline pte_t mfn_pte(unsigned long page_nr, pgprot_t pgprot) | |||
137 | pte_t pte; | 137 | pte_t pte; |
138 | 138 | ||
139 | pte.pte = ((phys_addr_t)page_nr << PAGE_SHIFT) | | 139 | pte.pte = ((phys_addr_t)page_nr << PAGE_SHIFT) | |
140 | (pgprot_val(pgprot) & __supported_pte_mask); | 140 | massage_pgprot(pgprot); |
141 | 141 | ||
142 | return pte; | 142 | return pte; |
143 | } | 143 | } |
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index d37593c2f438..7678f10c4568 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c | |||
@@ -973,6 +973,29 @@ void __init mp_register_ioapic(int id, u32 address, u32 gsi_base) | |||
973 | nr_ioapics++; | 973 | nr_ioapics++; |
974 | } | 974 | } |
975 | 975 | ||
976 | int __init acpi_probe_gsi(void) | ||
977 | { | ||
978 | int idx; | ||
979 | int gsi; | ||
980 | int max_gsi = 0; | ||
981 | |||
982 | if (acpi_disabled) | ||
983 | return 0; | ||
984 | |||
985 | if (!acpi_ioapic) | ||
986 | return 0; | ||
987 | |||
988 | max_gsi = 0; | ||
989 | for (idx = 0; idx < nr_ioapics; idx++) { | ||
990 | gsi = mp_ioapic_routing[idx].gsi_end; | ||
991 | |||
992 | if (gsi > max_gsi) | ||
993 | max_gsi = gsi; | ||
994 | } | ||
995 | |||
996 | return max_gsi + 1; | ||
997 | } | ||
998 | |||
976 | static void assign_to_mp_irq(struct mp_config_intsrc *m, | 999 | static void assign_to_mp_irq(struct mp_config_intsrc *m, |
977 | struct mp_config_intsrc *mp_irq) | 1000 | struct mp_config_intsrc *mp_irq) |
978 | { | 1001 | { |
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c index 707c1f6f95fa..a60c1f3bcb87 100644 --- a/arch/x86/kernel/acpi/sleep.c +++ b/arch/x86/kernel/acpi/sleep.c | |||
@@ -156,11 +156,11 @@ static int __init acpi_sleep_setup(char *str) | |||
156 | #ifdef CONFIG_HIBERNATION | 156 | #ifdef CONFIG_HIBERNATION |
157 | if (strncmp(str, "s4_nohwsig", 10) == 0) | 157 | if (strncmp(str, "s4_nohwsig", 10) == 0) |
158 | acpi_no_s4_hw_signature(); | 158 | acpi_no_s4_hw_signature(); |
159 | if (strncmp(str, "s4_nonvs", 8) == 0) | ||
160 | acpi_s4_no_nvs(); | ||
159 | #endif | 161 | #endif |
160 | if (strncmp(str, "old_ordering", 12) == 0) | 162 | if (strncmp(str, "old_ordering", 12) == 0) |
161 | acpi_old_suspend_ordering(); | 163 | acpi_old_suspend_ordering(); |
162 | if (strncmp(str, "s4_nonvs", 8) == 0) | ||
163 | acpi_s4_no_nvs(); | ||
164 | str = strchr(str, ','); | 164 | str = strchr(str, ','); |
165 | if (str != NULL) | 165 | if (str != NULL) |
166 | str += strspn(str, ", \t"); | 166 | str += strspn(str, ", \t"); |
diff --git a/arch/x86/kernel/apic.c b/arch/x86/kernel/apic.c index 4b6df2469fe3..115449f869ee 100644 --- a/arch/x86/kernel/apic.c +++ b/arch/x86/kernel/apic.c | |||
@@ -1436,7 +1436,7 @@ static int __init detect_init_APIC(void) | |||
1436 | switch (boot_cpu_data.x86_vendor) { | 1436 | switch (boot_cpu_data.x86_vendor) { |
1437 | case X86_VENDOR_AMD: | 1437 | case X86_VENDOR_AMD: |
1438 | if ((boot_cpu_data.x86 == 6 && boot_cpu_data.x86_model > 1) || | 1438 | if ((boot_cpu_data.x86 == 6 && boot_cpu_data.x86_model > 1) || |
1439 | (boot_cpu_data.x86 == 15)) | 1439 | (boot_cpu_data.x86 >= 15)) |
1440 | break; | 1440 | break; |
1441 | goto no_apic; | 1441 | goto no_apic; |
1442 | case X86_VENDOR_INTEL: | 1442 | case X86_VENDOR_INTEL: |
diff --git a/arch/x86/kernel/cpu/cpufreq/Kconfig b/arch/x86/kernel/cpu/cpufreq/Kconfig index efae3b22a0ff..65792c2cc462 100644 --- a/arch/x86/kernel/cpu/cpufreq/Kconfig +++ b/arch/x86/kernel/cpu/cpufreq/Kconfig | |||
@@ -245,17 +245,6 @@ config X86_E_POWERSAVER | |||
245 | 245 | ||
246 | comment "shared options" | 246 | comment "shared options" |
247 | 247 | ||
248 | config X86_ACPI_CPUFREQ_PROC_INTF | ||
249 | bool "/proc/acpi/processor/../performance interface (deprecated)" | ||
250 | depends on PROC_FS | ||
251 | depends on X86_ACPI_CPUFREQ || X86_POWERNOW_K7_ACPI || X86_POWERNOW_K8_ACPI | ||
252 | help | ||
253 | This enables the deprecated /proc/acpi/processor/../performance | ||
254 | interface. While it is helpful for debugging, the generic, | ||
255 | cross-architecture cpufreq interfaces should be used. | ||
256 | |||
257 | If in doubt, say N. | ||
258 | |||
259 | config X86_SPEEDSTEP_LIB | 248 | config X86_SPEEDSTEP_LIB |
260 | tristate | 249 | tristate |
261 | default (X86_SPEEDSTEP_ICH || X86_SPEEDSTEP_SMI || X86_P4_CLOCKMOD) | 250 | default (X86_SPEEDSTEP_ICH || X86_SPEEDSTEP_SMI || X86_P4_CLOCKMOD) |
diff --git a/arch/x86/kernel/cpu/cpufreq/powernow-k8.c b/arch/x86/kernel/cpu/cpufreq/powernow-k8.c index 5c28b37dea11..fb039cd345d8 100644 --- a/arch/x86/kernel/cpu/cpufreq/powernow-k8.c +++ b/arch/x86/kernel/cpu/cpufreq/powernow-k8.c | |||
@@ -939,10 +939,25 @@ static void powernow_k8_cpu_exit_acpi(struct powernow_k8_data *data) | |||
939 | free_cpumask_var(data->acpi_data.shared_cpu_map); | 939 | free_cpumask_var(data->acpi_data.shared_cpu_map); |
940 | } | 940 | } |
941 | 941 | ||
942 | static int get_transition_latency(struct powernow_k8_data *data) | ||
943 | { | ||
944 | int max_latency = 0; | ||
945 | int i; | ||
946 | for (i = 0; i < data->acpi_data.state_count; i++) { | ||
947 | int cur_latency = data->acpi_data.states[i].transition_latency | ||
948 | + data->acpi_data.states[i].bus_master_latency; | ||
949 | if (cur_latency > max_latency) | ||
950 | max_latency = cur_latency; | ||
951 | } | ||
952 | /* value in usecs, needs to be in nanoseconds */ | ||
953 | return 1000 * max_latency; | ||
954 | } | ||
955 | |||
942 | #else | 956 | #else |
943 | static int powernow_k8_cpu_init_acpi(struct powernow_k8_data *data) { return -ENODEV; } | 957 | static int powernow_k8_cpu_init_acpi(struct powernow_k8_data *data) { return -ENODEV; } |
944 | static void powernow_k8_cpu_exit_acpi(struct powernow_k8_data *data) { return; } | 958 | static void powernow_k8_cpu_exit_acpi(struct powernow_k8_data *data) { return; } |
945 | static void powernow_k8_acpi_pst_values(struct powernow_k8_data *data, unsigned int index) { return; } | 959 | static void powernow_k8_acpi_pst_values(struct powernow_k8_data *data, unsigned int index) { return; } |
960 | static int get_transition_latency(struct powernow_k8_data *data) { return 0; } | ||
946 | #endif /* CONFIG_X86_POWERNOW_K8_ACPI */ | 961 | #endif /* CONFIG_X86_POWERNOW_K8_ACPI */ |
947 | 962 | ||
948 | /* Take a frequency, and issue the fid/vid transition command */ | 963 | /* Take a frequency, and issue the fid/vid transition command */ |
@@ -1173,7 +1188,13 @@ static int __cpuinit powernowk8_cpu_init(struct cpufreq_policy *pol) | |||
1173 | if (rc) { | 1188 | if (rc) { |
1174 | goto err_out; | 1189 | goto err_out; |
1175 | } | 1190 | } |
1176 | } | 1191 | /* Take a crude guess here. |
1192 | * That guess was in microseconds, so multiply with 1000 */ | ||
1193 | pol->cpuinfo.transition_latency = ( | ||
1194 | ((data->rvo + 8) * data->vstable * VST_UNITS_20US) + | ||
1195 | ((1 << data->irt) * 30)) * 1000; | ||
1196 | } else /* ACPI _PSS objects available */ | ||
1197 | pol->cpuinfo.transition_latency = get_transition_latency(data); | ||
1177 | 1198 | ||
1178 | /* only run on specific CPU from here on */ | 1199 | /* only run on specific CPU from here on */ |
1179 | oldmask = current->cpus_allowed; | 1200 | oldmask = current->cpus_allowed; |
@@ -1204,11 +1225,6 @@ static int __cpuinit powernowk8_cpu_init(struct cpufreq_policy *pol) | |||
1204 | cpumask_copy(pol->cpus, &per_cpu(cpu_core_map, pol->cpu)); | 1225 | cpumask_copy(pol->cpus, &per_cpu(cpu_core_map, pol->cpu)); |
1205 | data->available_cores = pol->cpus; | 1226 | data->available_cores = pol->cpus; |
1206 | 1227 | ||
1207 | /* Take a crude guess here. | ||
1208 | * That guess was in microseconds, so multiply with 1000 */ | ||
1209 | pol->cpuinfo.transition_latency = (((data->rvo + 8) * data->vstable * VST_UNITS_20US) | ||
1210 | + (3 * (1 << data->irt) * 10)) * 1000; | ||
1211 | |||
1212 | if (cpu_family == CPU_HW_PSTATE) | 1228 | if (cpu_family == CPU_HW_PSTATE) |
1213 | pol->cur = find_khz_freq_from_pstate(data->powernow_table, data->currpstate); | 1229 | pol->cur = find_khz_freq_from_pstate(data->powernow_table, data->currpstate); |
1214 | else | 1230 | else |
diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c index 430e5c38a544..24ff26a38ade 100644 --- a/arch/x86/kernel/cpu/intel.c +++ b/arch/x86/kernel/cpu/intel.c | |||
@@ -291,6 +291,9 @@ static void __cpuinit init_intel(struct cpuinfo_x86 *c) | |||
291 | ds_init_intel(c); | 291 | ds_init_intel(c); |
292 | } | 292 | } |
293 | 293 | ||
294 | if (c->x86 == 6 && c->x86_model == 29 && cpu_has_clflush) | ||
295 | set_cpu_cap(c, X86_FEATURE_CLFLUSH_MONITOR); | ||
296 | |||
294 | #ifdef CONFIG_X86_64 | 297 | #ifdef CONFIG_X86_64 |
295 | if (c->x86 == 15) | 298 | if (c->x86 == 15) |
296 | c->x86_cache_alignment = c->x86_clflush_size * 2; | 299 | c->x86_cache_alignment = c->x86_clflush_size * 2; |
diff --git a/arch/x86/kernel/cpu/intel_cacheinfo.c b/arch/x86/kernel/cpu/intel_cacheinfo.c index 48533d77be78..da299eb85fc0 100644 --- a/arch/x86/kernel/cpu/intel_cacheinfo.c +++ b/arch/x86/kernel/cpu/intel_cacheinfo.c | |||
@@ -36,8 +36,11 @@ static struct _cache_table cache_table[] __cpuinitdata = | |||
36 | { | 36 | { |
37 | { 0x06, LVL_1_INST, 8 }, /* 4-way set assoc, 32 byte line size */ | 37 | { 0x06, LVL_1_INST, 8 }, /* 4-way set assoc, 32 byte line size */ |
38 | { 0x08, LVL_1_INST, 16 }, /* 4-way set assoc, 32 byte line size */ | 38 | { 0x08, LVL_1_INST, 16 }, /* 4-way set assoc, 32 byte line size */ |
39 | { 0x09, LVL_1_INST, 32 }, /* 4-way set assoc, 64 byte line size */ | ||
39 | { 0x0a, LVL_1_DATA, 8 }, /* 2 way set assoc, 32 byte line size */ | 40 | { 0x0a, LVL_1_DATA, 8 }, /* 2 way set assoc, 32 byte line size */ |
40 | { 0x0c, LVL_1_DATA, 16 }, /* 4-way set assoc, 32 byte line size */ | 41 | { 0x0c, LVL_1_DATA, 16 }, /* 4-way set assoc, 32 byte line size */ |
42 | { 0x0d, LVL_1_DATA, 16 }, /* 4-way set assoc, 64 byte line size */ | ||
43 | { 0x21, LVL_2, 256 }, /* 8-way set assoc, 64 byte line size */ | ||
41 | { 0x22, LVL_3, 512 }, /* 4-way set assoc, sectored cache, 64 byte line size */ | 44 | { 0x22, LVL_3, 512 }, /* 4-way set assoc, sectored cache, 64 byte line size */ |
42 | { 0x23, LVL_3, 1024 }, /* 8-way set assoc, sectored cache, 64 byte line size */ | 45 | { 0x23, LVL_3, 1024 }, /* 8-way set assoc, sectored cache, 64 byte line size */ |
43 | { 0x25, LVL_3, 2048 }, /* 8-way set assoc, sectored cache, 64 byte line size */ | 46 | { 0x25, LVL_3, 2048 }, /* 8-way set assoc, sectored cache, 64 byte line size */ |
@@ -85,6 +88,18 @@ static struct _cache_table cache_table[] __cpuinitdata = | |||
85 | { 0x85, LVL_2, 2048 }, /* 8-way set assoc, 32 byte line size */ | 88 | { 0x85, LVL_2, 2048 }, /* 8-way set assoc, 32 byte line size */ |
86 | { 0x86, LVL_2, 512 }, /* 4-way set assoc, 64 byte line size */ | 89 | { 0x86, LVL_2, 512 }, /* 4-way set assoc, 64 byte line size */ |
87 | { 0x87, LVL_2, 1024 }, /* 8-way set assoc, 64 byte line size */ | 90 | { 0x87, LVL_2, 1024 }, /* 8-way set assoc, 64 byte line size */ |
91 | { 0xd0, LVL_3, 512 }, /* 4-way set assoc, 64 byte line size */ | ||
92 | { 0xd1, LVL_3, 1024 }, /* 4-way set assoc, 64 byte line size */ | ||
93 | { 0xd2, LVL_3, 2048 }, /* 4-way set assoc, 64 byte line size */ | ||
94 | { 0xd6, LVL_3, 1024 }, /* 8-way set assoc, 64 byte line size */ | ||
95 | { 0xd7, LVL_3, 2038 }, /* 8-way set assoc, 64 byte line size */ | ||
96 | { 0xd8, LVL_3, 4096 }, /* 12-way set assoc, 64 byte line size */ | ||
97 | { 0xdc, LVL_3, 2048 }, /* 12-way set assoc, 64 byte line size */ | ||
98 | { 0xdd, LVL_3, 4096 }, /* 12-way set assoc, 64 byte line size */ | ||
99 | { 0xde, LVL_3, 8192 }, /* 12-way set assoc, 64 byte line size */ | ||
100 | { 0xe2, LVL_3, 2048 }, /* 16-way set assoc, 64 byte line size */ | ||
101 | { 0xe3, LVL_3, 4096 }, /* 16-way set assoc, 64 byte line size */ | ||
102 | { 0xe4, LVL_3, 8192 }, /* 16-way set assoc, 64 byte line size */ | ||
88 | { 0x00, 0, 0} | 103 | { 0x00, 0, 0} |
89 | }; | 104 | }; |
90 | 105 | ||
diff --git a/arch/x86/kernel/entry_64.S b/arch/x86/kernel/entry_64.S index e28c7a987793..a1346217e43c 100644 --- a/arch/x86/kernel/entry_64.S +++ b/arch/x86/kernel/entry_64.S | |||
@@ -346,6 +346,7 @@ ENTRY(save_args) | |||
346 | popq_cfi %rax /* move return address... */ | 346 | popq_cfi %rax /* move return address... */ |
347 | mov %gs:pda_irqstackptr,%rsp | 347 | mov %gs:pda_irqstackptr,%rsp |
348 | EMPTY_FRAME 0 | 348 | EMPTY_FRAME 0 |
349 | pushq_cfi %rbp /* backlink for unwinder */ | ||
349 | pushq_cfi %rax /* ... to the new stack */ | 350 | pushq_cfi %rax /* ... to the new stack */ |
350 | /* | 351 | /* |
351 | * We entered an interrupt context - irqs are off: | 352 | * We entered an interrupt context - irqs are off: |
diff --git a/arch/x86/kernel/ftrace.c b/arch/x86/kernel/ftrace.c index 1b43086b097a..231bdd3c5b1c 100644 --- a/arch/x86/kernel/ftrace.c +++ b/arch/x86/kernel/ftrace.c | |||
@@ -488,20 +488,21 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr) | |||
488 | * ignore such a protection. | 488 | * ignore such a protection. |
489 | */ | 489 | */ |
490 | asm volatile( | 490 | asm volatile( |
491 | "1: " _ASM_MOV " (%[parent_old]), %[old]\n" | 491 | "1: " _ASM_MOV " (%[parent]), %[old]\n" |
492 | "2: " _ASM_MOV " %[return_hooker], (%[parent_replaced])\n" | 492 | "2: " _ASM_MOV " %[return_hooker], (%[parent])\n" |
493 | " movl $0, %[faulted]\n" | 493 | " movl $0, %[faulted]\n" |
494 | "3:\n" | ||
494 | 495 | ||
495 | ".section .fixup, \"ax\"\n" | 496 | ".section .fixup, \"ax\"\n" |
496 | "3: movl $1, %[faulted]\n" | 497 | "4: movl $1, %[faulted]\n" |
498 | " jmp 3b\n" | ||
497 | ".previous\n" | 499 | ".previous\n" |
498 | 500 | ||
499 | _ASM_EXTABLE(1b, 3b) | 501 | _ASM_EXTABLE(1b, 4b) |
500 | _ASM_EXTABLE(2b, 3b) | 502 | _ASM_EXTABLE(2b, 4b) |
501 | 503 | ||
502 | : [parent_replaced] "=r" (parent), [old] "=r" (old), | 504 | : [old] "=r" (old), [faulted] "=r" (faulted) |
503 | [faulted] "=r" (faulted) | 505 | : [parent] "r" (parent), [return_hooker] "r" (return_hooker) |
504 | : [parent_old] "0" (parent), [return_hooker] "r" (return_hooker) | ||
505 | : "memory" | 506 | : "memory" |
506 | ); | 507 | ); |
507 | 508 | ||
diff --git a/arch/x86/kernel/hpet.c b/arch/x86/kernel/hpet.c index 64d5ad0b8add..388254f69a2a 100644 --- a/arch/x86/kernel/hpet.c +++ b/arch/x86/kernel/hpet.c | |||
@@ -897,7 +897,7 @@ static unsigned long hpet_rtc_flags; | |||
897 | static int hpet_prev_update_sec; | 897 | static int hpet_prev_update_sec; |
898 | static struct rtc_time hpet_alarm_time; | 898 | static struct rtc_time hpet_alarm_time; |
899 | static unsigned long hpet_pie_count; | 899 | static unsigned long hpet_pie_count; |
900 | static unsigned long hpet_t1_cmp; | 900 | static u32 hpet_t1_cmp; |
901 | static unsigned long hpet_default_delta; | 901 | static unsigned long hpet_default_delta; |
902 | static unsigned long hpet_pie_delta; | 902 | static unsigned long hpet_pie_delta; |
903 | static unsigned long hpet_pie_limit; | 903 | static unsigned long hpet_pie_limit; |
@@ -905,6 +905,14 @@ static unsigned long hpet_pie_limit; | |||
905 | static rtc_irq_handler irq_handler; | 905 | static rtc_irq_handler irq_handler; |
906 | 906 | ||
907 | /* | 907 | /* |
908 | * Check that the hpet counter c1 is ahead of the c2 | ||
909 | */ | ||
910 | static inline int hpet_cnt_ahead(u32 c1, u32 c2) | ||
911 | { | ||
912 | return (s32)(c2 - c1) < 0; | ||
913 | } | ||
914 | |||
915 | /* | ||
908 | * Registers a IRQ handler. | 916 | * Registers a IRQ handler. |
909 | */ | 917 | */ |
910 | int hpet_register_irq_handler(rtc_irq_handler handler) | 918 | int hpet_register_irq_handler(rtc_irq_handler handler) |
@@ -1075,7 +1083,7 @@ static void hpet_rtc_timer_reinit(void) | |||
1075 | hpet_t1_cmp += delta; | 1083 | hpet_t1_cmp += delta; |
1076 | hpet_writel(hpet_t1_cmp, HPET_T1_CMP); | 1084 | hpet_writel(hpet_t1_cmp, HPET_T1_CMP); |
1077 | lost_ints++; | 1085 | lost_ints++; |
1078 | } while ((long)(hpet_readl(HPET_COUNTER) - hpet_t1_cmp) > 0); | 1086 | } while (!hpet_cnt_ahead(hpet_t1_cmp, hpet_readl(HPET_COUNTER))); |
1079 | 1087 | ||
1080 | if (lost_ints) { | 1088 | if (lost_ints) { |
1081 | if (hpet_rtc_flags & RTC_PIE) | 1089 | if (hpet_rtc_flags & RTC_PIE) |
diff --git a/arch/x86/kernel/i8237.c b/arch/x86/kernel/i8237.c index dbd6c1d1b638..b42ca694dc68 100644 --- a/arch/x86/kernel/i8237.c +++ b/arch/x86/kernel/i8237.c | |||
@@ -28,10 +28,10 @@ static int i8237A_resume(struct sys_device *dev) | |||
28 | 28 | ||
29 | flags = claim_dma_lock(); | 29 | flags = claim_dma_lock(); |
30 | 30 | ||
31 | dma_outb(DMA1_RESET_REG, 0); | 31 | dma_outb(0, DMA1_RESET_REG); |
32 | dma_outb(DMA2_RESET_REG, 0); | 32 | dma_outb(0, DMA2_RESET_REG); |
33 | 33 | ||
34 | for (i = 0;i < 8;i++) { | 34 | for (i = 0; i < 8; i++) { |
35 | set_dma_addr(i, 0x000000); | 35 | set_dma_addr(i, 0x000000); |
36 | /* DMA count is a bit weird so this is not 0 */ | 36 | /* DMA count is a bit weird so this is not 0 */ |
37 | set_dma_count(i, 1); | 37 | set_dma_count(i, 1); |
@@ -51,14 +51,14 @@ static int i8237A_suspend(struct sys_device *dev, pm_message_t state) | |||
51 | } | 51 | } |
52 | 52 | ||
53 | static struct sysdev_class i8237_sysdev_class = { | 53 | static struct sysdev_class i8237_sysdev_class = { |
54 | .name = "i8237", | 54 | .name = "i8237", |
55 | .suspend = i8237A_suspend, | 55 | .suspend = i8237A_suspend, |
56 | .resume = i8237A_resume, | 56 | .resume = i8237A_resume, |
57 | }; | 57 | }; |
58 | 58 | ||
59 | static struct sys_device device_i8237A = { | 59 | static struct sys_device device_i8237A = { |
60 | .id = 0, | 60 | .id = 0, |
61 | .cls = &i8237_sysdev_class, | 61 | .cls = &i8237_sysdev_class, |
62 | }; | 62 | }; |
63 | 63 | ||
64 | static int __init i8237A_init_sysfs(void) | 64 | static int __init i8237A_init_sysfs(void) |
@@ -68,5 +68,4 @@ static int __init i8237A_init_sysfs(void) | |||
68 | error = sysdev_register(&device_i8237A); | 68 | error = sysdev_register(&device_i8237A); |
69 | return error; | 69 | return error; |
70 | } | 70 | } |
71 | |||
72 | device_initcall(i8237A_init_sysfs); | 71 | device_initcall(i8237A_init_sysfs); |
diff --git a/arch/x86/kernel/io_apic.c b/arch/x86/kernel/io_apic.c index 1c4a1302536c..bc7ac4da90d7 100644 --- a/arch/x86/kernel/io_apic.c +++ b/arch/x86/kernel/io_apic.c | |||
@@ -2528,14 +2528,15 @@ static void irq_complete_move(struct irq_desc **descp) | |||
2528 | 2528 | ||
2529 | vector = ~get_irq_regs()->orig_ax; | 2529 | vector = ~get_irq_regs()->orig_ax; |
2530 | me = smp_processor_id(); | 2530 | me = smp_processor_id(); |
2531 | |||
2532 | if (vector == cfg->vector && cpumask_test_cpu(me, cfg->domain)) { | ||
2531 | #ifdef CONFIG_NUMA_MIGRATE_IRQ_DESC | 2533 | #ifdef CONFIG_NUMA_MIGRATE_IRQ_DESC |
2532 | *descp = desc = move_irq_desc(desc, me); | 2534 | *descp = desc = move_irq_desc(desc, me); |
2533 | /* get the new one */ | 2535 | /* get the new one */ |
2534 | cfg = desc->chip_data; | 2536 | cfg = desc->chip_data; |
2535 | #endif | 2537 | #endif |
2536 | |||
2537 | if (vector == cfg->vector && cpumask_test_cpu(me, cfg->domain)) | ||
2538 | send_cleanup_vector(cfg); | 2538 | send_cleanup_vector(cfg); |
2539 | } | ||
2539 | } | 2540 | } |
2540 | #else | 2541 | #else |
2541 | static inline void irq_complete_move(struct irq_desc **descp) {} | 2542 | static inline void irq_complete_move(struct irq_desc **descp) {} |
@@ -3840,14 +3841,24 @@ int __init io_apic_get_redir_entries (int ioapic) | |||
3840 | 3841 | ||
3841 | void __init probe_nr_irqs_gsi(void) | 3842 | void __init probe_nr_irqs_gsi(void) |
3842 | { | 3843 | { |
3843 | int idx; | ||
3844 | int nr = 0; | 3844 | int nr = 0; |
3845 | 3845 | ||
3846 | for (idx = 0; idx < nr_ioapics; idx++) | 3846 | nr = acpi_probe_gsi(); |
3847 | nr += io_apic_get_redir_entries(idx) + 1; | 3847 | if (nr > nr_irqs_gsi) { |
3848 | |||
3849 | if (nr > nr_irqs_gsi) | ||
3850 | nr_irqs_gsi = nr; | 3848 | nr_irqs_gsi = nr; |
3849 | } else { | ||
3850 | /* for acpi=off or acpi is not compiled in */ | ||
3851 | int idx; | ||
3852 | |||
3853 | nr = 0; | ||
3854 | for (idx = 0; idx < nr_ioapics; idx++) | ||
3855 | nr += io_apic_get_redir_entries(idx) + 1; | ||
3856 | |||
3857 | if (nr > nr_irqs_gsi) | ||
3858 | nr_irqs_gsi = nr; | ||
3859 | } | ||
3860 | |||
3861 | printk(KERN_DEBUG "nr_irqs_gsi: %d\n", nr_irqs_gsi); | ||
3851 | } | 3862 | } |
3852 | 3863 | ||
3853 | /* -------------------------------------------------------------------------- | 3864 | /* -------------------------------------------------------------------------- |
diff --git a/arch/x86/kernel/irqinit_32.c b/arch/x86/kernel/irqinit_32.c index 1507ad4e674d..10a09c2f1828 100644 --- a/arch/x86/kernel/irqinit_32.c +++ b/arch/x86/kernel/irqinit_32.c | |||
@@ -78,15 +78,6 @@ void __init init_ISA_irqs(void) | |||
78 | } | 78 | } |
79 | } | 79 | } |
80 | 80 | ||
81 | /* | ||
82 | * IRQ2 is cascade interrupt to second interrupt controller | ||
83 | */ | ||
84 | static struct irqaction irq2 = { | ||
85 | .handler = no_action, | ||
86 | .mask = CPU_MASK_NONE, | ||
87 | .name = "cascade", | ||
88 | }; | ||
89 | |||
90 | DEFINE_PER_CPU(vector_irq_t, vector_irq) = { | 81 | DEFINE_PER_CPU(vector_irq_t, vector_irq) = { |
91 | [0 ... IRQ0_VECTOR - 1] = -1, | 82 | [0 ... IRQ0_VECTOR - 1] = -1, |
92 | [IRQ0_VECTOR] = 0, | 83 | [IRQ0_VECTOR] = 0, |
@@ -178,9 +169,6 @@ void __init native_init_IRQ(void) | |||
178 | alloc_intr_gate(THERMAL_APIC_VECTOR, thermal_interrupt); | 169 | alloc_intr_gate(THERMAL_APIC_VECTOR, thermal_interrupt); |
179 | #endif | 170 | #endif |
180 | 171 | ||
181 | if (!acpi_ioapic) | ||
182 | setup_irq(2, &irq2); | ||
183 | |||
184 | /* setup after call gates are initialised (usually add in | 172 | /* setup after call gates are initialised (usually add in |
185 | * the architecture specific gates) | 173 | * the architecture specific gates) |
186 | */ | 174 | */ |
diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c index e68bb9e30864..6d12f7e37f8c 100644 --- a/arch/x86/kernel/process.c +++ b/arch/x86/kernel/process.c | |||
@@ -180,6 +180,9 @@ void mwait_idle_with_hints(unsigned long ax, unsigned long cx) | |||
180 | 180 | ||
181 | trace_power_start(&it, POWER_CSTATE, (ax>>4)+1); | 181 | trace_power_start(&it, POWER_CSTATE, (ax>>4)+1); |
182 | if (!need_resched()) { | 182 | if (!need_resched()) { |
183 | if (cpu_has(¤t_cpu_data, X86_FEATURE_CLFLUSH_MONITOR)) | ||
184 | clflush((void *)¤t_thread_info()->flags); | ||
185 | |||
183 | __monitor((void *)¤t_thread_info()->flags, 0, 0); | 186 | __monitor((void *)¤t_thread_info()->flags, 0, 0); |
184 | smp_mb(); | 187 | smp_mb(); |
185 | if (!need_resched()) | 188 | if (!need_resched()) |
@@ -194,6 +197,9 @@ static void mwait_idle(void) | |||
194 | struct power_trace it; | 197 | struct power_trace it; |
195 | if (!need_resched()) { | 198 | if (!need_resched()) { |
196 | trace_power_start(&it, POWER_CSTATE, 1); | 199 | trace_power_start(&it, POWER_CSTATE, 1); |
200 | if (cpu_has(¤t_cpu_data, X86_FEATURE_CLFLUSH_MONITOR)) | ||
201 | clflush((void *)¤t_thread_info()->flags); | ||
202 | |||
197 | __monitor((void *)¤t_thread_info()->flags, 0, 0); | 203 | __monitor((void *)¤t_thread_info()->flags, 0, 0); |
198 | smp_mb(); | 204 | smp_mb(); |
199 | if (!need_resched()) | 205 | if (!need_resched()) |
diff --git a/arch/x86/kernel/process_64.c b/arch/x86/kernel/process_64.c index 416fb9282f4f..85b4cb5c1980 100644 --- a/arch/x86/kernel/process_64.c +++ b/arch/x86/kernel/process_64.c | |||
@@ -40,6 +40,7 @@ | |||
40 | #include <linux/uaccess.h> | 40 | #include <linux/uaccess.h> |
41 | #include <linux/io.h> | 41 | #include <linux/io.h> |
42 | #include <linux/ftrace.h> | 42 | #include <linux/ftrace.h> |
43 | #include <linux/dmi.h> | ||
43 | 44 | ||
44 | #include <asm/pgtable.h> | 45 | #include <asm/pgtable.h> |
45 | #include <asm/system.h> | 46 | #include <asm/system.h> |
@@ -151,14 +152,18 @@ void __show_regs(struct pt_regs *regs, int all) | |||
151 | unsigned long d0, d1, d2, d3, d6, d7; | 152 | unsigned long d0, d1, d2, d3, d6, d7; |
152 | unsigned int fsindex, gsindex; | 153 | unsigned int fsindex, gsindex; |
153 | unsigned int ds, cs, es; | 154 | unsigned int ds, cs, es; |
155 | const char *board; | ||
154 | 156 | ||
155 | printk("\n"); | 157 | printk("\n"); |
156 | print_modules(); | 158 | print_modules(); |
157 | printk(KERN_INFO "Pid: %d, comm: %.20s %s %s %.*s\n", | 159 | board = dmi_get_system_info(DMI_PRODUCT_NAME); |
160 | if (!board) | ||
161 | board = ""; | ||
162 | printk(KERN_INFO "Pid: %d, comm: %.20s %s %s %.*s %s\n", | ||
158 | current->pid, current->comm, print_tainted(), | 163 | current->pid, current->comm, print_tainted(), |
159 | init_utsname()->release, | 164 | init_utsname()->release, |
160 | (int)strcspn(init_utsname()->version, " "), | 165 | (int)strcspn(init_utsname()->version, " "), |
161 | init_utsname()->version); | 166 | init_utsname()->version, board); |
162 | printk(KERN_INFO "RIP: %04lx:[<%016lx>] ", regs->cs & 0xffff, regs->ip); | 167 | printk(KERN_INFO "RIP: %04lx:[<%016lx>] ", regs->cs & 0xffff, regs->ip); |
163 | printk_address(regs->ip, 1); | 168 | printk_address(regs->ip, 1); |
164 | printk(KERN_INFO "RSP: %04lx:%016lx EFLAGS: %08lx\n", regs->ss, | 169 | printk(KERN_INFO "RSP: %04lx:%016lx EFLAGS: %08lx\n", regs->ss, |
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c index ae0d8042cf69..c461f6d69074 100644 --- a/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c | |||
@@ -607,7 +607,7 @@ struct x86_quirks *x86_quirks __initdata = &default_x86_quirks; | |||
607 | static int __init dmi_low_memory_corruption(const struct dmi_system_id *d) | 607 | static int __init dmi_low_memory_corruption(const struct dmi_system_id *d) |
608 | { | 608 | { |
609 | printk(KERN_NOTICE | 609 | printk(KERN_NOTICE |
610 | "%s detected: BIOS may corrupt low RAM, working it around.\n", | 610 | "%s detected: BIOS may corrupt low RAM, working around it.\n", |
611 | d->ident); | 611 | d->ident); |
612 | 612 | ||
613 | e820_update_range(0, 0x10000, E820_RAM, E820_RESERVED); | 613 | e820_update_range(0, 0x10000, E820_RAM, E820_RESERVED); |
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index 98c2d055284b..7932338d7cb3 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c | |||
@@ -896,7 +896,7 @@ asmlinkage void math_state_restore(void) | |||
896 | EXPORT_SYMBOL_GPL(math_state_restore); | 896 | EXPORT_SYMBOL_GPL(math_state_restore); |
897 | 897 | ||
898 | #ifndef CONFIG_MATH_EMULATION | 898 | #ifndef CONFIG_MATH_EMULATION |
899 | asmlinkage void math_emulate(long arg) | 899 | void math_emulate(struct math_emu_info *info) |
900 | { | 900 | { |
901 | printk(KERN_EMERG | 901 | printk(KERN_EMERG |
902 | "math-emulation not enabled and no coprocessor found.\n"); | 902 | "math-emulation not enabled and no coprocessor found.\n"); |
@@ -906,16 +906,19 @@ asmlinkage void math_emulate(long arg) | |||
906 | } | 906 | } |
907 | #endif /* CONFIG_MATH_EMULATION */ | 907 | #endif /* CONFIG_MATH_EMULATION */ |
908 | 908 | ||
909 | dotraplinkage void __kprobes | 909 | dotraplinkage void __kprobes do_device_not_available(struct pt_regs regs) |
910 | do_device_not_available(struct pt_regs *regs, long error) | ||
911 | { | 910 | { |
912 | #ifdef CONFIG_X86_32 | 911 | #ifdef CONFIG_X86_32 |
913 | if (read_cr0() & X86_CR0_EM) { | 912 | if (read_cr0() & X86_CR0_EM) { |
914 | conditional_sti(regs); | 913 | struct math_emu_info info = { }; |
915 | math_emulate(0); | 914 | |
915 | conditional_sti(®s); | ||
916 | |||
917 | info.regs = ®s; | ||
918 | math_emulate(&info); | ||
916 | } else { | 919 | } else { |
917 | math_state_restore(); /* interrupts still off */ | 920 | math_state_restore(); /* interrupts still off */ |
918 | conditional_sti(regs); | 921 | conditional_sti(®s); |
919 | } | 922 | } |
920 | #else | 923 | #else |
921 | math_state_restore(); | 924 | math_state_restore(); |
diff --git a/arch/x86/kernel/vmi_32.c b/arch/x86/kernel/vmi_32.c index 1d3302cc2ddf..bef58b4982db 100644 --- a/arch/x86/kernel/vmi_32.c +++ b/arch/x86/kernel/vmi_32.c | |||
@@ -321,6 +321,16 @@ static void vmi_release_pmd(unsigned long pfn) | |||
321 | } | 321 | } |
322 | 322 | ||
323 | /* | 323 | /* |
324 | * We use the pgd_free hook for releasing the pgd page: | ||
325 | */ | ||
326 | static void vmi_pgd_free(struct mm_struct *mm, pgd_t *pgd) | ||
327 | { | ||
328 | unsigned long pfn = __pa(pgd) >> PAGE_SHIFT; | ||
329 | |||
330 | vmi_ops.release_page(pfn, VMI_PAGE_L2); | ||
331 | } | ||
332 | |||
333 | /* | ||
324 | * Helper macros for MMU update flags. We can defer updates until a flush | 334 | * Helper macros for MMU update flags. We can defer updates until a flush |
325 | * or page invalidation only if the update is to the current address space | 335 | * or page invalidation only if the update is to the current address space |
326 | * (otherwise, there is no flush). We must check against init_mm, since | 336 | * (otherwise, there is no flush). We must check against init_mm, since |
@@ -762,6 +772,7 @@ static inline int __init activate_vmi(void) | |||
762 | if (vmi_ops.release_page) { | 772 | if (vmi_ops.release_page) { |
763 | pv_mmu_ops.release_pte = vmi_release_pte; | 773 | pv_mmu_ops.release_pte = vmi_release_pte; |
764 | pv_mmu_ops.release_pmd = vmi_release_pmd; | 774 | pv_mmu_ops.release_pmd = vmi_release_pmd; |
775 | pv_mmu_ops.pgd_free = vmi_pgd_free; | ||
765 | } | 776 | } |
766 | 777 | ||
767 | /* Set linear is needed in all cases */ | 778 | /* Set linear is needed in all cases */ |
diff --git a/arch/x86/mach-default/setup.c b/arch/x86/mach-default/setup.c index df167f265622..a265a7c63190 100644 --- a/arch/x86/mach-default/setup.c +++ b/arch/x86/mach-default/setup.c | |||
@@ -38,6 +38,15 @@ void __init pre_intr_init_hook(void) | |||
38 | init_ISA_irqs(); | 38 | init_ISA_irqs(); |
39 | } | 39 | } |
40 | 40 | ||
41 | /* | ||
42 | * IRQ2 is cascade interrupt to second interrupt controller | ||
43 | */ | ||
44 | static struct irqaction irq2 = { | ||
45 | .handler = no_action, | ||
46 | .mask = CPU_MASK_NONE, | ||
47 | .name = "cascade", | ||
48 | }; | ||
49 | |||
41 | /** | 50 | /** |
42 | * intr_init_hook - post gate setup interrupt initialisation | 51 | * intr_init_hook - post gate setup interrupt initialisation |
43 | * | 52 | * |
@@ -53,6 +62,9 @@ void __init intr_init_hook(void) | |||
53 | if (x86_quirks->arch_intr_init()) | 62 | if (x86_quirks->arch_intr_init()) |
54 | return; | 63 | return; |
55 | } | 64 | } |
65 | if (!acpi_ioapic) | ||
66 | setup_irq(2, &irq2); | ||
67 | |||
56 | } | 68 | } |
57 | 69 | ||
58 | /** | 70 | /** |
diff --git a/arch/x86/mach-voyager/setup.c b/arch/x86/mach-voyager/setup.c index a580b9562e76..d914a7996a66 100644 --- a/arch/x86/mach-voyager/setup.c +++ b/arch/x86/mach-voyager/setup.c | |||
@@ -33,13 +33,23 @@ void __init intr_init_hook(void) | |||
33 | setup_irq(2, &irq2); | 33 | setup_irq(2, &irq2); |
34 | } | 34 | } |
35 | 35 | ||
36 | void __init pre_setup_arch_hook(void) | 36 | static void voyager_disable_tsc(void) |
37 | { | 37 | { |
38 | /* Voyagers run their CPUs from independent clocks, so disable | 38 | /* Voyagers run their CPUs from independent clocks, so disable |
39 | * the TSC code because we can't sync them */ | 39 | * the TSC code because we can't sync them */ |
40 | setup_clear_cpu_cap(X86_FEATURE_TSC); | 40 | setup_clear_cpu_cap(X86_FEATURE_TSC); |
41 | } | 41 | } |
42 | 42 | ||
43 | void __init pre_setup_arch_hook(void) | ||
44 | { | ||
45 | voyager_disable_tsc(); | ||
46 | } | ||
47 | |||
48 | void __init pre_time_init_hook(void) | ||
49 | { | ||
50 | voyager_disable_tsc(); | ||
51 | } | ||
52 | |||
43 | void __init trap_init_hook(void) | 53 | void __init trap_init_hook(void) |
44 | { | 54 | { |
45 | } | 55 | } |
diff --git a/arch/x86/mach-voyager/voyager_smp.c b/arch/x86/mach-voyager/voyager_smp.c index 9840b7ec749a..7ffcdeec4631 100644 --- a/arch/x86/mach-voyager/voyager_smp.c +++ b/arch/x86/mach-voyager/voyager_smp.c | |||
@@ -81,7 +81,7 @@ static void enable_local_vic_irq(unsigned int irq); | |||
81 | static void disable_local_vic_irq(unsigned int irq); | 81 | static void disable_local_vic_irq(unsigned int irq); |
82 | static void before_handle_vic_irq(unsigned int irq); | 82 | static void before_handle_vic_irq(unsigned int irq); |
83 | static void after_handle_vic_irq(unsigned int irq); | 83 | static void after_handle_vic_irq(unsigned int irq); |
84 | static void set_vic_irq_affinity(unsigned int irq, cpumask_t mask); | 84 | static void set_vic_irq_affinity(unsigned int irq, const struct cpumask *mask); |
85 | static void ack_vic_irq(unsigned int irq); | 85 | static void ack_vic_irq(unsigned int irq); |
86 | static void vic_enable_cpi(void); | 86 | static void vic_enable_cpi(void); |
87 | static void do_boot_cpu(__u8 cpuid); | 87 | static void do_boot_cpu(__u8 cpuid); |
@@ -211,8 +211,6 @@ static __u32 cpu_booted_map; | |||
211 | static cpumask_t smp_commenced_mask = CPU_MASK_NONE; | 211 | static cpumask_t smp_commenced_mask = CPU_MASK_NONE; |
212 | 212 | ||
213 | /* This is for the new dynamic CPU boot code */ | 213 | /* This is for the new dynamic CPU boot code */ |
214 | cpumask_t cpu_callin_map = CPU_MASK_NONE; | ||
215 | cpumask_t cpu_callout_map = CPU_MASK_NONE; | ||
216 | 214 | ||
217 | /* The per processor IRQ masks (these are usually kept in sync) */ | 215 | /* The per processor IRQ masks (these are usually kept in sync) */ |
218 | static __u16 vic_irq_mask[NR_CPUS] __cacheline_aligned; | 216 | static __u16 vic_irq_mask[NR_CPUS] __cacheline_aligned; |
@@ -378,7 +376,7 @@ void __init find_smp_config(void) | |||
378 | cpus_addr(phys_cpu_present_map)[0] |= | 376 | cpus_addr(phys_cpu_present_map)[0] |= |
379 | voyager_extended_cmos_read(VOYAGER_PROCESSOR_PRESENT_MASK + | 377 | voyager_extended_cmos_read(VOYAGER_PROCESSOR_PRESENT_MASK + |
380 | 3) << 24; | 378 | 3) << 24; |
381 | cpu_possible_map = phys_cpu_present_map; | 379 | init_cpu_possible(&phys_cpu_present_map); |
382 | printk("VOYAGER SMP: phys_cpu_present_map = 0x%lx\n", | 380 | printk("VOYAGER SMP: phys_cpu_present_map = 0x%lx\n", |
383 | cpus_addr(phys_cpu_present_map)[0]); | 381 | cpus_addr(phys_cpu_present_map)[0]); |
384 | /* Here we set up the VIC to enable SMP */ | 382 | /* Here we set up the VIC to enable SMP */ |
@@ -1599,16 +1597,16 @@ static void after_handle_vic_irq(unsigned int irq) | |||
1599 | * change the mask and then do an interrupt enable CPI to re-enable on | 1597 | * change the mask and then do an interrupt enable CPI to re-enable on |
1600 | * the selected processors */ | 1598 | * the selected processors */ |
1601 | 1599 | ||
1602 | void set_vic_irq_affinity(unsigned int irq, cpumask_t mask) | 1600 | void set_vic_irq_affinity(unsigned int irq, const struct cpumask *mask) |
1603 | { | 1601 | { |
1604 | /* Only extended processors handle interrupts */ | 1602 | /* Only extended processors handle interrupts */ |
1605 | unsigned long real_mask; | 1603 | unsigned long real_mask; |
1606 | unsigned long irq_mask = 1 << irq; | 1604 | unsigned long irq_mask = 1 << irq; |
1607 | int cpu; | 1605 | int cpu; |
1608 | 1606 | ||
1609 | real_mask = cpus_addr(mask)[0] & voyager_extended_vic_processors; | 1607 | real_mask = cpus_addr(*mask)[0] & voyager_extended_vic_processors; |
1610 | 1608 | ||
1611 | if (cpus_addr(mask)[0] == 0) | 1609 | if (cpus_addr(*mask)[0] == 0) |
1612 | /* can't have no CPUs to accept the interrupt -- extremely | 1610 | /* can't have no CPUs to accept the interrupt -- extremely |
1613 | * bad things will happen */ | 1611 | * bad things will happen */ |
1614 | return; | 1612 | return; |
@@ -1750,10 +1748,11 @@ static void __cpuinit voyager_smp_prepare_boot_cpu(void) | |||
1750 | init_gdt(smp_processor_id()); | 1748 | init_gdt(smp_processor_id()); |
1751 | switch_to_new_gdt(); | 1749 | switch_to_new_gdt(); |
1752 | 1750 | ||
1753 | cpu_set(smp_processor_id(), cpu_online_map); | 1751 | cpu_online_map = cpumask_of_cpu(smp_processor_id()); |
1754 | cpu_set(smp_processor_id(), cpu_callout_map); | 1752 | cpu_callout_map = cpumask_of_cpu(smp_processor_id()); |
1755 | cpu_set(smp_processor_id(), cpu_possible_map); | 1753 | cpu_callin_map = CPU_MASK_NONE; |
1756 | cpu_set(smp_processor_id(), cpu_present_map); | 1754 | cpu_present_map = cpumask_of_cpu(smp_processor_id()); |
1755 | |||
1757 | } | 1756 | } |
1758 | 1757 | ||
1759 | static int __cpuinit voyager_cpu_up(unsigned int cpu) | 1758 | static int __cpuinit voyager_cpu_up(unsigned int cpu) |
@@ -1783,9 +1782,9 @@ void __init smp_setup_processor_id(void) | |||
1783 | x86_write_percpu(cpu_number, hard_smp_processor_id()); | 1782 | x86_write_percpu(cpu_number, hard_smp_processor_id()); |
1784 | } | 1783 | } |
1785 | 1784 | ||
1786 | static void voyager_send_call_func(cpumask_t callmask) | 1785 | static void voyager_send_call_func(const struct cpumask *callmask) |
1787 | { | 1786 | { |
1788 | __u32 mask = cpus_addr(callmask)[0] & ~(1 << smp_processor_id()); | 1787 | __u32 mask = cpus_addr(*callmask)[0] & ~(1 << smp_processor_id()); |
1789 | send_CPI(mask, VIC_CALL_FUNCTION_CPI); | 1788 | send_CPI(mask, VIC_CALL_FUNCTION_CPI); |
1790 | } | 1789 | } |
1791 | 1790 | ||
diff --git a/arch/x86/math-emu/fpu_entry.c b/arch/x86/math-emu/fpu_entry.c index c7b06feb139b..5d87f586f8d7 100644 --- a/arch/x86/math-emu/fpu_entry.c +++ b/arch/x86/math-emu/fpu_entry.c | |||
@@ -131,7 +131,7 @@ u_char emulating = 0; | |||
131 | static int valid_prefix(u_char *Byte, u_char __user ** fpu_eip, | 131 | static int valid_prefix(u_char *Byte, u_char __user ** fpu_eip, |
132 | overrides * override); | 132 | overrides * override); |
133 | 133 | ||
134 | asmlinkage void math_emulate(long arg) | 134 | void math_emulate(struct math_emu_info *info) |
135 | { | 135 | { |
136 | u_char FPU_modrm, byte1; | 136 | u_char FPU_modrm, byte1; |
137 | unsigned short code; | 137 | unsigned short code; |
@@ -161,7 +161,7 @@ asmlinkage void math_emulate(long arg) | |||
161 | RE_ENTRANT_CHECK_ON; | 161 | RE_ENTRANT_CHECK_ON; |
162 | #endif /* RE_ENTRANT_CHECKING */ | 162 | #endif /* RE_ENTRANT_CHECKING */ |
163 | 163 | ||
164 | SETUP_DATA_AREA(arg); | 164 | FPU_info = info; |
165 | 165 | ||
166 | FPU_ORIG_EIP = FPU_EIP; | 166 | FPU_ORIG_EIP = FPU_EIP; |
167 | 167 | ||
@@ -659,7 +659,7 @@ static int valid_prefix(u_char *Byte, u_char __user **fpu_eip, | |||
659 | } | 659 | } |
660 | } | 660 | } |
661 | 661 | ||
662 | void math_abort(struct info *info, unsigned int signal) | 662 | void math_abort(struct math_emu_info *info, unsigned int signal) |
663 | { | 663 | { |
664 | FPU_EIP = FPU_ORIG_EIP; | 664 | FPU_EIP = FPU_ORIG_EIP; |
665 | current->thread.trap_no = 16; | 665 | current->thread.trap_no = 16; |
diff --git a/arch/x86/math-emu/fpu_proto.h b/arch/x86/math-emu/fpu_proto.h index aa49b6a0d850..9779df436b7d 100644 --- a/arch/x86/math-emu/fpu_proto.h +++ b/arch/x86/math-emu/fpu_proto.h | |||
@@ -51,8 +51,8 @@ extern void ffreep(void); | |||
51 | extern void fst_i_(void); | 51 | extern void fst_i_(void); |
52 | extern void fstp_i(void); | 52 | extern void fstp_i(void); |
53 | /* fpu_entry.c */ | 53 | /* fpu_entry.c */ |
54 | asmlinkage extern void math_emulate(long arg); | 54 | extern void math_emulate(struct math_emu_info *info); |
55 | extern void math_abort(struct info *info, unsigned int signal); | 55 | extern void math_abort(struct math_emu_info *info, unsigned int signal); |
56 | /* fpu_etc.c */ | 56 | /* fpu_etc.c */ |
57 | extern void FPU_etc(void); | 57 | extern void FPU_etc(void); |
58 | /* fpu_tags.c */ | 58 | /* fpu_tags.c */ |
diff --git a/arch/x86/math-emu/fpu_system.h b/arch/x86/math-emu/fpu_system.h index 13488fa153e0..50fa0ec2c8a5 100644 --- a/arch/x86/math-emu/fpu_system.h +++ b/arch/x86/math-emu/fpu_system.h | |||
@@ -16,10 +16,6 @@ | |||
16 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
17 | #include <linux/mm.h> | 17 | #include <linux/mm.h> |
18 | 18 | ||
19 | /* This sets the pointer FPU_info to point to the argument part | ||
20 | of the stack frame of math_emulate() */ | ||
21 | #define SETUP_DATA_AREA(arg) FPU_info = (struct info *) &arg | ||
22 | |||
23 | /* s is always from a cpu register, and the cpu does bounds checking | 19 | /* s is always from a cpu register, and the cpu does bounds checking |
24 | * during register load --> no further bounds checks needed */ | 20 | * during register load --> no further bounds checks needed */ |
25 | #define LDT_DESCRIPTOR(s) (((struct desc_struct *)current->mm->context.ldt)[(s) >> 3]) | 21 | #define LDT_DESCRIPTOR(s) (((struct desc_struct *)current->mm->context.ldt)[(s) >> 3]) |
@@ -38,12 +34,12 @@ | |||
38 | #define I387 (current->thread.xstate) | 34 | #define I387 (current->thread.xstate) |
39 | #define FPU_info (I387->soft.info) | 35 | #define FPU_info (I387->soft.info) |
40 | 36 | ||
41 | #define FPU_CS (*(unsigned short *) &(FPU_info->___cs)) | 37 | #define FPU_CS (*(unsigned short *) &(FPU_info->regs->cs)) |
42 | #define FPU_SS (*(unsigned short *) &(FPU_info->___ss)) | 38 | #define FPU_SS (*(unsigned short *) &(FPU_info->regs->ss)) |
43 | #define FPU_DS (*(unsigned short *) &(FPU_info->___ds)) | 39 | #define FPU_DS (*(unsigned short *) &(FPU_info->regs->ds)) |
44 | #define FPU_EAX (FPU_info->___eax) | 40 | #define FPU_EAX (FPU_info->regs->ax) |
45 | #define FPU_EFLAGS (FPU_info->___eflags) | 41 | #define FPU_EFLAGS (FPU_info->regs->flags) |
46 | #define FPU_EIP (FPU_info->___eip) | 42 | #define FPU_EIP (FPU_info->regs->ip) |
47 | #define FPU_ORIG_EIP (FPU_info->___orig_eip) | 43 | #define FPU_ORIG_EIP (FPU_info->___orig_eip) |
48 | 44 | ||
49 | #define FPU_lookahead (I387->soft.lookahead) | 45 | #define FPU_lookahead (I387->soft.lookahead) |
diff --git a/arch/x86/math-emu/get_address.c b/arch/x86/math-emu/get_address.c index d701e2b39e44..420b3b6e3915 100644 --- a/arch/x86/math-emu/get_address.c +++ b/arch/x86/math-emu/get_address.c | |||
@@ -29,46 +29,43 @@ | |||
29 | #define FPU_WRITE_BIT 0x10 | 29 | #define FPU_WRITE_BIT 0x10 |
30 | 30 | ||
31 | static int reg_offset[] = { | 31 | static int reg_offset[] = { |
32 | offsetof(struct info, ___eax), | 32 | offsetof(struct pt_regs, ax), |
33 | offsetof(struct info, ___ecx), | 33 | offsetof(struct pt_regs, cx), |
34 | offsetof(struct info, ___edx), | 34 | offsetof(struct pt_regs, dx), |
35 | offsetof(struct info, ___ebx), | 35 | offsetof(struct pt_regs, bx), |
36 | offsetof(struct info, ___esp), | 36 | offsetof(struct pt_regs, sp), |
37 | offsetof(struct info, ___ebp), | 37 | offsetof(struct pt_regs, bp), |
38 | offsetof(struct info, ___esi), | 38 | offsetof(struct pt_regs, si), |
39 | offsetof(struct info, ___edi) | 39 | offsetof(struct pt_regs, di) |
40 | }; | 40 | }; |
41 | 41 | ||
42 | #define REG_(x) (*(long *)(reg_offset[(x)]+(u_char *) FPU_info)) | 42 | #define REG_(x) (*(long *)(reg_offset[(x)] + (u_char *)FPU_info->regs)) |
43 | 43 | ||
44 | static int reg_offset_vm86[] = { | 44 | static int reg_offset_vm86[] = { |
45 | offsetof(struct info, ___cs), | 45 | offsetof(struct pt_regs, cs), |
46 | offsetof(struct info, ___vm86_ds), | 46 | offsetof(struct kernel_vm86_regs, ds), |
47 | offsetof(struct info, ___vm86_es), | 47 | offsetof(struct kernel_vm86_regs, es), |
48 | offsetof(struct info, ___vm86_fs), | 48 | offsetof(struct kernel_vm86_regs, fs), |
49 | offsetof(struct info, ___vm86_gs), | 49 | offsetof(struct kernel_vm86_regs, gs), |
50 | offsetof(struct info, ___ss), | 50 | offsetof(struct pt_regs, ss), |
51 | offsetof(struct info, ___vm86_ds) | 51 | offsetof(struct kernel_vm86_regs, ds) |
52 | }; | 52 | }; |
53 | 53 | ||
54 | #define VM86_REG_(x) (*(unsigned short *) \ | 54 | #define VM86_REG_(x) (*(unsigned short *) \ |
55 | (reg_offset_vm86[((unsigned)x)]+(u_char *) FPU_info)) | 55 | (reg_offset_vm86[((unsigned)x)] + (u_char *)FPU_info->regs)) |
56 | |||
57 | /* This dummy, gs is not saved on the stack. */ | ||
58 | #define ___GS ___ds | ||
59 | 56 | ||
60 | static int reg_offset_pm[] = { | 57 | static int reg_offset_pm[] = { |
61 | offsetof(struct info, ___cs), | 58 | offsetof(struct pt_regs, cs), |
62 | offsetof(struct info, ___ds), | 59 | offsetof(struct pt_regs, ds), |
63 | offsetof(struct info, ___es), | 60 | offsetof(struct pt_regs, es), |
64 | offsetof(struct info, ___fs), | 61 | offsetof(struct pt_regs, fs), |
65 | offsetof(struct info, ___GS), | 62 | offsetof(struct pt_regs, ds), /* dummy, not saved on stack */ |
66 | offsetof(struct info, ___ss), | 63 | offsetof(struct pt_regs, ss), |
67 | offsetof(struct info, ___ds) | 64 | offsetof(struct pt_regs, ds) |
68 | }; | 65 | }; |
69 | 66 | ||
70 | #define PM_REG_(x) (*(unsigned short *) \ | 67 | #define PM_REG_(x) (*(unsigned short *) \ |
71 | (reg_offset_pm[((unsigned)x)]+(u_char *) FPU_info)) | 68 | (reg_offset_pm[((unsigned)x)] + (u_char *)FPU_info->regs)) |
72 | 69 | ||
73 | /* Decode the SIB byte. This function assumes mod != 0 */ | 70 | /* Decode the SIB byte. This function assumes mod != 0 */ |
74 | static int sib(int mod, unsigned long *fpu_eip) | 71 | static int sib(int mod, unsigned long *fpu_eip) |
@@ -349,34 +346,34 @@ void __user *FPU_get_address_16(u_char FPU_modrm, unsigned long *fpu_eip, | |||
349 | } | 346 | } |
350 | switch (rm) { | 347 | switch (rm) { |
351 | case 0: | 348 | case 0: |
352 | address += FPU_info->___ebx + FPU_info->___esi; | 349 | address += FPU_info->regs->bx + FPU_info->regs->si; |
353 | break; | 350 | break; |
354 | case 1: | 351 | case 1: |
355 | address += FPU_info->___ebx + FPU_info->___edi; | 352 | address += FPU_info->regs->bx + FPU_info->regs->di; |
356 | break; | 353 | break; |
357 | case 2: | 354 | case 2: |
358 | address += FPU_info->___ebp + FPU_info->___esi; | 355 | address += FPU_info->regs->bp + FPU_info->regs->si; |
359 | if (addr_modes.override.segment == PREFIX_DEFAULT) | 356 | if (addr_modes.override.segment == PREFIX_DEFAULT) |
360 | addr_modes.override.segment = PREFIX_SS_; | 357 | addr_modes.override.segment = PREFIX_SS_; |
361 | break; | 358 | break; |
362 | case 3: | 359 | case 3: |
363 | address += FPU_info->___ebp + FPU_info->___edi; | 360 | address += FPU_info->regs->bp + FPU_info->regs->di; |
364 | if (addr_modes.override.segment == PREFIX_DEFAULT) | 361 | if (addr_modes.override.segment == PREFIX_DEFAULT) |
365 | addr_modes.override.segment = PREFIX_SS_; | 362 | addr_modes.override.segment = PREFIX_SS_; |
366 | break; | 363 | break; |
367 | case 4: | 364 | case 4: |
368 | address += FPU_info->___esi; | 365 | address += FPU_info->regs->si; |
369 | break; | 366 | break; |
370 | case 5: | 367 | case 5: |
371 | address += FPU_info->___edi; | 368 | address += FPU_info->regs->di; |
372 | break; | 369 | break; |
373 | case 6: | 370 | case 6: |
374 | address += FPU_info->___ebp; | 371 | address += FPU_info->regs->bp; |
375 | if (addr_modes.override.segment == PREFIX_DEFAULT) | 372 | if (addr_modes.override.segment == PREFIX_DEFAULT) |
376 | addr_modes.override.segment = PREFIX_SS_; | 373 | addr_modes.override.segment = PREFIX_SS_; |
377 | break; | 374 | break; |
378 | case 7: | 375 | case 7: |
379 | address += FPU_info->___ebx; | 376 | address += FPU_info->regs->bx; |
380 | break; | 377 | break; |
381 | } | 378 | } |
382 | 379 | ||
diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c index 90dfae511a41..c76ef1d701c9 100644 --- a/arch/x86/mm/fault.c +++ b/arch/x86/mm/fault.c | |||
@@ -603,8 +603,6 @@ void __kprobes do_page_fault(struct pt_regs *regs, unsigned long error_code) | |||
603 | 603 | ||
604 | si_code = SEGV_MAPERR; | 604 | si_code = SEGV_MAPERR; |
605 | 605 | ||
606 | if (notify_page_fault(regs)) | ||
607 | return; | ||
608 | if (unlikely(kmmio_fault(regs, address))) | 606 | if (unlikely(kmmio_fault(regs, address))) |
609 | return; | 607 | return; |
610 | 608 | ||
@@ -634,6 +632,9 @@ void __kprobes do_page_fault(struct pt_regs *regs, unsigned long error_code) | |||
634 | if (spurious_fault(address, error_code)) | 632 | if (spurious_fault(address, error_code)) |
635 | return; | 633 | return; |
636 | 634 | ||
635 | /* kprobes don't want to hook the spurious faults. */ | ||
636 | if (notify_page_fault(regs)) | ||
637 | return; | ||
637 | /* | 638 | /* |
638 | * Don't take the mm semaphore here. If we fixup a prefetch | 639 | * Don't take the mm semaphore here. If we fixup a prefetch |
639 | * fault we could otherwise deadlock. | 640 | * fault we could otherwise deadlock. |
@@ -641,6 +642,9 @@ void __kprobes do_page_fault(struct pt_regs *regs, unsigned long error_code) | |||
641 | goto bad_area_nosemaphore; | 642 | goto bad_area_nosemaphore; |
642 | } | 643 | } |
643 | 644 | ||
645 | /* kprobes don't want to hook the spurious faults. */ | ||
646 | if (notify_page_fault(regs)) | ||
647 | return; | ||
644 | 648 | ||
645 | /* | 649 | /* |
646 | * It's safe to allow irq's after cr2 has been saved and the | 650 | * It's safe to allow irq's after cr2 has been saved and the |
diff --git a/arch/x86/xen/multicalls.h b/arch/x86/xen/multicalls.h index 858938241616..fa3e10725d98 100644 --- a/arch/x86/xen/multicalls.h +++ b/arch/x86/xen/multicalls.h | |||
@@ -19,8 +19,10 @@ DECLARE_PER_CPU(unsigned long, xen_mc_irq_flags); | |||
19 | paired with xen_mc_issue() */ | 19 | paired with xen_mc_issue() */ |
20 | static inline void xen_mc_batch(void) | 20 | static inline void xen_mc_batch(void) |
21 | { | 21 | { |
22 | unsigned long flags; | ||
22 | /* need to disable interrupts until this entry is complete */ | 23 | /* need to disable interrupts until this entry is complete */ |
23 | local_irq_save(__get_cpu_var(xen_mc_irq_flags)); | 24 | local_irq_save(flags); |
25 | __get_cpu_var(xen_mc_irq_flags) = flags; | ||
24 | } | 26 | } |
25 | 27 | ||
26 | static inline struct multicall_space xen_mc_entry(size_t args) | 28 | static inline struct multicall_space xen_mc_entry(size_t args) |