4580b8d627624ef1618f9b8f92459ae33305f681
[openwrt/staging/yousong.git] / package / boot / uboot-sunxi / patches / 002-pcduino3.patch
1 diff -ruN u-boot-2014.01-rc1.old/board/sunxi/dram_pcduino3.c u-boot-2014.01-rc1/board/sunxi/dram_pcduino3.c
2 --- u-boot-2014.01-rc1.old/board/sunxi/dram_pcduino3.c 1970-01-01 01:00:00.000000000 +0100
3 +++ u-boot-2014.01-rc1/board/sunxi/dram_pcduino3.c 2014-04-23 20:04:00.919994615 +0200
4 @@ -0,0 +1,31 @@
5 +/* this file is generated, don't edit it yourself */
6 +
7 +#include <common.h>
8 +#include <asm/arch/dram.h>
9 +
10 +static struct dram_para dram_para = {
11 + .clock = 480,
12 + .type = 3,
13 + .rank_num = 1,
14 + .density = 4096,
15 + .io_width = 16,
16 + .bus_width = 32,
17 + .cas = 9,
18 + .zq = 0x7a,
19 + .odt_en = 0,
20 + .size = 1024,
21 + .tpr0 = 0x42d899b7,
22 + .tpr1 = 0xa090,
23 + .tpr2 = 0x22a00,
24 + .tpr3 = 0,
25 + .tpr4 = 0,
26 + .tpr5 = 0,
27 + .emr1 = 0x4,
28 + .emr2 = 0x10,
29 + .emr3 = 0x0,
30 +};
31 +
32 +unsigned long sunxi_dram_init(void)
33 +{
34 + return dramc_init(&dram_para);
35 +}
36 diff -ruN u-boot-2014.01-rc1.old/board/sunxi/Makefile u-boot-2014.01-rc1/board/sunxi/Makefile
37 --- u-boot-2014.01-rc1.old/board/sunxi/Makefile 2014-04-12 18:51:34.000000000 +0200
38 +++ u-boot-2014.01-rc1/board/sunxi/Makefile 2014-04-23 20:02:51.828839920 +0200
39 @@ -73,6 +73,7 @@
40 obj-$(CONFIG_MK802II) += dram_sun4i_408_1024_iow8.o
41 obj-$(CONFIG_MK802II_A20) += dram_mk802ii_a20.o
42 obj-$(CONFIG_PCDUINO) += dram_sun4i_408_1024_iow8.o
43 +obj-$(CONFIG_PCDUINO3) += dram_pcduino3.o
44 obj-$(CONFIG_PENGPOD700) += dram_sun4i_384_1024_iow8.o
45 obj-$(CONFIG_PENGPOD1000) += dram_sun4i_408_1024_iow16.o
46 obj-$(CONFIG_POV_PROTAB2) += dram_pov_protab2.o
47 diff -ruN u-boot-2014.01-rc1.old/boards.cfg u-boot-2014.01-rc1/boards.cfg
48 --- u-boot-2014.01-rc1.old/boards.cfg 2014-04-12 18:51:34.000000000 +0200
49 +++ u-boot-2014.01-rc1/boards.cfg 2014-04-23 20:02:27.897132713 +0200
50 @@ -404,6 +404,7 @@
51 Active arm armv7 sunxi - sunxi mk802ii_A20 sun7i:MK802II_A20,SPL -
52 Active arm armv7 sunxi - sunxi mk802ii sun4i:MK802II,SPL -
53 Active arm armv7 sunxi - sunxi pcDuino sun4i:PCDUINO,SPL,SUNXI_EMAC -
54 +Active arm armv7 sunxi - sunxi pcDuino3 sun7i:PCDUINO3,SPL,SUNXI_EMAC,FAST_MBUS -
55 Active arm armv7 sunxi - sunxi pengpod1000 sun4i:PENGPOD1000,SPL -
56 Active arm armv7 sunxi - sunxi pengpod700 sun4i:PENGPOD700,SPL -
57 Active arm armv7 sunxi - sunxi PoV_ProTab2_IPS9 sun4i:POV_PROTAB2,SPL -