When the machine is a FVP we will fetch and delpoy rom-binaries as well.
Signed-off-by: Pawel Zalewski pzalewski@thegoodpenguin.co.uk --- .../board-firmware/board-firmware-image.bb | 19 ++++++++++++++++--- .../board-firmware/board-firmware_1.4.bb | 4 +++- .../board-firmware/board-morello-fvp.inc | 2 ++ .../board-firmware/board-morello-soc.inc | 1 + 4 files changed, 22 insertions(+), 4 deletions(-) create mode 100644 recipes-bsp/board-firmware/board-morello-fvp.inc create mode 100644 recipes-bsp/board-firmware/board-morello-soc.inc
diff --git a/recipes-bsp/board-firmware/board-firmware-image.bb b/recipes-bsp/board-firmware/board-firmware-image.bb index b872a3a..2ab5e5f 100644 --- a/recipes-bsp/board-firmware/board-firmware-image.bb +++ b/recipes-bsp/board-firmware/board-firmware-image.bb @@ -8,9 +8,19 @@ LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ec OUTPUTS_NAME = "board-firmware-sd-image" SECTION = "firmware"
+MACHINE_BOARD_REQUIRE ?= "" +MACHINE_BOARD_REQUIRE:morello-fvp = "board-morello-fvp.inc" +MACHINE_BOARD_REQUIRE:morello-soc = "board-morello-soc.inc" +require ${MACHINE_BOARD_REQUIRE} + +PACKAGE_ARCH = "${MACHINE_ARCH}" + BB_DONT_CACHE = "1"
-DEPENDS += "virtual/board-firmware virtual/scp-firmware virtual/trusted-firmware-a virtual/uefi virtual/grub-efi mtools-native fiptool-native" +DEPENDS += "virtual/board-firmware virtual/scp-firmware \ + virtual/trusted-firmware-a virtual/uefi virtual/grub-efi \ + mtools-native fiptool-native" + PROVIDES = "virtual/board-firmware-image"
MCP_BLOB_ID = "54464222-a4cf-4bf8-b1b6-cee7dade539e" @@ -43,11 +53,11 @@ do_install[depends] += "virtual/trusted-firmware-a:do_populate_sysroot" do_install:prepend() {
fiptool create \ - --scp-fw "${FIRMWARE_PATH}/scp_ramfw_soc.bin" \ + --scp-fw "${FIRMWARE_PATH}/scp_ramfw_${TARGET_PLATFORM}.bin" \ "${FIRMWARE_PATH}/scp_fw.bin"
fiptool create \ - --blob uuid="${MCP_BLOB_ID}",file="${FIRMWARE_PATH}/mcp_ramfw_soc.bin" \ + --blob uuid="${MCP_BLOB_ID}",file="${FIRMWARE_PATH}/mcp_ramfw_${TARGET_PLATFORM}.bin" \ "${FIRMWARE_PATH}/mcp_fw.bin"
install -d "${FIRMWARE_PATH}/tfa_certs" @@ -78,5 +88,8 @@ do_install() {
do_deploy() { cp -rf ${D}/firmware/board-firmware-image/${OUTPUTS_NAME}.img ${DEPLOYDIR}/${OUTPUTS_NAME}.img + install ${SYSROOT_SOFTWARE_PATH}/fip.bin ${DEPLOYDIR}/fip.bin + install ${SYSROOT_SOFTWARE_PATH}/scp_fw.bin ${DEPLOYDIR}/scp_fw.bin + install ${SYSROOT_SOFTWARE_PATH}/mcp_fw.bin ${DEPLOYDIR}/mcp_fw.bin } addtask deploy after do_install \ No newline at end of file diff --git a/recipes-bsp/board-firmware/board-firmware_1.4.bb b/recipes-bsp/board-firmware/board-firmware_1.4.bb index 84a5394..9d98dc2 100644 --- a/recipes-bsp/board-firmware/board-firmware_1.4.bb +++ b/recipes-bsp/board-firmware/board-firmware_1.4.bb @@ -6,7 +6,9 @@ LICENSE = "STMicroelectronics & BSD-3-Clause & BSD-2-Clause" OUTPUTS_NAME = "board-firmware" SECTION = "firmware"
-PROVIDES += "virtual/${OUTPUTS_NAME}" +PROVIDES += "virtual/${OUTPUTS_NAME}" + +PACKAGE_ARCH = "${MACHINE_ARCH}"
SRC_URI = "git://git.morello-project.org/morello/board-firmware;protocol=https;branch=${SRCBRANCH}" SRCREV = "20e3e673f13e854109a069dd719f49e06336142d" diff --git a/recipes-bsp/board-firmware/board-morello-fvp.inc b/recipes-bsp/board-firmware/board-morello-fvp.inc new file mode 100644 index 0000000..fa62792 --- /dev/null +++ b/recipes-bsp/board-firmware/board-morello-fvp.inc @@ -0,0 +1,2 @@ +TARGET_PLATFORM = "fvp" +DEPENDS += "virtual/rom-binaries" diff --git a/recipes-bsp/board-firmware/board-morello-soc.inc b/recipes-bsp/board-firmware/board-morello-soc.inc new file mode 100644 index 0000000..94d624b --- /dev/null +++ b/recipes-bsp/board-firmware/board-morello-soc.inc @@ -0,0 +1 @@ +TARGET_PLATFORM = "soc" \ No newline at end of file