From 0ef9809cc7317760f8e51d1dde8b16521e9fe1d5 Mon Sep 17 00:00:00 2001 From: Pierre-Jean Texier Date: Sat, 13 Apr 2019 18:08:41 +0200 Subject: [PATCH] wic: Fix image generation for i.MX with bootpart script Some boards expects a specific binary name. Example : WaRP7 required the u-boot-dtb.imx file (instead of u-boot.imx). Signed-off-by: Pierre-Jean Texier Signed-off-by: Joris Offouga --- conf/machine/include/imx-base.inc | 7 ++++--- wic/{imx-uboot-bootpart.wks => imx-uboot-bootpart.wks.in} | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) rename wic/{imx-uboot-bootpart.wks => imx-uboot-bootpart.wks.in} (87%) diff --git a/conf/machine/include/imx-base.inc b/conf/machine/include/imx-base.inc index 5f19e043..bef8d6ce 100644 --- a/conf/machine/include/imx-base.inc +++ b/conf/machine/include/imx-base.inc @@ -14,6 +14,7 @@ PREFERRED_PROVIDER_virtual/bootloader ??= "${IMX_DEFAULT_BOOTLOADER}" PREFERRED_PROVIDER_u-boot-mxsboot-native ??= "u-boot-fslc-mxsboot-native" +UBOOT_BINARY ?= "u-boot.imx" UBOOT_MAKE_TARGET ?= "u-boot.imx" UBOOT_MAKE_TARGET_mxs ?= "u-boot.sb" UBOOT_MAKE_TARGET_mx8 ?= "" @@ -301,7 +302,7 @@ WKS_FILE_DEPENDS ?= " \ WKS_FILE_DEPENDS_mx8 += "imx-boot" -SOC_DEFAULT_WKS_FILE ?= "imx-uboot-bootpart.wks" +SOC_DEFAULT_WKS_FILE ?= "imx-uboot-bootpart.wks.in" SOC_DEFAULT_WKS_FILE_mx8 ?= "imx-imx-boot-bootpart.wks.in" SOC_DEFAULT_WKS_FILE_mxs ?= "imx-uboot-mxs-bootpart.wks.in" @@ -313,11 +314,11 @@ WKS_FILE ?= "${SOC_DEFAULT_WKS_FILE}" UBOOT_MAKE_TARGET_use-fsl-bsp_mx6 = "u-boot.imx" UBOOT_SUFFIX_use-fsl-bsp_mx6 = "imx" SPL_BINARY_use-fsl-bsp_mx6 = "" -WKS_FILE_use-fsl-bsp_mx6 = "imx-uboot-bootpart.wks" +WKS_FILE_use-fsl-bsp_mx6 = "imx-uboot-bootpart.wks.in" UBOOT_MAKE_TARGET_use-fsl-bsp_mx7 = "u-boot.imx" UBOOT_SUFFIX_use-fsl-bsp_mx7 = "imx" SPL_BINARY_use-fsl-bsp_mx7 = "" -WKS_FILE_use-fsl-bsp_mx7 = "imx-uboot-bootpart.wks" +WKS_FILE_use-fsl-bsp_mx7 = "imx-uboot-bootpart.wks.in" SERIAL_CONSOLES = "115200;ttymxc0" SERIAL_CONSOLES_mxs = "115200;ttyAMA0" diff --git a/wic/imx-uboot-bootpart.wks b/wic/imx-uboot-bootpart.wks.in similarity index 87% rename from wic/imx-uboot-bootpart.wks rename to wic/imx-uboot-bootpart.wks.in index a5e0137b..8fe019c0 100644 --- a/wic/imx-uboot-bootpart.wks +++ b/wic/imx-uboot-bootpart.wks.in @@ -12,7 +12,7 @@ # | | | | # 0 1kiB 4MiB 16MiB + rootfs + IMAGE_EXTRA_SPACE (default 10MiB) # -part u-boot --source rawcopy --sourceparams="file=u-boot.imx" --ondisk mmcblk --no-table --align 1 +part u-boot --source rawcopy --sourceparams="file=${UBOOT_BINARY}" --ondisk mmcblk --no-table --align 1 part /boot --source bootimg-partition --ondisk mmcblk --fstype=vfat --label boot --active --align 4096 --size 16 part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 4096 -- 2.40.1