[OpenWrt-Devel] [PATCH 2/2] ath79: GL.iNet AR300M family: Correct DTS LED definitions

Jeff Kletsky lede at allycomm.com
Sun Feb 24 20:22:33 EST 2019


On 2/24/19 4:21 PM, Andreas Ziegler wrote:
> Hi Jeff,
>
> thanks for your suggested change!
> Although i agree with your change regarding USB GPIO, i don't with the
> other part.
>
> Using stock/vendor firmware, GPIO 12 is a green system/status LED and
> GPIO 14 is a red wifi LED.
>
> I just sent a patch to the list which fixes this in ar71xx target, maybe
> you can update your patch for ath79, too.
> see "[PATCH] ar71xx: GL.iNet AR300M family: correct LED definitions"
>
> Regards
>
> Andreas


Thank you for taking care of the ar71xx target.


I agree that the device has a red LED and have confirmed
with the manufacturer on this.  Alas, I'm behind in
updating the patch.


Jeff


>
> Jeff Kletsky schrieb am 28.01.19 um 03:54:
>> Resend as per M. Kreskin
>>
>>
>>  From f485678e7f37b3f2995fefc1e7c41794091bd73e Mon Sep 17 00:00:00 2001
>> From: Jeff Kletsky <git-commits at allycomm.com>
>> Date: Sun, 20 Jan 2019 14:48:09 -0800
>> Subject: [PATCH 2/2] ath79: GL.iNet AR300M family: Correct DTS LED
>> definitions
>>
>> Change the "status" LED to proper GPIO 12 and "red" naming.
>>
>> Remove GPIO 2 from definition as a USB LED.
>>
>> GPIO 2 is used to control power to the USB socket, not an LED.
>> As such, PWM on the line or typical LED triggers are inappropriate.
>> Users who wish to control the USB power for custom applications
>> can manipulate the GPIO through code, or for example, export it
>> through /sys/class/gpio/export.
>>
>> Runtime-tested:  GL.iNet AR300M-Lite
>>
>> Signed-off-by: Jeff Kletsky <git-commits at allycomm.com>
>> ---
>>   target/linux/ath79/dts/qca9531_glinet_gl-ar300m.dtsi | 11 ++---------
>>   1 file changed, 2 insertions(+), 9 deletions(-)
>>
>> diff --git a/target/linux/ath79/dts/qca9531_glinet_gl-ar300m.dtsi
>> b/target/linux/ath79/dts/qca9531_glinet_gl-ar300m.dtsi
>> index 2a0c4385cd..9baa6235b2 100644
>> --- a/target/linux/ath79/dts/qca9531_glinet_gl-ar300m.dtsi
>> +++ b/target/linux/ath79/dts/qca9531_glinet_gl-ar300m.dtsi
>> @@ -41,13 +41,6 @@
>>       leds {
>>           compatible = "gpio-leds";
>>
>> -        usb {
>> -            label = "gl-ar300m:green:usb";
>> -            gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
>> -            trigger-sources = <&hub_port>;
>> -            linux,default-trigger = "usbport";
>> -        };
>> -
>>           wlan {
>>               label = "gl-ar300m:green:wlan";
>>               gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
>> @@ -60,8 +53,8 @@
>>           };
>>
>>           led_status: status {
>> -            label = "gl-ar300m:green:status";
>> -            gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
>> +            label = "gl-ar300m:red:status";
>> +            gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
>>           };
>>       };
>>   };

_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list