diff options
Diffstat (limited to 'arch/arm/common')
-rw-r--r-- | arch/arm/common/it8152.c | 14 | ||||
-rw-r--r-- | arch/arm/common/locomo.c | 26 | ||||
-rw-r--r-- | arch/arm/common/sharpsl_param.c | 2 |
3 files changed, 13 insertions, 29 deletions
diff --git a/arch/arm/common/it8152.c b/arch/arm/common/it8152.c index 5fe9588db077..2793447621c3 100644 --- a/arch/arm/common/it8152.c +++ b/arch/arm/common/it8152.c | |||
@@ -66,14 +66,6 @@ static void it8152_unmask_irq(unsigned int irq) | |||
66 | } | 66 | } |
67 | } | 67 | } |
68 | 68 | ||
69 | static inline void it8152_irq(int irq) | ||
70 | { | ||
71 | struct irq_desc *desc; | ||
72 | |||
73 | desc = irq_desc + irq; | ||
74 | desc_handle_irq(irq, desc); | ||
75 | } | ||
76 | |||
77 | static struct irq_chip it8152_irq_chip = { | 69 | static struct irq_chip it8152_irq_chip = { |
78 | .name = "it8152", | 70 | .name = "it8152", |
79 | .ack = it8152_mask_irq, | 71 | .ack = it8152_mask_irq, |
@@ -128,21 +120,21 @@ void it8152_irq_demux(unsigned int irq, struct irq_desc *desc) | |||
128 | bits_pd &= ((1 << IT8152_PD_IRQ_COUNT) - 1); | 120 | bits_pd &= ((1 << IT8152_PD_IRQ_COUNT) - 1); |
129 | while (bits_pd) { | 121 | while (bits_pd) { |
130 | i = __ffs(bits_pd); | 122 | i = __ffs(bits_pd); |
131 | it8152_irq(IT8152_PD_IRQ(i)); | 123 | generic_handle_irq(IT8152_PD_IRQ(i)); |
132 | bits_pd &= ~(1 << i); | 124 | bits_pd &= ~(1 << i); |
133 | } | 125 | } |
134 | 126 | ||
135 | bits_lp &= ((1 << IT8152_LP_IRQ_COUNT) - 1); | 127 | bits_lp &= ((1 << IT8152_LP_IRQ_COUNT) - 1); |
136 | while (bits_lp) { | 128 | while (bits_lp) { |
137 | i = __ffs(bits_lp); | 129 | i = __ffs(bits_lp); |
138 | it8152_irq(IT8152_LP_IRQ(i)); | 130 | generic_handle_irq(IT8152_LP_IRQ(i)); |
139 | bits_lp &= ~(1 << i); | 131 | bits_lp &= ~(1 << i); |
140 | } | 132 | } |
141 | 133 | ||
142 | bits_ld &= ((1 << IT8152_LD_IRQ_COUNT) - 1); | 134 | bits_ld &= ((1 << IT8152_LD_IRQ_COUNT) - 1); |
143 | while (bits_ld) { | 135 | while (bits_ld) { |
144 | i = __ffs(bits_ld); | 136 | i = __ffs(bits_ld); |
145 | it8152_irq(IT8152_LD_IRQ(i)); | 137 | generic_handle_irq(IT8152_LD_IRQ(i)); |
146 | bits_ld &= ~(1 << i); | 138 | bits_ld &= ~(1 << i); |
147 | } | 139 | } |
148 | } | 140 | } |
diff --git a/arch/arm/common/locomo.c b/arch/arm/common/locomo.c index 534b23d95864..7c6b4b99a2df 100644 --- a/arch/arm/common/locomo.c +++ b/arch/arm/common/locomo.c | |||
@@ -169,7 +169,6 @@ static struct locomo_dev_info locomo_devices[] = { | |||
169 | static void locomo_handler(unsigned int irq, struct irq_desc *desc) | 169 | static void locomo_handler(unsigned int irq, struct irq_desc *desc) |
170 | { | 170 | { |
171 | int req, i; | 171 | int req, i; |
172 | struct irq_desc *d; | ||
173 | void __iomem *mapbase = get_irq_chip_data(irq); | 172 | void __iomem *mapbase = get_irq_chip_data(irq); |
174 | 173 | ||
175 | /* Acknowledge the parent IRQ */ | 174 | /* Acknowledge the parent IRQ */ |
@@ -181,10 +180,9 @@ static void locomo_handler(unsigned int irq, struct irq_desc *desc) | |||
181 | if (req) { | 180 | if (req) { |
182 | /* generate the next interrupt(s) */ | 181 | /* generate the next interrupt(s) */ |
183 | irq = LOCOMO_IRQ_START; | 182 | irq = LOCOMO_IRQ_START; |
184 | d = irq_desc + irq; | 183 | for (i = 0; i <= 3; i++, irq++) { |
185 | for (i = 0; i <= 3; i++, d++, irq++) { | ||
186 | if (req & (0x0100 << i)) { | 184 | if (req & (0x0100 << i)) { |
187 | desc_handle_irq(irq, d); | 185 | generic_handle_irq(irq); |
188 | } | 186 | } |
189 | 187 | ||
190 | } | 188 | } |
@@ -222,12 +220,10 @@ static struct irq_chip locomo_chip = { | |||
222 | 220 | ||
223 | static void locomo_key_handler(unsigned int irq, struct irq_desc *desc) | 221 | static void locomo_key_handler(unsigned int irq, struct irq_desc *desc) |
224 | { | 222 | { |
225 | struct irq_desc *d; | ||
226 | void __iomem *mapbase = get_irq_chip_data(irq); | 223 | void __iomem *mapbase = get_irq_chip_data(irq); |
227 | 224 | ||
228 | if (locomo_readl(mapbase + LOCOMO_KEYBOARD + LOCOMO_KIC) & 0x0001) { | 225 | if (locomo_readl(mapbase + LOCOMO_KEYBOARD + LOCOMO_KIC) & 0x0001) { |
229 | d = irq_desc + LOCOMO_IRQ_KEY_START; | 226 | generic_handle_irq(LOCOMO_IRQ_KEY_START); |
230 | desc_handle_irq(LOCOMO_IRQ_KEY_START, d); | ||
231 | } | 227 | } |
232 | } | 228 | } |
233 | 229 | ||
@@ -268,7 +264,6 @@ static struct irq_chip locomo_key_chip = { | |||
268 | static void locomo_gpio_handler(unsigned int irq, struct irq_desc *desc) | 264 | static void locomo_gpio_handler(unsigned int irq, struct irq_desc *desc) |
269 | { | 265 | { |
270 | int req, i; | 266 | int req, i; |
271 | struct irq_desc *d; | ||
272 | void __iomem *mapbase = get_irq_chip_data(irq); | 267 | void __iomem *mapbase = get_irq_chip_data(irq); |
273 | 268 | ||
274 | req = locomo_readl(mapbase + LOCOMO_GIR) & | 269 | req = locomo_readl(mapbase + LOCOMO_GIR) & |
@@ -277,10 +272,9 @@ static void locomo_gpio_handler(unsigned int irq, struct irq_desc *desc) | |||
277 | 272 | ||
278 | if (req) { | 273 | if (req) { |
279 | irq = LOCOMO_IRQ_GPIO_START; | 274 | irq = LOCOMO_IRQ_GPIO_START; |
280 | d = irq_desc + LOCOMO_IRQ_GPIO_START; | 275 | for (i = 0; i <= 15; i++, irq++) { |
281 | for (i = 0; i <= 15; i++, irq++, d++) { | ||
282 | if (req & (0x0001 << i)) { | 276 | if (req & (0x0001 << i)) { |
283 | desc_handle_irq(irq, d); | 277 | generic_handle_irq(irq); |
284 | } | 278 | } |
285 | } | 279 | } |
286 | } | 280 | } |
@@ -361,12 +355,10 @@ static struct irq_chip locomo_gpio_chip = { | |||
361 | 355 | ||
362 | static void locomo_lt_handler(unsigned int irq, struct irq_desc *desc) | 356 | static void locomo_lt_handler(unsigned int irq, struct irq_desc *desc) |
363 | { | 357 | { |
364 | struct irq_desc *d; | ||
365 | void __iomem *mapbase = get_irq_chip_data(irq); | 358 | void __iomem *mapbase = get_irq_chip_data(irq); |
366 | 359 | ||
367 | if (locomo_readl(mapbase + LOCOMO_LTINT) & 0x0001) { | 360 | if (locomo_readl(mapbase + LOCOMO_LTINT) & 0x0001) { |
368 | d = irq_desc + LOCOMO_IRQ_LT_START; | 361 | generic_handle_irq(LOCOMO_IRQ_LT_START); |
369 | desc_handle_irq(LOCOMO_IRQ_LT_START, d); | ||
370 | } | 362 | } |
371 | } | 363 | } |
372 | 364 | ||
@@ -407,17 +399,15 @@ static struct irq_chip locomo_lt_chip = { | |||
407 | static void locomo_spi_handler(unsigned int irq, struct irq_desc *desc) | 399 | static void locomo_spi_handler(unsigned int irq, struct irq_desc *desc) |
408 | { | 400 | { |
409 | int req, i; | 401 | int req, i; |
410 | struct irq_desc *d; | ||
411 | void __iomem *mapbase = get_irq_chip_data(irq); | 402 | void __iomem *mapbase = get_irq_chip_data(irq); |
412 | 403 | ||
413 | req = locomo_readl(mapbase + LOCOMO_SPI + LOCOMO_SPIIR) & 0x000F; | 404 | req = locomo_readl(mapbase + LOCOMO_SPI + LOCOMO_SPIIR) & 0x000F; |
414 | if (req) { | 405 | if (req) { |
415 | irq = LOCOMO_IRQ_SPI_START; | 406 | irq = LOCOMO_IRQ_SPI_START; |
416 | d = irq_desc + irq; | ||
417 | 407 | ||
418 | for (i = 0; i <= 3; i++, irq++, d++) { | 408 | for (i = 0; i <= 3; i++, irq++) { |
419 | if (req & (0x0001 << i)) { | 409 | if (req & (0x0001 << i)) { |
420 | desc_handle_irq(irq, d); | 410 | generic_handle_irq(irq); |
421 | } | 411 | } |
422 | } | 412 | } |
423 | } | 413 | } |
diff --git a/arch/arm/common/sharpsl_param.c b/arch/arm/common/sharpsl_param.c index aad4d94ba8f5..d56c932580eb 100644 --- a/arch/arm/common/sharpsl_param.c +++ b/arch/arm/common/sharpsl_param.c | |||
@@ -12,6 +12,7 @@ | |||
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/kernel.h> | 14 | #include <linux/kernel.h> |
15 | #include <linux/module.h> | ||
15 | #include <linux/string.h> | 16 | #include <linux/string.h> |
16 | #include <asm/mach/sharpsl_param.h> | 17 | #include <asm/mach/sharpsl_param.h> |
17 | 18 | ||
@@ -36,6 +37,7 @@ | |||
36 | #define PHAD_MAGIC MAGIC_CHG('P','H','A','D') | 37 | #define PHAD_MAGIC MAGIC_CHG('P','H','A','D') |
37 | 38 | ||
38 | struct sharpsl_param_info sharpsl_param; | 39 | struct sharpsl_param_info sharpsl_param; |
40 | EXPORT_SYMBOL(sharpsl_param); | ||
39 | 41 | ||
40 | void sharpsl_save_param(void) | 42 | void sharpsl_save_param(void) |
41 | { | 43 | { |