dir-882 usb led support

Gagan Sidhu broly at mac.com
Mon Jan 11 18:55:22 EST 2021


yeah, it will.

i don’t like how many files there are. 

i was looking at the 8xx-x1, 882-a1 and mt7621.dtsi. completely overlooked there may have also been an 882-x1.dtsi *eye roll*
	-sometimes “factorisation” is a freakin’ nuisance.

this will for sure fix that problem. if only we could attach this to the mailing list to show how dumb i am (i have put it as a recipient).

thanks again pal

Thanks,
Gagan

> On Jan 11, 2021, at 4:45 PM, Alberto Bursi <bobafetthotmail at gmail.com> wrote:
> 
> Yeah if you are hacking the dts for your custom build then you can just copy-paste the contents of that file and it should fix the leds
> 
> -Alberto
> 
> On 12/01/21 00:40, Gagan Sidhu wrote:
>> nah this should work, thank you.
>> i am using the DTSes but not in the exact same way.
>> this is partially due to me using kernel 4.x and thus the mt7621.dtsi has slightly different properties.
>>  - wouldn’t work with 4.x mtk_eth_soc ethernet driver (esp w/  hardware nat and flow offload, no longer in driver).
>> thank you sir!
>> Thanks,
>> Gagan
>>> On Jan 11, 2021, at 4:38 PM, Alberto Bursi <bobafetthotmail at gmail.com <mailto:bobafetthotmail at gmail.com>> wrote:
>>> 
>>> If you look at the commit that added support for that device:
>>> https://github.com/openwrt/openwrt/commit/28262f815e4d0fe5302babc696ed5ce518b33759
>>> 
>>> 
>>> you see that your device's dts is this file
>>> https://github.com/openwrt/openwrt/tree/master/target/linux/ramips/dts/mt7621_dlink_dir-882-r1.dts
>>> 
>>> and it is calling in two other dts files where most of the contents are.
>>> One is the one you also linked, the other is this
>>> https://github.com/openwrt/openwrt/tree/master/target/linux/ramips/dts/mt7621_dlink_dir-882-x1.dtsi
>>> 
>>> where you actually find that both USB leds are defined and have default trigger set to "usbport".
>>> 
>>> 
>>> I don't know why it does not work in your device, maybe there is a typo somewhere 
>>> or it is a slightly different hardware revision where the USB leds are on a different GPIO line.
>>> 
>>> If it matters to you you can send an email to the guy that added support for this device (his email is in the commit above), and ask him.
>>> 
>>> Just waiting works for things that are not developed by OpenWrt (the wifi driver comes from Linux, upstream), 
>>> but is not the best way to solve OpenWrt-specific issues like wrong ports or leds or whatever.
>>> 
>>> -Alberto
>>> 
>>> 
>>> On 11/01/21 20:17, Gagan Sidhu wrote:
>>>> hi alberto,
>>>> yeah i checked out the latest git and this is the relevant DTS file:
>>>> https://github.com/openwrt/openwrt/blob/master/target/linux/ramips/dts/mt7621_dlink_dir-8xx-x1.dtsi 
>>>> i am assuming it’s not trivial to add the usb trigger and that’s why it is not done.
>>>> it’s not a huge concern at this point anyways.
>>>> 	-it seems the driver still needs a bit more work on the mt7615 chipset.
>>>> -mind you, it’s markedly improved from two years ago, but i’ve had a few-too-many niggles on 5 Ghz (2.4Ghz works well) so i’m sitting pat.
>>>> who knows, maybe it’ll be dealt with in a few months.
>>>> Thanks,
>>>> Gagan
>>>>> On Jan 11, 2021, at 12:14 PM, Alberto Bursi <bobafetthotmail at gmail.com <mailto:bobafetthotmail at gmail.com>> wrote:
>>>>> 
>>>>> 
>>>>> On 09/01/21 03:54, Gagan Sidhu via openwrt-devel wrote:
>>>>>> The sender domain has a DMARC Reject/Quarantine policy which disallows
>>>>>> sending mailing list messages using the original "From" header.
>>>>>> To mitigate this problem, the original message has been wrapped
>>>>>> hi,
>>>>> 
>>>>>> using the latest stuff from you guys, and i noticed the usb leds aren’t included in the dts.
>>>>>> is there an option i’m missing?
>>>>> 
>>>>>> currently i have:
>>>>>> CONFIG_NEW_LEDS=y
>>>>>> CONFIG_LEDS_CLASS=y
>>>>>> CONFIG_LEDS_GPIO=y
>>>>>> CONFIG_LED_TRIGGER_PHY=y
>>>>>> CONFIG_USB_LEDS_TRIGGER_USBPORT=y
>>>>>> CONFIG_LEDS_TRIGGER_GPIO=y
>>>>> 
>>>>>> enabled. what could i be missing?
>>>>> 
>>>>>> nice to see mt76 caught up to the proprietary driver.
>>>>> 
>>>>>> Thanks,
>>>>>> Gagan
>>>>>> _______________________________________________
>>>>>> openwrt-devel mailing list
>>>>>> openwrt-devel at lists.openwrt.org <mailto:openwrt-devel at lists.openwrt.org>
>>>>>> https://lists.openwrt.org/mailman/listinfo/openwrt-devel
>>>>> 
>>>>> 
>>>>> The things you posted are kernel config, if there is no usb led defined in dts file then that led will never work until you add it to the dts.
>>>>> 
>>>>> What device is this? Did you check the commit of the person that added it to OpenWrt? Maybe they explain why there is no USB led.
>>>>> 
>>>>> -Alberto



Thanks,
Gagan


More information about the openwrt-devel mailing list