xref: /OK3568_Linux_fs/u-boot/include/configs/rk322x_common.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /*
2  * (C) Copyright 2017 Rockchip Electronics Co., Ltd
3  *
4  * SPDX-License-Identifier:     GPL-2.0+
5  */
6 #ifndef __CONFIG_RK322X_COMMON_H
7 #define __CONFIG_RK322X_COMMON_H
8 
9 #include <asm/arch/hardware.h>
10 #include "rockchip-common.h"
11 
12 #define CONFIG_SKIP_LOWLEVEL_INIT
13 #define CONFIG_SYS_MALLOC_LEN		(32 << 20)
14 #define CONFIG_SYS_CBSIZE		2048
15 #define CONFIG_SYS_BOOTM_LEN	(64 << 20)	/*  64M */
16 
17 
18 #define CONFIG_SPL_FRAMEWORK
19 #define CONFIG_SYS_TEXT_BASE		0x60200000
20 #define CONFIG_SYS_INIT_SP_ADDR		0x60400000
21 #define CONFIG_SYS_LOAD_ADDR		0x61800800
22 #define CONFIG_SPL_TEXT_BASE		0x60000000
23 
24 #define GICD_BASE                 	0x32011000
25 #define GICC_BASE                  	0x32012000
26 
27 #define CONFIG_ROCKCHIP_MAX_INIT_SIZE	(28 << 10)
28 #define CONFIG_ROCKCHIP_CHIP_TAG	"RK32"
29 #define CONFIG_ROCKUSB_G_DNL_PID	0x320B
30 
31 /* MMC/SD IP block */
32 #define CONFIG_BOUNCE_BUFFER
33 
34 #define CONFIG_SYS_SDRAM_BASE		0x60000000
35 #define SDRAM_BANK_SIZE			(512UL << 20UL)
36 #define SDRAM_MAX_SIZE			0x80000000
37 
38 #ifndef CONFIG_SPL_BUILD
39 
40 /* usb mass storage */
41 #define CONFIG_USB_FUNCTION_MASS_STORAGE
42 
43 /* usb host */
44 #define ENV_MEM_LAYOUT_SETTINGS \
45 	"scriptaddr=0x60000000\0" \
46 	"pxefile_addr_r=0x60100000\0" \
47 	"fdt_addr_r=0x68300000\0" \
48 	"kernel_addr_r=0x62008000\0" \
49 	"ramdisk_addr_r=0x6a200000\0"
50 
51 #include <config_distro_bootcmd.h>
52 
53 #define CONFIG_EXTRA_ENV_SETTINGS \
54 	"partitions=" PARTS_DEFAULT \
55 	ENV_MEM_LAYOUT_SETTINGS \
56 	ROCKCHIP_DEVICE_SETTINGS \
57 	RKIMG_DET_BOOTDEV \
58 	BOOTENV
59 #endif
60 
61 #define CONFIG_PREBOOT
62 
63 #endif
64