diff options
Diffstat (limited to 'arch')
31 files changed, 128 insertions, 103 deletions
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c index d766e4256b74..4044abcf6f9d 100644 --- a/arch/arm/mm/dma-mapping.c +++ b/arch/arm/mm/dma-mapping.c | |||
@@ -1067,7 +1067,7 @@ static struct page **__iommu_alloc_buffer(struct device *dev, size_t size, gfp_t | |||
1067 | return NULL; | 1067 | return NULL; |
1068 | 1068 | ||
1069 | while (count) { | 1069 | while (count) { |
1070 | int j, order = __ffs(count); | 1070 | int j, order = __fls(count); |
1071 | 1071 | ||
1072 | pages[i] = alloc_pages(gfp | __GFP_NOWARN, order); | 1072 | pages[i] = alloc_pages(gfp | __GFP_NOWARN, order); |
1073 | while (!pages[i] && order) | 1073 | while (!pages[i] && order) |
diff --git a/arch/arm/plat-mxc/include/mach/mx2_cam.h b/arch/arm/plat-mxc/include/mach/mx2_cam.h index 7ded6f1f74bc..3c080a32dbf5 100644 --- a/arch/arm/plat-mxc/include/mach/mx2_cam.h +++ b/arch/arm/plat-mxc/include/mach/mx2_cam.h | |||
@@ -23,6 +23,7 @@ | |||
23 | #ifndef __MACH_MX2_CAM_H_ | 23 | #ifndef __MACH_MX2_CAM_H_ |
24 | #define __MACH_MX2_CAM_H_ | 24 | #define __MACH_MX2_CAM_H_ |
25 | 25 | ||
26 | #define MX2_CAMERA_SWAP16 (1 << 0) | ||
26 | #define MX2_CAMERA_EXT_VSYNC (1 << 1) | 27 | #define MX2_CAMERA_EXT_VSYNC (1 << 1) |
27 | #define MX2_CAMERA_CCIR (1 << 2) | 28 | #define MX2_CAMERA_CCIR (1 << 2) |
28 | #define MX2_CAMERA_CCIR_INTERLACE (1 << 3) | 29 | #define MX2_CAMERA_CCIR_INTERLACE (1 << 3) |
@@ -30,6 +31,7 @@ | |||
30 | #define MX2_CAMERA_GATED_CLOCK (1 << 5) | 31 | #define MX2_CAMERA_GATED_CLOCK (1 << 5) |
31 | #define MX2_CAMERA_INV_DATA (1 << 6) | 32 | #define MX2_CAMERA_INV_DATA (1 << 6) |
32 | #define MX2_CAMERA_PCLK_SAMPLE_RISING (1 << 7) | 33 | #define MX2_CAMERA_PCLK_SAMPLE_RISING (1 << 7) |
34 | #define MX2_CAMERA_PACK_DIR_MSB (1 << 8) | ||
33 | 35 | ||
34 | /** | 36 | /** |
35 | * struct mx2_camera_platform_data - optional platform data for mx2_camera | 37 | * struct mx2_camera_platform_data - optional platform data for mx2_camera |
diff --git a/arch/m68k/platform/coldfire/clk.c b/arch/m68k/platform/coldfire/clk.c index 9f1260c5e2ad..44da406897e5 100644 --- a/arch/m68k/platform/coldfire/clk.c +++ b/arch/m68k/platform/coldfire/clk.c | |||
@@ -42,4 +42,11 @@ unsigned long clk_get_rate(struct clk *clk) | |||
42 | return MCF_CLK; | 42 | return MCF_CLK; |
43 | } | 43 | } |
44 | EXPORT_SYMBOL(clk_get_rate); | 44 | EXPORT_SYMBOL(clk_get_rate); |
45 | |||
46 | struct clk *devm_clk_get(struct device *dev, const char *id) | ||
47 | { | ||
48 | return NULL; | ||
49 | } | ||
50 | EXPORT_SYMBOL(devm_clk_get); | ||
51 | |||
45 | /***************************************************************************/ | 52 | /***************************************************************************/ |
diff --git a/arch/powerpc/include/asm/hw_irq.h b/arch/powerpc/include/asm/hw_irq.h index 32b394f3b854..6eb75b80488c 100644 --- a/arch/powerpc/include/asm/hw_irq.h +++ b/arch/powerpc/include/asm/hw_irq.h | |||
@@ -103,6 +103,11 @@ static inline void hard_irq_disable(void) | |||
103 | /* include/linux/interrupt.h needs hard_irq_disable to be a macro */ | 103 | /* include/linux/interrupt.h needs hard_irq_disable to be a macro */ |
104 | #define hard_irq_disable hard_irq_disable | 104 | #define hard_irq_disable hard_irq_disable |
105 | 105 | ||
106 | static inline bool lazy_irq_pending(void) | ||
107 | { | ||
108 | return !!(get_paca()->irq_happened & ~PACA_IRQ_HARD_DIS); | ||
109 | } | ||
110 | |||
106 | /* | 111 | /* |
107 | * This is called by asynchronous interrupts to conditionally | 112 | * This is called by asynchronous interrupts to conditionally |
108 | * re-enable hard interrupts when soft-disabled after having | 113 | * re-enable hard interrupts when soft-disabled after having |
diff --git a/arch/powerpc/kernel/entry_64.S b/arch/powerpc/kernel/entry_64.S index ed1718feb9d9..5971c85df136 100644 --- a/arch/powerpc/kernel/entry_64.S +++ b/arch/powerpc/kernel/entry_64.S | |||
@@ -558,27 +558,54 @@ _GLOBAL(ret_from_except_lite) | |||
558 | mtmsrd r10,1 /* Update machine state */ | 558 | mtmsrd r10,1 /* Update machine state */ |
559 | #endif /* CONFIG_PPC_BOOK3E */ | 559 | #endif /* CONFIG_PPC_BOOK3E */ |
560 | 560 | ||
561 | #ifdef CONFIG_PREEMPT | ||
562 | clrrdi r9,r1,THREAD_SHIFT /* current_thread_info() */ | 561 | clrrdi r9,r1,THREAD_SHIFT /* current_thread_info() */ |
563 | li r0,_TIF_NEED_RESCHED /* bits to check */ | ||
564 | ld r3,_MSR(r1) | 562 | ld r3,_MSR(r1) |
565 | ld r4,TI_FLAGS(r9) | 563 | ld r4,TI_FLAGS(r9) |
566 | /* Move MSR_PR bit in r3 to _TIF_SIGPENDING position in r0 */ | ||
567 | rlwimi r0,r3,32+TIF_SIGPENDING-MSR_PR_LG,_TIF_SIGPENDING | ||
568 | and. r0,r4,r0 /* check NEED_RESCHED and maybe SIGPENDING */ | ||
569 | bne do_work | ||
570 | |||
571 | #else /* !CONFIG_PREEMPT */ | ||
572 | ld r3,_MSR(r1) /* Returning to user mode? */ | ||
573 | andi. r3,r3,MSR_PR | 564 | andi. r3,r3,MSR_PR |
574 | beq restore /* if not, just restore regs and return */ | 565 | beq resume_kernel |
575 | 566 | ||
576 | /* Check current_thread_info()->flags */ | 567 | /* Check current_thread_info()->flags */ |
568 | andi. r0,r4,_TIF_USER_WORK_MASK | ||
569 | beq restore | ||
570 | |||
571 | andi. r0,r4,_TIF_NEED_RESCHED | ||
572 | beq 1f | ||
573 | bl .restore_interrupts | ||
574 | bl .schedule | ||
575 | b .ret_from_except_lite | ||
576 | |||
577 | 1: bl .save_nvgprs | ||
578 | bl .restore_interrupts | ||
579 | addi r3,r1,STACK_FRAME_OVERHEAD | ||
580 | bl .do_notify_resume | ||
581 | b .ret_from_except | ||
582 | |||
583 | resume_kernel: | ||
584 | #ifdef CONFIG_PREEMPT | ||
585 | /* Check if we need to preempt */ | ||
586 | andi. r0,r4,_TIF_NEED_RESCHED | ||
587 | beq+ restore | ||
588 | /* Check that preempt_count() == 0 and interrupts are enabled */ | ||
589 | lwz r8,TI_PREEMPT(r9) | ||
590 | cmpwi cr1,r8,0 | ||
591 | ld r0,SOFTE(r1) | ||
592 | cmpdi r0,0 | ||
593 | crandc eq,cr1*4+eq,eq | ||
594 | bne restore | ||
595 | |||
596 | /* | ||
597 | * Here we are preempting the current task. We want to make | ||
598 | * sure we are soft-disabled first | ||
599 | */ | ||
600 | SOFT_DISABLE_INTS(r3,r4) | ||
601 | 1: bl .preempt_schedule_irq | ||
602 | |||
603 | /* Re-test flags and eventually loop */ | ||
577 | clrrdi r9,r1,THREAD_SHIFT | 604 | clrrdi r9,r1,THREAD_SHIFT |
578 | ld r4,TI_FLAGS(r9) | 605 | ld r4,TI_FLAGS(r9) |
579 | andi. r0,r4,_TIF_USER_WORK_MASK | 606 | andi. r0,r4,_TIF_NEED_RESCHED |
580 | bne do_work | 607 | bne 1b |
581 | #endif /* !CONFIG_PREEMPT */ | 608 | #endif /* CONFIG_PREEMPT */ |
582 | 609 | ||
583 | .globl fast_exc_return_irq | 610 | .globl fast_exc_return_irq |
584 | fast_exc_return_irq: | 611 | fast_exc_return_irq: |
@@ -759,50 +786,6 @@ restore_check_irq_replay: | |||
759 | #endif /* CONFIG_PPC_BOOK3E */ | 786 | #endif /* CONFIG_PPC_BOOK3E */ |
760 | 1: b .ret_from_except /* What else to do here ? */ | 787 | 1: b .ret_from_except /* What else to do here ? */ |
761 | 788 | ||
762 | |||
763 | |||
764 | 3: | ||
765 | do_work: | ||
766 | #ifdef CONFIG_PREEMPT | ||
767 | andi. r0,r3,MSR_PR /* Returning to user mode? */ | ||
768 | bne user_work | ||
769 | /* Check that preempt_count() == 0 and interrupts are enabled */ | ||
770 | lwz r8,TI_PREEMPT(r9) | ||
771 | cmpwi cr1,r8,0 | ||
772 | ld r0,SOFTE(r1) | ||
773 | cmpdi r0,0 | ||
774 | crandc eq,cr1*4+eq,eq | ||
775 | bne restore | ||
776 | |||
777 | /* | ||
778 | * Here we are preempting the current task. We want to make | ||
779 | * sure we are soft-disabled first | ||
780 | */ | ||
781 | SOFT_DISABLE_INTS(r3,r4) | ||
782 | 1: bl .preempt_schedule_irq | ||
783 | |||
784 | /* Re-test flags and eventually loop */ | ||
785 | clrrdi r9,r1,THREAD_SHIFT | ||
786 | ld r4,TI_FLAGS(r9) | ||
787 | andi. r0,r4,_TIF_NEED_RESCHED | ||
788 | bne 1b | ||
789 | b restore | ||
790 | |||
791 | user_work: | ||
792 | #endif /* CONFIG_PREEMPT */ | ||
793 | |||
794 | andi. r0,r4,_TIF_NEED_RESCHED | ||
795 | beq 1f | ||
796 | bl .restore_interrupts | ||
797 | bl .schedule | ||
798 | b .ret_from_except_lite | ||
799 | |||
800 | 1: bl .save_nvgprs | ||
801 | bl .restore_interrupts | ||
802 | addi r3,r1,STACK_FRAME_OVERHEAD | ||
803 | bl .do_notify_resume | ||
804 | b .ret_from_except | ||
805 | |||
806 | unrecov_restore: | 789 | unrecov_restore: |
807 | addi r3,r1,STACK_FRAME_OVERHEAD | 790 | addi r3,r1,STACK_FRAME_OVERHEAD |
808 | bl .unrecoverable_exception | 791 | bl .unrecoverable_exception |
diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c index 7835a5e1ea5f..1b415027ec0e 100644 --- a/arch/powerpc/kernel/irq.c +++ b/arch/powerpc/kernel/irq.c | |||
@@ -277,7 +277,7 @@ EXPORT_SYMBOL(arch_local_irq_restore); | |||
277 | * NOTE: This is called with interrupts hard disabled but not marked | 277 | * NOTE: This is called with interrupts hard disabled but not marked |
278 | * as such in paca->irq_happened, so we need to resync this. | 278 | * as such in paca->irq_happened, so we need to resync this. |
279 | */ | 279 | */ |
280 | void restore_interrupts(void) | 280 | void notrace restore_interrupts(void) |
281 | { | 281 | { |
282 | if (irqs_disabled()) { | 282 | if (irqs_disabled()) { |
283 | local_paca->irq_happened |= PACA_IRQ_HARD_DIS; | 283 | local_paca->irq_happened |= PACA_IRQ_HARD_DIS; |
diff --git a/arch/powerpc/kernel/prom_init.c b/arch/powerpc/kernel/prom_init.c index 1b488e5305c5..0794a3017b1b 100644 --- a/arch/powerpc/kernel/prom_init.c +++ b/arch/powerpc/kernel/prom_init.c | |||
@@ -1312,7 +1312,7 @@ static struct opal_secondary_data { | |||
1312 | 1312 | ||
1313 | extern char opal_secondary_entry; | 1313 | extern char opal_secondary_entry; |
1314 | 1314 | ||
1315 | static void prom_query_opal(void) | 1315 | static void __init prom_query_opal(void) |
1316 | { | 1316 | { |
1317 | long rc; | 1317 | long rc; |
1318 | 1318 | ||
@@ -1436,7 +1436,7 @@ static void __init prom_opal_hold_cpus(void) | |||
1436 | prom_debug("prom_opal_hold_cpus: end...\n"); | 1436 | prom_debug("prom_opal_hold_cpus: end...\n"); |
1437 | } | 1437 | } |
1438 | 1438 | ||
1439 | static void prom_opal_takeover(void) | 1439 | static void __init prom_opal_takeover(void) |
1440 | { | 1440 | { |
1441 | struct opal_secondary_data *data = &RELOC(opal_secondary_data); | 1441 | struct opal_secondary_data *data = &RELOC(opal_secondary_data); |
1442 | struct opal_takeover_args *args = &data->args; | 1442 | struct opal_takeover_args *args = &data->args; |
diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c index b6edbb3b4a54..6e8f677f5646 100644 --- a/arch/powerpc/mm/numa.c +++ b/arch/powerpc/mm/numa.c | |||
@@ -635,7 +635,7 @@ static inline int __init read_usm_ranges(const u32 **usm) | |||
635 | */ | 635 | */ |
636 | static void __init parse_drconf_memory(struct device_node *memory) | 636 | static void __init parse_drconf_memory(struct device_node *memory) |
637 | { | 637 | { |
638 | const u32 *dm, *usm; | 638 | const u32 *uninitialized_var(dm), *usm; |
639 | unsigned int n, rc, ranges, is_kexec_kdump = 0; | 639 | unsigned int n, rc, ranges, is_kexec_kdump = 0; |
640 | unsigned long lmb_size, base, size, sz; | 640 | unsigned long lmb_size, base, size, sz; |
641 | int nid; | 641 | int nid; |
diff --git a/arch/powerpc/net/bpf_jit_64.S b/arch/powerpc/net/bpf_jit_64.S index 55ba3855a97f..7d3a3b5619a2 100644 --- a/arch/powerpc/net/bpf_jit_64.S +++ b/arch/powerpc/net/bpf_jit_64.S | |||
@@ -105,6 +105,7 @@ sk_load_byte_msh_positive_offset: | |||
105 | mr r4, r_addr; \ | 105 | mr r4, r_addr; \ |
106 | li r6, SIZE; \ | 106 | li r6, SIZE; \ |
107 | bl skb_copy_bits; \ | 107 | bl skb_copy_bits; \ |
108 | nop; \ | ||
108 | /* R3 = 0 on success */ \ | 109 | /* R3 = 0 on success */ \ |
109 | addi r1, r1, BPF_PPC_SLOWPATH_FRAME; \ | 110 | addi r1, r1, BPF_PPC_SLOWPATH_FRAME; \ |
110 | ld r0, 16(r1); \ | 111 | ld r0, 16(r1); \ |
@@ -156,6 +157,7 @@ bpf_slow_path_byte_msh: | |||
156 | mr r4, r_addr; \ | 157 | mr r4, r_addr; \ |
157 | li r5, SIZE; \ | 158 | li r5, SIZE; \ |
158 | bl bpf_internal_load_pointer_neg_helper; \ | 159 | bl bpf_internal_load_pointer_neg_helper; \ |
160 | nop; \ | ||
159 | /* R3 != 0 on success */ \ | 161 | /* R3 != 0 on success */ \ |
160 | addi r1, r1, BPF_PPC_SLOWPATH_FRAME; \ | 162 | addi r1, r1, BPF_PPC_SLOWPATH_FRAME; \ |
161 | ld r0, 16(r1); \ | 163 | ld r0, 16(r1); \ |
diff --git a/arch/powerpc/platforms/pseries/iommu.c b/arch/powerpc/platforms/pseries/iommu.c index 0915b1ad66ce..2d311c0caf8e 100644 --- a/arch/powerpc/platforms/pseries/iommu.c +++ b/arch/powerpc/platforms/pseries/iommu.c | |||
@@ -106,7 +106,7 @@ static int tce_build_pSeries(struct iommu_table *tbl, long index, | |||
106 | tcep++; | 106 | tcep++; |
107 | } | 107 | } |
108 | 108 | ||
109 | if (tbl->it_type == TCE_PCI_SWINV_CREATE) | 109 | if (tbl->it_type & TCE_PCI_SWINV_CREATE) |
110 | tce_invalidate_pSeries_sw(tbl, tces, tcep - 1); | 110 | tce_invalidate_pSeries_sw(tbl, tces, tcep - 1); |
111 | return 0; | 111 | return 0; |
112 | } | 112 | } |
@@ -121,7 +121,7 @@ static void tce_free_pSeries(struct iommu_table *tbl, long index, long npages) | |||
121 | while (npages--) | 121 | while (npages--) |
122 | *(tcep++) = 0; | 122 | *(tcep++) = 0; |
123 | 123 | ||
124 | if (tbl->it_type == TCE_PCI_SWINV_FREE) | 124 | if (tbl->it_type & TCE_PCI_SWINV_FREE) |
125 | tce_invalidate_pSeries_sw(tbl, tces, tcep - 1); | 125 | tce_invalidate_pSeries_sw(tbl, tces, tcep - 1); |
126 | } | 126 | } |
127 | 127 | ||
diff --git a/arch/powerpc/platforms/pseries/processor_idle.c b/arch/powerpc/platforms/pseries/processor_idle.c index 41a34bc4a9a2..e61483e8e960 100644 --- a/arch/powerpc/platforms/pseries/processor_idle.c +++ b/arch/powerpc/platforms/pseries/processor_idle.c | |||
@@ -106,7 +106,7 @@ static void check_and_cede_processor(void) | |||
106 | * we first hard disable then check. | 106 | * we first hard disable then check. |
107 | */ | 107 | */ |
108 | hard_irq_disable(); | 108 | hard_irq_disable(); |
109 | if (get_paca()->irq_happened == 0) | 109 | if (!lazy_irq_pending()) |
110 | cede_processor(); | 110 | cede_processor(); |
111 | } | 111 | } |
112 | 112 | ||
diff --git a/arch/sh/boards/mach-kfr2r09/setup.c b/arch/sh/boards/mach-kfr2r09/setup.c index 158c9176e42a..43a179ce9afc 100644 --- a/arch/sh/boards/mach-kfr2r09/setup.c +++ b/arch/sh/boards/mach-kfr2r09/setup.c | |||
@@ -201,8 +201,8 @@ static struct resource kfr2r09_usb0_gadget_resources[] = { | |||
201 | .flags = IORESOURCE_MEM, | 201 | .flags = IORESOURCE_MEM, |
202 | }, | 202 | }, |
203 | [1] = { | 203 | [1] = { |
204 | .start = evtirq(0xa20), | 204 | .start = evt2irq(0xa20), |
205 | .end = evtirq(0xa20), | 205 | .end = evt2irq(0xa20), |
206 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_LOW, | 206 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_LOW, |
207 | }, | 207 | }, |
208 | }; | 208 | }; |
diff --git a/arch/sh/drivers/pci/pcie-sh7786.c b/arch/sh/drivers/pci/pcie-sh7786.c index c045142f7338..9e702f2f8045 100644 --- a/arch/sh/drivers/pci/pcie-sh7786.c +++ b/arch/sh/drivers/pci/pcie-sh7786.c | |||
@@ -239,7 +239,7 @@ static int __init pcie_clk_init(struct sh7786_pcie_port *port) | |||
239 | clk->enable_reg = (void __iomem *)(chan->reg_base + SH4A_PCIEPHYCTLR); | 239 | clk->enable_reg = (void __iomem *)(chan->reg_base + SH4A_PCIEPHYCTLR); |
240 | clk->enable_bit = BITS_CKE; | 240 | clk->enable_bit = BITS_CKE; |
241 | 241 | ||
242 | ret = sh_clk_mstp32_register(clk, 1); | 242 | ret = sh_clk_mstp_register(clk, 1); |
243 | if (unlikely(ret < 0)) | 243 | if (unlikely(ret < 0)) |
244 | goto err_phy; | 244 | goto err_phy; |
245 | 245 | ||
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7343.c b/arch/sh/kernel/cpu/sh4a/clock-sh7343.c index ea01a72f1b94..53638e231cd0 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7343.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7343.c | |||
@@ -283,7 +283,7 @@ int __init arch_clk_init(void) | |||
283 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); | 283 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); |
284 | 284 | ||
285 | if (!ret) | 285 | if (!ret) |
286 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 286 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
287 | 287 | ||
288 | return ret; | 288 | return ret; |
289 | } | 289 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7366.c b/arch/sh/kernel/cpu/sh4a/clock-sh7366.c index 7ac07b4f75de..22e485d1990b 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7366.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7366.c | |||
@@ -276,7 +276,7 @@ int __init arch_clk_init(void) | |||
276 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); | 276 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); |
277 | 277 | ||
278 | if (!ret) | 278 | if (!ret) |
279 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 279 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
280 | 280 | ||
281 | return ret; | 281 | return ret; |
282 | } | 282 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7722.c b/arch/sh/kernel/cpu/sh4a/clock-sh7722.c index 8e1f97010c0d..c4cb740e4d10 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7722.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7722.c | |||
@@ -261,7 +261,7 @@ int __init arch_clk_init(void) | |||
261 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); | 261 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); |
262 | 262 | ||
263 | if (!ret) | 263 | if (!ret) |
264 | ret = sh_clk_mstp32_register(mstp_clks, HWBLK_NR); | 264 | ret = sh_clk_mstp_register(mstp_clks, HWBLK_NR); |
265 | 265 | ||
266 | return ret; | 266 | return ret; |
267 | } | 267 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7723.c b/arch/sh/kernel/cpu/sh4a/clock-sh7723.c index 35f75cf0c7e5..37c41c7747a3 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7723.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7723.c | |||
@@ -311,7 +311,7 @@ int __init arch_clk_init(void) | |||
311 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); | 311 | ret = sh_clk_div6_register(div6_clks, DIV6_NR); |
312 | 312 | ||
313 | if (!ret) | 313 | if (!ret) |
314 | ret = sh_clk_mstp32_register(mstp_clks, HWBLK_NR); | 314 | ret = sh_clk_mstp_register(mstp_clks, HWBLK_NR); |
315 | 315 | ||
316 | return ret; | 316 | return ret; |
317 | } | 317 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7724.c b/arch/sh/kernel/cpu/sh4a/clock-sh7724.c index 2a87901673fe..c87e78f73234 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7724.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7724.c | |||
@@ -375,7 +375,7 @@ int __init arch_clk_init(void) | |||
375 | ret = sh_clk_div6_reparent_register(div6_clks, DIV6_NR); | 375 | ret = sh_clk_div6_reparent_register(div6_clks, DIV6_NR); |
376 | 376 | ||
377 | if (!ret) | 377 | if (!ret) |
378 | ret = sh_clk_mstp32_register(mstp_clks, HWBLK_NR); | 378 | ret = sh_clk_mstp_register(mstp_clks, HWBLK_NR); |
379 | 379 | ||
380 | return ret; | 380 | return ret; |
381 | } | 381 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7734.c b/arch/sh/kernel/cpu/sh4a/clock-sh7734.c index 1697642c1f73..deb683abacf0 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7734.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7734.c | |||
@@ -260,7 +260,7 @@ int __init arch_clk_init(void) | |||
260 | &div4_table); | 260 | &div4_table); |
261 | 261 | ||
262 | if (!ret) | 262 | if (!ret) |
263 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 263 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
264 | 264 | ||
265 | return ret; | 265 | return ret; |
266 | } | 266 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7757.c b/arch/sh/kernel/cpu/sh4a/clock-sh7757.c index 04ab5aeaf920..e84a43229b9c 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7757.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7757.c | |||
@@ -148,7 +148,7 @@ int __init arch_clk_init(void) | |||
148 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), | 148 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), |
149 | &div4_table); | 149 | &div4_table); |
150 | if (!ret) | 150 | if (!ret) |
151 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 151 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
152 | 152 | ||
153 | return ret; | 153 | return ret; |
154 | } | 154 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7785.c b/arch/sh/kernel/cpu/sh4a/clock-sh7785.c index ab1c58f2d101..1c83788db76a 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7785.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7785.c | |||
@@ -175,7 +175,7 @@ int __init arch_clk_init(void) | |||
175 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), | 175 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), |
176 | &div4_table); | 176 | &div4_table); |
177 | if (!ret) | 177 | if (!ret) |
178 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 178 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
179 | 179 | ||
180 | return ret; | 180 | return ret; |
181 | } | 181 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7786.c b/arch/sh/kernel/cpu/sh4a/clock-sh7786.c index 491709483e10..8bba6f159023 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7786.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7786.c | |||
@@ -194,7 +194,7 @@ int __init arch_clk_init(void) | |||
194 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), | 194 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), |
195 | &div4_table); | 195 | &div4_table); |
196 | if (!ret) | 196 | if (!ret) |
197 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 197 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
198 | 198 | ||
199 | return ret; | 199 | return ret; |
200 | } | 200 | } |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-shx3.c b/arch/sh/kernel/cpu/sh4a/clock-shx3.c index 0f11b392bf46..a9422dab0ce7 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-shx3.c +++ b/arch/sh/kernel/cpu/sh4a/clock-shx3.c | |||
@@ -149,7 +149,7 @@ int __init arch_clk_init(void) | |||
149 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), | 149 | ret = sh_clk_div4_register(div4_clks, ARRAY_SIZE(div4_clks), |
150 | &div4_table); | 150 | &div4_table); |
151 | if (!ret) | 151 | if (!ret) |
152 | ret = sh_clk_mstp32_register(mstp_clks, MSTP_NR); | 152 | ret = sh_clk_mstp_register(mstp_clks, MSTP_NR); |
153 | 153 | ||
154 | return ret; | 154 | return ret; |
155 | } | 155 | } |
diff --git a/arch/x86/ia32/ia32_signal.c b/arch/x86/ia32/ia32_signal.c index daeca56211e3..673ac9b63d6b 100644 --- a/arch/x86/ia32/ia32_signal.c +++ b/arch/x86/ia32/ia32_signal.c | |||
@@ -38,7 +38,7 @@ | |||
38 | int copy_siginfo_to_user32(compat_siginfo_t __user *to, siginfo_t *from) | 38 | int copy_siginfo_to_user32(compat_siginfo_t __user *to, siginfo_t *from) |
39 | { | 39 | { |
40 | int err = 0; | 40 | int err = 0; |
41 | bool ia32 = is_ia32_task(); | 41 | bool ia32 = test_thread_flag(TIF_IA32); |
42 | 42 | ||
43 | if (!access_ok(VERIFY_WRITE, to, sizeof(compat_siginfo_t))) | 43 | if (!access_ok(VERIFY_WRITE, to, sizeof(compat_siginfo_t))) |
44 | return -EFAULT; | 44 | return -EFAULT; |
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h index 340ee49961a6..f91e80f4f180 100644 --- a/arch/x86/include/asm/cpufeature.h +++ b/arch/x86/include/asm/cpufeature.h | |||
@@ -176,7 +176,7 @@ | |||
176 | #define X86_FEATURE_XSAVEOPT (7*32+ 4) /* Optimized Xsave */ | 176 | #define X86_FEATURE_XSAVEOPT (7*32+ 4) /* Optimized Xsave */ |
177 | #define X86_FEATURE_PLN (7*32+ 5) /* Intel Power Limit Notification */ | 177 | #define X86_FEATURE_PLN (7*32+ 5) /* Intel Power Limit Notification */ |
178 | #define X86_FEATURE_PTS (7*32+ 6) /* Intel Package Thermal Status */ | 178 | #define X86_FEATURE_PTS (7*32+ 6) /* Intel Package Thermal Status */ |
179 | #define X86_FEATURE_DTS (7*32+ 7) /* Digital Thermal Sensor */ | 179 | #define X86_FEATURE_DTHERM (7*32+ 7) /* Digital Thermal Sensor */ |
180 | #define X86_FEATURE_HW_PSTATE (7*32+ 8) /* AMD HW-PState */ | 180 | #define X86_FEATURE_HW_PSTATE (7*32+ 8) /* AMD HW-PState */ |
181 | 181 | ||
182 | /* Virtualization flags: Linux defined, word 8 */ | 182 | /* Virtualization flags: Linux defined, word 8 */ |
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index 8afb69319815..b2297e58c6ed 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c | |||
@@ -422,12 +422,14 @@ acpi_parse_int_src_ovr(struct acpi_subtable_header * header, | |||
422 | return 0; | 422 | return 0; |
423 | } | 423 | } |
424 | 424 | ||
425 | if (intsrc->source_irq == 0 && intsrc->global_irq == 2) { | 425 | if (intsrc->source_irq == 0) { |
426 | if (acpi_skip_timer_override) { | 426 | if (acpi_skip_timer_override) { |
427 | printk(PREFIX "BIOS IRQ0 pin2 override ignored.\n"); | 427 | printk(PREFIX "BIOS IRQ0 override ignored.\n"); |
428 | return 0; | 428 | return 0; |
429 | } | 429 | } |
430 | if (acpi_fix_pin2_polarity && (intsrc->inti_flags & ACPI_MADT_POLARITY_MASK)) { | 430 | |
431 | if ((intsrc->global_irq == 2) && acpi_fix_pin2_polarity | ||
432 | && (intsrc->inti_flags & ACPI_MADT_POLARITY_MASK)) { | ||
431 | intsrc->inti_flags &= ~ACPI_MADT_POLARITY_MASK; | 433 | intsrc->inti_flags &= ~ACPI_MADT_POLARITY_MASK; |
432 | printk(PREFIX "BIOS IRQ0 pin2 override: forcing polarity to high active.\n"); | 434 | printk(PREFIX "BIOS IRQ0 pin2 override: forcing polarity to high active.\n"); |
433 | } | 435 | } |
@@ -1334,17 +1336,12 @@ static int __init dmi_disable_acpi(const struct dmi_system_id *d) | |||
1334 | } | 1336 | } |
1335 | 1337 | ||
1336 | /* | 1338 | /* |
1337 | * Force ignoring BIOS IRQ0 pin2 override | 1339 | * Force ignoring BIOS IRQ0 override |
1338 | */ | 1340 | */ |
1339 | static int __init dmi_ignore_irq0_timer_override(const struct dmi_system_id *d) | 1341 | static int __init dmi_ignore_irq0_timer_override(const struct dmi_system_id *d) |
1340 | { | 1342 | { |
1341 | /* | ||
1342 | * The ati_ixp4x0_rev() early PCI quirk should have set | ||
1343 | * the acpi_skip_timer_override flag already: | ||
1344 | */ | ||
1345 | if (!acpi_skip_timer_override) { | 1343 | if (!acpi_skip_timer_override) { |
1346 | WARN(1, KERN_ERR "ati_ixp4x0 quirk not complete.\n"); | 1344 | pr_notice("%s detected: Ignoring BIOS IRQ0 override\n", |
1347 | pr_notice("%s detected: Ignoring BIOS IRQ0 pin2 override\n", | ||
1348 | d->ident); | 1345 | d->ident); |
1349 | acpi_skip_timer_override = 1; | 1346 | acpi_skip_timer_override = 1; |
1350 | } | 1347 | } |
@@ -1438,7 +1435,7 @@ static struct dmi_system_id __initdata acpi_dmi_table_late[] = { | |||
1438 | * is enabled. This input is incorrectly designated the | 1435 | * is enabled. This input is incorrectly designated the |
1439 | * ISA IRQ 0 via an interrupt source override even though | 1436 | * ISA IRQ 0 via an interrupt source override even though |
1440 | * it is wired to the output of the master 8259A and INTIN0 | 1437 | * it is wired to the output of the master 8259A and INTIN0 |
1441 | * is not connected at all. Force ignoring BIOS IRQ0 pin2 | 1438 | * is not connected at all. Force ignoring BIOS IRQ0 |
1442 | * override in that cases. | 1439 | * override in that cases. |
1443 | */ | 1440 | */ |
1444 | { | 1441 | { |
@@ -1473,6 +1470,14 @@ static struct dmi_system_id __initdata acpi_dmi_table_late[] = { | |||
1473 | DMI_MATCH(DMI_PRODUCT_NAME, "HP Compaq 6715b"), | 1470 | DMI_MATCH(DMI_PRODUCT_NAME, "HP Compaq 6715b"), |
1474 | }, | 1471 | }, |
1475 | }, | 1472 | }, |
1473 | { | ||
1474 | .callback = dmi_ignore_irq0_timer_override, | ||
1475 | .ident = "FUJITSU SIEMENS", | ||
1476 | .matches = { | ||
1477 | DMI_MATCH(DMI_SYS_VENDOR, "FUJITSU SIEMENS"), | ||
1478 | DMI_MATCH(DMI_PRODUCT_NAME, "AMILO PRO V2030"), | ||
1479 | }, | ||
1480 | }, | ||
1476 | {} | 1481 | {} |
1477 | }; | 1482 | }; |
1478 | 1483 | ||
diff --git a/arch/x86/kernel/cpu/mkcapflags.pl b/arch/x86/kernel/cpu/mkcapflags.pl index dfea390e1608..c7b3fe2d72e0 100644 --- a/arch/x86/kernel/cpu/mkcapflags.pl +++ b/arch/x86/kernel/cpu/mkcapflags.pl | |||
@@ -1,4 +1,4 @@ | |||
1 | #!/usr/bin/perl | 1 | #!/usr/bin/perl -w |
2 | # | 2 | # |
3 | # Generate the x86_cap_flags[] array from include/asm-x86/cpufeature.h | 3 | # Generate the x86_cap_flags[] array from include/asm-x86/cpufeature.h |
4 | # | 4 | # |
@@ -11,22 +11,35 @@ open(OUT, "> $out\0") or die "$0: cannot create: $out: $!\n"; | |||
11 | print OUT "#include <asm/cpufeature.h>\n\n"; | 11 | print OUT "#include <asm/cpufeature.h>\n\n"; |
12 | print OUT "const char * const x86_cap_flags[NCAPINTS*32] = {\n"; | 12 | print OUT "const char * const x86_cap_flags[NCAPINTS*32] = {\n"; |
13 | 13 | ||
14 | %features = (); | ||
15 | $err = 0; | ||
16 | |||
14 | while (defined($line = <IN>)) { | 17 | while (defined($line = <IN>)) { |
15 | if ($line =~ /^\s*\#\s*define\s+(X86_FEATURE_(\S+))\s+(.*)$/) { | 18 | if ($line =~ /^\s*\#\s*define\s+(X86_FEATURE_(\S+))\s+(.*)$/) { |
16 | $macro = $1; | 19 | $macro = $1; |
17 | $feature = $2; | 20 | $feature = "\L$2"; |
18 | $tail = $3; | 21 | $tail = $3; |
19 | if ($tail =~ /\/\*\s*\"([^"]*)\".*\*\//) { | 22 | if ($tail =~ /\/\*\s*\"([^"]*)\".*\*\//) { |
20 | $feature = $1; | 23 | $feature = "\L$1"; |
21 | } | 24 | } |
22 | 25 | ||
23 | if ($feature ne '') { | 26 | next if ($feature eq ''); |
24 | printf OUT "\t%-32s = \"%s\",\n", | 27 | |
25 | "[$macro]", "\L$feature"; | 28 | if ($features{$feature}++) { |
29 | print STDERR "$in: duplicate feature name: $feature\n"; | ||
30 | $err++; | ||
26 | } | 31 | } |
32 | printf OUT "\t%-32s = \"%s\",\n", "[$macro]", $feature; | ||
27 | } | 33 | } |
28 | } | 34 | } |
29 | print OUT "};\n"; | 35 | print OUT "};\n"; |
30 | 36 | ||
31 | close(IN); | 37 | close(IN); |
32 | close(OUT); | 38 | close(OUT); |
39 | |||
40 | if ($err) { | ||
41 | unlink($out); | ||
42 | exit(1); | ||
43 | } | ||
44 | |||
45 | exit(0); | ||
diff --git a/arch/x86/kernel/cpu/scattered.c b/arch/x86/kernel/cpu/scattered.c index addf9e82a7f2..ee8e9abc859f 100644 --- a/arch/x86/kernel/cpu/scattered.c +++ b/arch/x86/kernel/cpu/scattered.c | |||
@@ -31,7 +31,7 @@ void __cpuinit init_scattered_cpuid_features(struct cpuinfo_x86 *c) | |||
31 | const struct cpuid_bit *cb; | 31 | const struct cpuid_bit *cb; |
32 | 32 | ||
33 | static const struct cpuid_bit __cpuinitconst cpuid_bits[] = { | 33 | static const struct cpuid_bit __cpuinitconst cpuid_bits[] = { |
34 | { X86_FEATURE_DTS, CR_EAX, 0, 0x00000006, 0 }, | 34 | { X86_FEATURE_DTHERM, CR_EAX, 0, 0x00000006, 0 }, |
35 | { X86_FEATURE_IDA, CR_EAX, 1, 0x00000006, 0 }, | 35 | { X86_FEATURE_IDA, CR_EAX, 1, 0x00000006, 0 }, |
36 | { X86_FEATURE_ARAT, CR_EAX, 2, 0x00000006, 0 }, | 36 | { X86_FEATURE_ARAT, CR_EAX, 2, 0x00000006, 0 }, |
37 | { X86_FEATURE_PLN, CR_EAX, 4, 0x00000006, 0 }, | 37 | { X86_FEATURE_PLN, CR_EAX, 4, 0x00000006, 0 }, |
diff --git a/arch/x86/kernel/kgdb.c b/arch/x86/kernel/kgdb.c index 8bfb6146f753..3f61904365cf 100644 --- a/arch/x86/kernel/kgdb.c +++ b/arch/x86/kernel/kgdb.c | |||
@@ -444,12 +444,12 @@ void kgdb_roundup_cpus(unsigned long flags) | |||
444 | 444 | ||
445 | /** | 445 | /** |
446 | * kgdb_arch_handle_exception - Handle architecture specific GDB packets. | 446 | * kgdb_arch_handle_exception - Handle architecture specific GDB packets. |
447 | * @vector: The error vector of the exception that happened. | 447 | * @e_vector: The error vector of the exception that happened. |
448 | * @signo: The signal number of the exception that happened. | 448 | * @signo: The signal number of the exception that happened. |
449 | * @err_code: The error code of the exception that happened. | 449 | * @err_code: The error code of the exception that happened. |
450 | * @remcom_in_buffer: The buffer of the packet we have read. | 450 | * @remcomInBuffer: The buffer of the packet we have read. |
451 | * @remcom_out_buffer: The buffer of %BUFMAX bytes to write a packet into. | 451 | * @remcomOutBuffer: The buffer of %BUFMAX bytes to write a packet into. |
452 | * @regs: The &struct pt_regs of the current process. | 452 | * @linux_regs: The &struct pt_regs of the current process. |
453 | * | 453 | * |
454 | * This function MUST handle the 'c' and 's' command packets, | 454 | * This function MUST handle the 'c' and 's' command packets, |
455 | * as well packets to set / remove a hardware breakpoint, if used. | 455 | * as well packets to set / remove a hardware breakpoint, if used. |
diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c index 25b48edb847c..5de92f1abd76 100644 --- a/arch/x86/kernel/reboot.c +++ b/arch/x86/kernel/reboot.c | |||
@@ -451,6 +451,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = { | |||
451 | DMI_MATCH(DMI_PRODUCT_NAME, "OptiPlex 990"), | 451 | DMI_MATCH(DMI_PRODUCT_NAME, "OptiPlex 990"), |
452 | }, | 452 | }, |
453 | }, | 453 | }, |
454 | { /* Handle problems with rebooting on the Precision M6600. */ | ||
455 | .callback = set_pci_reboot, | ||
456 | .ident = "Dell OptiPlex 990", | ||
457 | .matches = { | ||
458 | DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), | ||
459 | DMI_MATCH(DMI_PRODUCT_NAME, "Precision M6600"), | ||
460 | }, | ||
461 | }, | ||
454 | { } | 462 | { } |
455 | }; | 463 | }; |
456 | 464 | ||
diff --git a/arch/x86/lib/csum-wrappers_64.c b/arch/x86/lib/csum-wrappers_64.c index 459b58a8a15c..25b7ae8d058a 100644 --- a/arch/x86/lib/csum-wrappers_64.c +++ b/arch/x86/lib/csum-wrappers_64.c | |||
@@ -115,7 +115,7 @@ EXPORT_SYMBOL(csum_partial_copy_to_user); | |||
115 | * @src: source address | 115 | * @src: source address |
116 | * @dst: destination address | 116 | * @dst: destination address |
117 | * @len: number of bytes to be copied. | 117 | * @len: number of bytes to be copied. |
118 | * @isum: initial sum that is added into the result (32bit unfolded) | 118 | * @sum: initial sum that is added into the result (32bit unfolded) |
119 | * | 119 | * |
120 | * Returns an 32bit unfolded checksum of the buffer. | 120 | * Returns an 32bit unfolded checksum of the buffer. |
121 | */ | 121 | */ |