]> www.infradead.org Git - users/jedix/linux-maple.git/commit
leds: pca955x: Add HW blink support
authorEddie James <eajames@linux.ibm.com>
Wed, 12 Feb 2025 14:30:38 +0000 (08:30 -0600)
committerLee Jones <lee@kernel.org>
Thu, 20 Feb 2025 14:29:41 +0000 (14:29 +0000)
commit575f10dc64a251fc69a3187f4058f272eab94bfe
treecc5f6c0cb3578a936e5cbae1f0480b835e12152f
parent14ef0738a31dcecfbba38626884b7d9a60b75cd0
leds: pca955x: Add HW blink support

Support blinking using the PCA955x chip. Use PWM0 for blinking
instead of LED_HALF brightness. Since there is only one frequency
and brightness register for any blinking LED, track the blink state
of each LED and only support one HW blinking frequency. If another
frequency is requested, fallback to software blinking. In addition,
blinked LEDs can only use full brightness in order to maintain 50%
duty cycle, which is required for the specified blink rate.

Signed-off-by: Eddie James <eajames@linux.ibm.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20250212143038.1416501-5-eajames@linux.ibm.com
Signed-off-by: Lee Jones <lee@kernel.org>
drivers/leds/leds-pca955x.c