leds: bcm6358: Use bcm6358_led_set() in order to get rid of the lock
Replaces bcm6358_led_mode with bcm6358_led_set so we don't need to handle the lock. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com>
This commit is contained in:
parent
0171dc6abb
commit
42273caa18
|
@ -141,9 +141,10 @@ static int bcm6358_led(struct device *dev, struct device_node *nc, u32 reg,
|
|||
} else {
|
||||
led->cdev.brightness = LED_OFF;
|
||||
}
|
||||
bcm6358_led_mode(led, led->cdev.brightness);
|
||||
spin_unlock_irqrestore(lock, flags);
|
||||
|
||||
bcm6358_led_set(&led->cdev, led->cdev.brightness);
|
||||
|
||||
led->cdev.brightness_set = bcm6358_led_set;
|
||||
|
||||
rc = led_classdev_register(dev, &led->cdev);
|
||||
|
|
Loading…
Reference in New Issue