mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-18 07:23:59 +00:00
ramips: mi ac2100: switch to new hnat driver
This commit is contained in:
parent
0eed36f2ea
commit
f46c60443c
target/linux/ramips
dts
mt7621_xiaomi_mi-router-ac2100.dtsmt7621_xiaomi_redmi-router-ac2100.dtsmt7621_xiaomi_router-ac2100.dtsi
mt7621/base-files/etc/board.d
@ -11,7 +11,7 @@
|
||||
led-failsafe = &led_status_yellow;
|
||||
led-running = &led_status_blue;
|
||||
led-upgrade = &led_status_blue;
|
||||
label-mac-device = ðernet;
|
||||
label-mac-device = &gmac0;
|
||||
};
|
||||
|
||||
leds {
|
||||
|
@ -11,7 +11,7 @@
|
||||
led-failsafe = &led_status_amber;
|
||||
led-running = &led_status_white;
|
||||
led-upgrade = &led_status_white;
|
||||
label-mac-device = ðernet;
|
||||
label-mac-device = &gmac0;
|
||||
};
|
||||
|
||||
leds {
|
||||
|
@ -24,19 +24,30 @@
|
||||
};
|
||||
};
|
||||
|
||||
ðernet {
|
||||
compatible = "mediatek,ralink-mt7621-eth";
|
||||
mediatek,switch = <&gsw>;
|
||||
&gmac0 {
|
||||
mtd-mac-address = <&factory 0xe000>;
|
||||
};
|
||||
|
||||
&switch0 {
|
||||
/delete-property/ compatible;
|
||||
phy-mode = "rgmii";
|
||||
&gmac1 {
|
||||
mtd-mac-address = <&factory 0xe006>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gsw {
|
||||
compatible = "mediatek,ralink-mt7621-gsw";
|
||||
mediatek,portmap = "wllll";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&hnat {
|
||||
mtketh-wan = "eth1";
|
||||
mtketh-ppd = "eth0";
|
||||
mtketh-lan = "eth0";
|
||||
mtketh-max-gmac = <2>;
|
||||
/delete-property/ mtkdsa-wan-port;
|
||||
};
|
||||
|
||||
&switch0 {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&state_default {
|
||||
|
@ -96,7 +96,7 @@ ramips_setup_interfaces()
|
||||
xiaomi,mi-router-ac2100|\
|
||||
xiaomi,redmi-router-ac2100)
|
||||
ucidef_add_switch "switch0" \
|
||||
"2:lan:1" "3:lan:2" "4:lan:3" "0:wan" "6@eth0"
|
||||
"2:lan:1" "3:lan:2" "4:lan:3" "0:wan" "6u@eth0" "5u@eth1"
|
||||
ucidef_set_interface_lan "eth0.1 ra0 rai0"
|
||||
;;
|
||||
zyxel,nr7101)
|
||||
@ -142,9 +142,7 @@ ramips_setup_macs()
|
||||
wan_mac="$(grep -m1 mac= "/dev/mtd${index}" | cut -d= -f2)"
|
||||
lan_mac=$wan_mac
|
||||
;;
|
||||
d-team,newifi-d2|\
|
||||
xiaomi,mi-router-ac2100|\
|
||||
xiaomi,redmi-router-ac2100)
|
||||
d-team,newifi-d2)
|
||||
lan_mac=$(cat /sys/class/net/eth0/address)
|
||||
wan_mac=$(mtd_get_mac_binary factory 0xe006)
|
||||
;;
|
||||
|
Loading…
Reference in New Issue
Block a user