]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
hwmon: (adc128d818) Fix build warning
authorGuenter Roeck <linux@roeck-us.net>
Thu, 4 Apr 2019 13:23:59 +0000 (06:23 -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/adc128d818.c:524:34: warning:
‘adc128_of_match’ defined but not used

Mark adc128_of_match as __maybe_unused to fix the problem.

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

index ca794bf904de481ef86b309bf337cf96531a26ad..e640be442daec553d27f1beff05c1dc1baa84670 100644 (file)
@@ -521,7 +521,7 @@ static const struct i2c_device_id adc128_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, adc128_id);
 
-static const struct of_device_id adc128_of_match[] = {
+static const struct of_device_id __maybe_unused adc128_of_match[] = {
        { .compatible = "ti,adc128d818" },
        { },
 };