[meta-arm,v2] arm-bsp/trusted-firmware-a: generate single-chip and multi-chip dtbs for N1SDP

Submitted by Khasim Mohammed on Aug. 5, 2020, 4:57 p.m. | Patch ID: 175058

Details

Message ID 20200805165759.23669-1-khasim.mohammed@arm.com
State New
Headers show

Commit Message

Khasim Mohammed Aug. 5, 2020, 4:57 p.m.
N1SDP supports both single-chip and multi-chip environment.
 - Updated SHA to latest TFA patchset to add support for both DTS files
 - generate dtbs for both single and multi-chip environment
 - Migrate N1SDP to use trusted-firmware-a version 2.3 as base line

Change-Id: I4b92e1680750041421fb9fbc9cef448250581f94
Issue-Id: PLATFORMS-3134
Signed-off-by: Khasim Syed Mohammed <khasim.mohammed@arm.com>
---
 meta-arm-bsp/conf/machine/n1sdp.conf                  |  4 ++--
 .../trusted-firmware-a/trusted-firmware-a-n1sdp.inc   | 11 ++++++++++-
 .../trusted-firmware-a_2.2.bbappend                   |  6 ------
 .../trusted-firmware-a_2.3.bbappend                   |  1 +
 4 files changed, 13 insertions(+), 9 deletions(-)

Patch hide | download patch | download mbox

diff --git a/meta-arm-bsp/conf/machine/n1sdp.conf b/meta-arm-bsp/conf/machine/n1sdp.conf
index d651270..a31f33d 100644
--- a/meta-arm-bsp/conf/machine/n1sdp.conf
+++ b/meta-arm-bsp/conf/machine/n1sdp.conf
@@ -26,9 +26,9 @@  PREFERRED_VERSION_linux-linaro-arm ?= "5.4%"
 # RTL8168E Gigabit Ethernet Controller is attached to the PCIe interface
 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "linux-firmware-rtl8168"
 
-# Trusted firmware v2.2 version
+# Trusted firmware v2.3 version
 PREFERRED_PROVIDER_virtual/trusted-firmware-a ?= "trusted-firmware-a"
-PREFERRED_VERSION_trusted-firmware-a ?= "2.2%"
+PREFERRED_VERSION_trusted-firmware-a ?= "2.3%"
 
 EXTRA_IMAGEDEPENDS += "virtual/trusted-firmware-a"
 EXTRA_IMAGEDEPENDS += "virtual/control-processor-firmware"
diff --git a/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a-n1sdp.inc b/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a-n1sdp.inc
index ef71ae5..c26cc78 100644
--- a/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a-n1sdp.inc
+++ b/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a-n1sdp.inc
@@ -2,7 +2,7 @@ 
 
 COMPATIBLE_MACHINE = "n1sdp"
 TFA_PLATFORM       = "n1sdp"
-TFA_BUILD_TARGET   = "bl31"
+TFA_BUILD_TARGET   = "bl31 dtbs"
 TFA_DEBUG          = "1"
 TFA_MBEDTLS        = "0"
 TFA_UBOOT          = "0"
@@ -10,3 +10,12 @@  TFA_UBOOT          = "0"
 SRC_URI_append = " \
     file://0001-n1sdp-arm-tf-disable-workaround-for-N1-Erratum-13157.patch \
     "
+
+SRCREV_tfa = "f0b1864f8e309a41d2eb1c9510f8cd3c7aacbb1d"
+
+PV = "2.3+git${SRCPV}"
+
+do_install_append() {
+    install -m 0644 "${BUILD_DIR}/fdts/n1sdp-single-chip.dtb" "${D}/firmware/n1sdp-single-chip.dtb"
+    install -m 0644 "${BUILD_DIR}/fdts/n1sdp-multi-chip.dtb" "${D}/firmware/n1sdp-multi-chip.dtb"
+}
diff --git a/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.2.bbappend b/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.2.bbappend
index 81138d3..6ede847 100644
--- a/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.2.bbappend
+++ b/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.2.bbappend
@@ -1,12 +1,6 @@ 
 # Machine specific TFAs
 
 MACHINE_TFA_REQUIRE ?= ""
-MACHINE_TFA_REQUIRE_n1sdp = "trusted-firmware-a-n1sdp.inc"
 MACHINE_TFA_REQUIRE_fvp-base-arm32 = "trusted-firmware-a-fvp-arm32.inc"
 
 require ${MACHINE_TFA_REQUIRE}
-
-# TFA referred in release tag N1SDP-2020.03.26
-SRCREV_tfa_n1sdp = "cfb3f73344217aa000aaff9d84baad7527af75bf"
-
-PV_n1sdp = "2.2+git${SRCPV}"
diff --git a/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.3.bbappend b/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.3.bbappend
index f37c589..6f67b49 100644
--- a/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.3.bbappend
+++ b/meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.3.bbappend
@@ -5,5 +5,6 @@  MACHINE_TFA_REQUIRE_tc0 = "trusted-firmware-a-tc0.inc"
 MACHINE_TFA_REQUIRE_a5ds = "trusted-firmware-a-a5ds.inc"
 MACHINE_TFA_REQUIRE_foundation-armv8 = "trusted-firmware-a-fvp.inc"
 MACHINE_TFA_REQUIRE_fvp-base = "trusted-firmware-a-fvp.inc"
+MACHINE_TFA_REQUIRE_n1sdp = "trusted-firmware-a-n1sdp.inc"
 
 require ${MACHINE_TFA_REQUIRE}