diff options
Diffstat (limited to 'drivers/bus/mvebu-mbus.c')
-rw-r--r-- | drivers/bus/mvebu-mbus.c | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/drivers/bus/mvebu-mbus.c b/drivers/bus/mvebu-mbus.c index df5f7a32d3..965a221d3b 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,26 @@ static int mvebu_mbus_of_fixup(struct device_node *root, void *context) return 0; } -static int mvebu_mbus_fixup_register(void) { +#define DOVE_REMAP_MC_REGS 0xf1800000 + +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); + + if (IS_ENABLED(CONFIG_ARCH_DOVE)) { + mvebu_mbus_add_range("marvell,dove", 0xf0, 0x01, + MVEBU_REMAP_INT_REG_BASE); + mvebu_mbus_add_range("marvell,dove", 0xf0, 0x02, + DOVE_REMAP_MC_REGS); + } + + if (IS_ENABLED(CONFIG_ARCH_KIRKWOOD)) + mvebu_mbus_add_range("marvell,kirkwood", 0xf0, 0x01, + MVEBU_REMAP_INT_REG_BASE); + return of_register_fixup(mvebu_mbus_of_fixup, NULL); } pure_initcall(mvebu_mbus_fixup_register); |