pinctrl: pinctrl-amd: Do not define 'struct acpi_device_id' when !CONFIG_ACPI
authorLee Jones <lee.jones@linaro.org>
Mon, 13 Jul 2020 14:49:30 +0000 (15:49 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Thu, 16 Jul 2020 13:58:12 +0000 (15:58 +0200)
commitde4334f7da83a169b984d617af0d7eb383aef5a5
tree95441aebe1729d016a7855e2673d3ace2088c127
parent192b752e0e4653b0c136d3ed5e588e16021778aa
pinctrl: pinctrl-amd: Do not define 'struct acpi_device_id' when !CONFIG_ACPI

Since ACPI_PTR() is used to NULLify the value when !CONFIG_ACPI,
'struct amd_gpio_acpi_match' becomes defined but unused.

Fixes the following W=1 kernel build warning(s):

 drivers/pinctrl/pinctrl-amd.c:959:36: warning: ‘amd_gpio_acpi_match’ defined but not used [-Wunused-const-variable=]
 959 | static const struct acpi_device_id amd_gpio_acpi_match[] = {

Signed-off-by: Lee Jones <lee.jones@linaro.org>
Cc: Ken Xue <Ken.Xue@amd.com>
Cc: "Wu, Jeff" <Jeff.Wu@amd.com>
Cc: Nehal Shah <Nehal-bakulchandra.Shah@amd.com>
Cc: Sundar S K <Shyam-sundar.S-k@amd.com>
Link: https://lore.kernel.org/r/20200713144930.1034632-26-lee.jones@linaro.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinctrl-amd.c