pwm: crc: Allow compilation as module and with COMPILE_TEST
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Fri, 4 Aug 2023 14:27:07 +0000 (16:27 +0200)
committerThierry Reding <thierry.reding@gmail.com>
Fri, 13 Oct 2023 08:07:17 +0000 (10:07 +0200)
The driver compiles just fine as a module. The parent driver's Kconfig
symbol already depends on X86 || COMPILE_TEST, so X86 can just be
dropped from the dependencies allowing compilation on other platforms
than x86.

Link: https://lore.kernel.org/r/20230804142707.412137-3-u.kleine-koenig@pengutronix.de
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
drivers/pwm/Kconfig
drivers/pwm/pwm-crc.c

index 502d041d4a11ed121a93deb2424e4c837611f144..ce22b1f311f5ae1829943dadebcc5dacec24cd2a 100644 (file)
@@ -173,8 +173,8 @@ config PWM_CLPS711X
          will be called pwm-clps711x.
 
 config PWM_CRC
-       bool "Intel Crystalcove (CRC) PWM support"
-       depends on X86 && INTEL_SOC_PMIC
+       tristate "Intel Crystalcove (CRC) PWM support"
+       depends on INTEL_SOC_PMIC
        help
          Generic PWM framework driver for Crystalcove (CRC) PMIC based PWM
          control.
index b9f063dc6b5fd9c70631cfd473f80db748924d46..2b0b659eee9797520587ada0537abb2c75329d42 100644 (file)
@@ -184,5 +184,8 @@ static struct platform_driver crystalcove_pwm_driver = {
                .name = "crystal_cove_pwm",
        },
 };
+module_platform_driver(crystalcove_pwm_driver);
 
-builtin_platform_driver(crystalcove_pwm_driver);
+MODULE_ALIAS("platform:crystal_cove_pwm");
+MODULE_DESCRIPTION("Intel Crystalcove (CRC) PWM support");
+MODULE_LICENSE("GPL");