요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/google,sc7280-herobrine.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Google SC7280-Herobrine ASoC sound card driver
maintainers:
- Judy Hsiao <judyhsiao@chromium.org>
description:
This binding describes the SC7280 sound card which uses LPASS for audio.
allOf:
- $ref: sound-card-common.yaml#
properties:
compatible:
enum:
- google,sc7280-herobrine
"#address-cells":
const: 1
"#size-cells":
const: 0
patternProperties:
"^dai-link@[0-9a-f]$":
description:
Each subnode represents a dai link. Subnodes of each dai links would be
cpu/codec dais.
type: object
properties:
link-name:
description: Indicates dai-link name and PCM stream name.
$ref: /schemas/types.yaml#/definitions/string
maxItems: 1
reg:
maxItems: 1
description: dai link address.
cpu:
description: Holds subnode which indicates cpu dai.
type: object
properties:
sound-dai: true
required:
- sound-dai
additionalProperties: false
codec:
description: Holds subnode which indicates codec dai.
type: object
properties:
sound-dai: true
required:
- sound-dai
additionalProperties: false
platform:
description: Holds subnode which includes the phandle of q6apm platform device.
type: object
properties:
sound-dai:
maxItems: 1
required:
- sound-dai
additionalProperties: false
required:
- link-name
- cpu
- codec
- reg
additionalProperties: false
required:
- compatible
- "#address-cells"
- "#size-cells"
unevaluatedProperties: false
examples:
- |
#include <dt-bindings/sound/qcom,lpass.h>
sound {
compatible = "google,sc7280-herobrine";
model = "sc7280-wcd938x-max98360a-4dmic";
audio-routing =
"IN1_HPHL", "HPHL_OUT",
"IN2_HPHR", "HPHR_OUT",
"AMIC1", "MIC BIAS1",
"AMIC2", "MIC BIAS2",
"VA DMIC0", "MIC BIAS3",
"VA DMIC1", "MIC BIAS3",
"VA DMIC2", "MIC BIAS4",
"VA DMIC3", "MIC BIAS4",
"TX SWR_ADC0", "ADC1_OUTPUT",
"TX SWR_ADC1", "ADC2_OUTPUT",
"TX SWR_ADC2", "ADC3_OUTPUT",
"TX SWR_DMIC0", "DMIC1_OUTPUT",
"TX SWR_DMIC1", "DMIC2_OUTPUT",
"TX SWR_DMIC2", "DMIC3_OUTPUT",
"TX SWR_DMIC3", "DMIC4_OUTPUT";
#address-cells = <1>;
#size-cells = <0>;
dai-link@0 {
link-name = "WCD Playback";
reg = <LPASS_CDC_DMA_RX0>;
cpu {
sound-dai = <&lpass_cpu LPASS_CDC_DMA_RX0>;
};
codec {
sound-dai = <&wcd938x 0>, <&swr0 0>, <&rxmacro 0>;
};
};
dai-link@1 {
link-name = "WCD Capture";
reg = <LPASS_CDC_DMA_TX3>;
cpu {
sound-dai = <&lpass_cpu LPASS_CDC_DMA_TX3>;
};
codec {
sound-dai = <&wcd938x 1>, <&swr1 0>, <&txmacro 0>;
};
};
dai-link@2 {
link-name = "MI2S Playback";
reg = <MI2S_SECONDARY>;
cpu {
sound-dai = <&lpass_cpu MI2S_SECONDARY>;
};
codec {
sound-dai = <&max98360a>;
};
};
dai-link@3 {
link-name = "DMIC Capture";
reg = <LPASS_CDC_DMA_VA_TX0>;
cpu {
sound-dai = <&lpass_cpu LPASS_CDC_DMA_VA_TX0>;
};
codec {
sound-dai = <&vamacro 0>;
};
};
dai-link@5 {
link-name = "DP Playback";
reg = <LPASS_DP_RX>;
cpu {
sound-dai = <&lpass_cpu LPASS_DP_RX>;
};
codec {
sound-dai = <&mdss_dp>;
};
};
};
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
SC7280 Herobrine ASoC card
1-17이 binding은 audio에 LPASS를 사용하는 Google SC7280 sound card를 설명합니다. `sound-card-common.yaml#`을 상속하며 schema ID는 `http://devicetree.org/schemas/sound/google,sc7280-herobrine.yaml#`, maintainer는 Judy Hsiao입니다.
Card compatible과 child addressing
18-28`compatible`은 `google,sc7280-herobrine`, `#address-cells`는 1, `#size-cells`는 0입니다.
DAI link와 CPU subnode
29-57각 `^dai-link@[0-9a-f]$` subnode는 하나의 DAI link이며 CPU와 codec DAI를 child로 둡니다. `link-name`은 DAI-link와 PCM stream 이름이고 `reg`는 link address로 각각 최대 한 항목입니다.
`cpu` subnode는 CPU DAI를 나타내며 `sound-dai`가 필수입니다. `additionalProperties: false`이므로 다른 속성은 허용하지 않습니다.
Codec·platform DAI와 link 계약
58-88`codec` subnode도 `sound-dai`가 필수이고 추가 속성을 허용하지 않습니다. `platform` subnode는 Q6APM platform device의 phandle을 포함하며 `sound-dai`는 최대 한 항목이면서 필수입니다.
각 link에는 `link-name`, `cpu`, `codec`, `reg`가 필수입니다. Link node 자체도 `additionalProperties: false`입니다.
Card 필수 속성과 확장 제한
89-95Card에 필요한 속성은 `compatible`, `#address-cells`, `#size-cells`입니다. `unevaluatedProperties: false`이므로 공통 sound-card schema 평가 뒤 정의되지 않은 속성은 허용하지 않습니다.
Herobrine WCD938x·MAX98360A 예제
96-182예제 `sc7280-wcd938x-max98360a-4dmic` card는 WCD playback/capture, secondary MI2S speaker playback, 4-DMIC capture, DisplayPort playback의 다섯 link를 정의합니다. 각 link는 `LPASS_CDC_DMA_RX0`, `LPASS_CDC_DMA_TX3`, `MI2S_SECONDARY`, `LPASS_CDC_DMA_VA_TX0`, `LPASS_DP_RX` ID로 CPU와 해당 codec을 연결합니다.
- |
#include <dt-bindings/sound/qcom,lpass.h>
sound {
compatible = "google,sc7280-herobrine";
model = "sc7280-wcd938x-max98360a-4dmic";
audio-routing =
"IN1_HPHL", "HPHL_OUT",
"IN2_HPHR", "HPHR_OUT",
"AMIC1", "MIC BIAS1",
"AMIC2", "MIC BIAS2",
"VA DMIC0", "MIC BIAS3",
"VA DMIC1", "MIC BIAS3",
"VA DMIC2", "MIC BIAS4",
"VA DMIC3", "MIC BIAS4",
"TX SWR_ADC0", "ADC1_OUTPUT",
"TX SWR_ADC1", "ADC2_OUTPUT",
"TX SWR_ADC2", "ADC3_OUTPUT",
"TX SWR_DMIC0", "DMIC1_OUTPUT",
"TX SWR_DMIC1", "DMIC2_OUTPUT",
"TX SWR_DMIC2", "DMIC3_OUTPUT",
"TX SWR_DMIC3", "DMIC4_OUTPUT";
#address-cells = <1>;
#size-cells = <0>;
dai-link@0 {
link-name = "WCD Playback";
reg = <LPASS_CDC_DMA_RX0>;
cpu {
sound-dai = <&lpass_cpu LPASS_CDC_DMA_RX0>;
};
codec {
sound-dai = <&wcd938x 0>, <&swr0 0>, <&rxmacro 0>;
};
};
dai-link@1 {
link-name = "WCD Capture";
reg = <LPASS_CDC_DMA_TX3>;
cpu {
sound-dai = <&lpass_cpu LPASS_CDC_DMA_TX3>;
};
codec {
sound-dai = <&wcd938x 1>, <&swr1 0>, <&txmacro 0>;
};
};
dai-link@2 {
link-name = "MI2S Playback";
reg = <MI2S_SECONDARY>;
cpu {
sound-dai = <&lpass_cpu MI2S_SECONDARY>;
};
codec {
sound-dai = <&max98360a>;
};
};
dai-link@3 {
link-name = "DMIC Capture";
reg = <LPASS_CDC_DMA_VA_TX0>;
cpu {
sound-dai = <&lpass_cpu LPASS_CDC_DMA_VA_TX0>;
};
codec {
sound-dai = <&vamacro 0>;
};
};
dai-link@5 {
link-name = "DP Playback";
reg = <LPASS_DP_RX>;
cpu {
sound-dai = <&lpass_cpu LPASS_DP_RX>;
};
codec {
sound-dai = <&mdss_dp>;
};
};
};
요약과 해설
google,sc7280-herobrine.yaml:1-182Google SC7280 LPASS card와 Hisilicon·Imagination audio controller의 DAI, DMA, clock, reset 계약을 먼저 해설하고, 접을 수 있는 영어 원문 전체와 legacy TXT의 property·code·줄 좌표를 보존한 한국어 전문 번역을 제공합니다.