From: Russell King Date: Wed, 25 Feb 2015 16:24:25 +0000 (-0600) Subject: ARM: socfpga: make sure socfpga_cpu1start_addr is properly flushed X-Git-Tag: firefly_0821_release~176^2~2154^2~8^2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=cee9b8d6b8b7d82bfb34e4700d839aec76519f02;hp=78c03c7af89721bd8a4428408a8cc7b53972e4b8;p=firefly-linux-kernel-4.4.55.git ARM: socfpga: make sure socfpga_cpu1start_addr is properly flushed Make sure socfpga_cpu1start_addr is properly flushed from it's cache line so that secondary cpu's can see it. Signed-off-by: Russell King Tested-by: Steffen Trumtrar Signed-off-by: Dinh Nguyen --- diff --git a/arch/arm/mach-socfpga/socfpga.c b/arch/arm/mach-socfpga/socfpga.c index 383d61e138af..f5e597c207b9 100644 --- a/arch/arm/mach-socfpga/socfpga.c +++ b/arch/arm/mach-socfpga/socfpga.c @@ -23,6 +23,7 @@ #include #include #include +#include #include "core.h" @@ -73,6 +74,10 @@ void __init socfpga_sysmgr_init(void) (u32 *) &socfpga_cpu1start_addr)) pr_err("SMP: Need cpu1-start-addr in device tree.\n"); + /* Ensure that socfpga_cpu1start_addr is visible to other CPUs */ + smp_wmb(); + sync_cache_w(&socfpga_cpu1start_addr); + sys_manager_base_addr = of_iomap(np, 0); np = of_find_compatible_node(NULL, NULL, "altr,rst-mgr");