[U-Boot] [PATCH 19/22] ARM sunxi: SPL support for MK802 board

Henrik Nordström henrik at henriknordstrom.net
Sun Nov 25 12:46:13 CET 2012


From: Sergey Lapin <slapin at ossfans.org>
Signed-off-by: Henrik Nordstrom <henrik at henriknordstrom.net>
---
 board/sunxi/Makefile     |    1 +
 board/sunxi/dram_mk802.c |   24 ++++++++++++++++++++++++
 boards.cfg               |    1 +
 3 files changed, 26 insertions(+), 0 deletions(-)
 create mode 100644 board/sunxi/dram_mk802.c

diff --git a/board/sunxi/Makefile b/board/sunxi/Makefile
index 091db59..b3a40f4 100644
--- a/board/sunxi/Makefile
+++ b/board/sunxi/Makefile
@@ -34,6 +34,7 @@ COBJS-$(CONFIG_HACKBERRY)	+= dram_hackberry.o
 COBJS-$(CONFIG_MELE_A1000)	+= dram_mele_a1000.o
 COBJS-$(CONFIG_MINI_X)		+= dram_mini_x.o
 COBJS-$(CONFIG_A7HD)		+= dram_hyundai_a7hd.o
+COBJS-$(CONFIG_MK802)		+= dram_mk802.o
 
 COBJS	:= $(COBJS-y)
 SRCS 	:= $(COBJS:.o=.c)
diff --git a/board/sunxi/dram_mk802.c b/board/sunxi/dram_mk802.c
new file mode 100644
index 0000000..a6779b0
--- /dev/null
+++ b/board/sunxi/dram_mk802.c
@@ -0,0 +1,24 @@
+/* this file is generated, don't edit it yourself */
+
+#include <common.h>
+#include <asm/arch/dram.h>
+
+static struct dram_para dram_para = {
+	.clock = 360,
+	.type = 3,
+	.rank_num = 1,
+	.density = 2048,
+	.io_width = 16,
+	.bus_width = 32,
+	.cas = 6,
+	.zq = 123,
+	.size = 512,
+	.tpr0 = 0x30926692,
+	.tpr1 = 0x1090,
+	.tpr2 = 0x1a0c8,
+};
+
+int sunxi_dram_init(void)
+{
+	return dramc_init(&dram_para);
+}
diff --git a/boards.cfg b/boards.cfg
index b8a5375..12fbcc9 100644
--- a/boards.cfg
+++ b/boards.cfg
@@ -300,6 +300,7 @@ sun4i                        arm         armv7       sunxi               -
 sun4i_sdcon                  arm         armv7       sunxi               -              sunxi       sun4i:UART0_PORT_F
 sun5i                        arm         armv7       sunxi               -              sunxi       sun5i
 sun5i_sdcon                  arm         armv7       sunxi               -              sunxi       sun5i:UART0_PORT_F
+mk802                        arm         armv7       sunxi               -              sunxi       sun4i:MK802,SPL
 kzm9g                        arm         armv7       kzm9g               kmc            rmobile
 armadillo-800eva             arm         armv7       armadillo-800eva    atmark-techno  rmobile
 zynq                         arm         armv7       zynq                xilinx         zynq
-- 
1.7.7.6




More information about the U-Boot mailing list