Commit dad492cf authored by Cezary Rojewski's avatar Cezary Rojewski Committed by Mark Brown

ASoC: Intel: catpt: Reduce size of catpt_component_open()

With some improved if-logy, function's size can be reduced slightly.
Signed-off-by: default avatarCezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20211216115743.2130622-3-cezary.rojewski@intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 2a9a72e2
...@@ -595,8 +595,7 @@ static int catpt_component_open(struct snd_soc_component *component, ...@@ -595,8 +595,7 @@ static int catpt_component_open(struct snd_soc_component *component,
{ {
struct snd_soc_pcm_runtime *rtm = substream->private_data; struct snd_soc_pcm_runtime *rtm = substream->private_data;
if (rtm->dai_link->no_pcm) if (!rtm->dai_link->no_pcm)
return 0;
snd_soc_set_runtime_hwparams(substream, &catpt_pcm_hardware); snd_soc_set_runtime_hwparams(substream, &catpt_pcm_hardware);
return 0; return 0;
} }
......
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