summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2026-07-21 01:00:09 +0000
committerMark Brown <broonie@kernel.org>2026-08-01 02:40:24 +0100
commit1bd470f27f283cfcfd5c94705a2fabbe5f1e4e9f (patch)
tree3469f89d3d4ff3a829a970ba496d4926b821435c
parent875e906efdc4e68025c97aaa8e258d9e1fc1ba2e (diff)
downloadlinux-next-1bd470f27f283cfcfd5c94705a2fabbe5f1e4e9f.tar.gz
linux-next-1bd470f27f283cfcfd5c94705a2fabbe5f1e4e9f.zip
ASoC: apple: use .auto_selectable_formats
We can use .auto_selectable_formats. Let's adds it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87y0f5jgx2.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/apple/mca.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/sound/soc/apple/mca.c b/sound/soc/apple/mca.c
index afb3754a8883..be702b2942a5 100644
--- a/sound/soc/apple/mca.c
+++ b/sound/soc/apple/mca.c
@@ -739,6 +739,19 @@ static int mca_fe_hw_params(struct snd_pcm_substream *substream,
return 0;
}
+static const u64 mca_fe_selectable_formats[] =
+{
+ /* pattern 1 */
+ SND_SOC_POSSIBLE_DAIFMT_I2S |
+ SND_SOC_POSSIBLE_DAIFMT_NB_IF |
+ SND_SOC_POSSIBLE_DAIFMT_IB_IF,
+
+ /* pattern 2 */
+ SND_SOC_POSSIBLE_DAIFMT_LEFT_J |
+ SND_SOC_POSSIBLE_DAIFMT_NB_NF |
+ SND_SOC_POSSIBLE_DAIFMT_IB_NF
+};
+
static const struct snd_soc_dai_ops mca_fe_ops = {
.startup = mca_fe_startup,
.set_fmt = mca_fe_set_fmt,
@@ -748,6 +761,8 @@ static const struct snd_soc_dai_ops mca_fe_ops = {
.trigger = mca_fe_trigger,
.prepare = mca_fe_prepare,
.hw_free = mca_fe_hw_free,
+ .auto_selectable_formats = mca_fe_selectable_formats,
+ .num_auto_selectable_formats = ARRAY_SIZE(mca_fe_selectable_formats),
};
/*