← Documents Documentation/devicetree/bindings/sound/fsl-asoc-card.yaml GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / Sound

Freescale generic ASoC card

Freescale generic sound card의 compatible, ASRC, routing, DAI format과 S/PDIF를 설명합니다.

Source pathDocumentation/devicetree/bindings/sound/fsl-asoc-card.yaml
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약과 해설

fsl-asoc-card.yaml:1-243

FourSemi amplifier와 Freescale/NXP audio card·controller의 compatible, clock, DMA, routing과 firmware 조건을 먼저 해설하고, 접을 수 있는 영어 원문 전체와 원문 줄 좌표를 보존한 한국어 전문 번역을 제공합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/sound/fsl-asoc-card.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: Freescale Generic ASoC Sound Card with ASRC support
8
9 description:
10 The Freescale Generic ASoC Sound Card can be used, ideally,
11 for all Freescale SoCs connecting with external CODECs.
12
13 The idea of this generic sound card is a bit like ASoC Simple Card.
14 However, for Freescale SoCs (especially those released in recent years),
15 most of them have ASRC inside. And this is a specific feature that might
16 be painstakingly controlled and merged into the Simple Card.
17
18 So having this generic sound card allows all Freescale SoC users to
19 benefit from the simplification of a new card support and the capability
20 of the wide sample rates support through ASRC.
21
22 Note, The card is initially designed for those sound cards who use AC'97, I2S
23 and PCM DAI formats. However, it'll be also possible to support those non
24 AC'97/I2S/PCM type sound cards, such as S/PDIF audio and HDMI audio, as
25 long as the driver has been properly upgraded.
26
27 maintainers:
28 - Shengjiu Wang <[email protected]>
29
30 properties:
31 compatible:
32 oneOf:
33 - items:
34 - enum:
35 - fsl,imx-sgtl5000
36 - fsl,imx25-pdk-sgtl5000
37 - fsl,imx53-cpuvo-sgtl5000
38 - fsl,imx51-babbage-sgtl5000
39 - fsl,imx53-m53evk-sgtl5000
40 - fsl,imx53-qsb-sgtl5000
41 - fsl,imx53-voipac-sgtl5000
42 - fsl,imx6-armadeus-sgtl5000
43 - fsl,imx6-rex-sgtl5000
44 - fsl,imx6-sabreauto-cs42888
45 - fsl,imx6-wandboard-sgtl5000
46 - fsl,imx6dl-nit6xlite-sgtl5000
47 - fsl,imx6q-ba16-sgtl5000
48 - fsl,imx6q-nitrogen6_max-sgtl5000
49 - fsl,imx6q-nitrogen6_som2-sgtl5000
50 - fsl,imx6q-nitrogen6x-sgtl5000
51 - fsl,imx6q-sabrelite-sgtl5000
52 - fsl,imx6q-sabresd-wm8962
53 - fsl,imx6q-udoo-ac97
54 - fsl,imx6q-ventana-sgtl5000
55 - fsl,imx6sl-evk-wm8962
56 - fsl,imx6sx-sdb-mqs
57 - fsl,imx6sx-sdb-wm8962
58 - fsl,imx7d-evk-wm8960
59 - karo,tx53-audio-sgtl5000
60 - tq,imx53-mba53-sgtl5000
61 - enum:
62 - fsl,imx-audio-ac97
63 - fsl,imx-audio-cs42888
64 - fsl,imx-audio-mqs
65 - fsl,imx-audio-sgtl5000
66 - fsl,imx-audio-wm8960
67 - fsl,imx-audio-wm8962
68 - items:
69 - enum:
70 - fsl,imx-sabreauto-spdif
71 - fsl,imx6sx-sdb-spdif
72 - const: fsl,imx-audio-spdif
73 - items:
74 - enum:
75 - fsl,imx-audio-ac97
76 - fsl,imx-audio-cs42888
77 - fsl,imx-audio-cs427x
78 - fsl,imx-audio-mqs
79 - fsl,imx-audio-nau8822
80 - fsl,imx-audio-sgtl5000
81 - fsl,imx-audio-si476x
82 - fsl,imx-audio-tlv320
83 - fsl,imx-audio-tlv320aic31xx
84 - fsl,imx-audio-tlv320aic32x4
85 - fsl,imx-audio-wm8524
86 - fsl,imx-audio-wm8904
87 - fsl,imx-audio-wm8960
88 - fsl,imx-audio-wm8962
89 - fsl,imx-audio-wm8958
90 - fsl,imx-audio-spdif
91
92 model:
93 $ref: /schemas/types.yaml#/definitions/string
94 description: The user-visible name of this sound complex
95
96 audio-asrc:
97 $ref: /schemas/types.yaml#/definitions/phandle
98 description:
99 The phandle of ASRC. It can be absent if there's no
100 need to add ASRC support via DPCM.
101
102 audio-codec:
103 $ref: /schemas/types.yaml#/definitions/phandle-array
104 description: |
105 The phandle of an audio codec.
106 With "fsl,imx-audio-spdif", either SPDIF audio codec spdif_transmitter,
107 spdif_receiver or both.
108 minItems: 1
109 maxItems: 2
110 items:
111 maxItems: 1
112
113 audio-cpu:
114 $ref: /schemas/types.yaml#/definitions/phandle
115 description: The phandle of an CPU DAI controller
116
117 audio-routing:
118 $ref: /schemas/types.yaml#/definitions/non-unique-string-array
119 description:
120 A list of the connections between audio components. Each entry is a
121 pair of strings, the first being the connection's sink, the second
122 being the connection's source. There're a few pre-designed board
123 connectors. "AMIC" stands for Analog Microphone Jack.
124 "DMIC" stands for Digital Microphone Jack. The "Mic Jack" and "AMIC"
125 are redundant while coexisting in order to support the old bindings
126 of wm8962 and sgtl5000.
127
128 hp-det-gpio:
129 deprecated: true
130 maxItems: 1
131 description: The GPIO that detect headphones are plugged in
132
133 hp-det-gpios:
134 maxItems: 1
135 description: The GPIO that detect headphones are plugged in
136
137 mic-det-gpio:
138 deprecated: true
139 maxItems: 1
140 description: The GPIO that detect microphones are plugged in
141
142 mic-det-gpios:
143 maxItems: 1
144 description: The GPIO that detect microphones are plugged in
145
146 bitclock-master:
147 $ref: simple-card.yaml#/definitions/bitclock-master
148 description: Indicates dai-link bit clock master.
149
150 frame-master:
151 $ref: simple-card.yaml#/definitions/frame-master
152 description: Indicates dai-link frame master.
153
154 format:
155 $ref: simple-card.yaml#/definitions/format
156 description: audio format.
157
158 frame-inversion:
159 $ref: simple-card.yaml#/definitions/frame-inversion
160 description: dai-link uses frame clock inversion.
161
162 bitclock-inversion:
163 $ref: simple-card.yaml#/definitions/bitclock-inversion
164 description: dai-link uses bit clock inversion.
165
166 mclk-id:
167 $ref: /schemas/types.yaml#/definitions/uint32-array
168 description: Main clock id for each codec, specific for each card configuration.
169 minItems: 1
170 maxItems: 2
171
172 mux-int-port:
173 $ref: /schemas/types.yaml#/definitions/uint32
174 enum: [1, 2, 7]
175 description: The internal port of the i.MX audio muxer (AUDMUX)
176
177 mux-ext-port:
178 $ref: /schemas/types.yaml#/definitions/uint32
179 enum: [3, 4, 5, 6]
180 description: The external port of the i.MX audio muxer
181
182 ssi-controller:
183 $ref: /schemas/types.yaml#/definitions/phandle
184 description: The phandle of an CPU DAI controller
185
186 spdif-controller:
187 $ref: /schemas/types.yaml#/definitions/phandle
188 deprecated: true
189 description: The phandle of an S/PDIF CPU DAI controller.
190
191 spdif-out:
192 type: boolean
193 deprecated: true
194 description: |
195 If present, the transmitting function of S/PDIF will be enabled,
196 indicating there's a physical S/PDIF out connector or jack on the
197 board or it's connecting to some other IP block, such as an HDMI
198 encoder or display-controller.
199
200 spdif-in:
201 type: boolean
202 deprecated: true
203 description: |
204 If present, the receiving function of S/PDIF will be enabled,
205 indicating there is a physical S/PDIF in connector/jack on the board.
206
207 required:
208 - compatible
209 - model
210
211 unevaluatedProperties: false
212
213 examples:
214 - |
215 sound-cs42888 {
216 compatible = "fsl,imx-audio-cs42888";
217 model = "cs42888-audio";
218 audio-cpu = <&esai>;
219 audio-asrc = <&asrc>;
220 audio-codec = <&cs42888>;
221 audio-routing =
222 "Line Out Jack", "AOUT1L",
223 "Line Out Jack", "AOUT1R",
224 "Line Out Jack", "AOUT2L",
225 "Line Out Jack", "AOUT2R",
226 "Line Out Jack", "AOUT3L",
227 "Line Out Jack", "AOUT3R",
228 "Line Out Jack", "AOUT4L",
229 "Line Out Jack", "AOUT4R",
230 "AIN1L", "Line In Jack",
231 "AIN1R", "Line In Jack",
232 "AIN2L", "Line In Jack",
233 "AIN2R", "Line In Jack";
234 };
235
236 - |
237 sound-spdif-asrc {
238 compatible = "fsl,imx-audio-spdif";
239 model = "spdif-asrc-audio";
240 audio-cpu = <&spdif>;
241 audio-asrc = <&easrc>;
242 audio-codec = <&spdifdit>, <&spdifdir>;
243 };
244

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

Freescale generic ASoC card 개요

1-29

이 YAML binding은 ASRC를 지원하는 Freescale generic ASoC sound card를 정의합니다. Freescale SoC와 external codec을 연결하는 공통 card이며 ASoC Simple Card와 비슷하지만 SoC 내부 ASRC를 자연스럽게 통합해 넓은 sample rate를 지원합니다.

초기 설계 대상은 AC'97, I2S, PCM DAI format이지만 driver가 확장되면 S/PDIF나 HDMI audio 같은 다른 형식도 지원할 수 있습니다. Maintainer는 Shengjiu Wang입니다.

Board-specific compatible과 fallback

30-67

첫 compatible 형식은 board-specific 문자열 하나와 그에 맞는 generic fallback 하나의 조합입니다. 허용되는 board-specific 값은 다음과 같습니다.

  • `fsl,imx-sgtl5000`
  • `fsl,imx25-pdk-sgtl5000`
  • `fsl,imx53-cpuvo-sgtl5000`
  • `fsl,imx51-babbage-sgtl5000`
  • `fsl,imx53-m53evk-sgtl5000`
  • `fsl,imx53-qsb-sgtl5000`
  • `fsl,imx53-voipac-sgtl5000`
  • `fsl,imx6-armadeus-sgtl5000`
  • `fsl,imx6-rex-sgtl5000`
  • `fsl,imx6-sabreauto-cs42888`
  • `fsl,imx6-wandboard-sgtl5000`
  • `fsl,imx6dl-nit6xlite-sgtl5000`
  • `fsl,imx6q-ba16-sgtl5000`
  • `fsl,imx6q-nitrogen6_max-sgtl5000`
  • `fsl,imx6q-nitrogen6_som2-sgtl5000`
  • `fsl,imx6q-nitrogen6x-sgtl5000`
  • `fsl,imx6q-sabrelite-sgtl5000`
  • `fsl,imx6q-sabresd-wm8962`
  • `fsl,imx6q-udoo-ac97`
  • `fsl,imx6q-ventana-sgtl5000`
  • `fsl,imx6sl-evk-wm8962`
  • `fsl,imx6sx-sdb-mqs`
  • `fsl,imx6sx-sdb-wm8962`
  • `fsl,imx7d-evk-wm8960`
  • `karo,tx53-audio-sgtl5000`
  • `tq,imx53-mba53-sgtl5000`

둘째 fallback 항목은 codec/card 구성에 따라 `fsl,imx-audio-ac97`, `fsl,imx-audio-cs42888`, `fsl,imx-audio-mqs`, `fsl,imx-audio-sgtl5000`, `fsl,imx-audio-wm8960`, `fsl,imx-audio-wm8962` 중 하나입니다.

S/PDIF와 generic compatible

68-91

S/PDIF board 형식은 `fsl,imx-sabreauto-spdif` 또는 `fsl,imx6sx-sdb-spdif` 뒤에 `fsl,imx-audio-spdif`를 둡니다.

단일 generic compatible로는 `fsl,imx-audio-ac97`, `fsl,imx-audio-cs42888`, `fsl,imx-audio-cs427x`, `fsl,imx-audio-mqs`, `fsl,imx-audio-nau8822`, `fsl,imx-audio-sgtl5000`, `fsl,imx-audio-si476x`, `fsl,imx-audio-tlv320`, `fsl,imx-audio-tlv320aic31xx`, `fsl,imx-audio-tlv320aic32x4`, `fsl,imx-audio-wm8524`, `fsl,imx-audio-wm8904`, `fsl,imx-audio-wm8960`, `fsl,imx-audio-wm8962`, `fsl,imx-audio-wm8958`, `fsl,imx-audio-spdif`를 허용합니다.

Audio routing과 jack detection

117-145

`audio-routing`은 audio component 연결 목록이며 각 pair의 첫 문자열이 sink, 둘째가 source입니다. `AMIC`은 analog microphone jack, `DMIC`은 digital microphone jack입니다. 기존 wm8962와 sgtl5000 binding 호환을 위해 `Mic Jack`과 `AMIC`은 함께 있을 때 의미가 중복됩니다.

Deprecated `hp-det-gpio`와 대체 속성 `hp-det-gpios`는 headphone plug detection GPIO 한 항목입니다. Deprecated `mic-det-gpio`와 대체 `mic-det-gpios`는 microphone plug detection GPIO 한 항목입니다.

DAI format, MCLK와 AUDMUX

146-180

`bitclock-master`, `frame-master`, `format`, `frame-inversion`, `bitclock-inversion`은 각각 `simple-card.yaml#`의 해당 정의를 참조해 DAI link의 clock master와 format/inversion을 지정합니다.

`mclk-id`는 codec별 main clock ID 배열로 1~2개입니다. `mux-int-port`는 AUDMUX internal port로 1, 2, 7 중 하나이고 `mux-ext-port`는 external port로 3, 4, 5, 6 중 하나입니다.

SSI와 deprecated S/PDIF 속성

181-206

`ssi-controller`는 CPU DAI controller phandle입니다. Deprecated `spdif-controller`는 S/PDIF CPU DAI controller phandle입니다.

Deprecated boolean `spdif-out`은 board의 physical S/PDIF output 또는 HDMI encoder/display controller 같은 IP 연결을 위해 transmit 기능을 활성화합니다. Deprecated `spdif-in`은 physical S/PDIF input connector를 위한 receive 기능을 활성화합니다.

필수 속성과 확장 제한

207-212

필수 속성은 `compatible`과 `model`입니다. `unevaluatedProperties: false`이므로 schema에서 평가되지 않은 속성을 허용하지 않습니다.

CS42888와 ASRC routing 예제

213-234

첫 예제는 `fsl,imx-audio-cs42888` card에 ESAI CPU DAI, ASRC와 CS42888 codec을 연결하고 네 stereo line output 및 두 stereo line input route를 정의합니다.

sound-cs42888 {
    compatible = "fsl,imx-audio-cs42888";
    model = "cs42888-audio";
    audio-cpu = <&esai>;
    audio-asrc = <&asrc>;
    audio-codec = <&cs42888>;
    audio-routing =
         "Line Out Jack", "AOUT1L",
         "Line Out Jack", "AOUT1R",
         "Line Out Jack", "AOUT2L",
         "Line Out Jack", "AOUT2R",
         "Line Out Jack", "AOUT3L",
         "Line Out Jack", "AOUT3R",
         "Line Out Jack", "AOUT4L",
         "Line Out Jack", "AOUT4R",
         "AIN1L", "Line In Jack",
         "AIN1R", "Line In Jack",
         "AIN2L", "Line In Jack",
         "AIN2R", "Line In Jack";
};

S/PDIF ASRC 예제

235-243

둘째 예제는 `fsl,imx-audio-spdif` card에 S/PDIF CPU, EASRC, transmitter와 receiver codec을 함께 연결합니다.

sound-spdif-asrc {
    compatible = "fsl,imx-audio-spdif";
    model = "spdif-asrc-audio";
    audio-cpu = <&spdif>;
    audio-asrc = <&easrc>;
    audio-codec = <&spdifdit>, <&spdifdir>;
};