Re: [PATCH v2 08/12] ASoC: simple-card: tidyup simple_util_parse_xxx() in simple_parse_of()
Geert Uytterhoeven <[email protected]>
| Newsgroups | org.kernel.vger.linux-renesas-soc,org.kernel.vger.linux-sound |
|---|---|
| Message-ID | <[email protected]> |
Hi Morimoto-san, > simple_parse_of() calls simple_util_parse_xxx(), but are random. > Let's gather them all in one place. > > Let's keep same style with audio-graph-card/audio-graph-card2. > > Signed-off-by: Kuninori Morimoto <[email protected]> Thanks for your patch, which is now commit 27ecf4da5ad3845b ("ASoC: simple-card: tidyup simple_util_parse_xxx() in simple_parse_of()") in sound-asoc/for-next. This breaks sound on Koelsch and RZ/Five: asoc-simple-card sound: error -EINVAL: parse error asoc-simple-card sound: probe with driver asoc-simple-card failed with error -22 ... ALSA device list: No soundcards found. > --- a/sound/soc/generic/simple-card.c > +++ b/sound/soc/generic/simple-card.c > @@ -704,23 +704,23 @@ static int simple_parse_of(struct simple_util_priv *priv) > if (ret < 0) > goto end; > > - /* Single/Muti DAI link(s) & New style of DT node */ > - memset(li, 0, sizeof(*li)); > - ret = simple_for_each_link(priv, li, > - simple_dai_link_of, > - simple_dai_link_of_dpcm); > + ret = simple_util_parse_card_name(priv, PREFIX); > if (ret < 0) > goto err; > > - ret = simple_util_parse_card_name(priv, PREFIX); > + ret = simple_util_parse_aux_devs(priv, PREFIX); > if (ret < 0) > goto err; > > - ret = simple_populate_aux(priv); > + /* Single/Muti DAI link(s) & New style of DT node */ > + memset(li, 0, sizeof(*li)); > + ret = simple_for_each_link(priv, li, > + simple_dai_link_of, > + simple_dai_link_of_dpcm); > if (ret < 0) > goto err; > > - ret = simple_util_parse_aux_devs(priv, PREFIX); > + ret = simple_populate_aux(priv); > if (ret < 0) > goto err; > All changed functions return zero, but the call to devm_snd_soc_register_card() below returns -EINVAL: snd_soc_card_set_drvdata(card, priv); simple_util_debug_info(priv); ret = devm_snd_soc_register_card(dev, card); Reverting the commit fixes the issue. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected] In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds