]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
imx: cortexa9: ventana, fix profiles names in profiles.json 22994/head
authorMario Andrés Pérez <mapb_@outlook.com>
Sat, 18 Apr 2026 12:38:57 +0000 (14:38 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Wed, 22 Apr 2026 23:13:36 +0000 (01:13 +0200)
These two image profiles overwrite DEVICE_NAME making the two image
profiles appear with the same name "ventana" in the "profiles.json"
mixing ramdomly the two profiles.

Use BOARD_NAME instead to keep the two profiles names unique (orginal
DEVICE_NAME) hence generating a coherent "profiles.json".

Since there are image recipes hardconding DEVICE_NAME, change them to use
BOARD_NAME if defined, in order to preserve the previous names used in
those recipes.

Fixes: cbc8bcfbaa71fe0928bf07d29ec0fe6217fd51ad ("imx6: image: use vendor_model scheme")
Reported-by: Eric Fahlgren <ericfahlgren@gmail.com>
Signed-off-by: Mario Andrés Pérez <mapb_@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/22994
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/imx/image/common.mk
target/linux/imx/image/cortexa9.mk

index 3b528a02b147715170c5871cffeab15ee3ac7353..431d1ef425a7da7bc921c624441e5f6747e3cbe5 100644 (file)
@@ -18,7 +18,7 @@ define Build/imx-combined-image
 
        mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
                -n '$(DEVICE_ID) OpenWrt bootscript' \
-               -d bootscript-$(DEVICE_NAME) \
+               -d bootscript-$(if $(BOARD_NAME),$(BOARD_NAME),$(DEVICE_NAME)) \
                $@.boot/boot.scr
 
        cp $@ $@.fs
index 5f087c83ed9e27edfd77b209d28d5693771f4a79..6a3cbe038c6ec86ea1a9ba2db47e6674d578cf80 100644 (file)
@@ -19,8 +19,8 @@ define Build/boot-overlay
        )
        mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
                -n '$(DEVICE_ID) OpenWrt bootscript' \
-               -d ./bootscript-$(DEVICE_NAME) \
-               $@.boot/6x_bootscript-$(DEVICE_NAME)
+               -d ./bootscript-$(if $(BOARD_NAME),$(BOARD_NAME),$(DEVICE_NAME)) \
+               $@.boot/6x_bootscript-$(if $(BOARD_NAME),$(BOARD_NAME),$(DEVICE_NAME))
 
        $(STAGING_DIR_HOST)/bin/mkfs.ubifs \
                --space-fixup --compr=zlib --squash-uids \
@@ -43,7 +43,7 @@ endef
 define Build/recovery-scr
        mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
        -n '$(DEVICE_ID) OpenWrt recovery bootscript' \
-       -d ./recovery-$(DEVICE_NAME) $@
+       -d ./recovery-$(if $(BOARD_NAME),$(BOARD_NAME),$(DEVICE_NAME)) $@
 endef
 
 define Build/apalis-emmc
@@ -63,7 +63,7 @@ define Build/ventana-img
        )
        mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
                -n '$(DEVICE_ID) OpenWrt bootscript' \
-               -d bootscript-$(DEVICE_NAME) \
+               -d bootscript-$(if $(BOARD_NAME),$(BOARD_NAME),$(DEVICE_NAME)) \
                $@.boot/boot/6x_bootscript-ventana
        cp $@ $@.fs
 
@@ -92,7 +92,7 @@ define Device/gateworks_ventana
   DEVICE_VENDOR := Gateworks
   DEVICE_MODEL := Ventana family
   DEVICE_VARIANT := normal NAND flash
-  DEVICE_NAME := ventana
+  BOARD_NAME := ventana
   DEVICE_DTS:= \
        imx6dl-gw51xx \
        imx6dl-gw52xx \