]> www.infradead.org Git - users/jedix/linux-maple.git/commit
pwm: Check for CONFIG_PWM using IS_REACHABLE() in main header
authorUwe Kleine-König <u.kleine-koenig@baylibre.com>
Mon, 17 Feb 2025 10:25:02 +0000 (11:25 +0100)
committerUwe Kleine-König <ukleinek@kernel.org>
Fri, 28 Feb 2025 22:56:07 +0000 (23:56 +0100)
commit4b31eb55dbc64d72ff57a1888f8e4d7996a693bc
tree23fb1c584dc4fcd04d9555831911314618de0ab9
parent058210e84b48dbb670a6bf72afaed6fbd8043a37
pwm: Check for CONFIG_PWM using IS_REACHABLE() in main header

Preparing CONFIG_PWM becoming tristate the right magic to check for the
availability of the pwm functions is using IS_REACHABLE() and not
IS_ENABLED(). The latter gives the wrong result for built-in code with
CONFIG_PWM=m.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Link: https://lore.kernel.org/r/20250217102504.687916-2-u.kleine-koenig@baylibre.com
Signed-off-by: Uwe Kleine-König <ukleinek@kernel.org>
include/linux/pwm.h