Commit a3f18f82 authored by Pierre-Louis Bossart's avatar Pierre-Louis Bossart Committed by Mark Brown

ASoC: Intel: hda_dsp_common: use static function in conditional block

cppcheck reports the following warning:

sound/soc/intel/boards/hda_dsp_common.c:17:0: style: The function
'hda_dsp_hdmi_pcm_handle' is never used. [unusedFunction]

Fix by moving to static inside compilation block.
Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: default avatarJaska Uimonen <jaska.uimonen@intel.com>
Signed-off-by: default avatarKai Vehmanen <kai.vehmanen@linux.intel.com>
Link: https://lore.kernel.org/r/20200923072939.3100468-1-kai.vehmanen@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 50b18e4a
...@@ -10,12 +10,14 @@ ...@@ -10,12 +10,14 @@
#include "hda_dsp_common.h" #include "hda_dsp_common.h"
#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC)
/* /*
* Search card topology and return PCM device number * Search card topology and return PCM device number
* matching Nth HDMI device (zero-based index). * matching Nth HDMI device (zero-based index).
*/ */
struct snd_pcm *hda_dsp_hdmi_pcm_handle(struct snd_soc_card *card, static struct snd_pcm *hda_dsp_hdmi_pcm_handle(struct snd_soc_card *card,
int hdmi_idx) int hdmi_idx)
{ {
struct snd_soc_pcm_runtime *rtd; struct snd_soc_pcm_runtime *rtd;
struct snd_pcm *spcm; struct snd_pcm *spcm;
...@@ -34,7 +36,6 @@ struct snd_pcm *hda_dsp_hdmi_pcm_handle(struct snd_soc_card *card, ...@@ -34,7 +36,6 @@ struct snd_pcm *hda_dsp_hdmi_pcm_handle(struct snd_soc_card *card,
return NULL; return NULL;
} }
#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC)
/* /*
* Search card topology and register HDMI PCM related controls * Search card topology and register HDMI PCM related controls
* to codec driver. * to codec driver.
......
...@@ -15,9 +15,6 @@ ...@@ -15,9 +15,6 @@
#include <sound/hda_i915.h> #include <sound/hda_i915.h>
#include "../../codecs/hdac_hda.h" #include "../../codecs/hdac_hda.h"
struct snd_pcm *hda_dsp_hdmi_pcm_handle(struct snd_soc_card *card,
int hdmi_idx);
#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC) #if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC)
int hda_dsp_hdmi_build_controls(struct snd_soc_card *card, int hda_dsp_hdmi_build_controls(struct snd_soc_card *card,
struct snd_soc_component *comp); struct snd_soc_component *comp);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment