]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
hwmon: (max6621) Fix build warning
authorGuenter Roeck <linux@roeck-us.net>
Thu, 4 Apr 2019 14:47:04 +0000 (07:47 -0700)
committerGuenter Roeck <linux@roeck-us.net>
Tue, 16 Apr 2019 00:19:53 +0000 (17:19 -0700)
The following build warning is seen if CONFIG_OF is disabled.

drivers/hwmon/max6621.c:573:34: warning:
‘max6621_of_match’ defined but not used

Mark max6621_of_match as __maybe_unused to fix the problem.

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

index 0c399e407de375f7512fbcad7d6d3224562b0c02..1810a753f1a3e0f81f11f18694f36858c7b65e87 100644 (file)
@@ -552,7 +552,7 @@ static const struct i2c_device_id max6621_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, max6621_id);
 
-static const struct of_device_id max6621_of_match[] = {
+static const struct of_device_id __maybe_unused max6621_of_match[] = {
        { .compatible = "maxim,max6621" },
        { }
 };