aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorSungbo Eo <mans0n@gorani.run>2020-03-10 15:41:09 +0900
committerAdrian Schmutzler <freifunk@adrianschmutzler.de>2020-03-21 19:55:12 +0100
commit5b392c7119f23aef10ffc0def9a70e8335f9f3f8 (patch)
tree73e56336895a2944f0cb8dfedfd04f7b7d7d6e67 /target
parentd5812478ad4c882256e43a2ad52ddf0c0944db7b (diff)
downloadupstream-5b392c7119f23aef10ffc0def9a70e8335f9f3f8.tar.gz
upstream-5b392c7119f23aef10ffc0def9a70e8335f9f3f8.tar.bz2
upstream-5b392c7119f23aef10ffc0def9a70e8335f9f3f8.zip
treewide: gather DEVICE_VARS into one place
Place DEVICE_VARS assignments at the top of the file or above Device/Default to make them easier to find. For ramips, remove redundant values already present in parent file. Signed-off-by: Sungbo Eo <mans0n@gorani.run> [do not touch ar71xx, extend commit message] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Diffstat (limited to 'target')
-rw-r--r--target/linux/ath79/image/nand.mk3
-rw-r--r--target/linux/bcm63xx/image/bcm63xx.mk11
-rw-r--r--target/linux/ipq40xx/image/Makefile6
-rw-r--r--target/linux/ipq806x/image/Makefile5
-rw-r--r--target/linux/lantiq/image/Makefile2
-rw-r--r--target/linux/lantiq/image/vr9.mk3
-rw-r--r--target/linux/mvebu/image/Makefile2
-rw-r--r--target/linux/omap/image/Makefile1
-rw-r--r--target/linux/ramips/image/mt7621.mk3
-rw-r--r--target/linux/sunxi/image/Makefile2
-rw-r--r--target/linux/tegra/image/Makefile1
11 files changed, 21 insertions, 18 deletions
diff --git a/target/linux/ath79/image/nand.mk b/target/linux/ath79/image/nand.mk
index 8f28af4655..7d283b54c4 100644
--- a/target/linux/ath79/image/nand.mk
+++ b/target/linux/ath79/image/nand.mk
@@ -1,5 +1,7 @@
include ./common-netgear.mk # for netgear-uImage
+DEVICE_VARS += RAS_ROOTFS_SIZE RAS_BOARD RAS_VERSION
+
# attention: only zlib compression is allowed for the boot fs
define Build/zyxel-buildkerneljffs
rm -rf $(KDIR_TMP)/zyxelnbg6716
@@ -216,4 +218,3 @@ define Device/zyxel_nbg6716
UBINIZE_OPTS := -E 5
endef
TARGET_DEVICES += zyxel_nbg6716
-DEVICE_VARS += RAS_ROOTFS_SIZE RAS_BOARD RAS_VERSION
diff --git a/target/linux/bcm63xx/image/bcm63xx.mk b/target/linux/bcm63xx/image/bcm63xx.mk
index 265fa0958a..ccbc7f1325 100644
--- a/target/linux/bcm63xx/image/bcm63xx.mk
+++ b/target/linux/bcm63xx/image/bcm63xx.mk
@@ -3,6 +3,12 @@
# BCM33XX/BCM63XX Profiles
#
+DEVICE_VARS += HCS_MAGIC_BYTES HCS_REV_MIN HCS_REV_MAJ
+DEVICE_VARS += BLOCK_SIZE FLASH_MB IMAGE_OFFSET
+DEVICE_VARS += CFE_BOARD_ID CFE_CHIP_ID CFE_EXTRAS
+DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_REGION
+DEVICE_VARS += REDBOOT_PREFIX
+
define Device/bcm33xx
KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | loader-lzma bin | hcs-initramfs
IMAGES :=
@@ -10,7 +16,6 @@ define Device/bcm33xx
HCS_REV_MIN :=
HCS_REV_MAJ :=
endef
-DEVICE_VARS += HCS_MAGIC_BYTES HCS_REV_MIN HCS_REV_MAJ
define Device/bcm63xx
FILESYSTEMS := squashfs jffs2-64k jffs2-128k
@@ -31,8 +36,6 @@ define Device/bcm63xx
CFE_CHIP_ID :=
CFE_EXTRAS = --block-size $$(BLOCK_SIZE) --image-offset $$(if $$(IMAGE_OFFSET),$$(IMAGE_OFFSET),$$(BLOCK_SIZE))
endef
-DEVICE_VARS += BLOCK_SIZE FLASH_MB IMAGE_OFFSET
-DEVICE_VARS += CFE_BOARD_ID CFE_CHIP_ID CFE_EXTRAS
define Device/bcm63xx_netgear
$(Device/bcm63xx)
@@ -42,7 +45,6 @@ define Device/bcm63xx_netgear
NETGEAR_BOARD_ID :=
NETGEAR_REGION :=
endef
-DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_REGION
define Device/bcm63xx_redboot
FILESYSTEMS := squashfs
@@ -52,7 +54,6 @@ define Device/bcm63xx_redboot
IMAGE/redboot.bin := redboot-bin
REDBOOT_PREFIX := $$(IMAGE_PREFIX)
endef
-DEVICE_VARS += REDBOOT_PREFIX
### Generic ###
define Device/brcm_bcm963281tan
diff --git a/target/linux/ipq40xx/image/Makefile b/target/linux/ipq40xx/image/Makefile
index 2e95ad4dfb..1cd7650881 100644
--- a/target/linux/ipq40xx/image/Makefile
+++ b/target/linux/ipq40xx/image/Makefile
@@ -1,8 +1,9 @@
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/image.mk
-DEVICE_VARS += RAS_BOARD RAS_ROOTFS_SIZE RAS_VERSION \
- WRGG_DEVNAME WRGG_SIGNATURE
+DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
+DEVICE_VARS += RAS_BOARD RAS_ROOTFS_SIZE RAS_VERSION
+DEVICE_VARS += WRGG_DEVNAME WRGG_SIGNATURE
define Device/Default
PROFILES := Default
@@ -51,7 +52,6 @@ define Device/DniImage
IMAGE/factory.img := append-kernel | pad-offset 64k 64 | append-uImage-fakehdr filesystem | append-rootfs | pad-rootfs | netgear-dni
IMAGE/sysupgrade.bin := append-kernel | pad-offset 64k 64 | append-uImage-fakehdr filesystem | append-rootfs | pad-rootfs | append-metadata
endef
-DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
define Build/mkmylofw_32m
$(eval device_id=$(word 1,$(1)))
diff --git a/target/linux/ipq806x/image/Makefile b/target/linux/ipq806x/image/Makefile
index 6f529aca06..6ea66d064d 100644
--- a/target/linux/ipq806x/image/Makefile
+++ b/target/linux/ipq806x/image/Makefile
@@ -3,6 +3,9 @@
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/image.mk
+DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
+DEVICE_VARS += TPLINK_BOARD_ID
+
define Build/buffalo-rootfs-cksum
( \
echo -ne "\x$$(od -A n -t u1 $@ | tr -s ' ' '\n' | \
@@ -58,7 +61,6 @@ define Device/DniImage
IMAGE/factory.img := append-kernel | pad-offset $$$$(BLOCKSIZE) 64 | append-uImage-fakehdr filesystem | pad-to $$$$(KERNEL_SIZE) | append-ubi | netgear-dni
IMAGE/sysupgrade.bin := append-kernel | pad-offset $$$$(BLOCKSIZE) 64 | append-uImage-fakehdr filesystem | sysupgrade-tar kernel=$$$$@ | append-metadata
endef
-DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
define Device/TpSafeImage
KERNEL_SUFFIX := -uImage
@@ -69,7 +71,6 @@ define Device/TpSafeImage
IMAGE/factory.bin := append-rootfs | tplink-safeloader factory
IMAGE/sysupgrade.bin := append-rootfs | tplink-safeloader sysupgrade | append-metadata
endef
-DEVICE_VARS += TPLINK_BOARD_ID
define Device/ZyXELImage
KERNEL_SUFFIX := -uImage
diff --git a/target/linux/lantiq/image/Makefile b/target/linux/lantiq/image/Makefile
index 0ec04af6b3..87a4110f7e 100644
--- a/target/linux/lantiq/image/Makefile
+++ b/target/linux/lantiq/image/Makefile
@@ -52,6 +52,7 @@ define Build/fullimage
rm $@.tmp
endef
+DEVICE_VARS += SIGNATURE MAGIC CRC32_POLY
DTS_DIR := $(DTS_DIR)/lantiq
# Shared device definition: applies to every defined device
@@ -93,7 +94,6 @@ define Device/lantiqBrnImage
IMAGES := factory.bin
IMAGE/factory.bin := mkbrnimg | check-size $$$$(IMAGE_SIZE)
endef
-DEVICE_VARS += SIGNATURE MAGIC CRC32_POLY
define Device/lantiqFullImage
KERNEL := kernel-bin | append-dtb | lzma | uImage lzma | pad-offset 4 0
diff --git a/target/linux/lantiq/image/vr9.mk b/target/linux/lantiq/image/vr9.mk
index 083d8efe0f..2bea40011d 100644
--- a/target/linux/lantiq/image/vr9.mk
+++ b/target/linux/lantiq/image/vr9.mk
@@ -1,3 +1,5 @@
+DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
+
define Device/alphanetworks_asl56026
DEVICE_VENDOR := Alpha
DEVICE_MODEL := ASL56026
@@ -199,7 +201,6 @@ define Device/netgear_dm200
NETGEAR_BOARD_ID := DM200
NETGEAR_HW_ID := 29765233+8+0+64+0+0
endef
-DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_HW_ID
TARGET_DEVICES += netgear_dm200
define Device/zyxel_p-2812hnu-f1
diff --git a/target/linux/mvebu/image/Makefile b/target/linux/mvebu/image/Makefile
index 024e77969a..ef9274866d 100644
--- a/target/linux/mvebu/image/Makefile
+++ b/target/linux/mvebu/image/Makefile
@@ -11,6 +11,7 @@ JFFS2_BLOCKSIZE = 128k
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/image.mk
+DEVICE_VARS += BOOT_SCRIPT UBOOT
KERNEL_LOADADDR := 0x00008000
define Build/boot-scr
@@ -96,7 +97,6 @@ define Device/Default
UBOOT :=
BOOT_SCRIPT :=
endef
-DEVICE_VARS += BOOT_SCRIPT UBOOT
define Device/Default-arm64
BOOT_SCRIPT := generic-arm64
diff --git a/target/linux/omap/image/Makefile b/target/linux/omap/image/Makefile
index 106071a38e..6a7b20199f 100644
--- a/target/linux/omap/image/Makefile
+++ b/target/linux/omap/image/Makefile
@@ -33,7 +33,6 @@ endef
define Device/Default
PROFILES := Default
- DEVICE_VARS :=
KERNEL_NAME := zImage
KERNEL := kernel-bin
IMAGES := sdcard.img.gz
diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk
index 4fcd92cced..e9572a70fc 100644
--- a/target/linux/ramips/image/mt7621.mk
+++ b/target/linux/ramips/image/mt7621.mk
@@ -7,7 +7,7 @@ include ./common-tp-link.mk
DEFAULT_SOC := mt7621
KERNEL_DTB += -d21
-DEVICE_VARS += UIMAGE_MAGIC
+DEVICE_VARS += UIMAGE_MAGIC SERCOMM_HWNAME
# The OEM webinterface expects an kernel with initramfs which has the uImage
# header field ih_name.
@@ -554,7 +554,6 @@ define Device/netgear_sercomm_nand
DEVICE_VENDOR := NETGEAR
DEVICE_PACKAGES := kmod-mt7603 kmod-usb3 kmod-usb-ledtrig-usbport wpad-basic
endef
-DEVICE_VARS += SERCOMM_HWNAME SERCOMM_HWID SERCOMM_HWVER SERCOMM_SWVER
define Device/netgear_r6220
$(Device/netgear_sercomm_nand)
diff --git a/target/linux/sunxi/image/Makefile b/target/linux/sunxi/image/Makefile
index cb8febca41..1b98849a50 100644
--- a/target/linux/sunxi/image/Makefile
+++ b/target/linux/sunxi/image/Makefile
@@ -11,6 +11,7 @@ include $(INCLUDE_DIR)/image.mk
FAT32_BLOCK_SIZE=1024
FAT32_BLOCKS=$(shell echo $$(($(CONFIG_SUNXI_SD_BOOT_PARTSIZE)*1024*1024/$(FAT32_BLOCK_SIZE))))
+DEVICE_VARS := SUNXI_DTS SUNXI_DTS_DIR
KERNEL_LOADADDR:=0x40008000
define Build/sunxi-sdcard
@@ -32,7 +33,6 @@ endef
# why \x00\x00\x00\x00 for zImage-initramfs
define Device/Default
PROFILES := Default
- DEVICE_VARS := SUNXI_DTS SUNXI_DTS_DIR
KERNEL_NAME := zImage
KERNEL := kernel-bin | uImage none
IMAGES := sdcard.img.gz
diff --git a/target/linux/tegra/image/Makefile b/target/linux/tegra/image/Makefile
index 10bada9c38..3a19feb55e 100644
--- a/target/linux/tegra/image/Makefile
+++ b/target/linux/tegra/image/Makefile
@@ -34,6 +34,7 @@ define Build/tegra-sdcard
endef
DEVICE_VARS += BOOT_SCRIPT UBOOT
+
define Device/Default
BOOT_SCRIPT := generic-bootscript
IMAGES := sdcard.img.gz