powerpc: Stack Pointer not properly aligned
The code first aligns the SP to 16 then subtract 8, making it 8 bytes aligned. Furthermore the initial stack frame not quite correct either. Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se> Signed-off-by: Andy Fleming <afleming@freescale.com>
This commit is contained in:
parent
89f4289958
commit
7de8a7169e
|
@ -521,9 +521,8 @@ void board_init_f(ulong bootflag)
|
||||||
addr_sp -= 16;
|
addr_sp -= 16;
|
||||||
addr_sp &= ~0xF;
|
addr_sp &= ~0xF;
|
||||||
s = (ulong *) addr_sp;
|
s = (ulong *) addr_sp;
|
||||||
*s-- = 0;
|
*s = 0; /* Terminate back chain */
|
||||||
*s-- = 0;
|
*++s = 0; /* NULL return address */
|
||||||
addr_sp = (ulong) s;
|
|
||||||
debug("Stack Pointer at: %08lx\n", addr_sp);
|
debug("Stack Pointer at: %08lx\n", addr_sp);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in New Issue