diff options
| author | Erik Larsson <karl.erik.larsson@gmail.com> | 2018-04-12 22:39:07 +0200 |
|---|---|---|
| committer | Thomas Petazzoni <thomas.petazzoni@bootlin.com> | 2018-04-12 22:39:43 +0200 |
| commit | 7f50b000e741a135293aef642e680987cf516b3a (patch) | |
| tree | fb7c6d3a4789424cc998061186d61e1df1cc0123 | |
| parent | 4a1ad1d135e38f01ba8dd13f713667a071ad3f2e (diff) | |
| download | buildroot-7f50b000e741a135293aef642e680987cf516b3a.tar.gz buildroot-7f50b000e741a135293aef642e680987cf516b3a.zip | |
board/freescale/common/imx: add i.MX8 genimage template
This commit adds a genimage template file that is used for i.MX8
platforms in the common i.MX post-image script.
Signed-off-by: Erik Larsson <karl.erik.larsson@gmail.com>
Signed-off-by: Christopher Dahlberg <crille.dahlberg@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| -rw-r--r-- | board/freescale/common/imx/genimage.cfg.template_imx8 | 40 | ||||
| -rwxr-xr-x | board/freescale/common/imx/post-image.sh | 4 |
2 files changed, 43 insertions, 1 deletions
diff --git a/board/freescale/common/imx/genimage.cfg.template_imx8 b/board/freescale/common/imx/genimage.cfg.template_imx8 new file mode 100644 index 0000000000..fdb645014a --- /dev/null +++ b/board/freescale/common/imx/genimage.cfg.template_imx8 @@ -0,0 +1,40 @@ +# Minimal SD card image for the Freescale iMX8 boards +# +# We mimic the .sdcard Freescale's image format: +# * the SD card must have 33 kB free space at the beginning, +# * U-Boot is integrated into imx8-boot-sd.bin and is dumped as is, +# * a FAT partition at offset 32MB is containing Image and DTB files +# * a single root filesystem partition is required (ext2, ext3 or ext4) +# + +image boot.vfat { + vfat { + files = { + %FILES% + } + } + size = 32M +} + +image sdcard.img { + hdimage { + } + + partition imx-boot { + in-partition-table = "no" + image = "imx8-boot-sd.bin" + offset = 33K + } + + partition boot { + partition-type = 0xC + bootable = "true" + image = "boot.vfat" + offset = 8M + } + + partition rootfs { + partition-type = 0x83 + image = "rootfs.ext2" + } +} diff --git a/board/freescale/common/imx/post-image.sh b/board/freescale/common/imx/post-image.sh index 70d2c9c600..264c8a4bcb 100755 --- a/board/freescale/common/imx/post-image.sh +++ b/board/freescale/common/imx/post-image.sh @@ -32,7 +32,9 @@ linux_image() genimage_type() { - if grep -Eq "^BR2_TARGET_UBOOT_SPL=y$" ${BR2_CONFIG}; then + if grep -Eq "^BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX8M=y$" ${BR2_CONFIG}; then + echo "genimage.cfg.template_imx8" + elif grep -Eq "^BR2_TARGET_UBOOT_SPL=y$" ${BR2_CONFIG}; then echo "genimage.cfg.template_spl" else echo "genimage.cfg.template" |

