From 1afcadfcd184c3b52e38bae15c247a5fa4a0e054 Mon Sep 17 00:00:00 2001 From: Jacek Anaszewski Date: Mon, 19 Oct 2015 09:04:01 +0200 Subject: leds: core: Use set_brightness_work for the blocking op This patch makes LED core capable of setting brightness for drivers that implement brightness_set_blocking op. It removes from LED class drivers responsibility for using work queues on their own. In order to achieve this set_brightness_delayed callback is being modified to directly call one of available ops for brightness setting. led_set_brightness_async() function didn't set brightness in an asynchronous way in all cases. It was mistakenly assuming that all LED subsystem drivers used work queue in their brightness_set op, whereas only half of them did that. Since it has no users now, it is being removed. Signed-off-by: Jacek Anaszewski Acked-by: Sakari Ailus --- include/linux/leds.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/linux/leds.h') diff --git a/include/linux/leds.h b/include/linux/leds.h index 403fa8690295..b35e0f5b8d6c 100644 --- a/include/linux/leds.h +++ b/include/linux/leds.h @@ -158,7 +158,7 @@ extern void led_blink_set_oneshot(struct led_classdev *led_cdev, * * Set an LED's brightness, and, if necessary, cancel the * software blink timer that implements blinking when the - * hardware doesn't. + * hardware doesn't. This function is guaranteed not to sleep. */ extern void led_set_brightness(struct led_classdev *led_cdev, enum led_brightness brightness); -- cgit v1.2.3-59-g8ed1b