Merge tag 'socfpga_fixes_for_v4.0' of git://git.rocketboards.org/linux-socfpga-next...
authorArnd Bergmann <arnd@arndb.de>
Wed, 11 Mar 2015 14:31:27 +0000 (15:31 +0100)
committerArnd Bergmann <arnd@arndb.de>
Wed, 11 Mar 2015 14:31:27 +0000 (15:31 +0100)
Pull "Fixes for v4.0 on the SoCFPGA platform" from Dinh Nguyen:

- Fix the SCU virtual mapping
- Add misssing DMA channels for UART nodes
- Fix a sporadic SMP error where CPU1 was not seeing its start address

* tag 'socfpga_fixes_for_v4.0' of git://git.rocketboards.org/linux-socfpga-next:
  ARM: socfpga: make sure socfpga_cpu1start_addr is properly flushed
  ARM: socfpga: fix uart DMA binding error
  ARM: socfpga: Correct SCU virtual mapping in socfpga

arch/arm/boot/dts/socfpga.dtsi
arch/arm/mach-socfpga/core.h
arch/arm/mach-socfpga/socfpga.c

index 252c3d1..9d87609 100644 (file)
                        reg-shift = <2>;
                        reg-io-width = <4>;
                        clocks = <&l4_sp_clk>;
+                       dmas = <&pdma 28>,
+                              <&pdma 29>;
+                       dma-names = "tx", "rx";
                };
 
                uart1: serial1@ffc03000 {
                        reg-shift = <2>;
                        reg-io-width = <4>;
                        clocks = <&l4_sp_clk>;
+                       dmas = <&pdma 30>,
+                              <&pdma 31>;
+                       dma-names = "tx", "rx";
                };
 
                rst: rstmgr@ffd05000 {
index 483cb46..a0f3b1c 100644 (file)
@@ -45,6 +45,6 @@ extern char secondary_trampoline, secondary_trampoline_end;
 
 extern unsigned long socfpga_cpu1start_addr;
 
-#define SOCFPGA_SCU_VIRT_BASE   0xfffec000
+#define SOCFPGA_SCU_VIRT_BASE   0xfee00000
 
 #endif
index 383d61e..f5e597c 100644 (file)
@@ -23,6 +23,7 @@
 #include <asm/hardware/cache-l2x0.h>
 #include <asm/mach/arch.h>
 #include <asm/mach/map.h>
+#include <asm/cacheflush.h>
 
 #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");