summaryrefslogtreecommitdiff
path: root/arch/arm/cpu
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2013-08-22 14:52:02 +0200
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2013-10-17 08:34:45 +0200
commit262f08d6ea18a62f827b8ccb60f355ca2eaf6e2b (patch)
tree3e0018f2503c28f259de50ec637b83ac4969a0a7 /arch/arm/cpu
parent183acb700378a8cfc5d50a01a65de93fb2c24586 (diff)
downloadu-boot-imx-262f08d6ea18a62f827b8ccb60f355ca2eaf6e2b.zip
u-boot-imx-262f08d6ea18a62f827b8ccb60f355ca2eaf6e2b.tar.gz
u-boot-imx-262f08d6ea18a62f827b8ccb60f355ca2eaf6e2b.tar.bz2
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: Sven Schwermer <sven.schwermer@tuhh.de> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'arch/arm/cpu')
-rw-r--r--arch/arm/cpu/armv7/zynq/cpu.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv7/zynq/cpu.c b/arch/arm/cpu/armv7/zynq/cpu.c
index 4914986..2bb3843 100644
--- a/arch/arm/cpu/armv7/zynq/cpu.c
+++ b/arch/arm/cpu/armv7/zynq/cpu.c
@@ -11,6 +11,10 @@
void lowlevel_init(void)
{
+}
+
+int arch_cpu_init(void)
+{
zynq_slcr_unlock();
/* remap DDR to zero, FILTERSTART */
writel(0, &scu_base->filter_start);
@@ -31,6 +35,8 @@ void lowlevel_init(void)
writel(0xC, &slcr_base->ddr_urgent);
zynq_slcr_lock();
+
+ return 0;
}
void reset_cpu(ulong addr)