summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAleksander Jan Bajkowski2025-02-16 22:23:17 +0000
committerDaniel Golle2025-03-01 03:04:18 +0000
commit25ea7ff393a17d7bb3e037e9536143d9707e7d7a (patch)
tree2ce0ca987e095a78e711172700d7ccee557a4f44
parentd50d51d74e93a057c607c9a4081ff3f29cbab38f (diff)
downloadopenwrt-25ea7ff393a17d7bb3e037e9536143d9707e7d7a.tar.gz
mediatek: filogic: migrate Acer W6/W6d to upstream PHY LED control
This commit switches the control of the leds connected to the Maxlinear GPY211C PHY to an upstream solution. There should be no functional changes. Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
-rw-r--r--target/linux/mediatek/dts/mt7986a-acer-predator-w6.dts19
-rw-r--r--target/linux/mediatek/dts/mt7986a-acer-predator-w6d.dts19
-rw-r--r--target/linux/mediatek/filogic/base-files/etc/board.d/01_leds5
3 files changed, 39 insertions, 4 deletions
diff --git a/target/linux/mediatek/dts/mt7986a-acer-predator-w6.dts b/target/linux/mediatek/dts/mt7986a-acer-predator-w6.dts
index 5002326d70..2fcbf3aa96 100644
--- a/target/linux/mediatek/dts/mt7986a-acer-predator-w6.dts
+++ b/target/linux/mediatek/dts/mt7986a-acer-predator-w6.dts
@@ -186,8 +186,23 @@
reset-gpios = <&pio 6 GPIO_ACTIVE_LOW>;
reset-assert-us = <10000>;
reset-deassert-us = <10000>;
- /* LED0: nc ; LED1: nc ; LED2: amber ; LED3: green */
- mxl,led-config = <0x0 0x0 0x370 0x380>;
+
+ leds {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ led-2 {
+ reg = <2>;
+ color = <LED_COLOR_ID_AMBER>;
+ function = LED_FUNCTION_WAN;
+ };
+
+ led-3 {
+ reg = <3>;
+ color = <LED_COLOR_ID_GREEN>;
+ function = LED_FUNCTION_WAN;
+ };
+ };
};
};
diff --git a/target/linux/mediatek/dts/mt7986a-acer-predator-w6d.dts b/target/linux/mediatek/dts/mt7986a-acer-predator-w6d.dts
index b2c35a6197..275f4134de 100644
--- a/target/linux/mediatek/dts/mt7986a-acer-predator-w6d.dts
+++ b/target/linux/mediatek/dts/mt7986a-acer-predator-w6d.dts
@@ -172,8 +172,23 @@
reset-gpios = <&pio 6 GPIO_ACTIVE_LOW>;
reset-assert-us = <10000>;
reset-deassert-us = <10000>;
- /* LED0: nc ; LED1: nc ; LED2: amber ; LED3: green */
- mxl,led-config = <0x0 0x0 0x370 0x380>;
+
+ leds {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ led-2 {
+ reg = <2>;
+ color = <LED_COLOR_ID_AMBER>;
+ function = LED_FUNCTION_WAN;
+ };
+
+ led-3 {
+ reg = <3>;
+ color = <LED_COLOR_ID_GREEN>;
+ function = LED_FUNCTION_WAN;
+ };
+ };
};
};
diff --git a/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds b/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds
index 3287cfe29b..53a0e1ad6f 100644
--- a/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds
+++ b/target/linux/mediatek/filogic/base-files/etc/board.d/01_leds
@@ -11,6 +11,11 @@ abt,asr3000)
ucidef_set_led_netdev "wlan2g" "WLAN2G" "green:wlan-2ghz" "phy0-ap0"
ucidef_set_led_netdev "wlan5g" "WLAN5G" "green:wlan-5ghz" "phy1-ap0"
;;
+acer,predator-w6|\
+acer,predator-w6d)
+ ucidef_set_led_netdev "internet" "INTERNET" "mdio-bus:06:amber:wan" "eth1" "link_10 link_100 link_1000 tx rx"
+ ucidef_set_led_netdev "internet" "INTERNET" "mdio-bus:06:green:wan" "eth1" "link_2500 tx rx"
+ ;;
asus,tuf-ax4200)
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:white:wan" "eth1" "link tx rx"
;;