diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2010-10-12 02:03:09 +0900 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2010-10-26 15:01:52 +0900 |
commit | c4318baf00ed24b7fdcc255de33a18ab37ee8606 (patch) | |
tree | 2bf80722d2e7236de917e0e577fb14233e58e513 /drivers/sh/intc/core.c | |
parent | 2f98492c5375e906e48c78d88351f45bb11b6a8a (diff) | |
download | linux-c4318baf00ed24b7fdcc255de33a18ab37ee8606.tar.bz2 |
sh: Sanitize sparse irq
Switch over to the new allocator functions.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'drivers/sh/intc/core.c')
-rw-r--r-- | drivers/sh/intc/core.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/sh/intc/core.c b/drivers/sh/intc/core.c index 306ed287077a..8f3c27e9f9e2 100644 --- a/drivers/sh/intc/core.c +++ b/drivers/sh/intc/core.c @@ -300,13 +300,13 @@ int __init register_intc_controller(struct intc_desc *desc) for (i = 0; i < hw->nr_vectors; i++) { struct intc_vect *vect = hw->vectors + i; unsigned int irq = evt2irq(vect->vect); - struct irq_desc *irq_desc; + int res; if (!vect->enum_id) continue; - irq_desc = irq_to_desc_alloc_node(irq, numa_node_id()); - if (unlikely(!irq_desc)) { + res = irq_alloc_desc_at(irq, numa_node_id()); + if (res != irq && res != -EEXIST) { pr_err("can't get irq_desc for %d\n", irq); continue; } @@ -326,8 +326,8 @@ int __init register_intc_controller(struct intc_desc *desc) * IRQ support, each vector still needs to have * its own backing irq_desc. */ - irq_desc = irq_to_desc_alloc_node(irq2, numa_node_id()); - if (unlikely(!irq_desc)) { + res = irq_alloc_desc_at(irq2, numa_node_id()); + if (res != irq2 && res != -EEXIST) { pr_err("can't get irq_desc for %d\n", irq2); continue; } |