diff options
-rw-r--r-- | arch/arm/mach-s3c2410/clock.c | 5 | ||||
-rw-r--r-- | include/asm-arm/arch-ixp4xx/entry-macro.S | 9 | ||||
-rw-r--r-- | include/asm-arm/arch-ixp4xx/hardware.h | 2 | ||||
-rw-r--r-- | include/asm-arm/locks.h | 4 |
4 files changed, 12 insertions, 8 deletions
diff --git a/arch/arm/mach-s3c2410/clock.c b/arch/arm/mach-s3c2410/clock.c index f59608268751..8b3d5dc35de5 100644 --- a/arch/arm/mach-s3c2410/clock.c +++ b/arch/arm/mach-s3c2410/clock.c | |||
@@ -98,7 +98,10 @@ struct clk *clk_get(struct device *dev, const char *id) | |||
98 | struct clk *clk = ERR_PTR(-ENOENT); | 98 | struct clk *clk = ERR_PTR(-ENOENT); |
99 | int idno; | 99 | int idno; |
100 | 100 | ||
101 | idno = (dev == NULL) ? -1 : to_platform_device(dev)->id; | 101 | if (dev == NULL || dev->bus != &platform_bus_type) |
102 | idno = -1; | ||
103 | else | ||
104 | idno = to_platform_device(dev)->id; | ||
102 | 105 | ||
103 | down(&clocks_sem); | 106 | down(&clocks_sem); |
104 | 107 | ||
diff --git a/include/asm-arm/arch-ixp4xx/entry-macro.S b/include/asm-arm/arch-ixp4xx/entry-macro.S index 455da64832de..323b0bc4a39c 100644 --- a/include/asm-arm/arch-ixp4xx/entry-macro.S +++ b/include/asm-arm/arch-ixp4xx/entry-macro.S | |||
@@ -15,25 +15,26 @@ | |||
15 | ldr \irqstat, =(IXP4XX_INTC_BASE_VIRT+IXP4XX_ICIP_OFFSET) | 15 | ldr \irqstat, =(IXP4XX_INTC_BASE_VIRT+IXP4XX_ICIP_OFFSET) |
16 | ldr \irqstat, [\irqstat] @ get interrupts | 16 | ldr \irqstat, [\irqstat] @ get interrupts |
17 | cmp \irqstat, #0 | 17 | cmp \irqstat, #0 |
18 | beq 1001f | 18 | beq 1001f @ upper IRQ? |
19 | clz \irqnr, \irqstat | 19 | clz \irqnr, \irqstat |
20 | mov \base, #31 | 20 | mov \base, #31 |
21 | subs \irqnr, \base, \irqnr | 21 | sub \irqnr, \base, \irqnr |
22 | b 1002f @ lower IRQ being | ||
23 | @ handled | ||
22 | 24 | ||
23 | 1001: | 25 | 1001: |
24 | /* | 26 | /* |
25 | * IXP465 has an upper IRQ status register | 27 | * IXP465 has an upper IRQ status register |
26 | */ | 28 | */ |
27 | #if defined(CONFIG_CPU_IXP46X) | 29 | #if defined(CONFIG_CPU_IXP46X) |
28 | bne 1002f | ||
29 | ldr \irqstat, =(IXP4XX_INTC_BASE_VIRT+IXP4XX_ICIP2_OFFSET) | 30 | ldr \irqstat, =(IXP4XX_INTC_BASE_VIRT+IXP4XX_ICIP2_OFFSET) |
30 | ldr \irqstat, [\irqstat] @ get upper interrupts | 31 | ldr \irqstat, [\irqstat] @ get upper interrupts |
31 | mov \irqnr, #63 | 32 | mov \irqnr, #63 |
32 | clz \irqstat, \irqstat | 33 | clz \irqstat, \irqstat |
33 | cmp \irqstat, #32 | 34 | cmp \irqstat, #32 |
34 | subne \irqnr, \irqnr, \irqstat | 35 | subne \irqnr, \irqnr, \irqstat |
35 | 1002: | ||
36 | #endif | 36 | #endif |
37 | 1002: | ||
37 | .endm | 38 | .endm |
38 | 39 | ||
39 | 40 | ||
diff --git a/include/asm-arm/arch-ixp4xx/hardware.h b/include/asm-arm/arch-ixp4xx/hardware.h index 4ac964b9078a..55d85eea8c1a 100644 --- a/include/asm-arm/arch-ixp4xx/hardware.h +++ b/include/asm-arm/arch-ixp4xx/hardware.h | |||
@@ -27,7 +27,7 @@ | |||
27 | 27 | ||
28 | #define pcibios_assign_all_busses() 1 | 28 | #define pcibios_assign_all_busses() 1 |
29 | 29 | ||
30 | #if defined(CONFIG_CPU_IXP465) && !defined(__ASSEMBLY__) | 30 | #if defined(CONFIG_CPU_IXP46X) && !defined(__ASSEMBLY__) |
31 | extern unsigned int processor_id; | 31 | extern unsigned int processor_id; |
32 | #define cpu_is_ixp465() ((processor_id & 0xffffffc0) == 0x69054200) | 32 | #define cpu_is_ixp465() ((processor_id & 0xffffffc0) == 0x69054200) |
33 | #else | 33 | #else |
diff --git a/include/asm-arm/locks.h b/include/asm-arm/locks.h index f08dc8447913..852220eecdbc 100644 --- a/include/asm-arm/locks.h +++ b/include/asm-arm/locks.h | |||
@@ -103,7 +103,7 @@ | |||
103 | ({ \ | 103 | ({ \ |
104 | smp_mb(); \ | 104 | smp_mb(); \ |
105 | __asm__ __volatile__( \ | 105 | __asm__ __volatile__( \ |
106 | "@ up_op_read\n" \ | 106 | "@ up_op_write\n" \ |
107 | "1: ldrex lr, [%0]\n" \ | 107 | "1: ldrex lr, [%0]\n" \ |
108 | " adds lr, lr, %1\n" \ | 108 | " adds lr, lr, %1\n" \ |
109 | " strex ip, lr, [%0]\n" \ | 109 | " strex ip, lr, [%0]\n" \ |
@@ -231,7 +231,7 @@ | |||
231 | #define __up_op_write(ptr,wake) \ | 231 | #define __up_op_write(ptr,wake) \ |
232 | ({ \ | 232 | ({ \ |
233 | __asm__ __volatile__( \ | 233 | __asm__ __volatile__( \ |
234 | "@ up_op_read\n" \ | 234 | "@ up_op_write\n" \ |
235 | " mrs ip, cpsr\n" \ | 235 | " mrs ip, cpsr\n" \ |
236 | " orr lr, ip, #128\n" \ | 236 | " orr lr, ip, #128\n" \ |
237 | " msr cpsr_c, lr\n" \ | 237 | " msr cpsr_c, lr\n" \ |