diff mbox series

[05/24] iio: accel: mxc4005: Drop ACPI_PTR() usage

Message ID 20231231183514.566609-6-jic23@kernel.org (mailing list archive)
State Accepted
Headers show
Series IIO: Clean up ACPI_PTR() usage. | expand

Commit Message

Jonathan Cameron Dec. 31, 2023, 6:34 p.m. UTC
From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Avoiding unused variable warnings when using this macro adds
complexity that in simple cases like this one is not justified
for the small saving in data.

Switch include to mod_devicetable.h as that contains the only
acpi specific definitions needed in this driver.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202311181952.1usxCcup-lkp@intel.com/
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
---
 drivers/iio/accel/mxc4005.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Andy Shevchenko Jan. 1, 2024, 11:39 p.m. UTC | #1
On Sun, Dec 31, 2023 at 8:35 PM Jonathan Cameron <jic23@kernel.org> wrote:
>
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
>
> Avoiding unused variable warnings when using this macro adds
> complexity that in simple cases like this one is not justified
> for the small saving in data.
>
> Switch include to mod_devicetable.h as that contains the only
> acpi specific definitions needed in this driver.

ACPI

(and in other commit messages that repeat this text)
diff mbox series

Patch

diff --git a/drivers/iio/accel/mxc4005.c b/drivers/iio/accel/mxc4005.c
index 82e8d0b39049..8118cc13614a 100644
--- a/drivers/iio/accel/mxc4005.c
+++ b/drivers/iio/accel/mxc4005.c
@@ -8,7 +8,7 @@ 
 #include <linux/module.h>
 #include <linux/i2c.h>
 #include <linux/iio/iio.h>
-#include <linux/acpi.h>
+#include <linux/mod_devicetable.h>
 #include <linux/regmap.h>
 #include <linux/iio/sysfs.h>
 #include <linux/iio/trigger.h>
@@ -493,7 +493,7 @@  MODULE_DEVICE_TABLE(i2c, mxc4005_id);
 static struct i2c_driver mxc4005_driver = {
 	.driver = {
 		.name = MXC4005_DRV_NAME,
-		.acpi_match_table = ACPI_PTR(mxc4005_acpi_match),
+		.acpi_match_table = mxc4005_acpi_match,
 		.of_match_table = mxc4005_of_match,
 	},
 	.probe		= mxc4005_probe,