ramips: improve edimax 6200n/nl support
authorMathias Kresin <dev@kresin.me>
Tue, 27 Sep 2016 05:16:16 +0000 (07:16 +0200)
committerMathias Kresin <dev@kresin.me>
Sat, 15 Oct 2016 07:01:45 +0000 (09:01 +0200)
Assign the reset functionality to the wps/reset buttons. Use the wlan
switch of the 6200n to enable/disable wlan.

Add the internet led of the 6200nl and use the led for boot status
indication

Signed-off-by: Mathias Kresin <dev@kresin.me>
target/linux/ramips/base-files/etc/board.d/01_leds
target/linux/ramips/base-files/etc/diag.sh
target/linux/ramips/dts/3G-6200N.dts
target/linux/ramips/dts/3G-6200NL.dts

index e3b2177820304f0ad077b934ca85749beb0540cb..e14448e3f27012b926fa2a073ab392617f090cdf 100755 (executable)
@@ -26,6 +26,9 @@ case $board in
        set_usb_led "$board:blue:3g"
        ;;
 3g-6200nl|\
+wnce2001)
+       set_wifi_led "$board:green:wlan"
+       ;;
 br-6475nd|\
 mzk-w300nh2)
        set_wifi_led "$board:amber:wlan"
@@ -306,9 +309,6 @@ whr-600d)
        ucidef_set_led_default "power" "power" "$board:green:power" "1"
        ucidef_set_led_default "router" "router" "$board:green:router" "1"
        ;;
-wnce2001)
-       set_wifi_led "$board:green:wlan"
-       ;;
 wrh-300cr)
        set_wifi_led "$board:green:wlan"
        ucidef_set_led_netdev "lan" "lan" "$board:green:ethernet" "eth0"
index 2f092b0bca3c55c8bcf6184133fbe0f56da6f90a..67dcf99a00230b4e183325440852f8337a6f29bc 100644 (file)
@@ -36,6 +36,9 @@ get_status_led() {
        xdxrn502j)
                status_led="$board:green:power"
                ;;
+       3g-6200nl)
+               status_led="$board:green:internet"
+               ;;
        a5-v11|\
        cs-qr10|\
        d105|\
index cd2ba51d1ac1e7d01cee7b7f3da10b6cd4a532de..a8032c5a78d5acf8f8561b77468174f07651960a 100644 (file)
                #size-cells = <0>;
                poll-interval = <20>;
 
-               wps {
-                       label = "wps";
+               reset {
+                       label = "reset";
                        gpios = <&gpio0 12 1>;
-                       linux,code = <0x211>;
+                       linux,code = <0x198>;
                };
 
-               wlanswitch {
+               rfkill {
                        label = "wlanswitch";
                        gpios = <&gpio0 13 1>;
-                       linux,code = <0x100>;
+                       linux,code = <0xf7>;
                };
        };
 };
index 7ef7618f6843490af97457a836eea3c8d82d0761..453e45b0226067892842bdeb68bf165f0bfec951 100644 (file)
        gpio-leds {
                compatible = "gpio-leds";
 
+               internet {
+                       label = "3g-6200nl:green:internet";
+                       gpios = <&gpio0 9 1>;
+               };
+
                wlan {
-                       label = "3g-6200nl:amber:wlan";
+                       label = "3g-6200nl:green:wlan";
                        gpios = <&gpio0 14 1>;
                };
        };
                #size-cells = <0>;
                poll-interval = <20>;
 
-               wps {
-                       label = "wps";
+               reset {
+                       label = "reset";
                        gpios = <&gpio0 12 1>;
-                       linux,code = <0x211>;
+                       linux,code = <0x198>;
                };
        };
 };