1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/sound/qcom,lpass-cpu.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: Qualcomm Technologies Inc. LPASS CPU dai driver bindings 8 9maintainers: 10 - Srinivas Kandagatla <srinivas.kandagatla@linaro.org> 11 - Rohit kumar <rohitkr@codeaurora.org> 12 13description: | 14 Qualcomm Technologies Inc. SOC Low-Power Audio SubSystem (LPASS) that consist 15 of MI2S interface for audio data transfer on external codecs. LPASS cpu driver 16 is a module to configure Low-Power Audio Interface(LPAIF) core registers 17 across different IP versions. 18 19properties: 20 compatible: 21 enum: 22 - qcom,lpass-cpu 23 - qcom,apq8016-lpass-cpu 24 - qcom,sc7180-lpass-cpu 25 - qcom,sc7280-lpass-cpu 26 27 reg: 28 minItems: 2 29 maxItems: 6 30 description: LPAIF core registers 31 32 reg-names: 33 minItems: 2 34 maxItems: 6 35 36 clocks: 37 minItems: 3 38 maxItems: 7 39 40 clock-names: 41 minItems: 3 42 maxItems: 7 43 44 interrupts: 45 minItems: 2 46 maxItems: 4 47 description: LPAIF DMA buffer interrupt 48 49 interrupt-names: 50 minItems: 2 51 maxItems: 4 52 53 qcom,adsp: 54 $ref: /schemas/types.yaml#/definitions/phandle 55 description: Phandle for the audio DSP node 56 57 iommus: 58 minItems: 2 59 maxItems: 3 60 description: Phandle to apps_smmu node with sid mask 61 62 power-domains: 63 maxItems: 1 64 65 '#sound-dai-cells': 66 const: 1 67 68 '#address-cells': 69 const: 1 70 71 '#size-cells': 72 const: 0 73 74patternProperties: 75 "^dai-link@[0-9a-f]$": 76 type: object 77 description: | 78 LPASS CPU dai node for each I2S device or Soundwire device. Bindings of each node 79 depends on the specific driver providing the functionality and 80 properties. 81 properties: 82 reg: 83 maxItems: 1 84 description: Must be one of the DAI ID 85 86 qcom,playback-sd-lines: 87 $ref: /schemas/types.yaml#/definitions/uint32-array 88 description: list of MI2S data lines for playback 89 90 qcom,capture-sd-lines: 91 $ref: /schemas/types.yaml#/definitions/uint32-array 92 description: list of MI2S data lines for capture 93 94 required: 95 - reg 96 97 additionalProperties: false 98 99required: 100 - compatible 101 - reg 102 - reg-names 103 - clocks 104 - clock-names 105 - interrupts 106 - interrupt-names 107 - '#sound-dai-cells' 108 109additionalProperties: false 110 111allOf: 112 - if: 113 properties: 114 compatible: 115 contains: 116 const: qcom,lpass-cpu 117 118 then: 119 properties: 120 clock-names: 121 items: 122 - const: ahbix-clk 123 - const: mi2s-osr-clk 124 - const: mi2s-bit-clk 125 126 - if: 127 properties: 128 compatible: 129 contains: 130 const: qcom,apq8016-lpass-cpu 131 132 then: 133 properties: 134 clock-names: 135 items: 136 - const: ahbix-clk 137 - const: mi2s-bit-clk0 138 - const: mi2s-bit-clk1 139 - const: mi2s-bit-clk2 140 - const: mi2s-bit-clk3 141 - const: pcnoc-mport-clk 142 - const: pcnoc-sway-clk 143 144 - if: 145 properties: 146 compatible: 147 contains: 148 const: qcom,sc7180-lpass-cpu 149 150 then: 151 properties: 152 clock-names: 153 oneOf: 154 - items: #for I2S 155 - const: pcnoc-sway-clk 156 - const: audio-core 157 - const: mclk0 158 - const: pcnoc-mport-clk 159 - const: mi2s-bit-clk0 160 - const: mi2s-bit-clk1 161 - items: #for HDMI 162 - const: pcnoc-sway-clk 163 - const: audio-core 164 - const: pcnoc-mport-clk 165 reg-names: 166 anyOf: 167 - items: #for I2S 168 - const: lpass-lpaif 169 - items: #for I2S and HDMI 170 - const: lpass-hdmiif 171 - const: lpass-lpaif 172 interrupt-names: 173 anyOf: 174 - items: #for I2S 175 - const: lpass-irq-lpaif 176 - items: #for I2S and HDMI 177 - const: lpass-irq-lpaif 178 - const: lpass-irq-hdmi 179 required: 180 - iommus 181 - power-domains 182 183 - if: 184 properties: 185 compatible: 186 contains: 187 const: qcom,sc7280-lpass-cpu 188 189 then: 190 properties: 191 clock-names: 192 oneOf: 193 - items: #for I2S 194 - const: aon_cc_audio_hm_h 195 - const: core_cc_sysnoc_mport_core 196 - const: core_cc_ext_if1_ibit 197 - items: #for Soundwire 198 - const: aon_cc_audio_hm_h 199 - const: audio_cc_codec_mem0 200 - const: audio_cc_codec_mem1 201 - const: audio_cc_codec_mem2 202 - items: #for HDMI 203 - const: aon_cc_audio_hm_h 204 205 reg-names: 206 anyOf: 207 - items: #for I2S 208 - const: lpass-lpaif 209 - items: #for I2S and HDMI 210 - const: lpass-hdmiif 211 - const: lpass-lpaif 212 - items: #for I2S, soundwire and HDMI 213 - const: lpass-hdmiif 214 - const: lpass-lpaif 215 - const: lpass-rxtx-cdc-dma-lpm 216 - const: lpass-rxtx-lpaif 217 - const: lpass-va-lpaif 218 - const: lpass-va-cdc-dma-lpm 219 interrupt-names: 220 anyOf: 221 - items: #for I2S 222 - const: lpass-irq-lpaif 223 - items: #for I2S and HDMI 224 - const: lpass-irq-lpaif 225 - const: lpass-irq-hdmi 226 - items: #for I2S, soundwire and HDMI 227 - const: lpass-irq-lpaif 228 - const: lpass-irq-hdmi 229 - const: lpass-irq-vaif 230 - const: lpass-irq-rxtxif 231 232 required: 233 - iommus 234 - power-domains 235 236examples: 237 - | 238 #include <dt-bindings/sound/sc7180-lpass.h> 239 240 soc { 241 #address-cells = <2>; 242 #size-cells = <2>; 243 lpass@62d80000 { 244 compatible = "qcom,sc7180-lpass-cpu"; 245 246 reg = <0 0x62d87000 0 0x68000>, 247 <0 0x62f00000 0 0x29000>; 248 reg-names = "lpass-hdmiif", 249 "lpass-lpaif"; 250 iommus = <&apps_smmu 0x1020 0>, 251 <&apps_smmu 0x1032 0>; 252 power-domains = <&lpass_hm 0>; 253 254 clocks = <&gcc 131>, 255 <&lpasscorecc 6>, 256 <&lpasscorecc 7>, 257 <&lpasscorecc 10>, 258 <&lpasscorecc 8>, 259 <&lpasscorecc 9>; 260 261 clock-names = "pcnoc-sway-clk", "audio-core", 262 "mclk0", "pcnoc-mport-clk", 263 "mi2s-bit-clk0", "mi2s-bit-clk1"; 264 265 interrupts = <0 160 1>, 266 <0 268 1>; 267 interrupt-names = "lpass-irq-lpaif", 268 "lpass-irq-hdmi"; 269 #sound-dai-cells = <1>; 270 271 #address-cells = <1>; 272 #size-cells = <0>; 273 /* Optional to set different MI2S SD lines */ 274 dai-link@0 { 275 reg = <MI2S_PRIMARY>; 276 qcom,playback-sd-lines = <1>; 277 qcom,capture-sd-lines = <0>; 278 }; 279 }; 280 }; 281 282... 283