Browse Source

ramips: mt7621: Reduce hardcoded metadata for Inteno Y3 imgs

Instead of hardcoded metadata, put some sensible data instead.

Signed-off-by: Andreas Gnau <[email protected]>
Link: https://github.com/openwrt/openwrt/pull/17551
Signed-off-by: Hauke Mehrtens <[email protected]>
Andreas Gnau 1 year ago
parent
commit
4e3342f5f1
1 changed files with 7 additions and 7 deletions
  1. 7 7
      target/linux/ramips/image/mt7621.mk

+ 7 - 7
target/linux/ramips/image/mt7621.mk

@@ -67,12 +67,12 @@ define Build/inteno-y3-header
 	echo "IntenoIopY" > [email protected] ;\
 	echo "version 5" >> [email protected] ;\
 	echo "integrity MD5SUM" >> [email protected] ;\
-	echo "board EX400" >> [email protected] ;\
-	echo "chip 7621" >> [email protected] ;\
-	echo "arch all mipsel_1004kc" >> [email protected] ;\
-	echo "model EX400" >> [email protected] ;\
-	echo "release EX400-X-DNA-4.3.6.100-R-210518_0935" >> [email protected] ;\
-	echo "customer DNA" >> [email protected] ;\
+	echo "board $(word 1,$(1))" >> [email protected] ;\
+	echo "chip $(patsubst mt%,%,$(SOC:bcm%=%))" >> [email protected] ;\
+	echo "arch all $(CONFIG_TARGET_ARCH_PACKAGES)" >> [email protected] ;\
+	echo "model $(word 1,$(1))" >> [email protected] ;\
+	echo "release $(DEVICE_IMG_PREFIX)" >> [email protected] ;\
+	echo "customer $(if $(CONFIG_VERSION_DIST),$(CONFIG_VERSION_DIST),OpenWrt)" >> [email protected] ;\
 	echo "ubifsofs $${ubifsofs}" >> [email protected] ;\
 	echo "ubifs $${ubifs}" >> [email protected] ;\
 	echo "pkginfoofs $${pkginfoofs}" >> [email protected] ;\
@@ -1405,7 +1405,7 @@ define Device/genexis_pulse-ex400/common
   KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | uImage lzma
   IMAGES += factory.bin
   IMAGE/factory.bin := append-image-stage initramfs-kernel.bin | \
-	inteno-bootfs | inteno-y3-header | append-md5sum-ascii-salted
+	inteno-bootfs | inteno-y3-header EX400 | append-md5sum-ascii-salted
   IMAGE/sysupgrade.bin := append-kernel | inteno-bootfs | \
     sysupgrade-tar kernel=$$$$@ | check-size | append-metadata
   DEVICE_IMG_NAME = $$(DEVICE_IMG_PREFIX)-$$(2)