From da075c1965460bb8ce87f7ce5f4bf0cc8dcc9c3d Mon Sep 17 00:00:00 2001 From: CN_SZTL Date: Sun, 19 Jul 2020 20:16:32 +0800 Subject: [PATCH] target/ramips: sync with recently changes from Lean --- .../dts/mt7621_xiaomi_router-ac2100.dtsi | 1 - target/linux/ramips/image/mt7621.mk | 32 ++++++++----------- .../mt7621/base-files/etc/board.d/01_leds | 6 ++-- 3 files changed, 16 insertions(+), 23 deletions(-) diff --git a/target/linux/ramips/dts/mt7621_xiaomi_router-ac2100.dtsi b/target/linux/ramips/dts/mt7621_xiaomi_router-ac2100.dtsi index ee92d4c20f..878357eff6 100644 --- a/target/linux/ramips/dts/mt7621_xiaomi_router-ac2100.dtsi +++ b/target/linux/ramips/dts/mt7621_xiaomi_router-ac2100.dtsi @@ -6,7 +6,6 @@ #include / { - chosen { bootargs = "console=ttyS0,115200n8"; }; diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk index e1d49436f4..db9d351517 100644 --- a/target/linux/ramips/image/mt7621.mk +++ b/target/linux/ramips/image/mt7621.mk @@ -946,23 +946,7 @@ define Device/xiaomi_mir4 endef TARGET_DEVICES += xiaomi_mir4 -define Device/xiaomi_mi-router-ac2100 - BLOCKSIZE := 128k - PAGESIZE := 2048 - KERNEL_SIZE := 4096k - IMAGE_SIZE := 120320k - UBINIZE_OPTS := -E 5 - IMAGES += kernel1.bin rootfs0.bin - IMAGE/kernel1.bin := append-kernel - IMAGE/rootfs0.bin := append-ubi | check-size $$$$(IMAGE_SIZE) - IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata - DEVICE_VENDOR := Xiaomi - DEVICE_MODEL := Mi Router AC2100 - DEVICE_PACKAGES := kmod-mt7603 kmod-mt7615e wpad-openssl uboot-envtools -endef -TARGET_DEVICES += xiaomi_mi-router-ac2100 - -define Device/xiaomi_redmi-router-ac2100 +define Device/xiaomi-ac2100 BLOCKSIZE := 128k PAGESIZE := 2048 KERNEL_SIZE := 4096k @@ -972,11 +956,21 @@ define Device/xiaomi_redmi-router-ac2100 IMAGE/kernel1.bin := append-kernel IMAGE/rootfs0.bin := append-ubi | check-size $$$$(IMAGE_SIZE) IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata - IMAGE/factory.bin := append-kernel | pad-to $$(KERNEL_SIZE) | append-ubi | check-size $$$$(IMAGE_SIZE) + IMAGE/factory.bin := append-kernel | pad-to $$(KERNEL_SIZE) | append-ubi | check-size DEVICE_VENDOR := Xiaomi - DEVICE_MODEL := Redmi Router AC2100 DEVICE_PACKAGES := kmod-mt7603 kmod-mt7615e wpad-openssl uboot-envtools endef + +define Device/xiaomi_mi-router-ac2100 + $(Device/xiaomi-ac2100) + DEVICE_MODEL := Mi Router AC2100 +endef +TARGET_DEVICES += xiaomi_mi-router-ac2100 + +define Device/xiaomi_redmi-router-ac2100 + $(Device/xiaomi-ac2100) + DEVICE_MODEL := Redmi Router AC2100 +endef TARGET_DEVICES += xiaomi_redmi-router-ac2100 define Device/xiaoyu_xy-c5 diff --git a/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds b/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds index 4d41881c16..626ae54abc 100755 --- a/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds +++ b/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds @@ -89,15 +89,15 @@ xiaomi,mir3p) ucidef_set_led_switch "lan2-amber" "LAN2 (amber)" "$boardname:amber:lan2" "switch0" "0x04" "0x08" ucidef_set_led_switch "lan3-amber" "LAN3 (amber)" "$boardname:amber:lan3" "switch0" "0x08" "0x08" ;; -xzwifi,creativebox-v1) - ucidef_set_led_switch "internet" "internet" "$boardname:blue:internet" "switch0" "0x10" - ;; xiaomi,mi-router-ac2100) ucidef_set_led_netdev "wan" "wan" "$boardname:blue:wan" "wan" ;; xiaomi,redmi-router-ac2100) ucidef_set_led_netdev "wan" "wan" "$boardname:white:wan" "wan" ;; +xzwifi,creativebox-v1) + ucidef_set_led_switch "internet" "internet" "$boardname:blue:internet" "switch0" "0x10" + ;; youhua,wr1200js) ucidef_set_led_switch "internet" "INTERNET" "$boardname:green:wan" "switch0" "0x01" ;;