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