Skip to content

Commit b2693ed

Browse files
andy-shevUwe Kleine-König
authored andcommitted
pwm: pca9685: Drop ACPI_PTR() and of_match_ptr()
Drop rather useless use of ACPI_PTR() and of_match_ptr(). It also removes the necessity to be dependent acpi.h inclusion. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20250214154031.3395014-1-andriy.shevchenko@linux.intel.com Signed-off-by: Uwe Kleine-König <ukleinek@kernel.org>
1 parent e71e46a commit b2693ed

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

drivers/pwm/pwm-pca9685.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
* based on the pwm-twl-led.c driver
99
*/
1010

11-
#include <linux/acpi.h>
1211
#include <linux/gpio/driver.h>
1312
#include <linux/i2c.h>
1413
#include <linux/module.h>
@@ -639,21 +638,17 @@ static const struct i2c_device_id pca9685_id[] = {
639638
};
640639
MODULE_DEVICE_TABLE(i2c, pca9685_id);
641640

642-
#ifdef CONFIG_ACPI
643641
static const struct acpi_device_id pca9685_acpi_ids[] = {
644642
{ "INT3492", 0 },
645643
{ /* sentinel */ },
646644
};
647645
MODULE_DEVICE_TABLE(acpi, pca9685_acpi_ids);
648-
#endif
649646

650-
#ifdef CONFIG_OF
651647
static const struct of_device_id pca9685_dt_ids[] = {
652648
{ .compatible = "nxp,pca9685-pwm", },
653649
{ /* sentinel */ }
654650
};
655651
MODULE_DEVICE_TABLE(of, pca9685_dt_ids);
656-
#endif
657652

658653
static const struct dev_pm_ops pca9685_pwm_pm = {
659654
SET_RUNTIME_PM_OPS(pca9685_pwm_runtime_suspend,
@@ -663,8 +658,8 @@ static const struct dev_pm_ops pca9685_pwm_pm = {
663658
static struct i2c_driver pca9685_i2c_driver = {
664659
.driver = {
665660
.name = "pca9685-pwm",
666-
.acpi_match_table = ACPI_PTR(pca9685_acpi_ids),
667-
.of_match_table = of_match_ptr(pca9685_dt_ids),
661+
.acpi_match_table = pca9685_acpi_ids,
662+
.of_match_table = pca9685_dt_ids,
668663
.pm = &pca9685_pwm_pm,
669664
},
670665
.probe = pca9685_pwm_probe,

0 commit comments

Comments
 (0)