aboutsummaryrefslogtreecommitdiff
path: root/arch/arm/mach-rockchip
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-rockchip')
-rw-r--r--arch/arm/mach-rockchip/Kconfig2
-rwxr-xr-xarch/arm/mach-rockchip/fit_spl_optee.sh12
-rwxr-xr-xarch/arm/mach-rockchip/make_fit_atf.py2
3 files changed, 11 insertions, 5 deletions
diff --git a/arch/arm/mach-rockchip/Kconfig b/arch/arm/mach-rockchip/Kconfig
index d8d68ba447..b689a420bd 100644
--- a/arch/arm/mach-rockchip/Kconfig
+++ b/arch/arm/mach-rockchip/Kconfig
@@ -306,7 +306,7 @@ config SPL_ROCKCHIP_COMMON_BOARD
no TPL for the board.
config TPL_ROCKCHIP_COMMON_BOARD
- bool ""
+ bool "Rockchip TPL common board file"
depends on TPL
help
Rockchip SoCs have similar boot process, prefer to use TPL for DRAM
diff --git a/arch/arm/mach-rockchip/fit_spl_optee.sh b/arch/arm/mach-rockchip/fit_spl_optee.sh
index 89ef04312c..4118472d9f 100755
--- a/arch/arm/mach-rockchip/fit_spl_optee.sh
+++ b/arch/arm/mach-rockchip/fit_spl_optee.sh
@@ -17,6 +17,12 @@ if [ ! -f $TEE ]; then
fi
dtname=$1
+text_base=`sed -n "/SYS_TEXT_BASE=/s/CONFIG_SYS_TEXT_BASE=//p" .config \
+ |tr -d '\r'`
+dram_base=`sed -n "/SYS_SDRAM_BASE=/s/CONFIG_SYS_SDRAM_BASE=//p" \
+ include/autoconf.mk|tr -d '\r'`
+tee_base=`echo "obase=16;$(($dram_base+0x8400000))"|bc`
+tee_base='0x'$tee_base
cat << __HEADER_EOF
/*
@@ -39,7 +45,7 @@ cat << __HEADER_EOF
os = "U-Boot";
arch = "arm";
compression = "none";
- load = <0x61000000>;
+ load = <$text_base>;
};
optee {
description = "OP-TEE";
@@ -48,8 +54,8 @@ cat << __HEADER_EOF
arch = "arm";
os = "tee";
compression = "none";
- load = <0x68400000>;
- entry = <0x68400000>;
+ load = <$tee_base>;
+ entry = <$tee_base>;
};
fdt {
description = "$(basename $dtname .dtb)";
diff --git a/arch/arm/mach-rockchip/make_fit_atf.py b/arch/arm/mach-rockchip/make_fit_atf.py
index 3c045a5e17..c79317d6c5 100755
--- a/arch/arm/mach-rockchip/make_fit_atf.py
+++ b/arch/arm/mach-rockchip/make_fit_atf.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python3
"""
# SPDX-License-Identifier: GPL-2.0+
#