Commit aec3ff99 authored by Kuninori Morimoto's avatar Kuninori Morimoto Committed by Mark Brown

ASoC: soc-core: soc_set_name_prefix(): get component device_node at out of loop

Component device_node is not related to codec_conf loop at
soc_set_name_prefix().
This patch moves it to out of loop.
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Reviewed-by: default avatarRanjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/87v9qpxbkj.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 4702f991
......@@ -1209,11 +1209,11 @@ static void soc_set_of_name_prefix(struct snd_soc_component *component)
static void soc_set_name_prefix(struct snd_soc_card *card,
struct snd_soc_component *component)
{
struct device_node *of_node = soc_component_to_node(component);
int i;
for (i = 0; i < card->num_configs; i++) {
struct snd_soc_codec_conf *map = &card->codec_conf[i];
struct device_node *of_node = soc_component_to_node(component);
if (map->of_node && of_node != map->of_node)
continue;
......
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