From 256ac6a6c64798eca80f83d952973cd22c9ce53b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabian=20Bl=C3=A4se?= Date: Mon, 12 Jul 2021 15:33:10 +0200 Subject: [PATCH] Add support for Xiaomi Mi Router 4A (Gigabit Edition) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Fabian Bläse Reviewed-by: Christian Dresel Tested-by: Fabian Bläse --- bsp/ramips-mt7621.bsp | 1 + bsp/ramips-mt7621/.config | 2 ++ .../fff/fff-network/files/lib/functions/fff/cpuport | 3 ++- .../fff-network/mipsel/network.xiaomi,mi-router-4a-gigabit | 6 ++++++ 4 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 src/packages/fff/fff-network/mipsel/network.xiaomi,mi-router-4a-gigabit diff --git a/bsp/ramips-mt7621.bsp b/bsp/ramips-mt7621.bsp index c06e41a8..091c5d1d 100644 --- a/bsp/ramips-mt7621.bsp +++ b/bsp/ramips-mt7621.bsp @@ -5,4 +5,5 @@ images=( "openwrt-ramips-mt7621-netgear_r6220-squashfs-*" "openwrt-ramips-mt7621-ubnt_edgerouter-x-squashfs-*" "openwrt-ramips-mt7621-ubnt_edgerouter-x-sfp-squashfs-*" + "openwrt-ramips-mt7621-xiaomi_mi-router-4a-gigabit-squashfs-*" ) diff --git a/bsp/ramips-mt7621/.config b/bsp/ramips-mt7621/.config index c86ca2c9..bc7766a9 100644 --- a/bsp/ramips-mt7621/.config +++ b/bsp/ramips-mt7621/.config @@ -10,6 +10,8 @@ CONFIG_TARGET_DEVICE_ramips_mt7621_DEVICE_ubnt_edgerouter-x=y CONFIG_TARGET_DEVICE_PACKAGES_ramips_mt7621_DEVICE_ubnt_edgerouter-x="" CONFIG_TARGET_DEVICE_ramips_mt7621_DEVICE_ubnt_edgerouter-x-sfp=y CONFIG_TARGET_DEVICE_PACKAGES_ramips_mt7621_DEVICE_ubnt_edgerouter-x-sfp="" +CONFIG_TARGET_DEVICE_ramips_mt7621_DEVICE_xiaomi_mi-router-4a-gigabit=y +CONFIG_TARGET_DEVICE_PACKAGES_ramips_mt7621_DEVICE_xiaomi_mi-router-4a-gigabit="" CONFIG_BUSYBOX_CUSTOM=y CONFIG_TARGET_PER_DEVICE_ROOTFS=y # CONFIG_BUSYBOX_CONFIG_BRCTL is not set diff --git a/src/packages/fff/fff-network/files/lib/functions/fff/cpuport b/src/packages/fff/fff-network/files/lib/functions/fff/cpuport index 3d153b34..5a15f1c4 100644 --- a/src/packages/fff/fff-network/files/lib/functions/fff/cpuport +++ b/src/packages/fff/fff-network/files/lib/functions/fff/cpuport @@ -31,7 +31,8 @@ get_cpu_port() { ubnt,nanostation-m|\ ubnt,picostation-m|\ ubnt,unifi|\ - ubnt,unifiac-mesh) + ubnt,unifiac-mesh|\ + xiaomi,mi-router-4a-gigabit) CPUPORT="" ;; tplink,tl-wr1043nd-v1) diff --git a/src/packages/fff/fff-network/mipsel/network.xiaomi,mi-router-4a-gigabit b/src/packages/fff/fff-network/mipsel/network.xiaomi,mi-router-4a-gigabit new file mode 100644 index 00000000..dd32a3e0 --- /dev/null +++ b/src/packages/fff/fff-network/mipsel/network.xiaomi,mi-router-4a-gigabit @@ -0,0 +1,6 @@ +WANDEV=switch0 +SWITCHDEV=switch0 +CLIENT_PORTS="lan2" +WAN_PORTS="wan" +BATMAN_PORTS="lan1" +DSA=1