From d60e4f1e4be5e2dfb55fb084b119aed094227a35 Mon Sep 17 00:00:00 2001 From: Jerome Brunet Date: Tue, 17 Jul 2018 17:42:59 +0200 Subject: ASoC: meson: add tdm interface driver Add Amlogic's axg TDM interface driver. This driver manages the format and clocks provided on the pads. On this SoC, each stream direction provides 4 serial lanes. This makes a maximum of 8 channels in i2s modes and 128 channels in DSP modes. While each lanes operate on the same slot number (same bit clock), they may have different TDM masks. This requires to provide a function to let the card set the 4 masks, in lieu of the usual set_tdm_slots() callback of the dai driver. Signed-off-by: Jerome Brunet Signed-off-by: Mark Brown --- sound/soc/meson/axg-tdm.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'sound/soc/meson/axg-tdm.h') diff --git a/sound/soc/meson/axg-tdm.h b/sound/soc/meson/axg-tdm.h index 435d95b86457..e578b6f40a07 100644 --- a/sound/soc/meson/axg-tdm.h +++ b/sound/soc/meson/axg-tdm.h @@ -71,4 +71,8 @@ static inline int axg_tdm_stream_reset(struct axg_tdm_stream *ts) return axg_tdm_stream_start(ts); } +int axg_tdm_set_tdm_slots(struct snd_soc_dai *dai, u32 *tx_mask, + u32 *rx_mask, unsigned int slots, + unsigned int slot_width); + #endif /* _MESON_AXG_TDM_H */ -- cgit