199 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2%YAML 1.23---4$id: http://devicetree.org/schemas/sound/mt8186-mt6366-da7219-max98357.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#6 7title: Mediatek MT8186 with MT6366, DA7219 and MAX98357 ASoC sound card driver8 9maintainers:10 - Jiaxin Yu <jiaxin.yu@mediatek.com>11 12description:13 This binding describes the MT8186 sound card.14 15allOf:16 - $ref: sound-card-common.yaml#17 18properties:19 compatible:20 enum:21 - mediatek,mt8186-mt6366-da7219-max98357-sound22 23 audio-routing:24 $ref: /schemas/types.yaml#/definitions/non-unique-string-array25 description:26 A list of the connections between audio components. Each entry is a27 pair of strings, the first being the connection's sink, the second28 being the connection's source.29 Valid names could be the input or output widgets of audio components,30 power supplies, MicBias of codec and the software switch.31 minItems: 232 items:33 enum:34 # Sinks35 - HDMI136 - Headphones37 - Line Out38 - MIC39 - Speakers40 41 # Sources42 - Headset Mic43 - HPL44 - HPR45 - Speaker46 - TX47 48 mediatek,platform:49 $ref: /schemas/types.yaml#/definitions/phandle50 description: The phandle of MT8186 ASoC platform.51 52 headset-codec:53 type: object54 deprecated: true55 additionalProperties: false56 properties:57 sound-dai:58 maxItems: 159 required:60 - sound-dai61 62 playback-codecs:63 type: object64 deprecated: true65 additionalProperties: false66 properties:67 sound-dai:68 items:69 - description: phandle of dp codec70 - description: phandle of l channel speaker codec71 - description: phandle of r channel speaker codec72 minItems: 273 required:74 - sound-dai75 76 mediatek,adsp:77 $ref: /schemas/types.yaml#/definitions/phandle78 description: The phandle of MT8186 ADSP platform.79 80 mediatek,dai-link:81 $ref: /schemas/types.yaml#/definitions/string-array82 description:83 A list of the desired dai-links in the sound card. Each entry is a84 name defined in the machine driver.85 86patternProperties:87 ".*-dai-link$":88 type: object89 additionalProperties: false90 description:91 Container for dai-link level properties and CODEC sub-nodes.92 93 properties:94 link-name:95 description: Indicates dai-link name and PCM stream name96 items:97 enum:98 - I2S099 - I2S1100 - I2S2101 - I2S3102 103 codec:104 description: Holds subnode which indicates codec dai.105 type: object106 additionalProperties: false107 properties:108 sound-dai:109 minItems: 1110 maxItems: 2111 required:112 - sound-dai113 114 dai-format:115 description: audio format116 items:117 enum:118 - i2s119 - right_j120 - left_j121 - dsp_a122 - dsp_b123 124 mediatek,clk-provider:125 $ref: /schemas/types.yaml#/definitions/string126 description: Indicates dai-link clock master.127 items:128 enum:129 - cpu130 - codec131 132 required:133 - link-name134 135unevaluatedProperties: false136 137required:138 - compatible139 - mediatek,platform140 141# Disallow legacy properties if xxx-dai-link nodes are specified142if:143 not:144 patternProperties:145 ".*-dai-link$": false146then:147 properties:148 headset-codec: false149 speaker-codecs: false150 151examples:152 - |153 154 sound: mt8186-sound {155 compatible = "mediatek,mt8186-mt6366-da7219-max98357-sound";156 model = "mt8186_da7219_m98357";157 pinctrl-names = "aud_clk_mosi_off",158 "aud_clk_mosi_on";159 pinctrl-0 = <&aud_clk_mosi_off>;160 pinctrl-1 = <&aud_clk_mosi_on>;161 mediatek,platform = <&afe>;162 163 audio-routing =164 "Headphones", "HPL",165 "Headphones", "HPR",166 "MIC", "Headset Mic",167 "Speakers", "Speaker",168 "HDMI1", "TX";169 170 hs-playback-dai-link {171 link-name = "I2S0";172 dai-format = "i2s";173 mediatek,clk-provider = "cpu";174 codec {175 sound-dai = <&da7219>;176 };177 };178 179 hs-capture-dai-link {180 link-name = "I2S1";181 dai-format = "i2s";182 mediatek,clk-provider = "cpu";183 codec {184 sound-dai = <&da7219>;185 };186 };187 188 spk-dp-playback-dai-link {189 link-name = "I2S3";190 dai-format = "i2s";191 mediatek,clk-provider = "cpu";192 codec {193 sound-dai = <&anx_bridge_dp>, <&max98357a>;194 };195 };196 };197 198...199