orion5x and GPIO blink question

Benjamin Herrenschmidt benh at kernel.crashing.org
Wed Apr 21 17:31:13 EDT 2010


> If you have blink enabled/disabled options along with set_brightness you
> can end up in a state where you disable blinking but the brightness the
> LED is left with is effectively random. This is why the LED core does
> things that way and I stand by that as it gives defined behaviour (and
> mirrors the sysfs interface).
> 
> I appreciate in the world of GPIO controllers and the leds-gpio layer
> this is tricky to implement but this is more of a mismatch between the
> GPIO layer and the LED subsystem which was not addressed in the design
> of leds-gpio.

I do agree that it does make some amount of sense from the pure
standpoint of the LED subsystem (and I still somewhat dislike the API
with it's two output parameter function, dunno, somewhat hurts me to see
that in C :-)

You are right in that it's more of a gpio-leds issue. I'll look into
changing the prototype of gpio-leds own set_blink() to sort that out and
fix existing users, maybe this week-end. 

This is not a blocking issue for that dns323 rev C1 support anyways,
just something I noticed in passing, with the current code, the LED is
somewhat hard to be coerced into doing what I want :-)

Cheers,
Ben.





More information about the linux-arm-kernel mailing list