diff --git a/include/image.mk b/include/image.mk index 8cc6e38cad672fb6fadff018c38cfaf2e1ddcfa8..324582a5d4a5d710d833201f6a187cc91b6cc1fe 100644 --- a/include/image.mk +++ b/include/image.mk @@ -369,7 +369,7 @@ define Device/Init endef DEFAULT_DEVICE_VARS := \ - DEVICE_NAME KERNEL KERNEL_INITRAMFS KERNEL_INITRAMFS_IMAGE \ + DEVICE_NAME KERNEL KERNEL_INITRAMFS KERNEL_SIZE KERNEL_INITRAMFS_IMAGE \ DEVICE_DTS DEVICE_DTS_DIR BOARD_NAME CMDLINE \ UBOOTENV_IN_UBI KERNEL_IN_UBI \ BLOCKSIZE PAGESIZE SUBPAGESIZE VID_HDR_OFFSET \ diff --git a/target/linux/ar71xx/image/generic.mk b/target/linux/ar71xx/image/generic.mk index 10717cb7faf2cf565df705f4ec4f507022dfb676..bd92a8413db8ed6043741c0e17bfd3a9641f7e48 100644 --- a/target/linux/ar71xx/image/generic.mk +++ b/target/linux/ar71xx/image/generic.mk @@ -410,7 +410,7 @@ define Device/NBG6616 CMDLINE += mem=128M IMAGES := sysupgrade.bin KERNEL := kernel-bin | patch-cmdline | lzma | uImage lzma | jffs2 boot/vmlinux.lzma.uImage - IMAGE/sysupgrade.bin = append-kernel $$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) + IMAGE/sysupgrade.bin = append-kernel $$$$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) # We cannot currently build a factory image. It is the sysupgrade image # prefixed with a header (which is actually written into the MTD device). # The header is 2kiB and is filled with 0xff. The format seems to be: @@ -443,7 +443,7 @@ define Device/c-55 KERNEL_SIZE = 2048k IMAGE_SIZE = 15872k MTDPARTS = spi0.0:256k(u-boot)ro,128k(u-boot-env)ro,2048k(kernel),13824k(rootfs),13824k(opt)ro,2624k(failsafe)ro,64k(art)ro,15872k@0x60000(firmware) - IMAGE/sysupgrade.bin = append-kernel $$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) + IMAGE/sysupgrade.bin = append-kernel $$$$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) endef TARGET_DEVICES += c-55 diff --git a/target/linux/ar71xx/image/ubnt.mk b/target/linux/ar71xx/image/ubnt.mk index 99496f72a16d0365628b59d194c444ad2198f676..98c9ca0066e8a79e2e4f1d3d6fe814515a52a8d4 100644 --- a/target/linux/ar71xx/image/ubnt.mk +++ b/target/linux/ar71xx/image/ubnt.mk @@ -261,7 +261,7 @@ define Device/ubnt-uap-pro DEVICE_PROFILE := UBNT UAPPRO KERNEL := kernel-bin | patch-cmdline | lzma | uImage lzma | jffs2 kernel0 IMAGES := sysupgrade.bin factory.bin - IMAGE/sysupgrade.bin = append-kernel $$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) + IMAGE/sysupgrade.bin = append-kernel $$$$(KERNEL_SIZE) | append-rootfs | pad-rootfs | check-size $$$$(IMAGE_SIZE) IMAGE/factory.bin = $$(IMAGE/sysupgrade.bin) | mkubntimage2 endef diff --git a/target/linux/ipq806x/image/Makefile b/target/linux/ipq806x/image/Makefile index daf910e74e05d3767354b4e478f07cb9929c1a6e..7703a62339376d348bc8efbc6cd3d7c2a31dea71 100644 --- a/target/linux/ipq806x/image/Makefile +++ b/target/linux/ipq806x/image/Makefile @@ -41,7 +41,6 @@ define Device/Default KERNEL_INITRAMFS_PREFIX := $$(IMG_PREFIX)-$(1)-initramfs KERNEL_PREFIX := $$(IMAGE_PREFIX) endef -DEVICE_VARS += KERNEL_SIZE define Device/LegacyImage KERNEL_SUFFIX := -uImage diff --git a/target/linux/kirkwood/image/Makefile b/target/linux/kirkwood/image/Makefile index 03a9873c9f3ee66d8de616d69aea496f153d2fc4..12d2a311ef8558b2a1b490c6c9887323666e913f 100644 --- a/target/linux/kirkwood/image/Makefile +++ b/target/linux/kirkwood/image/Makefile @@ -10,7 +10,6 @@ NAND_BLOCKSIZE := 2048-128k include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/image.mk -DEVICE_VARS += KERNEL_SIZE KERNEL_LOADADDR:=0x8000 TARGET_DEVICES = linksys-audi linksys-viper dockstar goflexnet goflexhome diff --git a/target/linux/mvebu/image/Makefile b/target/linux/mvebu/image/Makefile index c855cca42cc4f917ff35f762e64c2804c0153091..2c3d6589fec0847f58d8bd948c60acaf51048c57 100644 --- a/target/linux/mvebu/image/Makefile +++ b/target/linux/mvebu/image/Makefile @@ -12,8 +12,6 @@ include $(INCLUDE_DIR)/image.mk KERNEL_LOADADDR := 0x00008000 -DEVICE_VARS += KERNEL_SIZE - define Build/dtb $(call Image/BuildDTB,$(DTS_DIR)/$(DEVICE_DTS).dts,$@.dtb) endef diff --git a/target/linux/oxnas/image/Makefile b/target/linux/oxnas/image/Makefile index 6e5bb82e6cf3174ada05d6bfb777c3b7ef012350..a2312f246774d72076ecbdfdd1ef46ce8fe86eb3 100644 --- a/target/linux/oxnas/image/Makefile +++ b/target/linux/oxnas/image/Makefile @@ -10,7 +10,7 @@ include $(INCLUDE_DIR)/image.mk UBIFS_OPTS = -m 2048 -e 126KiB -c 4096 -DEVICE_VARS += DTS KERNEL_SIZE UBIFS_OPTS +DEVICE_VARS += DTS UBIFS_OPTS KERNEL_LOADADDR := 0x60008000 diff --git a/target/linux/ramips/image/Makefile b/target/linux/ramips/image/Makefile index 7794d48482fb05984584b15e4de6a23eb3376cf3..d165ec55126e0824cc4b7b11e09a6dc3e425a496 100644 --- a/target/linux/ramips/image/Makefile +++ b/target/linux/ramips/image/Makefile @@ -22,7 +22,7 @@ define Image/Build/Initramfs $(call Image/Build/Profile/$(PROFILE),initramfs) endef -DEVICE_VARS += DTS IMAGE_SIZE KERNEL_SIZE +DEVICE_VARS += DTS IMAGE_SIZE loadaddr-y := 0x80000000 loadaddr-$(CONFIG_TARGET_ramips_rt288x) := 0x88000000