]> www.infradead.org Git - linux.git/commit
leds: aw200xx: Calculate dts property display_rows in the driver
authorGeorge Stark <gnstark@salutedevices.com>
Sat, 25 Nov 2023 20:05:12 +0000 (23:05 +0300)
committerLee Jones <lee@kernel.org>
Wed, 13 Dec 2023 11:28:56 +0000 (11:28 +0000)
commit2b8db5729d10b23edd61e018c18fa7b865e2d76c
tree7c8255106a11d3a0381a96a03210e375256f01fa
parent20dbf6d4a19c5bb5d2521c4993d4373fbe05f1bc
leds: aw200xx: Calculate dts property display_rows in the driver

Get rid of device tree property "awinic,display-rows". The property
value actually means number of current switches and depends on how LEDs
are connected to the device. It should be calculated manually by max
used LED number. In the same way it is computed automatically now.
Max used LED is taken from LED definition subnodes.

Signed-off-by: George Stark <gnstark@salutedevices.com>
Signed-off-by: Dmitry Rokosov <ddrokosov@salutedevices.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20231125200519.1750-5-ddrokosov@salutedevices.com
Signed-off-by: Lee Jones <lee@kernel.org>
drivers/leds/leds-aw200xx.c