ramips: enable power LED and second uart on GL-MT300N-V2
authorBenjamin Valentin <benjamin.valentin@volatiles.de>
Tue, 20 Feb 2018 17:39:16 +0000 (18:39 +0100)
committerMathias Kresin <dev@kresin.me>
Fri, 23 Feb 2018 06:54:29 +0000 (07:54 +0100)
The device has a second uart accessible via pin headers, so enable it.

There is also a green power led which was not enabled previously.
Enable it too and use it as status LED.

Signed-off-by: Benjamin Valentin <benjamin.valentin@volatiles.de>
target/linux/ramips/base-files/etc/diag.sh
target/linux/ramips/dts/GL-MT300N-V2.dts

index 6038804b123422d6a3586388a761ff53d5addd2a..2e326af0ed8fd64222162bbe451c17e9d3e2bc3c 100644 (file)
@@ -191,7 +191,7 @@ get_status_led() {
                status_led="$boardname:blue:wifi"
                ;;
        gl-mt300n-v2)
-               status_led="$boardname:red:wlan"
+               status_led="$boardname:green:power"
                ;;
        m4-4M|\
        m4-8M)
index 8db3d4bc9177a627cf067814273f4c3d34be11f7..ada618f17bb05f575ab46f26d510fda312cc8c64 100644 (file)
        gpio-leds {
                compatible = "gpio-leds";
 
+               power {
+                       label = "gl-mt300n-v2:green:power";
+                       default-state = "on";
+                       gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+               };
+
                wan {
                        label = "gl-mt300n-v2:blue:wan";
                        gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
@@ -73,7 +79,7 @@
 &pinctrl {
        state_default: pinctrl0 {
                gpio {
-                       ralink,group = "wdt", "gpio", "wled_an", "p0led_an", "i2s";
+                       ralink,group = "wdt", "gpio", "wled_an", "p0led_an", "p1led_an", "i2s";
                        ralink,function = "gpio";
                };
        };
        };
 };
 
+&uart1 {
+       status = "okay";
+};
+
 &ehci {
        status = "okay";
 };