mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] ASoC: adau7118: Allow dsp_a mode
@ 2025-04-11  7:49 Michael Sikora
  2025-04-23 11:44 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Michael Sikora @ 2025-04-11  7:49 UTC (permalink / raw)
  To: Lars-Peter Clausen, Nuno Sá,
	Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai
  Cc: linux-sound, linux-kernel, kernel, Michael Sikora

TDM mode on the adau7118 is dsp_a compatible. Set SPT_SAI_MODE on the
SPT_CTRL1 register to 1 for TDM mode when the DAI is operating in
dsp_a mode.

Signed-off-by: Michael Sikora <michael.sikora@axis.com>
---
 sound/soc/codecs/adau7118.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/sound/soc/codecs/adau7118.c b/sound/soc/codecs/adau7118.c
index abc4764697a5..14259807c872 100644
--- a/sound/soc/codecs/adau7118.c
+++ b/sound/soc/codecs/adau7118.c
@@ -169,6 +169,12 @@ static int adau7118_set_fmt(struct snd_soc_dai *dai, unsigned int fmt)
 	case SND_SOC_DAIFMT_RIGHT_J:
 		st->right_j = true;
 		break;
+	case SND_SOC_DAIFMT_DSP_A:
+		ret = snd_soc_component_update_bits(dai->component,
+						    ADAU7118_REG_SPT_CTRL1,
+						    ADAU7118_DATA_FMT_MASK,
+						    ADAU7118_DATA_FMT(1));
+		break;
 	default:
 		dev_err(st->dev, "Invalid format %d",
 			fmt & SND_SOC_DAIFMT_FORMAT_MASK);

---
base-commit: 5751a1448babcf892161b4496d6b3da11a0862ec
change-id: 20250325-adau7118-dsp-a-e26e1dfc2b8f

Best regards,
-- 
Michael Sikora <michael.sikora@axis.com>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-04-23 11:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-04-11  7:49 [PATCH] ASoC: adau7118: Allow dsp_a mode Michael Sikora
2025-04-23 11:44 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®