summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorKevin Smith <kevin.smith@elecsyscorp.com>2015-05-18 16:09:44 +0000
committerLuka Perkov <luka.perkov@sartura.hr>2015-06-14 17:48:28 +0200
commite1b078e06c8be4c1991132fdc4cb8ca996ab2c4c (patch)
treeb2e5315fec85bed34d3d69900201949b4fa28f97 /arch
parent5730360efc153aefaddb980287a3b3c8eab26351 (diff)
downloadtalos-obmc-uboot-e1b078e06c8be4c1991132fdc4cb8ca996ab2c4c.tar.gz
talos-obmc-uboot-e1b078e06c8be4c1991132fdc4cb8ca996ab2c4c.zip
arm: mvebu: Update CBAR with SOC regs base
SMP-enabled Linux kernels read the CBAR register in CP15 to find the address of the SCU registers. After remapping internal registers, also update the CBAR so the kernel can find them. Signed-off-by: Kevin Smith <kevin.smith@elecsyscorp.com> Acked-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-mvebu/cpu.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/arm/mach-mvebu/cpu.c b/arch/arm/mach-mvebu/cpu.c
index 417fc35149..0121db8bb5 100644
--- a/arch/arm/mach-mvebu/cpu.c
+++ b/arch/arm/mach-mvebu/cpu.c
@@ -161,10 +161,17 @@ static void update_sdram_window_sizes(void)
}
#ifdef CONFIG_ARCH_CPU_INIT
+static void set_cbar(u32 addr)
+{
+ asm("mcr p15, 4, %0, c15, c0" : : "r" (addr));
+}
+
+
int arch_cpu_init(void)
{
/* Linux expects the internal registers to be at 0xf1000000 */
writel(SOC_REGS_PHY_BASE, INTREG_BASE_ADDR_REG);
+ set_cbar(SOC_REGS_PHY_BASE + 0xC000);
/*
* We need to call mvebu_mbus_probe() before calling
OpenPOWER on IntegriCloud