leds: tlc591xx: Mark OF related data as maybe unused
authorKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Sat, 11 Mar 2023 11:17:17 +0000 (12:17 +0100)
committerLee Jones <lee@kernel.org>
Thu, 16 Mar 2023 15:08:43 +0000 (15:08 +0000)
The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/leds/leds-tlc591xx.c:138:34: error: ‘of_tlc591xx_leds_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Lee Jones <lee@kernel.org>
Link: https://lore.kernel.org/r/20230311111717.252019-1-krzysztof.kozlowski@linaro.org
drivers/leds/leds-tlc591xx.c

index ec25e0c16bea3a942aeb7ccf09c020b16c5e0fd7..7e31db50036f05bdd928b0793dac5d1d7f80c4dc 100644 (file)
@@ -135,7 +135,7 @@ static const struct regmap_config tlc591xx_regmap = {
        .max_register = 0x1e,
 };
 
-static const struct of_device_id of_tlc591xx_leds_match[] = {
+static const struct of_device_id of_tlc591xx_leds_match[] __maybe_unused = {
        { .compatible = "ti,tlc59116",
          .data = &tlc59116 },
        { .compatible = "ti,tlc59108",