mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 06:09:23 -04:00
leds: qti-flash: Allow symmetrical switch on with no channels configured
Currently, with LED symmetry enabled, turning on a switch without configuring current in a channel first results in errors being seen. Without LED symmetry enabled, the same action results only in qti_flash_led_strobe() being called with the value argument set to zero. Bring about the same behaviour for LED symmetry as well. Change-Id: I2d6301ec3cc19d89acbd0545509485866ffa9085 Signed-off-by: Guru Das Srinagesh <gurus@codeaurora.org>
This commit is contained in:
parent
c671c54aa2
commit
ec2cf0ad13
1 changed files with 2 additions and 2 deletions
|
|
@ -522,8 +522,8 @@ static int qti_flash_led_symmetry_config(
|
|||
}
|
||||
|
||||
if (type == FLASH_LED_TYPE_UNKNOWN) {
|
||||
pr_err("Error in symmetry configuration for switch device\n");
|
||||
return -EINVAL;
|
||||
/* No channels are configured */
|
||||
return 0;
|
||||
}
|
||||
|
||||
for (i = 0; i < led->num_fnodes; i++) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue