2020-06-07 11:13:46 +00:00
|
|
|
define Build/create-uImage-dtb
|
|
|
|
# flat_dt target expect FIT image - which WNDR4700's uboot doesn't support
|
|
|
|
-$(STAGING_DIR_HOST)/bin/mkimage -A $(LINUX_KARCH) \
|
|
|
|
-O linux -T kernel -C none \
|
|
|
|
-n '$(call toupper,$(LINUX_KARCH)) $(VERSION_DIST) Linux-$(LINUX_VERSION)' \
|
2023-10-20 14:20:27 +00:00
|
|
|
-d "$(KDIR)/image-$(firstword $(DEVICE_DTS)).dtb" "$@.dtb.uimage"
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Build/prepend-dtb-uImage
|
|
|
|
cat "$@.dtb.uimage" "$@" > "$@.new"
|
|
|
|
mv "$@.new" "$@"
|
2020-06-07 11:13:46 +00:00
|
|
|
endef
|
|
|
|
|
2023-05-13 19:09:56 +00:00
|
|
|
define Build/meraki-header
|
2020-06-07 11:13:46 +00:00
|
|
|
-$(STAGING_DIR_HOST)/bin/mkmerakifw \
|
|
|
|
-B $(BOARD_NAME) -s \
|
|
|
|
-i $@ \
|
|
|
|
-o $@.new
|
|
|
|
@cp $@.new $@
|
|
|
|
endef
|
|
|
|
|
|
|
|
|
|
|
|
define Device/meraki_mr24
|
|
|
|
DEVICE_VENDOR := Cisco Meraki
|
|
|
|
DEVICE_MODEL := MR24
|
|
|
|
DEVICE_PACKAGES := kmod-spi-gpio -swconfig
|
|
|
|
BOARD_NAME := mr24
|
|
|
|
IMAGES := sysupgrade.bin
|
2023-06-08 16:12:05 +00:00
|
|
|
DEVICE_DTC_FLAGS := --space 64512
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE_SIZE := 8191k
|
2023-06-08 16:12:05 +00:00
|
|
|
KERNEL := kernel-bin | lzma | uImage lzma | prepend-dtb | meraki-header
|
|
|
|
KERNEL_INITRAMFS := kernel-bin | lzma | MuImage-initramfs lzma
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
|
|
|
|
UBINIZE_OPTS := -E 5
|
|
|
|
SUPPORTED_DEVICES += mr24
|
|
|
|
endef
|
|
|
|
TARGET_DEVICES += meraki_mr24
|
|
|
|
|
|
|
|
define Device/meraki_mx60
|
|
|
|
DEVICE_VENDOR := Cisco Meraki
|
2022-02-13 12:29:23 +00:00
|
|
|
DEVICE_MODEL := MX60
|
|
|
|
DEVICE_ALT0_VENDOR := Cisco Meraki
|
|
|
|
DEVICE_ALT0_MODEL := MX60W
|
2020-06-07 11:13:46 +00:00
|
|
|
DEVICE_PACKAGES := kmod-spi-gpio kmod-usb-ledtrig-usbport kmod-usb-dwc2 \
|
|
|
|
kmod-usb-storage block-mount
|
2021-10-01 19:53:26 +00:00
|
|
|
BLOCKSIZE := 128k
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGES := sysupgrade.bin
|
2023-06-08 16:12:05 +00:00
|
|
|
DEVICE_DTC_FLAGS := --space 20480
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE_SIZE := 1021m
|
2023-06-08 16:12:05 +00:00
|
|
|
KERNEL := kernel-bin | libdeflate-gzip | MuImage-initramfs gzip
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
|
|
|
|
UBINIZE_OPTS := -E 5
|
2023-10-09 20:15:52 +00:00
|
|
|
DEVICE_COMPAT_VERSION := 3.0
|
2021-10-01 19:53:26 +00:00
|
|
|
DEVICE_COMPAT_MESSAGE := uboot's bootcmd has to be updated to support standard multi-image uImages. \
|
2023-10-09 20:15:52 +00:00
|
|
|
Network swconfig configuration cannot be upgraded to DSA. \
|
2021-10-01 19:53:26 +00:00
|
|
|
Upgrade via sysupgrade mechanism is not possible.
|
2020-06-07 11:13:46 +00:00
|
|
|
endef
|
|
|
|
TARGET_DEVICES += meraki_mx60
|
|
|
|
|
|
|
|
define Device/netgear_wndap6x0
|
|
|
|
DEVICE_VENDOR := NETGEAR
|
|
|
|
DEVICE_PACKAGES := kmod-eeprom-at24
|
|
|
|
SUBPAGESIZE := 256
|
|
|
|
PAGESIZE := 512
|
|
|
|
BLOCKSIZE := 16k
|
2023-06-08 16:12:05 +00:00
|
|
|
DEVICE_DTC_FLAGS := --space 32768
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE_SIZE := 27392k
|
|
|
|
IMAGES := sysupgrade.bin factory.img
|
2021-10-02 22:19:58 +00:00
|
|
|
KERNEL_SIZE := 6080k
|
2023-06-08 16:12:05 +00:00
|
|
|
KERNEL := kernel-bin | libdeflate-gzip | MuImage-initramfs gzip
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
|
|
|
|
IMAGE/factory.img := append-kernel | pad-to $$$$(KERNEL_SIZE) | append-ubi
|
|
|
|
UBINIZE_OPTS := -E 5
|
2021-10-02 22:19:58 +00:00
|
|
|
DEVICE_COMPAT_VERSION := 2.0
|
|
|
|
DEVICE_COMPAT_MESSAGE := kernel and ubi partitions had to be resized. \
|
|
|
|
Upgrade via sysupgrade mechanism is not possible.
|
2020-06-07 11:13:46 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Device/netgear_wndap620
|
|
|
|
$(Device/netgear_wndap6x0)
|
|
|
|
DEVICE_MODEL := WNDAP620 (Premium Wireless-N)
|
|
|
|
endef
|
|
|
|
TARGET_DEVICES += netgear_wndap620
|
|
|
|
|
|
|
|
define Device/netgear_wndap660
|
|
|
|
$(Device/netgear_wndap6x0)
|
|
|
|
DEVICE_MODEL := WNDAP660 (Dual Radio Dual Band Wireless-N)
|
|
|
|
endef
|
|
|
|
TARGET_DEVICES += netgear_wndap660
|
|
|
|
|
|
|
|
define Device/netgear_wndr4700
|
2023-10-09 20:15:52 +00:00
|
|
|
DEVICE_COMPAT_VERSION := 3.0
|
|
|
|
DEVICE_COMPAT_MESSAGE := Network swconfig configuration cannot be upgraded to DSA. \
|
|
|
|
Upgrade via sysupgrade mechanism is not possible.
|
2020-06-07 11:13:46 +00:00
|
|
|
DEVICE_VENDOR := NETGEAR
|
2022-02-13 12:29:23 +00:00
|
|
|
DEVICE_MODEL := Centria N900 WNDR4700
|
|
|
|
DEVICE_ALT0_VENDOR := NETGEAR
|
|
|
|
DEVICE_ALT0_MODEL := Centria N900 WNDR4720
|
2020-06-07 11:13:46 +00:00
|
|
|
DEVICE_PACKAGES := badblocks block-mount e2fsprogs kmod-hwmon-drivetemp \
|
|
|
|
kmod-dm kmod-fs-ext4 kmod-fs-vfat kmod-usb-ledtrig-usbport \
|
|
|
|
kmod-md-mod kmod-nls-cp437 kmod-nls-iso8859-1 kmod-nls-iso8859-15 \
|
|
|
|
kmod-nls-utf8 kmod-usb3 kmod-usb-dwc2 kmod-usb-storage \
|
2023-05-28 19:22:52 +00:00
|
|
|
partx-utils kmod-ata-dwc
|
2020-06-07 11:13:46 +00:00
|
|
|
BOARD_NAME := wndr4700
|
|
|
|
PAGESIZE := 2048
|
|
|
|
SUBPAGESIZE := 512
|
|
|
|
BLOCKSIZE := 128k
|
2023-06-08 16:12:05 +00:00
|
|
|
DEVICE_DTC_FLAGS := --space 131008
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE_SIZE := 24960k
|
|
|
|
IMAGES := factory.img sysupgrade.bin
|
|
|
|
ARTIFACTS := device-tree.dtb
|
2024-03-23 10:26:23 +00:00
|
|
|
KERNEL_SIZE := 4608k
|
2020-06-07 11:13:46 +00:00
|
|
|
# append a fake/empty rootfs to fool netgear's uboot
|
|
|
|
# CHECK_DNI_FIRMWARE_ROOTFS_INTEGRITY in do_chk_dniimg()
|
2020-09-27 14:27:59 +00:00
|
|
|
KERNEL := kernel-bin | lzma -d16 | uImage lzma | pad-offset $$(BLOCKSIZE) 64 | \
|
2023-10-20 14:20:27 +00:00
|
|
|
append-uImage-fakehdr filesystem | create-uImage-dtb | prepend-dtb-uImage
|
2023-06-08 16:12:05 +00:00
|
|
|
KERNEL_INITRAMFS := kernel-bin | libdeflate-gzip | MuImage-initramfs gzip
|
2020-06-07 11:13:46 +00:00
|
|
|
IMAGE/factory.img := append-kernel | pad-to $$$$(KERNEL_SIZE) | append-ubi | \
|
|
|
|
netgear-dni | check-size
|
|
|
|
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
|
|
|
|
ARTIFACT/device-tree.dtb := export-dtb | uImage none
|
|
|
|
NETGEAR_BOARD_ID := WNDR4700
|
|
|
|
NETGEAR_HW_ID := 29763875+128+256
|
|
|
|
UBINIZE_OPTS := -E 5
|
|
|
|
SUPPORTED_DEVICES += wndr4700
|
2024-03-23 10:26:23 +00:00
|
|
|
DEVICE_COMPAT_VERSION := 2.0
|
|
|
|
DEVICE_COMPAT_MESSAGE := kernel and ubi partitions had to be resized. \
|
|
|
|
Upgrade via sysupgrade mechanism is not possible.
|
2020-06-07 11:13:46 +00:00
|
|
|
endef
|
|
|
|
TARGET_DEVICES += netgear_wndr4700
|