xref: /rk3399_rockchip-uboot/include/configs/stm32f746-disco.h (revision 1f20fc53b382ece8da7440f354b219deb7ed19df)
1e66c49faSVikas Manocha /*
2e66c49faSVikas Manocha  * (C) Copyright 2016
3e66c49faSVikas Manocha  * Vikas Manocha, <vikas.manocha@st.com>
4e66c49faSVikas Manocha  *
5e66c49faSVikas Manocha  * SPDX-License-Identifier:	GPL-2.0+
6e66c49faSVikas Manocha  */
7e66c49faSVikas Manocha 
8e66c49faSVikas Manocha #ifndef __CONFIG_H
9e66c49faSVikas Manocha #define __CONFIG_H
10e66c49faSVikas Manocha 
11e66c49faSVikas Manocha #define CONFIG_SYS_FLASH_BASE		0x08000000
12e66c49faSVikas Manocha #define CONFIG_SYS_INIT_SP_ADDR		0x20050000
13b9747696SVikas Manocha 
14b9747696SVikas Manocha #ifdef CONFIG_SUPPORT_SPL
15*1a73bd84SVikas Manocha #define CONFIG_SYS_TEXT_BASE		0x08008000
16*1a73bd84SVikas Manocha #define CONFIG_SYS_LOAD_ADDR		0x08008000
17b9747696SVikas Manocha #else
18b9747696SVikas Manocha #define CONFIG_SYS_TEXT_BASE		CONFIG_SYS_FLASH_BASE
19*1a73bd84SVikas Manocha #define CONFIG_SYS_LOAD_ADDR		0xC0400000
20*1a73bd84SVikas Manocha #define CONFIG_LOADADDR			0xC0400000
21b9747696SVikas Manocha #endif
22e66c49faSVikas Manocha 
23e66c49faSVikas Manocha /*
24e66c49faSVikas Manocha  * Configuration of the external SDRAM memory
25e66c49faSVikas Manocha  */
26e66c49faSVikas Manocha #define CONFIG_NR_DRAM_BANKS		1
27e66c49faSVikas Manocha 
28adcc90b4SVikas Manocha #define CONFIG_SYS_MAX_FLASH_SECT	8
29adcc90b4SVikas Manocha #define CONFIG_SYS_MAX_FLASH_BANKS	1
30e66c49faSVikas Manocha 
31e66c49faSVikas Manocha #define CONFIG_ENV_SIZE			(8 << 10)
32e66c49faSVikas Manocha 
33adcc90b4SVikas Manocha #define CONFIG_STM32_FLASH
34e66c49faSVikas Manocha 
35b20b70fcSMichael Kurz #define CONFIG_DW_GMAC_DEFAULT_DMA_PBL	(8)
36b20b70fcSMichael Kurz #define CONFIG_DW_ALTDESCRIPTOR
37b20b70fcSMichael Kurz #define CONFIG_MII
38fc0d3dbcSMichael Kurz #define CONFIG_PHY_SMSC
39b20b70fcSMichael Kurz 
40ba0a3c16SToshifumi NISHINAGA #define CONFIG_STM32_HSE_HZ		25000000
41ba0a3c16SToshifumi NISHINAGA #define CONFIG_SYS_CLK_FREQ		200000000 /* 200 MHz */
42e66c49faSVikas Manocha #define CONFIG_SYS_HZ_CLOCK		1000000	/* Timer is clocked at 1MHz */
43e66c49faSVikas Manocha 
44e66c49faSVikas Manocha #define CONFIG_CMDLINE_TAG
45e66c49faSVikas Manocha #define CONFIG_SETUP_MEMORY_TAGS
46e66c49faSVikas Manocha #define CONFIG_INITRD_TAG
47e66c49faSVikas Manocha #define CONFIG_REVISION_TAG
48e66c49faSVikas Manocha 
49e66c49faSVikas Manocha #define CONFIG_SYS_CBSIZE		1024
50e66c49faSVikas Manocha 
51b20b70fcSMichael Kurz #define CONFIG_SYS_MALLOC_LEN		(1 * 1024 * 1024)
52e66c49faSVikas Manocha 
53e66c49faSVikas Manocha #define CONFIG_BOOTCOMMAND						\
54e66c49faSVikas Manocha 	"run bootcmd_romfs"
55e66c49faSVikas Manocha 
56e66c49faSVikas Manocha #define CONFIG_EXTRA_ENV_SETTINGS \
57e66c49faSVikas Manocha 	"bootargs_romfs=uclinux.physaddr=0x08180000 root=/dev/mtdblock0\0" \
58e66c49faSVikas Manocha 	"bootcmd_romfs=setenv bootargs ${bootargs} ${bootargs_romfs};" \
59e66c49faSVikas Manocha 	"bootm 0x08044000 - 0x08042000\0"
60e66c49faSVikas Manocha 
61e66c49faSVikas Manocha 
62e66c49faSVikas Manocha /*
63e66c49faSVikas Manocha  * Command line configuration.
64e66c49faSVikas Manocha  */
65e66c49faSVikas Manocha #define CONFIG_SYS_LONGHELP
66e66c49faSVikas Manocha #define CONFIG_AUTO_COMPLETE
67e66c49faSVikas Manocha #define CONFIG_CMDLINE_EDITING
68dc11d83aSVikas Manocha #define CONFIG_CMD_CACHE
692f80a9f7SVikas Manocha #define CONFIG_BOARD_LATE_INIT
70a241c241SVikas Manocha #define CONFIG_DISPLAY_BOARDINFO
71b9747696SVikas Manocha 
72b9747696SVikas Manocha /* For SPL */
73b9747696SVikas Manocha #ifdef CONFIG_SUPPORT_SPL
74b9747696SVikas Manocha #define CONFIG_SPL_STACK		CONFIG_SYS_INIT_SP_ADDR
75b9747696SVikas Manocha #define CONFIG_SPL_FRAMEWORK
76b9747696SVikas Manocha #define CONFIG_SPL_BOARD_INIT
77b9747696SVikas Manocha #define CONFIG_SPL_TEXT_BASE		CONFIG_SYS_FLASH_BASE
78b9747696SVikas Manocha #define CONFIG_SYS_MONITOR_LEN		(512 * 1024)
79b9747696SVikas Manocha #define CONFIG_SYS_SPL_LEN		0x00008000
80*1a73bd84SVikas Manocha #define CONFIG_SYS_UBOOT_START		0x080083FD
81b9747696SVikas Manocha #define CONFIG_SYS_UBOOT_BASE		(CONFIG_SYS_FLASH_BASE + \
82b9747696SVikas Manocha 					 CONFIG_SYS_SPL_LEN)
8355a3ef71SVikas Manocha 
8455a3ef71SVikas Manocha /* DT blob (fdt) address */
8555a3ef71SVikas Manocha #define CONFIG_SYS_FDT_BASE		(CONFIG_SYS_FLASH_BASE + \
8655a3ef71SVikas Manocha 					0x1C0000)
87b9747696SVikas Manocha #endif
88b9747696SVikas Manocha /* For SPL ends */
89b9747696SVikas Manocha 
90e66c49faSVikas Manocha #endif /* __CONFIG_H */
91