xref: /freebsd/sys/contrib/device-tree/Bindings/sound/mediatek,mt8188-mt6359.yaml (revision f126890ac5386406dadf7c4cfa9566cbb56537c5)
1cb7aa33aSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2cb7aa33aSEmmanuel Vadot%YAML 1.2
3cb7aa33aSEmmanuel Vadot---
4cb7aa33aSEmmanuel Vadot$id: http://devicetree.org/schemas/sound/mediatek,mt8188-mt6359.yaml#
5cb7aa33aSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6cb7aa33aSEmmanuel Vadot
7cb7aa33aSEmmanuel Vadottitle: MediaTek MT8188 ASoC sound card
8cb7aa33aSEmmanuel Vadot
9cb7aa33aSEmmanuel Vadotmaintainers:
10cb7aa33aSEmmanuel Vadot  - Trevor Wu <trevor.wu@mediatek.com>
11cb7aa33aSEmmanuel Vadot
12cb7aa33aSEmmanuel Vadotproperties:
13cb7aa33aSEmmanuel Vadot  compatible:
14*f126890aSEmmanuel Vadot    enum:
15*f126890aSEmmanuel Vadot      - mediatek,mt8188-mt6359-evb
16*f126890aSEmmanuel Vadot      - mediatek,mt8188-nau8825
17cb7aa33aSEmmanuel Vadot
18cb7aa33aSEmmanuel Vadot  model:
19cb7aa33aSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/string
20cb7aa33aSEmmanuel Vadot    description: User specified audio sound card name
21cb7aa33aSEmmanuel Vadot
22cb7aa33aSEmmanuel Vadot  audio-routing:
23cb7aa33aSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/non-unique-string-array
24cb7aa33aSEmmanuel Vadot    description:
25cb7aa33aSEmmanuel Vadot      A list of the connections between audio components. Each entry is a
26cb7aa33aSEmmanuel Vadot      sink/source pair of strings. Valid names could be the input or output
27cb7aa33aSEmmanuel Vadot      widgets of audio components, power supplies, MicBias of codec and the
28cb7aa33aSEmmanuel Vadot      software switch.
29cb7aa33aSEmmanuel Vadot
30cb7aa33aSEmmanuel Vadot  mediatek,platform:
31cb7aa33aSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/phandle
32cb7aa33aSEmmanuel Vadot    description: The phandle of MT8188 ASoC platform.
33cb7aa33aSEmmanuel Vadot
34cb7aa33aSEmmanuel VadotpatternProperties:
35cb7aa33aSEmmanuel Vadot  "^dai-link-[0-9]+$":
36cb7aa33aSEmmanuel Vadot    type: object
37cb7aa33aSEmmanuel Vadot    description:
38cb7aa33aSEmmanuel Vadot      Container for dai-link level properties and CODEC sub-nodes.
39cb7aa33aSEmmanuel Vadot
40cb7aa33aSEmmanuel Vadot    properties:
41cb7aa33aSEmmanuel Vadot      link-name:
42cb7aa33aSEmmanuel Vadot        description:
43cb7aa33aSEmmanuel Vadot          This property corresponds to the name of the BE dai-link to which
44cb7aa33aSEmmanuel Vadot          we are going to update parameters in this node.
45cb7aa33aSEmmanuel Vadot        items:
46cb7aa33aSEmmanuel Vadot          enum:
47cb7aa33aSEmmanuel Vadot            - DPTX_BE
48cb7aa33aSEmmanuel Vadot            - ETDM1_IN_BE
49cb7aa33aSEmmanuel Vadot            - ETDM2_IN_BE
50cb7aa33aSEmmanuel Vadot            - ETDM1_OUT_BE
51cb7aa33aSEmmanuel Vadot            - ETDM2_OUT_BE
52cb7aa33aSEmmanuel Vadot            - ETDM3_OUT_BE
53cb7aa33aSEmmanuel Vadot            - PCM1_BE
54cb7aa33aSEmmanuel Vadot
55cb7aa33aSEmmanuel Vadot      codec:
56cb7aa33aSEmmanuel Vadot        description: Holds subnode which indicates codec dai.
57cb7aa33aSEmmanuel Vadot        type: object
58cb7aa33aSEmmanuel Vadot        additionalProperties: false
59cb7aa33aSEmmanuel Vadot        properties:
60cb7aa33aSEmmanuel Vadot          sound-dai:
61cb7aa33aSEmmanuel Vadot            minItems: 1
62cb7aa33aSEmmanuel Vadot            maxItems: 2
63cb7aa33aSEmmanuel Vadot        required:
64cb7aa33aSEmmanuel Vadot          - sound-dai
65cb7aa33aSEmmanuel Vadot
66*f126890aSEmmanuel Vadot      dai-format:
67*f126890aSEmmanuel Vadot        description: audio format.
68*f126890aSEmmanuel Vadot        items:
69*f126890aSEmmanuel Vadot          enum:
70*f126890aSEmmanuel Vadot            - i2s
71*f126890aSEmmanuel Vadot            - right_j
72*f126890aSEmmanuel Vadot            - left_j
73*f126890aSEmmanuel Vadot            - dsp_a
74*f126890aSEmmanuel Vadot            - dsp_b
75*f126890aSEmmanuel Vadot
76*f126890aSEmmanuel Vadot      mediatek,clk-provider:
77*f126890aSEmmanuel Vadot        $ref: /schemas/types.yaml#/definitions/string
78*f126890aSEmmanuel Vadot        description: Indicates dai-link clock master.
79*f126890aSEmmanuel Vadot        items:
80*f126890aSEmmanuel Vadot          enum:
81*f126890aSEmmanuel Vadot            - cpu
82*f126890aSEmmanuel Vadot            - codec
83*f126890aSEmmanuel Vadot
84cb7aa33aSEmmanuel Vadot    additionalProperties: false
85cb7aa33aSEmmanuel Vadot
86cb7aa33aSEmmanuel Vadot    required:
87cb7aa33aSEmmanuel Vadot      - link-name
88cb7aa33aSEmmanuel Vadot
89cb7aa33aSEmmanuel VadotadditionalProperties: false
90cb7aa33aSEmmanuel Vadot
91cb7aa33aSEmmanuel Vadotrequired:
92cb7aa33aSEmmanuel Vadot  - compatible
93cb7aa33aSEmmanuel Vadot  - mediatek,platform
94cb7aa33aSEmmanuel Vadot
95cb7aa33aSEmmanuel Vadotexamples:
96cb7aa33aSEmmanuel Vadot  - |
97cb7aa33aSEmmanuel Vadot    sound {
98cb7aa33aSEmmanuel Vadot        compatible = "mediatek,mt8188-mt6359-evb";
99cb7aa33aSEmmanuel Vadot        mediatek,platform = <&afe>;
100cb7aa33aSEmmanuel Vadot        pinctrl-names = "default";
101cb7aa33aSEmmanuel Vadot        pinctrl-0 = <&aud_pins_default>;
102cb7aa33aSEmmanuel Vadot        audio-routing =
103cb7aa33aSEmmanuel Vadot            "Headphone", "Headphone L",
104cb7aa33aSEmmanuel Vadot            "Headphone", "Headphone R",
105cb7aa33aSEmmanuel Vadot            "AIN1", "Headset Mic";
106cb7aa33aSEmmanuel Vadot        dai-link-0 {
107cb7aa33aSEmmanuel Vadot            link-name = "ETDM3_OUT_BE";
108*f126890aSEmmanuel Vadot            dai-format = "i2s";
109*f126890aSEmmanuel Vadot            mediatek,clk-provider = "cpu";
110cb7aa33aSEmmanuel Vadot            codec {
111cb7aa33aSEmmanuel Vadot                sound-dai = <&hdmi0>;
112cb7aa33aSEmmanuel Vadot            };
113cb7aa33aSEmmanuel Vadot        };
114cb7aa33aSEmmanuel Vadot    };
115cb7aa33aSEmmanuel Vadot
116cb7aa33aSEmmanuel Vadot...
117