platform/x86: classmate: mark SPI related data as maybe unused
authorKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Sun, 12 Mar 2023 13:26:23 +0000 (14:26 +0100)
committerHans de Goede <hdegoede@redhat.com>
Thu, 16 Mar 2023 15:10:54 +0000 (16:10 +0100)
The driver can be compile tested as built-in making certain data unused:

  drivers/platform/x86/classmate-laptop.c:1137:36: error: ‘cmpc_device_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230312132624.352703-2-krzysztof.kozlowski@linaro.org
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/classmate-laptop.c

index 8b6a1461185999a3aed75ba4a34fdd5776af92e5..2edaea2492df7327fa8f6a6cafde9732fc2e6381 100644 (file)
@@ -1134,7 +1134,7 @@ static void cmpc_exit(void)
 module_init(cmpc_init);
 module_exit(cmpc_exit);
 
-static const struct acpi_device_id cmpc_device_ids[] = {
+static const struct acpi_device_id cmpc_device_ids[] __maybe_unused = {
        {CMPC_ACCEL_HID, 0},
        {CMPC_ACCEL_HID_V4, 0},
        {CMPC_TABLET_HID, 0},