diff options
Diffstat (limited to 'drivers/of/irq.c')
-rw-r--r-- | drivers/of/irq.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/of/irq.c b/drivers/of/irq.c index a23ec7779997..a3c1c5aae6a9 100644 --- a/drivers/of/irq.c +++ b/drivers/of/irq.c | |||
@@ -192,11 +192,13 @@ int of_irq_map_raw(struct device_node *parent, const __be32 *intspec, | |||
192 | /* Compare specifiers */ | 192 | /* Compare specifiers */ |
193 | match = 1; | 193 | match = 1; |
194 | for (i = 0; i < addrsize && match; ++i) { | 194 | for (i = 0; i < addrsize && match; ++i) { |
195 | u32 mask = imask ? imask[i] : 0xffffffffu; | 195 | __be32 mask = imask ? imask[i] |
196 | : cpu_to_be32(0xffffffffu); | ||
196 | match = ((addr[i] ^ imap[i]) & mask) == 0; | 197 | match = ((addr[i] ^ imap[i]) & mask) == 0; |
197 | } | 198 | } |
198 | for (; i < (addrsize + intsize) && match; ++i) { | 199 | for (; i < (addrsize + intsize) && match; ++i) { |
199 | u32 mask = imask ? imask[i] : 0xffffffffu; | 200 | __be32 mask = imask ? imask[i] |
201 | : cpu_to_be32(0xffffffffu); | ||
200 | match = | 202 | match = |
201 | ((intspec[i-addrsize] ^ imap[i]) & mask) == 0; | 203 | ((intspec[i-addrsize] ^ imap[i]) & mask) == 0; |
202 | } | 204 | } |
@@ -465,7 +467,7 @@ void __init of_irq_init(const struct of_device_id *matches) | |||
465 | pr_debug("of_irq_init: init %s @ %p, parent %p\n", | 467 | pr_debug("of_irq_init: init %s @ %p, parent %p\n", |
466 | match->compatible, | 468 | match->compatible, |
467 | desc->dev, desc->interrupt_parent); | 469 | desc->dev, desc->interrupt_parent); |
468 | irq_init_cb = match->data; | 470 | irq_init_cb = (of_irq_init_cb_t)match->data; |
469 | ret = irq_init_cb(desc->dev, desc->interrupt_parent); | 471 | ret = irq_init_cb(desc->dev, desc->interrupt_parent); |
470 | if (ret) { | 472 | if (ret) { |
471 | kfree(desc); | 473 | kfree(desc); |