xref: /OK3568_Linux_fs/u-boot/include/configs/rk3128_common.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /*
2  * (C) Copyright 2017 Rockchip Electronics Co., Ltd
3  *
4  * SPDX-License-Identifier:     GPL-2.0+
5  */
6 
7 #ifndef __CONFIG_RK3128_COMMON_H
8 #define __CONFIG_RK3128_COMMON_H
9 
10 #include "rockchip-common.h"
11 
12 #define CONFIG_SYS_MAXARGS		16
13 #define CONFIG_BAUDRATE			115200
14 #define CONFIG_SYS_MALLOC_LEN		(32 << 20)
15 #define CONFIG_SYS_CBSIZE		1024
16 #define CONFIG_SKIP_LOWLEVEL_INIT
17 
18 #define CONFIG_SYS_TEXT_BASE		0x60000000
19 #define CONFIG_SYS_INIT_SP_ADDR		0x60300000
20 #define CONFIG_SYS_LOAD_ADDR		0x60800800
21 
22 #define GICC_BASE			0x1013A000
23 #define GICD_BASE			0x10139000
24 
25 #define CONFIG_SYS_BOOTM_LEN	(64 << 20)	/* 64M */
26 
27 #define CONFIG_ROCKUSB_G_DNL_PID	0x310C
28 #define TEST_NUM_G
29 
30 /* MMC/SD IP block */
31 #define CONFIG_BOUNCE_BUFFER
32 
33 #define CONFIG_SUPPORT_VFAT
34 #define CONFIG_FS_EXT4
35 
36 /* RAW SD card / eMMC locations. */
37 #define CONFIG_SYS_SPI_U_BOOT_OFFS	(128 << 10)
38 
39 #define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION	1
40 #define CONFIG_SYS_SDRAM_BASE		0x60000000
41 #define SDRAM_MAX_SIZE			0x80000000
42 
43 #ifndef CONFIG_SPL_BUILD
44 #define CONFIG_PREBOOT
45 
46 /* Nand */
47 #define CONFIG_SYS_MAX_NAND_DEVICE	1
48 #define CONFIG_SYS_NAND_ONFI_DETECTION
49 
50 /* usb mass storage */
51 #define CONFIG_USB_FUNCTION_MASS_STORAGE
52 
53 #define ENV_MEM_LAYOUT_SETTINGS1 \
54 	"scriptaddr1=0x60500000\0" \
55 	"pxefile_addr1_r=0x60600000\0" \
56 	"fdt_addr1_r=0x61700000\0" \
57 	"kernel_addr1_r=0x62008000\0" \
58 	"ramdisk_addr1_r=0x63000000\0"
59 
60 #define ENV_MEM_LAYOUT_SETTINGS \
61 	"scriptaddr=0x60500000\0" \
62 	"pxefile_addr_r=0x60600000\0" \
63 	"fdt_addr_r=0x68300000\0" \
64 	"kernel_addr_r=0x62008000\0" \
65 	"ramdisk_addr_r=0x6a200000\0"
66 
67 #include <config_distro_bootcmd.h>
68 #define CONFIG_EXTRA_ENV_SETTINGS \
69 	ENV_MEM_LAYOUT_SETTINGS \
70 	ENV_MEM_LAYOUT_SETTINGS1 \
71 	"partitions=" PARTS_DEFAULT \
72 	ROCKCHIP_DEVICE_SETTINGS \
73 	RKIMG_DET_BOOTDEV \
74 	BOOTENV
75 
76 #endif
77 
78 /* rockchip ohci host driver */
79 #define CONFIG_USB_OHCI_NEW
80 #define CONFIG_SYS_USB_OHCI_MAX_ROOT_PORTS	1
81 
82 #endif
83