summaryrefslogtreecommitdiffstats
path: root/drivers/bus
diff options
context:
space:
mode:
authorSebastian Hesselbarth <sebastian.hesselbarth@gmail.com>2015-04-20 22:11:19 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2015-04-27 08:09:35 +0200
commit60f947b494e53e5e85d73895ed0ff79428bdca6b (patch)
tree496f205187b7f96d8b445da6ff4f8dafadffd948 /drivers/bus
parent5e585631599ff31c3de8c59f1ac28cff321be773 (diff)
downloadbarebox-60f947b494e53e5e85d73895ed0ff79428bdca6b.tar.gz
barebox-60f947b494e53e5e85d73895ed0ff79428bdca6b.tar.xz
bus: mvebu-mbus: Convert mbus platform driver to direct driver
Registering mbus driver as platform driver is a little late for some register accesses to work. We have to make sure boot-up mbus windows are disabled early, so call mbus driver directly from SoC init. Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/bus')
-rw-r--r--drivers/bus/mvebu-mbus.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/drivers/bus/mvebu-mbus.c b/drivers/bus/mvebu-mbus.c
index 077d7ccb83..e189810354 100644
--- a/drivers/bus/mvebu-mbus.c
+++ b/drivers/bus/mvebu-mbus.c
@@ -673,7 +673,7 @@ static void mvebu_mbus_get_pcie_resources(struct device_node *np,
}
}
-static int mvebu_mbus_probe(struct device_d *dev)
+int mvebu_mbus_init(void)
{
struct device_node *np, *controller;
const struct of_device_id *match;
@@ -725,18 +725,6 @@ static int mvebu_mbus_probe(struct device_d *dev)
return mbus_dt_setup(&mbus_state);
}
-static struct driver_d mvebu_mbus_driver = {
- .probe = mvebu_mbus_probe,
- .name = "mvebu-mbus",
- .of_compatible = DRV_OF_COMPAT(mvebu_mbus_dt_ids),
-};
-
-static int mvebu_mbus_init(void)
-{
- return platform_driver_register(&mvebu_mbus_driver);
-}
-postcore_initcall(mvebu_mbus_init);
-
struct mbus_range {
const char *compatible;
u32 mbusid;