Skip to content

Commit

Permalink
ath79: improve support for GL.iNet GL-XE300
Browse files Browse the repository at this point in the history
- fix eth0 eth1 sharing same mac so it conforms to the behavior stated
  in the original commit and the way it is in vendor firmware :
  WAN is label, LAN is label +1 and WLAN is label +2
- add default leds config
- add default network config

Signed-off-by: Pascal Coudurier <coudu@wanadoo.fr>
  • Loading branch information
Pascal Coudurier authored and blocktrron committed Mar 17, 2022
1 parent 83ca16f commit 0905b07
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion target/linux/ath79/dts/qca9531_glinet_gl-xe300.dts
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,12 @@

nvmem-cells = <&macaddr_art_0>;
nvmem-cell-names = "mac-address";
mac-address-increment = <1>;
};

&eth1 {
nvmem-cells = <&macaddr_art_0>;
nvmem-cell-names = "mac-address";
mac-address-increment = <1>;
};

&wmac {
Expand Down
4 changes: 4 additions & 0 deletions target/linux/ath79/nand/base-files/etc/board.d/01_leds
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ glinet,gl-ar300m-nand|\
glinet,gl-ar300m-nor)
ucidef_set_led_netdev "lan" "LAN" "green:lan" "eth0"
;;
glinet,gl-xe300)
ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth1"
ucidef_set_led_switch "lan" "LAN" "green:lan" "switch0" "0x10"
;;
netgear,r6100)
ucidef_set_led_netdev "wan-green" "WAN (green)" "green:wan" "eth1"
;;
Expand Down
5 changes: 5 additions & 0 deletions target/linux/ath79/nand/base-files/etc/board.d/02_network
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@ ath79_setup_interfaces()
ucidef_add_switch "switch0" \
"0@eth0" "2:lan:2" "3:lan:1" "1:wan"
;;
glinet,gl-xe300)
ucidef_set_interface_wan "eth1"
ucidef_add_switch "switch0" \
"0@eth0" "4:lan"
;;
netgear,r6100)
ucidef_set_interface_wan "eth1"
ucidef_add_switch "switch0" \
Expand Down

0 comments on commit 0905b07

Please sign in to comment.