[yocto] [meta-raspberrypi][PATCH v4 2/2] linux-raspberrypi: Make sure we have initramfs image before running mkknlimg

Andrei Gherzan andrei at gherzan.ro
Sun Feb 28 03:48:36 PST 2016


Signed-off-by: Andrei Gherzan <andrei at gherzan.ro>
---
 recipes-kernel/linux/linux-raspberrypi.inc | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/recipes-kernel/linux/linux-raspberrypi.inc b/recipes-kernel/linux/linux-raspberrypi.inc
index 1befee4..5a8a175 100644
--- a/recipes-kernel/linux/linux-raspberrypi.inc
+++ b/recipes-kernel/linux/linux-raspberrypi.inc
@@ -66,10 +66,12 @@ do_rpiboot_mkimage() {
 }
 
 do_bundle_initramfs_append() {
-    if test "x${KERNEL_IMAGETYPE}" != "xuImage" ; then
-        if test -n "${KERNEL_DEVICETREE}"; then
-            # Add RPi bootloader trailer to kernel image to enable DeviceTree support
-            ${STAGING_LIBEXECDIR_NATIVE}/mkknlimg --dtok ${KERNEL_OUTPUT}.initramfs ${KERNEL_OUTPUT}.initramfs
+    if [ ! -z "${INITRAMFS_IMAGE}" -a x"${INITRAMFS_IMAGE_BUNDLE}" = x1 ]; then
+        if test "x${KERNEL_IMAGETYPE}" != "xuImage" ; then
+            if test -n "${KERNEL_DEVICETREE}"; then
+                # Add RPi bootloader trailer to kernel image to enable DeviceTree support
+                ${STAGING_LIBEXECDIR_NATIVE}/mkknlimg --dtok ${KERNEL_OUTPUT}.initramfs ${KERNEL_OUTPUT}.initramfs
+            fi
         fi
     fi
 }
-- 
2.7.0




More information about the yocto mailing list