arm/trusted-firmware-a: fix variable name typo
PATCH v2 1/3 arm/trusted-firmware-a: fix variable name typo
Variable name "processes" is wrongly mentioned as "processed", this patch fixes the same.
Change-Id: Id9362f514861c75f8f6a727582e11b0e65736349
Issue-Id: PLATFORMS-3971
--- meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc +1 -1
@@ -171,7 +171,7 @@ do_install() { echo "dtbs install, skipped" elif [ -f ${B}/tools/$atfbin/$atfbin ]; then echo "Tools $atfbin install, skipped" - elif [ "$processed" = "0" ]; then + elif [ "$processes" = "0" ]; then bberror "Unsupported TFA_INSTALL_TARGET target $atfbin" exit 1 fi
Signature · 1 line
2.17.1
PATCH v2 2/3 arm/trusted-firmware-a: add support to install dtb built as part of TFA
Device tree blobs (DTBs) generated as part of TFA were installed separately in the platform specific TFA recipes, its redundant as each platform was executing similar installation steps.
The patch avoids skipping dtb installation and adds support to check for DTB entries in TFA_INSTALL_TARGET and install the same to respective deploy folder.
Change-Id: I0f8f5c39dc4b4931d202696990fa915ea7ed60eb
Issue-Id: PLATFORMS-3971
--- .../trusted-firmware-a/trusted-firmware-a.inc | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc +7 -3
@@ -166,9 +166,13 @@ do_install() { ln -sf $atfbin-${TFA_PLATFORM} ${D}/firmware/$atfbin processes="1" fi - - if [ "$atfbin" = "dtbs" ]; then - echo "dtbs install, skipped" + if [ -f ${BUILD_DIR}/fdts/$atfbin.dtb ]; then + echo "Install $atfbin.dtb" + install -m 0644 "${BUILD_DIR}/fdts/$atfbin.dtb" \ + "${D}/firmware/$atfbin.dtb" + processes="1" + elif [ "$atfbin" = "dtbs" ]; then + echo "dtbs install, skipped: set dtbs in TFA_INSTALL_TARGET" elif [ -f ${B}/tools/$atfbin/$atfbin ]; then echo "Tools $atfbin install, skipped" elif [ "$processes" = "0" ]; then
Signature · 1 line
2.17.1
PATCH v2 3/3 arm-bsp/trusted-firmware-a: Install dtbs from the generic TFA recipe
In reply to Khasim MohammedConfigure TFA_INSTALL_TARGET to multi-chip and single-chip dtbs, avoid installing dtbs in platform specific recipe instead use the generic step.
Change-Id: I79835f2c4f4d0bde938e43d6cf59f73392520935
Issue-Id: PLATFORMS-3971
--- .../trusted-firmware-a/trusted-firmware-a-n1sdp.inc | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)
meta-arm-bsp/recipes-bsp/trusted-firmware-a/trusted-firmware-a-n1sdp.inc +1 -5
@@ -3,6 +3,7 @@ COMPATIBLE_MACHINE = "n1sdp" TFA_PLATFORM = "n1sdp" TFA_BUILD_TARGET = "bl31 dtbs" +TFA_INSTALL_TARGET = "bl31 n1sdp-multi-chip n1sdp-single-chip" TFA_DEBUG = "1" TFA_MBEDTLS = "0" TFA_UBOOT = "0"
@@ -14,8 +15,3 @@ SRC_URI_append = " \ 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" -}
Signature · 1 line
2.17.1
Quoted 2 lines · Khasim Mohammed
Variable name "processes" is wrongly mentioned as "processed", this patch fixes the same.
Heh, I believe it was meant to be called "processed", i.e. when at least one of the checks matches and gets processed, the final condition is not met. So, it results in an error only when none of them gets processed.
But looks like I copied and pasted the version with the typo all over the place, while using the correct name in the final "if" statement:
https://git.yoctoproject.org/cgit/cgit.cgi/meta-arm/commit/meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc?id=01825739a4a49d857f7b1a839374da4381b92c2e
Sorry about that. Using the correct name would require fixing it in 4 places instead of one. So not sure if it's worth it...
Quoted 25 lines
Change-Id: Id9362f514861c75f8f6a727582e11b0e65736349
Issue-Id: PLATFORMS-3971Signed-off-by Khasim Syed Mohammed <[email protected]>--- meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc +1
-1@@ -171,7 +171,7 @@ do_install() { echo "dtbs install, skipped" elif [ -f ${B}/tools/$atfbin/$atfbin ]; then echo "Tools $atfbin install, skipped" - elif [ "$processed" = "0" ]; then + elif [ "$processes" = "0" ]; then bberror "Unsupported TFA_INSTALL_TARGET target $atfbin" exit 1 fiSignature · 1 line
2.17.1
Quoted 8 lines · Denys Dmytriyenko
Quoted 2 lines · Khasim Mohammed
Variable name "processes" is wrongly mentioned as "processed", this patch fixes the same.
Heh, I believe it was meant to be called "processed", i.e. when at least one of the checks matches and gets processed, the final condition is not met. So, it results in an error only when none of them gets processed.
Quoted 6 lines
But looks like I copied and pasted the version with the typo all over the place, while using the correct name in the final "if" statement:
https://git.yoctoproject.org/cgit/cgit.cgi/meta-arm/commit/meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc?id=01825739a4a49d857f7b1a839374da4381b92c2eSorry about that. Using the correct name would require fixing it in 4 places instead of one. So not sure if it's worth it...
Yeah, I was of the same opinion. It should be "processed", but don't feel live a v3 of this patch is needed for just that. I'll do a follow-on patcch to clean it up :)
Thanks,
Jon
Quoted 30 lines
Quoted 27 lines
Change-Id: Id9362f514861c75f8f6a727582e11b0e65736349
Issue-Id: PLATFORMS-3971Signed-off-by Khasim Syed Mohammed <[email protected]>--- meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc +1
-1@@ -171,7 +171,7 @@ do_install() { echo "dtbs install, skipped" elif [ -f ${B}/tools/$atfbin/$atfbin ]; then echo "Tools $atfbin install, skipped" - elif [ "$processed" = "0" ]; then + elif [ "$processes" = "0" ]; then bberror "Unsupported TFA_INSTALL_TARGET target $atfbin" exit 1 fiSignature · 1 line
2.17.1
Quoted 6 lines · Khasim Mohammed
Variable name "processes" is wrongly mentioned as "processed", this patch fixes the same.
Change-Id: Id9362f514861c75f8f6a727582e11b0e65736349
Issue-Id: PLATFORMS-3971Signed-off-by Khasim Syed Mohammed <[email protected]>
Series pulled into master.
Thanks,
Jon
Quoted 22 lines
--- meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a.inc +1
-1@@ -171,7 +171,7 @@ do_install() { echo "dtbs install, skipped" elif [ -f ${B}/tools/$atfbin/$atfbin ]; then echo "Tools $atfbin install, skipped" - elif [ "$processed" = "0" ]; then + elif [ "$processes" = "0" ]; then bberror "Unsupported TFA_INSTALL_TARGET target $atfbin" exit 1 fiSignature · 1 line
2.17.1