Commit 006ab58d4636124f617174fa2dfe24739874ee91

Authored by Kever Yang
1 parent 4b294886d0

rockchip: rk3399: update SPL_STACK_R_ADDR

Use the same SPL_STACK_R_ADDR in Kconfig instead of each board config;
default to 0x4000000(64MB) instead of 0x80000(512KB) for this address
can support all the SoCs including those may have only 64MB memory, and
also reserve enough space for atf, kernel(in falcon mode) loading.

After the ATF entry move to 0x40000, the stack from 0x80000 may be override
when loading ATF bl31.

Signed-off-by: Kever Yang <kever.yang@rock-chips.com>

Showing 18 changed files with 3 additions and 17 deletions Side-by-side Diff

arch/arm/mach-rockchip/rk3399/Kconfig
... ... @@ -91,6 +91,9 @@
91 91 config TPL_TEXT_BASE
92 92 default 0xff8c2000
93 93  
  94 +config SPL_STACK_R_ADDR
  95 + default 0x04000000
  96 +
94 97 source "board/rockchip/evb_rk3399/Kconfig"
95 98 source "board/theobroma-systems/puma_rk3399/Kconfig"
96 99 source "board/vamrs/rock960_rk3399/Kconfig"
configs/chromebook_bob_defconfig
... ... @@ -8,7 +8,6 @@
8 8 # CONFIG_SPL_MMC_SUPPORT is not set
9 9 CONFIG_TARGET_CHROMEBOOK_BOB=y
10 10 CONFIG_NR_DRAM_BANKS=1
11   -CONFIG_SPL_STACK_R_ADDR=0x80000
12 11 CONFIG_DEBUG_UART_BASE=0xff1a0000
13 12 CONFIG_DEBUG_UART_CLOCK=24000000
14 13 CONFIG_SPL_SPI_FLASH_SUPPORT=y
configs/evb-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/ficus-rk3399_defconfig
... ... @@ -4,7 +4,6 @@
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_ROCKCHIP_SPL_RESERVE_IRAM=0x4000
6 6 CONFIG_TARGET_ROCK960_RK3399=y
7   -CONFIG_SPL_STACK_R_ADDR=0x80000
8 7 CONFIG_DEBUG_UART_BASE=0xFF1A0000
9 8 CONFIG_DEBUG_UART_CLOCK=24000000
10 9 CONFIG_DEBUG_UART=y
configs/firefly-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/khadas-edge-captain-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/khadas-edge-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/khadas-edge-v-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/leez-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/nanopc-t4-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/nanopi-m4-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/nanopi-neo4-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/orangepi-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/puma-rk3399_defconfig
... ... @@ -6,7 +6,6 @@
6 6 CONFIG_ROCKCHIP_BOOT_MODE_REG=0x0
7 7 CONFIG_TARGET_PUMA_RK3399=y
8 8 CONFIG_NR_DRAM_BANKS=1
9   -CONFIG_SPL_STACK_R_ADDR=0x80000
10 9 CONFIG_DEBUG_UART_BASE=0xFF180000
11 10 CONFIG_DEBUG_UART_CLOCK=24000000
12 11 CONFIG_SPL_SPI_FLASH_SUPPORT=y
configs/roc-rk3399-pc_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/rock-pi-4-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y
configs/rock960-rk3399_defconfig
... ... @@ -4,7 +4,6 @@
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_ROCKCHIP_SPL_RESERVE_IRAM=0x4000
6 6 CONFIG_TARGET_ROCK960_RK3399=y
7   -CONFIG_SPL_STACK_R_ADDR=0x80000
8 7 CONFIG_DEBUG_UART_BASE=0xFF1A0000
9 8 CONFIG_DEBUG_UART_CLOCK=24000000
10 9 CONFIG_DEBUG_UART=y
configs/rockpro64-rk3399_defconfig
... ... @@ -3,7 +3,6 @@
3 3 CONFIG_SYS_TEXT_BASE=0x00200000
4 4 CONFIG_ROCKCHIP_RK3399=y
5 5 CONFIG_NR_DRAM_BANKS=1
6   -CONFIG_SPL_STACK_R_ADDR=0x80000
7 6 CONFIG_DEBUG_UART_BASE=0xFF1A0000
8 7 CONFIG_DEBUG_UART_CLOCK=24000000
9 8 CONFIG_DEBUG_UART=y