diff options
author | Paul Cercueil <paul@crapouillou.net> | 2022-10-24 21:52:11 +0100 |
---|---|---|
committer | Thierry Reding <thierry.reding@gmail.com> | 2022-11-29 13:05:40 +0100 |
commit | 731c47930f63883bae5de0293241f851042cbd77 (patch) | |
tree | 471c0e2c7c536aa00fb4f237779e1c8e6922c491 /drivers/pwm/pwm-jz4740.c | |
parent | 50315945d178eebec4e8e2c50c265767ddb926eb (diff) | |
download | linux-stable-731c47930f63883bae5de0293241f851042cbd77.tar.gz linux-stable-731c47930f63883bae5de0293241f851042cbd77.tar.bz2 linux-stable-731c47930f63883bae5de0293241f851042cbd77.zip |
pwm: jz4740: Force dependency on Device Tree
Ingenic SoCs all require CONFIG_OF, so there is no case where we want to
use this driver without CONFIG_OF.
Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Diffstat (limited to 'drivers/pwm/pwm-jz4740.c')
-rw-r--r-- | drivers/pwm/pwm-jz4740.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/pwm/pwm-jz4740.c b/drivers/pwm/pwm-jz4740.c index a5fdf97c0d2e..1a1a651c2cce 100644 --- a/drivers/pwm/pwm-jz4740.c +++ b/drivers/pwm/pwm-jz4740.c @@ -248,19 +248,18 @@ static int jz4740_pwm_probe(struct platform_device *pdev) return devm_pwmchip_add(dev, &jz4740->chip); } -static const struct soc_info __maybe_unused jz4740_soc_info = { +static const struct soc_info jz4740_soc_info = { .num_pwms = 8, }; -static const struct soc_info __maybe_unused jz4725b_soc_info = { +static const struct soc_info jz4725b_soc_info = { .num_pwms = 6, }; -static const struct soc_info __maybe_unused x1000_soc_info = { +static const struct soc_info x1000_soc_info = { .num_pwms = 5, }; -#ifdef CONFIG_OF static const struct of_device_id jz4740_pwm_dt_ids[] = { { .compatible = "ingenic,jz4740-pwm", .data = &jz4740_soc_info }, { .compatible = "ingenic,jz4725b-pwm", .data = &jz4725b_soc_info }, @@ -268,12 +267,11 @@ static const struct of_device_id jz4740_pwm_dt_ids[] = { {}, }; MODULE_DEVICE_TABLE(of, jz4740_pwm_dt_ids); -#endif static struct platform_driver jz4740_pwm_driver = { .driver = { .name = "jz4740-pwm", - .of_match_table = of_match_ptr(jz4740_pwm_dt_ids), + .of_match_table = jz4740_pwm_dt_ids, }, .probe = jz4740_pwm_probe, }; |