]> git.dujemihanovic.xyz Git - linux.git/commitdiff
platform/x86/intel: punit_ipc: Drop wrong use of ACPI_PTR()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Fri, 27 Aug 2021 14:53:10 +0000 (17:53 +0300)
committerHans de Goede <hdegoede@redhat.com>
Mon, 13 Sep 2021 08:36:52 +0000 (10:36 +0200)
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 unused acpi.h.

Fixes: fdca4f16f57d ("platform:x86: add Intel P-Unit mailbox IPC driver")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210827145310.76239-1-andriy.shevchenko@linux.intel.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/intel/punit_ipc.c

index f58b8543f6ac576243bc1734f3a0ba52a7107dac..66bb39fd0ef9022988f7e8ffbe63944acc53f939 100644 (file)
@@ -8,7 +8,6 @@
  * which provide mailbox interface for power management usage.
  */
 
-#include <linux/acpi.h>
 #include <linux/bitops.h>
 #include <linux/delay.h>
 #include <linux/device.h>
@@ -319,7 +318,7 @@ static struct platform_driver intel_punit_ipc_driver = {
        .remove = intel_punit_ipc_remove,
        .driver = {
                .name = "intel_punit_ipc",
-               .acpi_match_table = ACPI_PTR(punit_ipc_acpi_ids),
+               .acpi_match_table = punit_ipc_acpi_ids,
        },
 };