hwmon: (adt7475) Fix build warning
authorGuenter Roeck <linux@roeck-us.net>
Thu, 4 Apr 2019 13:33:42 +0000 (06:33 -0700)
committerGuenter Roeck <linux@roeck-us.net>
Tue, 16 Apr 2019 00:19:53 +0000 (17:19 -0700)
If CONFIG_OF is not enabled, the following build warning is observed.

drivers/hwmon/adt7475.c:171:34: warning:
‘adt7475_of_match’ defined but not used

Mark adt7475_of_match as __maybe_unused to fix the problem.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/adt7475.c

index 0dbb8df..7caec12 100644 (file)
@@ -168,7 +168,7 @@ static const struct i2c_device_id adt7475_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, adt7475_id);
 
-static const struct of_device_id adt7475_of_match[] = {
+static const struct of_device_id __maybe_unused adt7475_of_match[] = {
        {
                .compatible = "adi,adt7473",
                .data = (void *)adt7473