aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPali Rohár2020-10-29 10:44:45 -0500
committerManish Pandey2020-11-19 04:17:21 -0600
commitc6a7ab7787ccc2d1c916918a0b8c470321d41448 (patch)
tree9019a11a3cecb94d055278331a7bbbcf7205ea7b
parent7b12a8d673c215007476918630e5579ca4039703 (diff)
downloadarm-trusted-firmware-c6a7ab7787ccc2d1c916918a0b8c470321d41448.tar.gz
arm-trusted-firmware-c6a7ab7787ccc2d1c916918a0b8c470321d41448.tar.xz
arm-trusted-firmware-c6a7ab7787ccc2d1c916918a0b8c470321d41448.zip
plat: marvell: armada: a3k: Add support for building $(DOIMAGETOOL)
Current binary wtptp/linux/tbb_linux which is specified in $(DOIMAGETOOL) variable points to external pre-compiled Marvell x86_64 ELF linux binary from A3700-utils-marvell WTP repository. It means that currently it is not possible to compile TF-A for A3720 on other host platform then linux x86_64. Part of the A3700-utils-marvell WTP repository is also source code of $(DOIMAGETOOL) TBB_Linux tool. This change adds support for building $(DOIMAGETOOL) also for a3k platform. After running $(MAKE) at appropriate subdirectory of A3700-utils-marvell WTP repository, compiled TBB_linux tool will appear in WTP subdirectory wtptp/src/TBB_Linux/release/. So update also $(DOIMAGETOOL) variable to point to the correct location where TBB_linux was built. To build TBB_linux it is required to compile external Crypto++ library which is available at: https://github.com/weidai11/cryptopp.git User needs to set CRYPTOPP_PATH option to specify path to that library. After this change it is now possible to build whole firmware for A3720 platform without requirement to use pre-compiled/proprietary x86_64 executable binaries from Marvell. Signed-off-by: Pali Rohár <pali@kernel.org> Change-Id: I6f26bd4356778a2f8f730a223067a2e550e6c8e0
-rw-r--r--plat/marvell/armada/a3k/common/a3700_common.mk7
1 files changed, 6 insertions, 1 deletions
diff --git a/plat/marvell/armada/a3k/common/a3700_common.mk b/plat/marvell/armada/a3k/common/a3700_common.mk
index 2050d59b6..001443c6f 100644
--- a/plat/marvell/armada/a3k/common/a3700_common.mk
+++ b/plat/marvell/armada/a3k/common/a3700_common.mk
@@ -65,7 +65,7 @@ BL31_SOURCES += lib/cpus/aarch64/cortex_a53.S \
65ifneq (${WTP},) 65ifneq (${WTP},)
66 66
67DOIMAGEPATH := $(WTP) 67DOIMAGEPATH := $(WTP)
68DOIMAGETOOL := $(DOIMAGEPATH)/wtptp/linux/tbb_linux 68DOIMAGETOOL := $(DOIMAGEPATH)/wtptp/src/TBB_Linux/release/TBB_linux
69 69
70include plat/marvell/marvell.mk 70include plat/marvell/marvell.mk
71 71
@@ -120,6 +120,11 @@ TIMBLDUARTARGS := $(MARVELL_SECURE_BOOT) UART $(IMAGESPATH) $(DOIMAGEPATH) $(CL
120 $(DDR_TOPOLOGY) 0 0 $(DOIMAGE_CFG) $(TIMNCFG) $(TIMNSIG) 0 120 $(DDR_TOPOLOGY) 0 0 $(DOIMAGE_CFG) $(TIMNCFG) $(TIMNSIG) 0
121DOIMAGE_FLAGS := -r $(DOIMAGE_CFG) -v -D 121DOIMAGE_FLAGS := -r $(DOIMAGE_CFG) -v -D
122 122
123$(DOIMAGETOOL):
124 $(if $(value CRYPTOPP_PATH),,$(error "Platform '${PLAT}' for WTP image tool requires CRYPTOPP_PATH. Please set CRYPTOPP_PATH to point to the right directory"))
125 $(Q)$(MAKE) --no-print-directory -C $(CRYPTOPP_PATH) -f GNUmakefile
126 $(Q)$(MAKE) --no-print-directory -C $(DOIMAGEPATH)/wtptp/src/TBB_Linux -f TBB_linux.mak LIBDIR=$(CRYPTOPP_PATH)
127
123mrvl_flash: ${BUILD_PLAT}/${FIP_NAME} ${DOIMAGETOOL} 128mrvl_flash: ${BUILD_PLAT}/${FIP_NAME} ${DOIMAGETOOL}
124 $(shell truncate -s %128K ${BUILD_PLAT}/bl1.bin) 129 $(shell truncate -s %128K ${BUILD_PLAT}/bl1.bin)
125 $(shell cat ${BUILD_PLAT}/bl1.bin ${BUILD_PLAT}/${FIP_NAME} > ${BUILD_PLAT}/${BOOT_IMAGE}) 130 $(shell cat ${BUILD_PLAT}/bl1.bin ${BUILD_PLAT}/${FIP_NAME} > ${BUILD_PLAT}/${BOOT_IMAGE})