imx-atf-boundary_2.3: add recipe

Add custom imx-atf applicable only to Nitrogen8m, Nitrogen8mm and
Nitrogen8mn, which pulls from Boundary's imx-atf. This is done because
meta-freescale imx-atf_2.0 sets the RDC so that UART4 is only accessible
by M4 core.

Signed-off-by: Chris Dimich <Chris.Dimich@boundarydevices.com>
(cherry picked from commit 8bf3414ad6)
This commit is contained in:
Chris Dimich 2020-04-24 12:31:03 -07:00 committed by Otavio Salvador
parent fa97865d92
commit 242005d81e

View File

@ -0,0 +1,56 @@
# Copyright (C) 2017-2019 NXP
DESCRIPTION = "i.MX ARM Trusted Firmware"
SECTION = "BSP"
LICENSE = "BSD-3-Clause"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
PROVIDES = "imx-atf"
PV .= "+git${SRCPV}"
SRCBRANCH = "boundary-imx_4.14.98_2.3.0"
SRC_URI = "git://github.com/boundarydevices/imx-atf.git;branch=${SRCBRANCH} \
"
SRCREV = "99e07a29006b35e5b76e3a2555c54575f3b63d0c"
S = "${WORKDIR}/git"
inherit deploy
BOOT_TOOLS = "imx-boot-tools"
PLATFORM ?= "INVALID"
PLATFORM_mx8mq = "imx8mq"
PLATFORM_mx8mm = "imx8mm"
PLATFORM_mx8mn = "imx8mn"
EXTRA_OEMAKE += " \
CROSS_COMPILE="${TARGET_PREFIX}" \
PLAT=${PLATFORM} \
"
BUILD_OPTEE = "${@bb.utils.contains('MACHINE_FEATURES', 'optee', 'true', 'false', d)}"
do_compile() {
# Clear LDFLAGS to avoid the option -Wl recognize issue
unset LDFLAGS
oe_runmake bl31
if ${BUILD_OPTEE}; then
oe_runmake clean BUILD_BASE=build-optee
oe_runmake BUILD_BASE=build-optee SPD=opteed bl31
fi
}
do_install[noexec] = "1"
do_deploy() {
install -Dm 0644 ${S}/build/${PLATFORM}/release/bl31.bin ${DEPLOYDIR}/${BOOT_TOOLS}/bl31-${PLATFORM}.bin
if ${BUILD_OPTEE}; then
install -m 0644 ${S}/build-optee/${PLATFORM}/release/bl31.bin ${DEPLOYDIR}/${BOOT_TOOLS}/bl31-${PLATFORM}.bin-optee
fi
}
addtask deploy after do_compile
PACKAGE_ARCH = "${MACHINE_SOCARCH}"
COMPATIBLE_MACHINE = "(nitrogen8m|nitrogen8mm|nitrogen8mn)"