diff options
author | Moise Gergaud <moise.gergaud@st.com> | 2016-04-19 05:24:45 -0400 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-04-19 05:37:17 -0400 |
commit | ee4c879b53eb5d757661b9bc8fcdf1a3d2e5fdfb (patch) | |
tree | 2e257a236346d660ce59c5d6345896a39531bb04 | |
parent | 3ee15cac90e168fdea497a168a2e79acb1c4e612 (diff) |
ASoC: sti-asoc-card: update tdm mode
- Add "TDM" in the st,mode property list
- st,mode property is also mandatory for reader
- add tdm playback dai-link example
Signed-off-by: Moise Gergaud <moise.gergaud@st.com>
Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r-- | Documentation/devicetree/bindings/sound/st,sti-asoc-card.txt | 44 |
1 files changed, 39 insertions, 5 deletions
diff --git a/Documentation/devicetree/bindings/sound/st,sti-asoc-card.txt b/Documentation/devicetree/bindings/sound/st,sti-asoc-card.txt index f546dd914812..4d9a83d9a017 100644 --- a/Documentation/devicetree/bindings/sound/st,sti-asoc-card.txt +++ b/Documentation/devicetree/bindings/sound/st,sti-asoc-card.txt | |||
@@ -37,17 +37,18 @@ Required properties: | |||
37 | 37 | ||
38 | - dai-name: DAI name that describes the IP. | 38 | - dai-name: DAI name that describes the IP. |
39 | 39 | ||
40 | - IP mode: IP working mode depending on associated codec. | ||
41 | "HDMI" connected to HDMI codec and support IEC HDMI formats (player only). | ||
42 | "SPDIF" connected to SPDIF codec and support SPDIF formats (player only). | ||
43 | "PCM" PCM standard mode for I2S or TDM bus. | ||
44 | "TDM" TDM mode for TDM bus. | ||
45 | |||
40 | Required properties ("st,sti-uni-player" compatibility only): | 46 | Required properties ("st,sti-uni-player" compatibility only): |
41 | - clocks: CPU_DAI IP clock source, listed in the same order than the | 47 | - clocks: CPU_DAI IP clock source, listed in the same order than the |
42 | CPU_DAI properties. | 48 | CPU_DAI properties. |
43 | 49 | ||
44 | - uniperiph-id: internal SOC IP instance ID. | 50 | - uniperiph-id: internal SOC IP instance ID. |
45 | 51 | ||
46 | - IP mode: IP working mode depending on associated codec. | ||
47 | "HDMI" connected to HDMI codec IP and IEC HDMI formats. | ||
48 | "SPDIF"connected to SPDIF codec and support SPDIF formats. | ||
49 | "PCM" PCM standard mode for I2S or TDM bus. | ||
50 | |||
51 | Optional properties: | 52 | Optional properties: |
52 | - pinctrl-0: defined for CPU_DAI@1 and CPU_DAI@4 to describe I2S PIOs for | 53 | - pinctrl-0: defined for CPU_DAI@1 and CPU_DAI@4 to describe I2S PIOs for |
53 | external codecs connection. | 54 | external codecs connection. |
@@ -56,6 +57,22 @@ Optional properties: | |||
56 | 57 | ||
57 | Example: | 58 | Example: |
58 | 59 | ||
60 | sti_uni_player1: sti-uni-player@1 { | ||
61 | compatible = "st,sti-uni-player"; | ||
62 | status = "okay"; | ||
63 | #sound-dai-cells = <0>; | ||
64 | st,syscfg = <&syscfg_core>; | ||
65 | clocks = <&clk_s_d0_flexgen CLK_PCM_1>; | ||
66 | reg = <0x8D81000 0x158>; | ||
67 | interrupts = <GIC_SPI 85 IRQ_TYPE_NONE>; | ||
68 | dmas = <&fdma0 3 0 1>; | ||
69 | st,dai-name = "Uni Player #1 (I2S)"; | ||
70 | dma-names = "tx"; | ||
71 | st,uniperiph-id = <1>; | ||
72 | st,version = <5>; | ||
73 | st,mode = "TDM"; | ||
74 | }; | ||
75 | |||
59 | sti_uni_player2: sti-uni-player@2 { | 76 | sti_uni_player2: sti-uni-player@2 { |
60 | compatible = "st,sti-uni-player"; | 77 | compatible = "st,sti-uni-player"; |
61 | status = "okay"; | 78 | status = "okay"; |
@@ -99,6 +116,7 @@ Example: | |||
99 | dma-names = "rx"; | 116 | dma-names = "rx"; |
100 | dai-name = "Uni Reader #1 (HDMI RX)"; | 117 | dai-name = "Uni Reader #1 (HDMI RX)"; |
101 | version = <3>; | 118 | version = <3>; |
119 | st,mode = "PCM"; | ||
102 | }; | 120 | }; |
103 | 121 | ||
104 | 2) sti-sas-codec: internal audio codec IPs driver | 122 | 2) sti-sas-codec: internal audio codec IPs driver |
@@ -152,4 +170,20 @@ Example of audio card declaration: | |||
152 | sound-dai = <&sti_sasg_codec 0>; | 170 | sound-dai = <&sti_sasg_codec 0>; |
153 | }; | 171 | }; |
154 | }; | 172 | }; |
173 | simple-audio-card,dai-link@2 { | ||
174 | /* TDM playback */ | ||
175 | format = "left_j"; | ||
176 | frame-inversion = <1>; | ||
177 | cpu { | ||
178 | sound-dai = <&sti_uni_player1>; | ||
179 | dai-tdm-slot-num = <16>; | ||
180 | dai-tdm-slot-width = <16>; | ||
181 | dai-tdm-slot-tx-mask = | ||
182 | <1 1 1 1 0 0 0 0 0 0 1 1 0 0 1 1>; | ||
183 | }; | ||
184 | |||
185 | codec { | ||
186 | sound-dai = <&sti_sasg_codec 3>; | ||
187 | }; | ||
188 | }; | ||
155 | }; | 189 | }; |