tfa-layerscape: bump to LSDK-21.08

Update tfa package to latest LSDK-21.08.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
This commit is contained in:
Martin Schiller 2021-10-11 12:43:55 +02:00 committed by Hauke Mehrtens
parent 674af9c1f6
commit 294140c124
4 changed files with 60 additions and 56 deletions

View file

@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=tfa-layerscape PKG_NAME:=tfa-layerscape
PKG_VERSION:=LSDK-20.12 PKG_VERSION:=LSDK-21.08
PKG_RELEASE:=$(AUTORELEASE) PKG_RELEASE:=$(AUTORELEASE)
PKG_SOURCE_PROTO:=git PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://source.codeaurora.org/external/qoriq/qoriq-components/atf PKG_SOURCE_URL:=https://source.codeaurora.org/external/qoriq/qoriq-components/atf
PKG_SOURCE_VERSION:=LSDK-20.12 PKG_SOURCE_VERSION:=LSDK-21.08
PKG_MIRROR_HASH:=8e3a0bd33c00657beeb2df88a881b1831aeb790751cacd4c4fdf33ffa01e956e PKG_MIRROR_HASH:=500da1f5743255b2c301b89fba4df31d05a7dfbc731fbf137a88caf86f5568d0
PKG_BUILD_DEPENDS:=tfa-layerscape/host PKG_BUILD_DEPENDS:=tfa-layerscape/host
include $(INCLUDE_DIR)/host-build.mk include $(INCLUDE_DIR)/host-build.mk
@ -27,14 +27,14 @@ define Host/Compile
CFLAGS="$(HOST_CFLAGS)" \ CFLAGS="$(HOST_CFLAGS)" \
LDFLAGS="$(HOST_LDFLAGS)" LDFLAGS="$(HOST_LDFLAGS)"
$(MAKE) -C \ $(MAKE) -C \
$(HOST_BUILD_DIR)/plat/nxp/tools \ $(HOST_BUILD_DIR)/tools/nxp \
CFLAGS="$(HOST_CFLAGS)" CFLAGS="$(HOST_CFLAGS)"
endef endef
define Host/Install define Host/Install
$(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/fiptool/fiptool $(STAGING_DIR_HOST)/bin/fiptool-layerscape $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/fiptool/fiptool $(STAGING_DIR_HOST)/bin/fiptool-layerscape
$(INSTALL_BIN) $(HOST_BUILD_DIR)/plat/nxp/tools/create_pbl $(STAGING_DIR_HOST)/bin/tfa-create-pbl $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/nxp/create_pbl $(STAGING_DIR_HOST)/bin/tfa-create-pbl
$(INSTALL_BIN) $(HOST_BUILD_DIR)/plat/nxp/tools/byte_swap $(STAGING_DIR_HOST)/bin/tfa-byte-swap $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/nxp/byte_swap $(STAGING_DIR_HOST)/bin/tfa-byte-swap
endef endef
define Package/tfa-generic define Package/tfa-generic

View file

@ -1,32 +1,45 @@
--- a/Makefile --- a/Makefile
+++ b/Makefile +++ b/Makefile
@@ -448,10 +448,6 @@ endif @@ -801,10 +801,6 @@ CRTTOOL ?= ${CRTTOOLPATH}/cert_create$
CRTTOOLPATH ?= tools/cert_create ENCTOOLPATH ?= tools/encrypt_fw
CRTTOOL ?= ${CRTTOOLPATH}/cert_create${BIN_EXT} ENCTOOL ?= ${ENCTOOLPATH}/encrypt_fw${BIN_EXT}
-# Variables for use with Firmware Image Package -# Variables for use with Firmware Image Package
-FIPTOOLPATH ?= tools/fiptool -FIPTOOLPATH ?= tools/fiptool
-FIPTOOL ?= ${FIPTOOLPATH}/fiptool${BIN_EXT} -FIPTOOL ?= ${FIPTOOLPATH}/fiptool${BIN_EXT}
- -
################################################################################ # Variables for use with sptool
# Include BL specific makefiles SPTOOLPATH ?= tools/sptool
################################################################################ SPTOOL ?= ${SPTOOLPATH}/sptool${BIN_EXT}
@@ -661,14 +657,12 @@ endif @@ -1160,13 +1156,6 @@ endif
clean: clean:
@echo " CLEAN" @echo " CLEAN"
$(call SHELL_REMOVE_DIR,${BUILD_PLAT}) $(call SHELL_REMOVE_DIR,${BUILD_PLAT})
-ifdef UNIX_MK
- ${Q}${MAKE} --no-print-directory -C ${FIPTOOLPATH} clean - ${Q}${MAKE} --no-print-directory -C ${FIPTOOLPATH} clean
-else
-# Clear the MAKEFLAGS as we do not want
-# to pass the gnumake flags to nmake.
- ${Q}set MAKEFLAGS= && ${MSVC_NMAKE} /nologo /f ${FIPTOOLPATH}/Makefile.msvc FIPTOOLPATH=$(subst /,\,$(FIPTOOLPATH)) FIPTOOL=$(subst /,\,$(FIPTOOL)) clean
-endif
${Q}${MAKE} PLAT=${PLAT} --no-print-directory -C ${CRTTOOLPATH} clean ${Q}${MAKE} PLAT=${PLAT} --no-print-directory -C ${CRTTOOLPATH} clean
${Q}${MAKE} PLAT=${PLAT} --no-print-directory -C ${ENCTOOLPATH} clean
realclean distclean: ${Q}${MAKE} --no-print-directory -C ${ROMLIBPATH} clean
@@ -1175,13 +1164,6 @@ realclean distclean:
@echo " REALCLEAN" @echo " REALCLEAN"
$(call SHELL_REMOVE_DIR,${BUILD_BASE}) $(call SHELL_REMOVE_DIR,${BUILD_BASE})
$(call SHELL_DELETE_ALL, ${CURDIR}/cscope.*) $(call SHELL_DELETE_ALL, ${CURDIR}/cscope.*)
-ifdef UNIX_MK
- ${Q}${MAKE} --no-print-directory -C ${FIPTOOLPATH} clean - ${Q}${MAKE} --no-print-directory -C ${FIPTOOLPATH} clean
-else
-# Clear the MAKEFLAGS as we do not want
-# to pass the gnumake flags to nmake.
- ${Q}set MAKEFLAGS= && ${MSVC_NMAKE} /nologo /f ${FIPTOOLPATH}/Makefile.msvc FIPTOOLPATH=$(subst /,\,$(FIPTOOLPATH)) FIPTOOL=$(subst /,\,$(FIPTOOL)) realclean
-endif
${Q}${MAKE} --no-print-directory -C ${SPTOOLPATH} clean
${Q}${MAKE} PLAT=${PLAT} --no-print-directory -C ${CRTTOOLPATH} clean ${Q}${MAKE} PLAT=${PLAT} --no-print-directory -C ${CRTTOOLPATH} clean
${Q}${MAKE} PLAT=${PLAT} --no-print-directory -C ${ENCTOOLPATH} realclean
checkcodebase: locate-checkpatch @@ -1238,7 +1220,7 @@ certificates: ${CRT_DEPS} ${CRTTOOL}
@@ -717,7 +711,7 @@ certificates: ${CRT_DEPS} ${CRTTOOL}
@${ECHO_BLANK_LINE} @${ECHO_BLANK_LINE}
endif endif
@ -35,7 +48,7 @@
${Q}${FIPTOOL} create ${FIP_ARGS} $@ ${Q}${FIPTOOL} create ${FIP_ARGS} $@
${Q}${FIPTOOL} info $@ ${Q}${FIPTOOL} info $@
@${ECHO_BLANK_LINE} @${ECHO_BLANK_LINE}
@@ -733,21 +727,16 @@ fwu_certificates: ${FWU_CRT_DEPS} ${CRTT @@ -1254,7 +1236,7 @@ fwu_certificates: ${FWU_CRT_DEPS} ${CRTT
@${ECHO_BLANK_LINE} @${ECHO_BLANK_LINE}
endif endif
@ -44,26 +57,37 @@
${Q}${FIPTOOL} create ${FWU_FIP_ARGS} $@ ${Q}${FIPTOOL} create ${FWU_FIP_ARGS} $@
${Q}${FIPTOOL} info $@ ${Q}${FIPTOOL} info $@
@${ECHO_BLANK_LINE} @${ECHO_BLANK_LINE}
@@ -1279,24 +1261,10 @@ ${BUILD_PLAT}/${DDR_FIP_NAME}: ${DDR_FIP
@echo "Built $@ successfully" @echo "Built $@ successfully"
@${ECHO_BLANK_LINE} @${ECHO_BLANK_LINE}
-fiptool: ${FIPTOOL} -fiptool: ${FIPTOOL}
fip: ${BUILD_PLAT}/${FIP_NAME} fip: ${BUILD_PLAT}/${FIP_NAME}
fwu_fip: ${BUILD_PLAT}/${FWU_FIP_NAME} fwu_fip: ${BUILD_PLAT}/${FWU_FIP_NAME}
fip_ddr: ${BUILD_PLAT}/${DDR_FIP_NAME}
-.PHONY: ${FIPTOOL} -.PHONY: ${FIPTOOL}
-${FIPTOOL}: -${FIPTOOL}:
- ${Q}${MAKE} CPPFLAGS="-DVERSION='\"${VERSION_STRING}\"'" --no-print-directory -C ${FIPTOOLPATH} - @${ECHO_BLANK_LINE}
- @echo "Building $@"
-ifdef UNIX_MK
- ${Q}${MAKE} CPPFLAGS="-DVERSION='\"${VERSION_STRING}\"'" FIPTOOL=${FIPTOOL} --no-print-directory -C ${FIPTOOLPATH}
-else
-# Clear the MAKEFLAGS as we do not want
-# to pass the gnumake flags to nmake.
- ${Q}set MAKEFLAGS= && ${MSVC_NMAKE} /nologo /f ${FIPTOOLPATH}/Makefile.msvc FIPTOOLPATH=$(subst /,\,$(FIPTOOLPATH)) FIPTOOL=$(subst /,\,$(FIPTOOL))
-endif
- @${ECHO_BLANK_LINE}
- -
cscope: sptool: ${SPTOOL}
@echo " CSCOPE" .PHONY: ${SPTOOL}
${Q}find ${CURDIR} -name "*.[chsS]" > cscope.files ${SPTOOL}:
--- a/tools/fiptool/Makefile --- a/tools/fiptool/Makefile
+++ b/tools/fiptool/Makefile +++ b/tools/fiptool/Makefile
@@ -37,7 +37,7 @@ all: ${PROJECT} fip_create @@ -38,7 +38,7 @@ all: ${PROJECT}
${PROJECT}: ${OBJECTS} Makefile ${PROJECT}: ${OBJECTS} Makefile
@echo " LD $@" @echo " HOSTLD $@"
- ${Q}${HOSTCC} ${OBJECTS} -o $@ ${LDLIBS} - ${Q}${HOSTCC} ${OBJECTS} -o $@ ${LDLIBS}
+ ${Q}${HOSTCC} ${OBJECTS} -o $@ ${LDLIBS} $(LDFLAGS) + ${Q}${HOSTCC} ${OBJECTS} -o $@ ${LDLIBS} $(LDFLAGS)
@${ECHO_BLANK_LINE} @${ECHO_BLANK_LINE}

View file

@ -1,19 +1,19 @@
From 8a458876013991fe2f288bbe4694264b16c3b9e9 Mon Sep 17 00:00:00 2001 From 8a458876013991fe2f288bbe4694264b16c3b9e9 Mon Sep 17 00:00:00 2001
From: Biwen Li <biwen.li@nxp.com> From: Biwen Li <biwen.li@nxp.com>
Date: Fri, 26 Jul 2019 15:44:10 +0800 Date: Fri, 26 Jul 2019 15:44:10 +0800
Subject: [PATCH 3/3] plat/nxp/tools: fix create_pbl and byte_swap host build Subject: [PATCH 3/3] tools/nxp: fix create_pbl and byte_swap host build
Not compile create_pbl and byte_swap in the process of cross compilation Not compile create_pbl and byte_swap in the process of cross compilation
Signed-off-by: Biwen Li <biwen.li@nxp.com> Signed-off-by: Biwen Li <biwen.li@nxp.com>
--- ---
plat/nxp/tools/pbl_ch2.mk | 3 --- tools/nxp/pbl_ch2.mk | 3 ---
plat/nxp/tools/pbl_ch3.mk | 5 ----- tools/nxp/pbl_ch3.mk | 5 -----
2 files changed, 8 deletions(-) 2 files changed, 8 deletions(-)
--- a/plat/nxp/tools/pbl_ch2.mk --- a/tools/nxp/pbl_ch2.mk
+++ b/plat/nxp/tools/pbl_ch2.mk +++ b/tools/nxp/pbl_ch2.mk
@@ -20,8 +20,6 @@ ifeq ($(RCW),"") @@ -19,8 +19,6 @@ ifeq ($(RCW),"")
else else
# Generate header for bl2.bin # Generate header for bl2.bin
$(Q)$(CST_DIR)/create_hdr_isbc --in ${BUILD_PLAT}/bl2.bin --out ${BUILD_PLAT}/hdr_bl2 ${BL2_INPUT_FILE} $(Q)$(CST_DIR)/create_hdr_isbc --in ${BUILD_PLAT}/bl2.bin --out ${BUILD_PLAT}/hdr_bl2 ${BL2_INPUT_FILE}
@ -22,7 +22,7 @@ Signed-off-by: Biwen Li <biwen.li@nxp.com>
# Add bl2.bin to RCW # Add bl2.bin to RCW
${CREATE_PBL} -r ${RCW} -i ${BUILD_PLAT}/bl2.bin -b ${BOOT_MODE} -c ${SOC_NUM} -d ${BL2_BASE} -e ${BL2_BASE}\ ${CREATE_PBL} -r ${RCW} -i ${BUILD_PLAT}/bl2.bin -b ${BOOT_MODE} -c ${SOC_NUM} -d ${BL2_BASE} -e ${BL2_BASE}\
-o ${BUILD_PLAT}/bl2_${BOOT_MODE}.pbl ;\ -o ${BUILD_PLAT}/bl2_${BOOT_MODE}.pbl ;\
@@ -43,7 +41,6 @@ ifeq ($(RCW),"") @@ -42,7 +40,6 @@ ifeq ($(RCW),"")
${Q}echo "Platform ${PLAT} requires rcw file. Please set RCW to point to the right RCW file for boot mode ${BOOT_MODE}" ${Q}echo "Platform ${PLAT} requires rcw file. Please set RCW to point to the right RCW file for boot mode ${BOOT_MODE}"
else else
# -a option appends the image for Chassis 3 devices in case of non secure boot # -a option appends the image for Chassis 3 devices in case of non secure boot
@ -30,9 +30,9 @@ Signed-off-by: Biwen Li <biwen.li@nxp.com>
${CREATE_PBL} -r ${RCW} -i ${BUILD_PLAT}/bl2.bin -b ${BOOT_MODE} -c ${SOC_NUM} -d ${BL2_BASE} -e ${BL2_BASE} \ ${CREATE_PBL} -r ${RCW} -i ${BUILD_PLAT}/bl2.bin -b ${BOOT_MODE} -c ${SOC_NUM} -d ${BL2_BASE} -e ${BL2_BASE} \
-o ${BUILD_PLAT}/bl2_${BOOT_MODE}.pbl ; -o ${BUILD_PLAT}/bl2_${BOOT_MODE}.pbl ;
# Swapping of RCW is required for QSPi Chassis 2 devices # Swapping of RCW is required for QSPi Chassis 2 devices
--- a/plat/nxp/tools/pbl_ch3.mk --- a/tools/nxp/pbl_ch3.mk
+++ b/plat/nxp/tools/pbl_ch3.mk +++ b/tools/nxp/pbl_ch3.mk
@@ -27,9 +27,6 @@ else @@ -26,9 +26,6 @@ else
# Generate header for bl2.bin # Generate header for bl2.bin
$(Q)$(CST_DIR)/create_hdr_isbc --in ${BUILD_PLAT}/bl2.bin --out ${BUILD_PLAT}/hdr_bl2 ${BL2_INPUT_FILE} $(Q)$(CST_DIR)/create_hdr_isbc --in ${BUILD_PLAT}/bl2.bin --out ${BUILD_PLAT}/hdr_bl2 ${BL2_INPUT_FILE}
@ -42,7 +42,7 @@ Signed-off-by: Biwen Li <biwen.li@nxp.com>
# Add Block Copy command for bl2.bin to RCW # Add Block Copy command for bl2.bin to RCW
${CREATE_PBL} -r ${RCW} -i ${BUILD_PLAT}/bl2.bin -b ${BOOT_MODE} -c ${SOC_NUM} -d ${BL2_BASE} -e ${BL2_BASE}\ ${CREATE_PBL} -r ${RCW} -i ${BUILD_PLAT}/bl2.bin -b ${BOOT_MODE} -c ${SOC_NUM} -d ${BL2_BASE} -e ${BL2_BASE}\
-o ${BUILD_PLAT}/bl2_${BOOT_MODE}.pbl -f ${BL2_SRC_OFFSET};\ -o ${BUILD_PLAT}/bl2_${BOOT_MODE}.pbl -f ${BL2_SRC_OFFSET};\
@@ -57,8 +54,6 @@ else #SECURE_BOOT @@ -56,8 +53,6 @@ else #SECURE_BOOT
ifeq ($(RCW),"") ifeq ($(RCW),"")
${Q}echo "Platform ${PLAT} requires rcw file. Please set RCW to point to the right RCW file for boot mode ${BOOT_MODE}" ${Q}echo "Platform ${PLAT} requires rcw file. Please set RCW to point to the right RCW file for boot mode ${BOOT_MODE}"
else else

View file

@ -1,20 +0,0 @@
--- a/common/runtime_svc.c
+++ b/common/runtime_svc.c
@@ -38,7 +38,7 @@ uintptr_t handle_runtime_svc(uint32_t smc_fid,
u_register_t x1, x2, x3, x4;
int index;
unsigned int idx;
- const rt_svc_desc_t *rt_svc_descs;
+ rt_svc_desc_t *rt_svc_descs = NULL;
assert(handle);
idx = get_unique_oen_from_smc_fid(smc_fid);
@@ -48,7 +48,7 @@ uintptr_t handle_runtime_svc(uint32_t smc_fid,
if (index < 0 || index >= (int)RT_SVC_DECS_NUM)
SMC_RET1(handle, SMC_UNK);
- rt_svc_descs = (rt_svc_desc_t *) RT_SVC_DESCS_START;
+ memcpy(rt_svc_descs, (rt_svc_desc_t *)RT_SVC_DESCS_START, MAX_RT_SVCS);
get_smc_params_from_ctx(handle, x1, x2, x3, x4);