of/irq: Use irq_of_parse_and_map()
Replace some instances of of_irq_map_one()/irq_create_of_mapping() and of_irq_to_resource() by the simpler equivalent irq_of_parse_and_map(). Signed-off-by: Thierry Reding <treding@nvidia.com> Acked-by: Rob Herring <rob.herring@calxeda.com> [grant.likely: resolved conflicts with core code renames] Signed-off-by: Grant Likely <grant.likely@linaro.org>
This commit is contained in:

committed by
Grant Likely

parent
3da5278727
commit
f7578496a6
@@ -237,15 +237,13 @@ static int mpic_msgr_probe(struct platform_device *dev)
|
||||
raw_spin_lock_init(&msgr->lock);
|
||||
|
||||
if (receive_mask & (1 << i)) {
|
||||
struct resource irq;
|
||||
|
||||
if (of_irq_to_resource(np, irq_index, &irq) == NO_IRQ) {
|
||||
msgr->irq = irq_of_parse_and_map(np, irq_index);
|
||||
if (msgr->irq == NO_IRQ) {
|
||||
dev_err(&dev->dev,
|
||||
"Missing interrupt specifier");
|
||||
kfree(msgr);
|
||||
return -EFAULT;
|
||||
}
|
||||
msgr->irq = irq.start;
|
||||
irq_index += 1;
|
||||
} else {
|
||||
msgr->irq = NO_IRQ;
|
||||
|
Reference in New Issue
Block a user