diff mbox

[U-Boot,22/27] mips: Ensure stack is at a virtual address

Message ID 20161001141931.32354-23-paul.burton@imgtec.com
State Deferred
Delegated to: Tom Rini
Headers show

Commit Message

Paul Burton Oct. 1, 2016, 2:19 p.m. UTC
In preparation for making CONFIG_SYS_SDRAM_BASE a physical address on
MIPS as README says it should be, ensure that our default
CONFIG_SYS_INIT_SP_ADDR is placed in (c)kseg0 rather than being a simple
offset addition to CONFIG_SYS_SDRAM_BASE.

Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
---

 arch/mips/cpu/start.S | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/arch/mips/cpu/start.S b/arch/mips/cpu/start.S
index 3f0fc12..936d63c 100644
--- a/arch/mips/cpu/start.S
+++ b/arch/mips/cpu/start.S
@@ -8,12 +8,13 @@ 
 
 #include <asm-offsets.h>
 #include <config.h>
+#include <asm/addrspace.h>
 #include <asm/asm.h>
 #include <asm/regdef.h>
 #include <asm/mipsregs.h>
 
 #ifndef CONFIG_SYS_INIT_SP_ADDR
-#define CONFIG_SYS_INIT_SP_ADDR	(CONFIG_SYS_SDRAM_BASE + \
+#define CONFIG_SYS_INIT_SP_ADDR	CKSEG0ADDR(CONFIG_SYS_SDRAM_BASE + \
 				CONFIG_SYS_INIT_SP_OFFSET)
 #endif