Skip to content
Snippets Groups Projects
Commit 262f08d6 authored by Michal Simek's avatar Michal Simek Committed by Albert ARIBAUD
Browse files

zynq: Use arch_cpu_init() instead of lowlevel_init()


Zynq lowlevel_init() was implemented in C but stack
pointer is setup after function call in _main().
Move architecture setup to arch_cpu_init() which is call
as the first function in board_init_f() which
already have correct stack pointer.

Reported-by: default avatarSven Schwermer <sven.schwermer@tuhh.de>
Signed-off-by: default avatarMichal Simek <michal.simek@xilinx.com>
parent 183acb70
No related branches found
No related tags found
No related merge requests found
...@@ -10,6 +10,10 @@ ...@@ -10,6 +10,10 @@
#include <asm/arch/hardware.h> #include <asm/arch/hardware.h>
void lowlevel_init(void) void lowlevel_init(void)
{
}
int arch_cpu_init(void)
{ {
zynq_slcr_unlock(); zynq_slcr_unlock();
/* remap DDR to zero, FILTERSTART */ /* remap DDR to zero, FILTERSTART */
...@@ -31,6 +35,8 @@ void lowlevel_init(void) ...@@ -31,6 +35,8 @@ void lowlevel_init(void)
writel(0xC, &slcr_base->ddr_urgent); writel(0xC, &slcr_base->ddr_urgent);
zynq_slcr_lock(); zynq_slcr_lock();
return 0;
} }
void reset_cpu(ulong addr) void reset_cpu(ulong addr)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment