]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: sti: uniperif: fix 'defined by not used' warning
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Thu, 9 Jul 2020 16:23:18 +0000 (11:23 -0500)
committerMark Brown <broonie@kernel.org>
Fri, 10 Jul 2020 14:13:44 +0000 (15:13 +0100)
commita73e12c4c3cc5d9e6d1ca0b0184ee8eb8c98f1ff
tree019f92aedc477892cf6aa3fbbd1edfea8dc249c6
parentbd650d47a5b3816c5ede9c928582e8d340beb010
ASoC: sti: uniperif: fix 'defined by not used' warning

Fix W=1 warning. The table uni_tdm_hw is declared in a header included
by multiple C file. This isn't really a good practice but for now
using __maybe_unused makes the following warning go away.

sound/soc/sti/sti_uniperif.c:12:
sound/soc/sti/uniperif.h:1351:38: warning: ‘uni_tdm_hw’ defined but
not used [-Wunused-const-variable=]
 1351 | static const struct snd_pcm_hardware uni_tdm_hw = {
      |                                      ^~~~~~~~~~

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com>
Link: https://lore.kernel.org/r/20200709162328.259586-2-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sti/uniperif.h