From: Andy Shevchenko Date: Mon, 16 Aug 2021 11:59:49 +0000 (+0300) Subject: gpio: mlxbf2: Drop wrong use of ACPI_PTR() X-Git-Tag: microblaze-v5.16~72^2~12 X-Git-Url: http://git.monstr.eu/?a=commitdiff_plain;h=603607e70e3626e6ceb3ddec86e2a060c6cd6191;p=linux-2.6-microblaze.git gpio: mlxbf2: Drop wrong use of ACPI_PTR() ACPI_PTR() is more harmful than helpful. For example, in this case if CONFIG_ACPI=n, the ID table left unused which is not what we want. Instead of adding ifdeffery here and there, drop ACPI_PTR() and replace acpi.h with mod_devicetable.h. Signed-off-by: Andy Shevchenko Acked-by: Asmaa Mnehi Signed-off-by: Bartosz Golaszewski --- diff --git a/drivers/gpio/gpio-mlxbf2.c b/drivers/gpio/gpio-mlxbf2.c index 68c471c10fa4..8e6f780923a6 100644 --- a/drivers/gpio/gpio-mlxbf2.c +++ b/drivers/gpio/gpio-mlxbf2.c @@ -1,6 +1,5 @@ // SPDX-License-Identifier: GPL-2.0 -#include #include #include #include @@ -8,6 +7,7 @@ #include #include #include +#include #include #include #include @@ -314,7 +314,7 @@ MODULE_DEVICE_TABLE(acpi, mlxbf2_gpio_acpi_match); static struct platform_driver mlxbf2_gpio_driver = { .driver = { .name = "mlxbf2_gpio", - .acpi_match_table = ACPI_PTR(mlxbf2_gpio_acpi_match), + .acpi_match_table = mlxbf2_gpio_acpi_match, .pm = &mlxbf2_pm_ops, }, .probe = mlxbf2_gpio_probe,