leds: qti-flash: Handle all-enabled led mask separately
In certain devices, LED channels are paired and connected to two
separate LEDs. Due to symmetrical configuration, a switch that controls
all four channels sets the same brightness value to both LEDs, which is
not the intended behaviour; hence, handle this case separately.
E.g. If flash0 (group 1) is set to 144 and flash1 (group 2) is set to
1056, current will be distributed evenly to all 4 channels like so: 300
mA would be set on all channels (as 144 + 1056 = 1200; 1200 / 4 = 300).
Change this to:
144 / 2 = 72 on channels 0 and 3 (group 1)
1056 / 2 = 528 on channels 1 and 2 (group 2).
Change-Id: Ie135811d59104cfa5551d17ebbb729a57c101099
Signed-off-by:
Guru Das Srinagesh <gurus@codeaurora.org>
Loading
Please register or sign in to comment