diff options
author | Rick Altherr <raltherr@google.com> | 2016-12-09 00:22:36 +0300 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2016-12-22 04:33:25 +0300 |
commit | 8c1f920df4f41adc9e7a88b2ec542d59bb7fdee8 (patch) | |
tree | f7e916cab3dbddc29c3d9682d0a91bfed90dea71 | |
parent | 934907241d876895b644229e7ed9f3a74ff71fac (diff) | |
download | openbmc-8c1f920df4f41adc9e7a88b2ec542d59bb7fdee8.tar.xz |
Use INITRAMFS_FSTYPES to build a u-boot ramdisk
do_generate_flash() was manually packaging the initramfs cpio archive as
a u-boot ramdisk legacy image. Add the u-boot type to
INITRAMFS_FSTYPES to use the existing infrastructure instead.
NOTE: if you have an existing build directory, this change may cause the
build to fail while creating symlinks. This is caused by the .u-boot
file changing from an actual file to a symlink.
Change-Id: I9fa69620f97452671f89675768b1d1f33dbe97f2
Signed-off-by: Rick Altherr <raltherr@google.com>
-rw-r--r-- | meta-phosphor/classes/obmc-phosphor-image_types_uboot.bbclass | 5 | ||||
-rw-r--r-- | meta-phosphor/conf/machine/include/obmc-bsp-common.inc | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/meta-phosphor/classes/obmc-phosphor-image_types_uboot.bbclass b/meta-phosphor/classes/obmc-phosphor-image_types_uboot.bbclass index 5c991265d..bb2ddd228 100644 --- a/meta-phosphor/classes/obmc-phosphor-image_types_uboot.bbclass +++ b/meta-phosphor/classes/obmc-phosphor-image_types_uboot.bbclass @@ -66,12 +66,13 @@ do_generate_flash() { if [ ! -f $ddir/$initrd ]; then bbfatal "initrd file ${ddir}/${initrd} does not exist" fi + if [ ! -f $ddir/$uinitrd ]; then + bbfatal "uinitrd file ${ddir}/${uinitrd} does not exist" + fi if [ ! -f $ddir/$rootfs ]; then bbfatal "Rootfs file ${ddir}/${rootfs} does not exist" fi - oe_mkimage "${initrd}" "${INITRD_CTYPE}" || bbfatal "oe_mkimage initrd" - mk_nor_image ${ddir}/${rwfs} ${RWFS_SIZE} if [ "${OVERLAY_BASETYPE}" != jffs2 ]; then mkfs.${OVERLAY_BASETYPE} ${OVERLAY_MKFS_OPTS} ${ddir}/${rwfs} || \ diff --git a/meta-phosphor/conf/machine/include/obmc-bsp-common.inc b/meta-phosphor/conf/machine/include/obmc-bsp-common.inc index 3fe9e9f0a..e52d8a315 100644 --- a/meta-phosphor/conf/machine/include/obmc-bsp-common.inc +++ b/meta-phosphor/conf/machine/include/obmc-bsp-common.inc @@ -20,7 +20,7 @@ OBMC_IMAGE_EXTRA_INSTALL_append = " u-boot-fw-utils" IMAGE_CLASSES += "obmc-phosphor-image_types_uboot" INITRAMFS_CTYPE ?= "lzma" -INITRAMFS_FSTYPES += "cpio.${INITRAMFS_CTYPE}" +INITRAMFS_FSTYPES += "cpio.${INITRAMFS_CTYPE} cpio.${INITRAMFS_CTYPE}.u-boot" MACHINE_FEATURES_BACKFILL_CONSIDERED = "qemu-usermode" |