summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRob Herring <rob.herring@calxeda.com>2012-02-01 16:57:55 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-03-28 23:31:23 +0200
commit0c34e69f57ad94e0ba66ace657eda2fb80bc5847 (patch)
tree7bc4a2a27bcd91a363c38aca031d449eb161ecd4
parent877012df309329a9264e6e9558d4f71bfa0cddbe (diff)
downloadtalos-obmc-uboot-0c34e69f57ad94e0ba66ace657eda2fb80bc5847.tar.gz
talos-obmc-uboot-0c34e69f57ad94e0ba66ace657eda2fb80bc5847.zip
ARM: highbank: add reset support
Implement reset for highbank platform. Reset is triggered via a wfi instruction, so enabling armv7 for the compiler is necessary. Signed-off-by: Rob Herring <rob.herring@calxeda.com>
-rw-r--r--arch/arm/cpu/armv7/highbank/config.mk1
-rw-r--r--board/highbank/highbank.c8
2 files changed, 9 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv7/highbank/config.mk b/arch/arm/cpu/armv7/highbank/config.mk
new file mode 100644
index 0000000000..935a147c59
--- /dev/null
+++ b/arch/arm/cpu/armv7/highbank/config.mk
@@ -0,0 +1 @@
+PLATFORM_CPPFLAGS += -march=armv7-a
diff --git a/board/highbank/highbank.c b/board/highbank/highbank.c
index 096e2f6372..1e2da783c6 100644
--- a/board/highbank/highbank.c
+++ b/board/highbank/highbank.c
@@ -23,6 +23,12 @@
#include <asm/sizes.h>
#include <asm/io.h>
+#define HB_SREG_A9_PWR_REQ 0xfff3cf00
+#define HB_PWR_SUSPEND 0
+#define HB_PWR_SOFT_RESET 1
+#define HB_PWR_HARD_RESET 2
+#define HB_PWR_SHUTDOWN 3
+
DECLARE_GLOBAL_DATA_PTR;
/*
@@ -68,4 +74,6 @@ void dram_init_banksize(void)
void reset_cpu(ulong addr)
{
+ writel(HB_PWR_HARD_RESET, HB_SREG_A9_PWR_REQ);
+ asm(" wfi");
}
OpenPOWER on IntegriCloud