]> code.ossystems Code Review - meta-freescale.git/commitdiff
wic: add new wks file to use boot container for mx8m
authorAndrey Zhizhikin <andrey.z@gmail.com>
Fri, 18 Dec 2020 11:06:16 +0000 (11:06 +0000)
committerOtavio Salvador <otavio@ossystems.com.br>
Tue, 4 May 2021 17:07:09 +0000 (14:07 -0300)
Add new WKS template file, which uses the boot container provided by
mainline U-Boot.

Boot container built as a part of U-Boot packs binary components into
two separate files, namely 'flash.bin' and 'u-boot.itb'. First file
contains SPL, while second one represents the FIT image containing
U-Boot and ATF blob.

Signed-off-by: Andrey Zhizhikin <andrey.z@gmail.com>
wic/imx-boot-container-bootpart.wks.in [new file with mode: 0644]

diff --git a/wic/imx-boot-container-bootpart.wks.in b/wic/imx-boot-container-bootpart.wks.in
new file mode 100644 (file)
index 0000000..88679a6
--- /dev/null
@@ -0,0 +1,27 @@
+# short-description: Create SD card image with a boot partition for i.MX8M
+# long-description:
+# Create an image that can be written onto a SD card using dd for use
+# with i.MX8M SoC family
+# It uses binary boot container called flash.bin provided directly by
+# the U-Boot recipe, and U-Boot ITB files which is created by binman utility
+# of U-Boot.
+# Those files are added it into the boot partition, which is populated as a
+# raw copy into the image.
+# Boot container prepared by U-Boot already container SPL, U-Boot itself,
+# U-Boot DTB file, ATF, and optional OP-TEE components.
+#
+# The disk layout used is:
+#  - ----------- -------------- ----------------------------
+# | | flash.bin | u-boot.itb |     boot     |    rootfs    |
+#  - ----------- -------------- ----------------------------
+# ^ ^           ^            ^              ^              ^
+# | |           |            |              |              |
+# 0 |        384KiB         8MiB          72MiB          72MiB + rootfs + IMAGE_EXTRA_SPACE (default 10MiB)
+#   ${IMX_BOOT_SEEK} 32 or 33kiB, see reference manual
+#
+part u-boot --source rawcopy --sourceparams="file=flash.bin" --ondisk mmcblk --no-table --align ${IMX_BOOT_SEEK}
+part u-boot-itb --source rawcopy --sourceparams="file=u-boot.itb" --ondisk mmcblk --no-table --align 384
+part /boot --source bootimg-partition --ondisk mmcblk --fstype=vfat --label boot --active --align 8192 --size 64
+part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 8192
+
+bootloader --ptable msdos