]> www.infradead.org Git - users/jedix/linux-maple.git/commit
pwm: core: export pwm_get_state_hw()
authorDavid Lechner <dlechner@baylibre.com>
Tue, 29 Oct 2024 21:18:49 +0000 (16:18 -0500)
committerUwe Kleine-König <ukleinek@kernel.org>
Sun, 3 Nov 2024 20:13:21 +0000 (21:13 +0100)
commit2ea25aab938a250bdf3148acd15359b56b91b40e
tree9bd66a20cf822fc7ed63c77e92fc187564214a42
parentfdb62922ae89c17963f80abdd14b4d9f053bc962
pwm: core: export pwm_get_state_hw()

Export the pwm_get_state_hw() function. This is useful in cases where
we want to know what the hardware is actually doing, rather than what
what we requested it should do.

Locking had to be rearranged to ensure that the chip is still
operational before trying to access ops now that this can be called
from outside the pwm core.

Signed-off-by: David Lechner <dlechner@baylibre.com>
Link: https://lore.kernel.org/r/20241029-pwm-export-pwm_get_state_hw-v2-1-03ba063a3230@baylibre.com
[ukleinek: Add dummy for !CONFIG_PWM]
Signed-off-by: Uwe Kleine-König <ukleinek@kernel.org>
drivers/pwm/core.c
include/linux/pwm.h