ramips: use mt proprietary driver for Netgear R6800

Signed-off-by: noire11 <noire.wei@gmail.com>
Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
This commit is contained in:
noire11 2021-02-11 09:19:39 +08:00 committed by CN_SZTL
parent 0df51491b9
commit 0d5151f435
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
2 changed files with 17 additions and 29 deletions

View File

@ -9,7 +9,7 @@
compatible = "mediatek,mt7621-soc";
aliases {
label-mac-device = &gmac0;
label-mac-device = &ethernet;
led-boot = &led_power_white;
led-failsafe = &led_power_orange;
led-running = &led_power_white;
@ -161,39 +161,19 @@
};
};
&gmac0 {
&ethernet {
compatible = "mediatek,ralink-mt7621-eth";
mediatek,switch = <&gsw>;
mtd-mac-address = <&factory 0x4>;
};
&switch0 {
ports {
port@0 {
status = "okay";
label = "lan4";
};
/delete-property/ compatible;
phy-mode = "rgmii";
};
port@1 {
status = "okay";
label = "lan3";
};
port@2 {
status = "okay";
label = "lan2";
};
port@3 {
status = "okay";
label = "lan1";
};
port@4 {
status = "okay";
label = "wan";
mtd-mac-address = <&factory 0x4>;
mtd-mac-address-increment = <2>;
};
};
&gsw {
compatible = "mediatek,ralink-mt7621-gsw";
};
&i2c {

View File

@ -73,6 +73,10 @@ ramips_setup_interfaces()
mikrotik,routerboard-760igs)
ucidef_set_interfaces_lan_wan "lan2 lan3 lan4 lan5" "wan sfp"
;;
netgear,r6800)
ucidef_add_switch "switch0" \
"0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "4:wan" "6@eth0"
;;
phicomm,k2p|\
xiaoyu,xy-c5)
ucidef_add_switch "switch0" \
@ -170,6 +174,10 @@ ramips_setup_macs()
wan_mac=$label_mac
lan_mac=$(macaddr_add $label_mac 1)
;;
netgear,r6800)
lan_mac=$(mtd_get_mac_binary factory 0x4)
wan_mac=$(macaddr_add "$lan_mac" 2)
;;
phicomm,k2p)
wan_mac=$(mtd_get_mac_binary factory 0xe006)
;;