]> www.infradead.org Git - users/jedix/linux-maple.git/commit
leds: leds-lp55xx: Generalize run_engine function
authorChristian Marangi <ansuelsmth@gmail.com>
Wed, 26 Jun 2024 16:00:12 +0000 (18:00 +0200)
committerLee Jones <lee@kernel.org>
Wed, 26 Jun 2024 16:08:30 +0000 (17:08 +0100)
commit42a9eaac9784e9b3df56f1947526d7d4d0ed9b26
tree696bb7d5d2e0ebff33543e879208ea86f04050d2
parent409a9dc53682b9f02793584d17721ab3e1b9c86f
leds: leds-lp55xx: Generalize run_engine function

Generalize run_engine function for lp55xx based LED driver. The logic is
similar to every LED driver, rework it with more macro magic and account
for LED model that might have OP MODE and EXEC at base offset in the
reg.

Update any lp55xx based LED driver to use this generalized function and
declare required bits.

Suggested-by: Lee Jones <lee@kernel.org>
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Link: https://lore.kernel.org/r/20240626160027.19703-8-ansuelsmth@gmail.com
Signed-off-by: Lee Jones <lee@kernel.org>
drivers/leds/leds-lp5521.c
drivers/leds/leds-lp5523.c
drivers/leds/leds-lp5562.c
drivers/leds/leds-lp55xx-common.c
drivers/leds/leds-lp55xx-common.h
drivers/leds/leds-lp8501.c