mirror of
https://github.com/torvalds/linux.git
synced 2024-12-11 13:41:55 +00:00
ASoC: audio-graph-card: tidyup asoc_simple_card_canonicalize_cpu() parameter
asoc_simple_card_canonicalize_cpu() 2nd param is asking CPU component's DAI links, not Card links. This patch fixup it. Otherwise, audio-graph-card can't handle CPU component correctly if CPU has mult-DAIs and Card uses only one of them Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
fa2760dd36
commit
47ca9593de
@ -100,7 +100,6 @@ static int asoc_graph_card_dai_link_of(struct device_node *cpu_port,
|
||||
struct graph_dai_props *dai_props = graph_priv_to_props(priv, idx);
|
||||
struct asoc_simple_dai *cpu_dai = &dai_props->cpu_dai;
|
||||
struct asoc_simple_dai *codec_dai = &dai_props->codec_dai;
|
||||
struct snd_soc_card *card = graph_priv_to_card(priv);
|
||||
struct device_node *cpu_ep = of_get_next_child(cpu_port, NULL);
|
||||
struct device_node *codec_ep = of_graph_get_remote_endpoint(cpu_ep);
|
||||
struct device_node *rcpu_ep = of_graph_get_remote_endpoint(codec_ep);
|
||||
@ -162,7 +161,7 @@ static int asoc_graph_card_dai_link_of(struct device_node *cpu_port,
|
||||
dai_link->init = asoc_graph_card_dai_init;
|
||||
|
||||
asoc_simple_card_canonicalize_cpu(dai_link,
|
||||
card->num_links == 1);
|
||||
of_graph_get_endpoint_count(dai_link->cpu_of_node) == 1);
|
||||
|
||||
dai_link_of_err:
|
||||
of_node_put(cpu_ep);
|
||||
|
Loading…
Reference in New Issue
Block a user