diff options
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2017-02-25 21:40:20 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2017-03-02 14:03:43 +0100 |
commit | 8a5edc9e99f0326b855f7b07d35f320b58bbdcb3 (patch) | |
tree | 32aa5c74cc02d552f1529ba1fe7e7b0597b130ff /drivers/bus | |
parent | f3acd214a179fb0d98a6d29edb11cd32dbafd196 (diff) | |
download | barebox-8a5edc9e99f0326b855f7b07d35f320b58bbdcb3.tar.gz barebox-8a5edc9e99f0326b855f7b07d35f320b58bbdcb3.tar.xz |
mvebu: armada-370-xp: simplify soc init code flow
This gets rid of a of-fixup which is strange because the soc init stuff
is rerun then when a new dt for booting into Linux is loaded.
The initcall must be postponed to post-core to ensure
of_machine_is_compatible is working correctly.
The call to mvebu_mbus_add_range is moved to drivers/bus/mvebu-mbus.c to
ensure it's registered early enough.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/bus')
-rw-r--r-- | drivers/bus/mvebu-mbus.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/bus/mvebu-mbus.c b/drivers/bus/mvebu-mbus.c index df5f7a32d3..b95c071d57 100644 --- a/drivers/bus/mvebu-mbus.c +++ b/drivers/bus/mvebu-mbus.c @@ -59,6 +59,7 @@ #include <of.h> #include <of_address.h> #include <linux/mbus.h> +#include <mach/common.h> /* DDR target is the same on all platforms */ #define TARGET_DDR 0 @@ -810,7 +811,13 @@ static int mvebu_mbus_of_fixup(struct device_node *root, void *context) return 0; } -static int mvebu_mbus_fixup_register(void) { +static int mvebu_mbus_fixup_register(void) +{ + if (IS_ENABLED(CONFIG_ARCH_ARMADA_370) || + IS_ENABLED(CONFIG_ARCH_ARMADA_XP)) + mvebu_mbus_add_range("marvell,armada-370-xp", 0xf0, 0x01, + MVEBU_REMAP_INT_REG_BASE); + return of_register_fixup(mvebu_mbus_of_fixup, NULL); } pure_initcall(mvebu_mbus_fixup_register); |