[alsa-devel] simple-card: DAI link creation
Kuninori Morimoto
kuninori.morimoto.gx at renesas.com
Fri Jan 17 02:14:16 CET 2020
Hi Daniel
Thank you for contacting me
> link->cpus->of_node = <&my_dai>;
> link->codecs->of_node = <&my_codec>;
> link->platforms->of_node = <&my_platform>;
> link->no_pcm = 1;
>
> Somehow, similar with qcom_snd_parse_of from
> sound/soc/qcom/common.c.
>
> Do you think it would be OK to create another file to handle this case
> in sound/soc/generic?
Or having extra flag for it ?
static const struct of_device_id simple_of_match[] = {
{ .compatible = "simple-audio-card", },
{ .compatible = "simple-scu-audio-card",
.data = (void *)DPCM_SELECTABLE },
+ { .compatible = "simple-xxx-audio-card",
+ .data = (void *)DPCM_WITH_PLATFORM },
{},
};
This idea is adding new feature on simple-card.
But, in sound card case, many patterns exist,
thus, adding new feature into simple-card will be difficult.
So having new file is not bad idea.
But, I'm thinking some Card driver want to create new driver,
but want to share simple-card code.
Actually, simple-card-utils.c is for it.
But, maybe someone want to share simple-card.c code itself ?
Some overwrite technic can be nice idea.
# Now I'm focusing cleanup ALSA SoC
# Current framework has "normal sound" and "DPCM sound",
# and it makes code/DT difficult.
# But if all cleanup could be done, these can be merged,
# and can have more flexible connection.
# Then, I want to create new simple-card with *really* simple code :)
Thank you for your help !!
Best regards
---
Kuninori Morimoto
More information about the Alsa-devel
mailing list