summaryrefslogtreecommitdiff
path: root/recipes
diff options
context:
space:
mode:
authorStefan Agner <stefan.agner@toradex.com>2014-10-20 15:00:00 +0200
committerStefan Agner <stefan.agner@toradex.com>2014-10-20 15:00:00 +0200
commit3cd55b34ff554d7b4496535e46acf1126dc8d399 (patch)
tree1f87f6f6a04d8c8f42ed1f8448ccdc61d20ee951 /recipes
parentbc1c1753f3db63a95855e38ba9ecd0f43635a2e8 (diff)
colibri-vf: switch to zImage inside root fs
Due to U-Boot udpate we need to create one big UBI volume. Since attaching the UBI volume is the expensive operation (compared to mount the UBIFS inside that volume), it is relatively cheep to load the kernel directly from the root filesystems /boot directory instead of creating a own volume for the kernel. This also makes it simpler to load a mainline kernel (along with the required dtb file). However, we loose the integrity check of the uImage. But since there were no measures in place to handle a invalid image, we do not loose functionality here. In case we need integrity check, we should consider switching to the new FIT image format...
Diffstat (limited to 'recipes')
-rw-r--r--recipes/images/trdx-image-fstype.inc19
1 files changed, 14 insertions, 5 deletions
diff --git a/recipes/images/trdx-image-fstype.inc b/recipes/images/trdx-image-fstype.inc
index ad5e435..dbafc48 100644
--- a/recipes/images/trdx-image-fstype.inc
+++ b/recipes/images/trdx-image-fstype.inc
@@ -42,16 +42,25 @@ imagedeploytools_append_mx6() {
cp ${STAGING_ETCDIR_NATIVE}/imx-loader.d/mx6_usb_work.conf ${IMAGE_ROOT}/
}
+imagedeploy_kernel() {
+ # put u-boot, kernel into the bin directories, remove the kernel/dtb from the rootfs/boot
+ # rm -f ${IMAGE_ROOTFS}/boot/uImage* ${IMAGE_ROOTFS}/boot/*.dtb
+ cp -pP ${DEPLOY_DIR_IMAGE}/uImage* ${IMAGE_ROOTFS}/../${MACHINE}_bin/
+ ls ${DEPLOY_DIR_IMAGE}/*.dtb 2> /dev/null && cp -pP ${DEPLOY_DIR_IMAGE}/*.dtb ${IMAGE_ROOTFS}/../${MACHINE}_bin/
+ mv ${IMAGE_ROOTFS}/../${MACHINE}_bin/uImage-${MACHINE}.bin ${IMAGE_ROOTFS}/../${MACHINE}_bin/uImage
+}
+
+imagedeploy_kernel_colibri-vf() {
+ # Do nothing, we use the kernel from /boot inside root fs
+ :
+}
+
fakeroot do_imagedeploy() {
cd ${WORKDIR}
tar -xf ${BURNFLASH}
cp -pPr burnflash/* ${IMAGE_NAME}${PV}/
- # put u-boot, kernel into the bin directories, remove the kernel/dtb from the rootfs/boot
- rm -f ${IMAGE_ROOTFS}/boot/uImage* ${IMAGE_ROOTFS}/boot/*.dtb
- cp -pP ${DEPLOY_DIR_IMAGE}/uImage* ${IMAGE_ROOTFS}/../${MACHINE}_bin/
- ls ${DEPLOY_DIR_IMAGE}/*.dtb 2> /dev/null && cp -pP ${DEPLOY_DIR_IMAGE}/*.dtb ${IMAGE_ROOTFS}/../${MACHINE}_bin/
- mv ${IMAGE_ROOTFS}/../${MACHINE}_bin/uImage-${MACHINE}.bin ${IMAGE_ROOTFS}/../${MACHINE}_bin/uImage
+ imagedeploy_kernel
cp -pP ${DEPLOY_DIR_IMAGE}/u-boot* ${IMAGE_ROOTFS}/../${MACHINE}_bin/
rm -f ${IMAGE_ROOTFS}/../${MACHINE}_bin/u-boot-hsmmc-${MACHINE}.${U_BOOT_EXT}