diff mbox series

[5/9] ASoC: codecs: adau1977-spi: Mark OF related data as maybe unused

Message ID 20230310214333.274903-6-krzysztof.kozlowski@linaro.org
State Accepted
Commit a9048d64fb9605eb68c9912724e4a1346db8ba1a
Headers show
Series [1/9] ASoC: qcom: lpass-sc7280: Drop of_match_ptr for ID table | expand

Commit Message

Krzysztof Kozlowski March 10, 2023, 9:43 p.m. UTC
The driver can be compile tested with !CONFIG_OF making certain data
unused:

  sound/soc/codecs/adau1977-spi.c:58:34: error: ‘adau1977_spi_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 sound/soc/codecs/adau1977-spi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/sound/soc/codecs/adau1977-spi.c b/sound/soc/codecs/adau1977-spi.c
index 8370bec27a9c..207c5c95f35a 100644
--- a/sound/soc/codecs/adau1977-spi.c
+++ b/sound/soc/codecs/adau1977-spi.c
@@ -55,7 +55,7 @@  static const struct spi_device_id adau1977_spi_ids[] = {
 };
 MODULE_DEVICE_TABLE(spi, adau1977_spi_ids);
 
-static const struct of_device_id adau1977_spi_of_match[] = {
+static const struct of_device_id adau1977_spi_of_match[] __maybe_unused = {
         { .compatible = "adi,adau1977" },
         { .compatible = "adi,adau1978" },
         { .compatible = "adi,adau1979" },