Lines Matching +full:custom +full:- +full:rtd
1 // SPDX-License-Identifier: GPL-2.0
3 // audio-graph-card2-custom-sample.c
15 * Custom driver can have own priv
21 /* custom driver's own params */
34 dev_info(dev, "custom probe\n"); in custom_card_probe()
36 custom_priv->custom_params = 1; in custom_card_probe()
46 /* You can custom before parsing */ in custom_hook_pre()
57 /* You can custom after parsing */ in custom_hook_post()
62 card->probe = custom_card_probe; in custom_hook_post()
74 * You can custom Normal parsing in custom_normal()
89 * You can custom DPCM parsing in custom_dpcm()
104 * You can custom Codec2Codec parsing in custom_c2c()
113 * audio-graph-card2 has many hooks for your customizing.
125 struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream); in custom_startup() local
126 struct simple_util_priv *priv = snd_soc_card_get_drvdata(rtd->card); in custom_startup()
129 dev_info(dev, "custom startup\n"); in custom_startup()
134 /* You can use custom ops */
145 struct device *dev = &pdev->dev; in custom_probe()
150 return -ENOMEM; in custom_probe()
152 simple_priv = &custom_priv->simple_priv; in custom_probe()
153 simple_priv->ops = &custom_ops; /* customize dai_link ops */ in custom_probe()
155 /* "audio-graph-card2-custom-sample" is too long */ in custom_probe()
156 simple_priv->snd_card.name = "card2-custom"; in custom_probe()
158 /* use audio-graph-card2 parsing with own custom hooks */ in custom_probe()
169 { .compatible = "audio-graph-card2-custom-sample", },
176 .name = "audio-graph-card2-custom-sample",
184 MODULE_ALIAS("platform:asoc-audio-graph-card2-custom-sample");
186 MODULE_DESCRIPTION("ASoC Audio Graph Card2 Custom Sample");