diff options
| author | Chancel Liu <chancel.liu@nxp.com> | 2025-04-21 19:57:00 +0900 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2025-05-02 05:38:53 +0900 |
| commit | 17fa55fe77d8234131ce0728a735da6dea19acd5 (patch) | |
| tree | 26c78b53a2ae798268605d3174bd2edd5785406c | |
| parent | c23c7c60711e34963c78f18fc3b9aaa313b6c8ce (diff) | |
| download | lwn-17fa55fe77d8234131ce0728a735da6dea19acd5.tar.gz lwn-17fa55fe77d8234131ce0728a735da6dea19acd5.zip | |
ASoC: fsl_rpmsg: Configure CPU DAI for card that sits on rpmsg-micfil-channel
Sound card that sits on rpmsg-micfil-channel has different settings on
CPU DAI.
Signed-off-by: Chancel Liu <chancel.liu@nxp.com>
Link: https://patch.msgid.link/20250421105701.2273588-1-chancel.liu@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
| -rw-r--r-- | sound/soc/fsl/fsl_rpmsg.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sound/soc/fsl/fsl_rpmsg.c b/sound/soc/fsl/fsl_rpmsg.c index 6d67db4e0581..4e3ca05bedd6 100644 --- a/sound/soc/fsl/fsl_rpmsg.c +++ b/sound/soc/fsl/fsl_rpmsg.c @@ -229,6 +229,16 @@ static int fsl_rpmsg_probe(struct platform_device *pdev) } dai_drv->name = dai_name; + /* Setup cpu dai for sound card that sits on rpmsg-micfil-channel */ + if (!strcmp(dai_name, "rpmsg-micfil-channel")) { + dai_drv->capture.channels_min = 1; + dai_drv->capture.channels_max = 8; + dai_drv->capture.rates = SNDRV_PCM_RATE_8000_48000; + dai_drv->capture.formats = SNDRV_PCM_FMTBIT_S32_LE; + if (of_device_is_compatible(np, "fsl,imx8mm-rpmsg-audio")) + dai_drv->capture.formats = SNDRV_PCM_FMTBIT_S16_LE; + } + if (of_property_read_bool(np, "fsl,enable-lpa")) { rpmsg->enable_lpa = 1; rpmsg->buffer_size = LPA_LARGE_BUFFER_SIZE; |
