|
| 1 | +diff --git a/target/linux/ramips/base-files/etc/board.d/02_network b/target/linux/ramips/base-files/etc/board.d/02_network |
| 2 | +index 8ca1831afe..24b895c92b 100755 |
| 3 | +--- a/target/linux/ramips/base-files/etc/board.d/02_network |
| 4 | ++++ b/target/linux/ramips/base-files/etc/board.d/02_network |
| 5 | +@@ -310,7 +310,8 @@ ramips_setup_interfaces() |
| 6 | + ucidef_add_switch "switch0" \ |
| 7 | + "4:lan" "6t@eth0" |
| 8 | + ;; |
| 9 | +- cudy,wr1000) |
| 10 | ++ cudy,wr1000|\ |
| 11 | ++ xiaomi,mi-router-4a-gigabit) |
| 12 | + ucidef_add_switch "switch0" \ |
| 13 | + "2:lan:2" "3:lan:1" "4:wan" "6@eth0" |
| 14 | + ;; |
| 15 | +@@ -687,6 +688,10 @@ ramips_setup_macs() |
| 16 | + xiaomi,mir3p) |
| 17 | + lan_mac=$(mtd_get_mac_binary Factory 0xe006) |
| 18 | + ;; |
| 19 | ++ xiaomi,mi-router-4a-gigabit) |
| 20 | ++ wan_mac=$(mtd_get_mac_binary factory 0xe006) |
| 21 | ++ label_mac=$wan_mac |
| 22 | ++ ;; |
| 23 | + zyxel,keenetic-start) |
| 24 | + wan_mac=$(mtd_get_mac_binary factory 40) |
| 25 | + ;; |
| 26 | +diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk |
| 27 | +index 28ae0d451f..084c03b2a9 100644 |
| 28 | +--- a/target/linux/ramips/image/mt7621.mk |
| 29 | ++++ b/target/linux/ramips/image/mt7621.mk |
| 30 | +@@ -60,6 +60,14 @@ define Build/wr1201-factory-header |
| 31 | + mv $@.new $@ |
| 32 | + endef |
| 33 | + |
| 34 | ++define Build/mi-router-4a-gigabit-factory-header |
| 35 | ++ mkimage -A $(LINUX_KARCH) \ |
| 36 | ++ -O linux -T kernel \ |
| 37 | ++ -C lzma -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \ |
| 38 | ++ -n 'R4A' -d $@ $@.new |
| 39 | ++ mv $@.new $@ |
| 40 | ++endef |
| 41 | ++ |
| 42 | + define Build/netis-tail |
| 43 | + echo -n $(1) >> $@ |
| 44 | + echo -n $(UIMAGE_NAME)-yun | $(STAGING_DIR_HOST)/bin/mkhash md5 | \ |
| 45 | +@@ -298,6 +306,18 @@ define Device/xiaomi_mir3g |
| 46 | + endef |
| 47 | + TARGET_DEVICES += xiaomi_mir3g |
| 48 | + |
| 49 | ++define Device/xiaomi_mi-router-4a-gigabit |
| 50 | ++ DTS := XIAOMI-MIR4A-GIGABIT |
| 51 | ++ MTK_SOC := mt7621 |
| 52 | ++ IMAGE_SIZE := 14848k |
| 53 | ++ DEVICE_VENDOR := Xiaomi |
| 54 | ++ DEVICE_TITLE := Xiaomi Mi Router 4A Gigabit Edition |
| 55 | ++ DEVICE_VARIANT := Gigabit Edition |
| 56 | ++ DEVICE_MODEL := Mi Router 4A |
| 57 | ++ DEVICE_PACKAGES := kmod-mt7603-compat kmod-mt76x2-compat wpad-basic uboot-envtools |
| 58 | ++endef |
| 59 | ++TARGET_DEVICES += xiaomi_mi-router-4a-gigabit |
| 60 | ++ |
| 61 | + define Device/mt7621 |
| 62 | + DTS := MT7621 |
| 63 | + BLOCKSIZE := 64k |
| 64 | +@@ -384,6 +404,7 @@ define Device/netgear_r6350 |
| 65 | + IMAGE/kernel.bin := append-kernel |
| 66 | + IMAGE/rootfs.bin := append-ubi | check-size $$$$(IMAGE_SIZE) |
| 67 | + DEVICE_TITLE := Netgear R6350 |
| 68 | ++ DEVICE_MODEL := netgear_r6350 |
| 69 | + DEVICE_PACKAGES := \ |
| 70 | + kmod-mt7603 kmod-mt7615e kmod-usb3 kmod-usb-ledtrig-usbport wpad-basic |
| 71 | + endef |
0 commit comments