lkml.org 
[lkml]   [2015]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH/RFC RESEND] leds: Use set_brightness_work for brightness_set ops that can sleep
On 06/30/2015 01:58 PM, Pavel Machek wrote:
> On Tue 2015-06-30 10:01:08, Jacek Anaszewski wrote:
>> This patch rearranges the core LED subsystem code, so that it
>> now removes from drivers the responsibility of using work queues
>> internally in case their brightness_set ops can sleep.
>> Addition of two flags: LED_BRIGHTNESS_FAST and LED_BLINK_DISABLE
>> as well as new_brightness_value property to the struct led_classdev
>> allows for employing existing set_brightness_work to do the job.
>> The modifications allow also to get rid of brightness_set_sync op,
>> as flash LED devices can now be handled properly only basing on the
>> SET_BRIGHTNESS_SYNC flag.
>
> Are you sure this is good idea?
>
> You'll now use single callback for blocking and non-blocking
> behaviour. I'm pretty sure stuff like lockdep will have some fun with
> that.

I enabled "Lock Debugging" options and didn't get any warning.
Could you describe the use case you are thinking of?

--
Best Regards,
Jacek Anaszewski


\
 
 \ /
  Last update: 2015-06-30 15:21    [W:0.105 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site