diff options
author | Philipp Zabel <p.zabel@pengutronix.de> | 2016-08-09 16:18:51 +0200 |
---|---|---|
committer | Rob Herring <robh@kernel.org> | 2016-08-09 12:36:28 -0500 |
commit | e55aeb6ba4e8cc3549bff1e75ea1d029324bce21 (patch) | |
tree | 8508d24b726cb9b74244eb429b1371cfbb42372c | |
parent | 89c67752ae4dedc1244344b266c837ddb4053ebd (diff) |
of/irq: Mark interrupt controllers as populated before initialisation
That way the init callback may clear the flag again, in case of drivers
split between early irq chip and a normal platform driver.
Fixes: 15cc2ed6dcf9 ("of/irq: Mark initialised interrupt controllers as populated")
Suggested-by: Rob Herring <robh@kernel.org>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Acked-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Rob Herring <robh@kernel.org>
-rw-r--r-- | drivers/of/irq.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/of/irq.c b/drivers/of/irq.c index 89a71c6074fc..a2e68f740eda 100644 --- a/drivers/of/irq.c +++ b/drivers/of/irq.c @@ -544,12 +544,15 @@ void __init of_irq_init(const struct of_device_id *matches) list_del(&desc->list); + of_node_set_flag(desc->dev, OF_POPULATED); + pr_debug("of_irq_init: init %s (%p), parent %p\n", desc->dev->full_name, desc->dev, desc->interrupt_parent); ret = desc->irq_init_cb(desc->dev, desc->interrupt_parent); if (ret) { + of_node_clear_flag(desc->dev, OF_POPULATED); kfree(desc); continue; } @@ -559,8 +562,6 @@ void __init of_irq_init(const struct of_device_id *matches) * its children can get processed in a subsequent pass. */ list_add_tail(&desc->list, &intc_parent_list); - - of_node_set_flag(desc->dev, OF_POPULATED); } /* Get the next pending parent that might have children */ |