diff options
author | Rafał Miłecki <rafal@milecki.pl> | 2017-03-03 11:34:15 +0100 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2017-03-20 19:12:01 +0200 |
commit | f825f6ed20e37a20ad5feaf607acfb84bfdf9d99 (patch) | |
tree | 7d9e76879109bc3721742dda425796c9349d7fdc /drivers/bcma | |
parent | 5e48a4cd2ee916a98fbc36c944b21a7c935cf4f4 (diff) |
bcma: fill core OF info independently of bus type
PCI devices can be described in DT as well so we should always execute
relevant code. This will make bcma e.g. set of_node for cores described
in DT.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/bcma')
-rw-r--r-- | drivers/bcma/main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/bcma/main.c b/drivers/bcma/main.c index e6f3810d594d..e6986c7608f1 100644 --- a/drivers/bcma/main.c +++ b/drivers/bcma/main.c @@ -240,6 +240,8 @@ void bcma_prepare_core(struct bcma_bus *bus, struct bcma_device *core) core->dev.bus = &bcma_bus_type; dev_set_name(&core->dev, "bcma%d:%d", bus->num, core->core_index); core->dev.parent = bcma_bus_get_host_dev(bus); + if (core->dev.parent) + bcma_of_fill_device(core->dev.parent, core); switch (bus->hosttype) { case BCMA_HOSTTYPE_PCI: @@ -249,8 +251,6 @@ void bcma_prepare_core(struct bcma_bus *bus, struct bcma_device *core) case BCMA_HOSTTYPE_SOC: if (IS_ENABLED(CONFIG_OF) && bus->host_pdev) { core->dma_dev = &bus->host_pdev->dev; - if (core->dev.parent) - bcma_of_fill_device(core->dev.parent, core); } else { core->dev.dma_mask = &core->dev.coherent_dma_mask; core->dma_dev = &core->dev; |