1*8cc087a1SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2*8cc087a1SEmmanuel Vadot%YAML 1.2 3*8cc087a1SEmmanuel Vadot--- 4*8cc087a1SEmmanuel Vadot$id: "http://devicetree.org/schemas/sound/qcom,q6dsp-lpass-ports.yaml#" 5*8cc087a1SEmmanuel Vadot$schema: "http://devicetree.org/meta-schemas/core.yaml#" 6*8cc087a1SEmmanuel Vadot 7*8cc087a1SEmmanuel Vadottitle: Qualcomm DSP LPASS(Low Power Audio SubSystem) Audio Ports binding 8*8cc087a1SEmmanuel Vadot 9*8cc087a1SEmmanuel Vadotmaintainers: 10*8cc087a1SEmmanuel Vadot - Srinivas Kandagatla <srinivas.kandagatla@linaro.org> 11*8cc087a1SEmmanuel Vadot 12*8cc087a1SEmmanuel Vadotdescription: | 13*8cc087a1SEmmanuel Vadot This binding describes the Qualcomm DSP LPASS Audio ports 14*8cc087a1SEmmanuel Vadot 15*8cc087a1SEmmanuel Vadotproperties: 16*8cc087a1SEmmanuel Vadot compatible: 17*8cc087a1SEmmanuel Vadot enum: 18*8cc087a1SEmmanuel Vadot - qcom,q6afe-dais 19*8cc087a1SEmmanuel Vadot - qcom,q6apm-lpass-dais 20*8cc087a1SEmmanuel Vadot 21*8cc087a1SEmmanuel Vadot reg: 22*8cc087a1SEmmanuel Vadot maxItems: 1 23*8cc087a1SEmmanuel Vadot 24*8cc087a1SEmmanuel Vadot '#sound-dai-cells': 25*8cc087a1SEmmanuel Vadot const: 1 26*8cc087a1SEmmanuel Vadot 27*8cc087a1SEmmanuel Vadot '#address-cells': 28*8cc087a1SEmmanuel Vadot const: 1 29*8cc087a1SEmmanuel Vadot 30*8cc087a1SEmmanuel Vadot '#size-cells': 31*8cc087a1SEmmanuel Vadot const: 0 32*8cc087a1SEmmanuel Vadot 33*8cc087a1SEmmanuel Vadot#Digital Audio Interfaces 34*8cc087a1SEmmanuel VadotpatternProperties: 35*8cc087a1SEmmanuel Vadot '^dai@[0-9]+$': 36*8cc087a1SEmmanuel Vadot type: object 37*8cc087a1SEmmanuel Vadot description: 38*8cc087a1SEmmanuel Vadot Q6DSP Digital Audio Interfaces. 39*8cc087a1SEmmanuel Vadot 40*8cc087a1SEmmanuel Vadot properties: 41*8cc087a1SEmmanuel Vadot reg: 42*8cc087a1SEmmanuel Vadot description: 43*8cc087a1SEmmanuel Vadot Digital Audio Interface ID 44*8cc087a1SEmmanuel Vadot 45*8cc087a1SEmmanuel Vadot qcom,sd-lines: 46*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32-array 47*8cc087a1SEmmanuel Vadot description: 48*8cc087a1SEmmanuel Vadot List of serial data lines used by this dai.should be one or more of the 0-3 sd lines. 49*8cc087a1SEmmanuel Vadot minItems: 1 50*8cc087a1SEmmanuel Vadot maxItems: 4 51*8cc087a1SEmmanuel Vadot uniqueItems: true 52*8cc087a1SEmmanuel Vadot items: 53*8cc087a1SEmmanuel Vadot minimum: 0 54*8cc087a1SEmmanuel Vadot maximum: 3 55*8cc087a1SEmmanuel Vadot 56*8cc087a1SEmmanuel Vadot qcom,tdm-sync-mode: 57*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 58*8cc087a1SEmmanuel Vadot enum: [0, 1, 2] 59*8cc087a1SEmmanuel Vadot description: 60*8cc087a1SEmmanuel Vadot TDM Synchronization mode 61*8cc087a1SEmmanuel Vadot 0 = Short sync bit mode 62*8cc087a1SEmmanuel Vadot 1 = Long sync mode 63*8cc087a1SEmmanuel Vadot 2 = Short sync slot mode 64*8cc087a1SEmmanuel Vadot 65*8cc087a1SEmmanuel Vadot qcom,tdm-sync-src: 66*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 67*8cc087a1SEmmanuel Vadot enum: [0, 1] 68*8cc087a1SEmmanuel Vadot description: 69*8cc087a1SEmmanuel Vadot TDM Synchronization source 70*8cc087a1SEmmanuel Vadot 0 = External source 71*8cc087a1SEmmanuel Vadot 1 = Internal source 72*8cc087a1SEmmanuel Vadot 73*8cc087a1SEmmanuel Vadot qcom,tdm-data-out: 74*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 75*8cc087a1SEmmanuel Vadot enum: [0, 1] 76*8cc087a1SEmmanuel Vadot description: 77*8cc087a1SEmmanuel Vadot TDM Data out signal to drive with other masters 78*8cc087a1SEmmanuel Vadot 0 = Disable 79*8cc087a1SEmmanuel Vadot 1 = Enable 80*8cc087a1SEmmanuel Vadot 81*8cc087a1SEmmanuel Vadot qcom,tdm-invert-sync: 82*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 83*8cc087a1SEmmanuel Vadot enum: [0, 1] 84*8cc087a1SEmmanuel Vadot description: 85*8cc087a1SEmmanuel Vadot TDM Invert the sync 86*8cc087a1SEmmanuel Vadot 0 = Normal 87*8cc087a1SEmmanuel Vadot 1 = Invert 88*8cc087a1SEmmanuel Vadot 89*8cc087a1SEmmanuel Vadot qcom,tdm-data-delay: 90*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 91*8cc087a1SEmmanuel Vadot enum: [0, 1, 2] 92*8cc087a1SEmmanuel Vadot description: 93*8cc087a1SEmmanuel Vadot TDM Number of bit clock to delay data 94*8cc087a1SEmmanuel Vadot 0 = 0 bit clock cycle 95*8cc087a1SEmmanuel Vadot 1 = 1 bit clock cycle 96*8cc087a1SEmmanuel Vadot 2 = 2 bit clock cycle 97*8cc087a1SEmmanuel Vadot 98*8cc087a1SEmmanuel Vadot qcom,tdm-data-align: 99*8cc087a1SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 100*8cc087a1SEmmanuel Vadot enum: [0, 1] 101*8cc087a1SEmmanuel Vadot description: 102*8cc087a1SEmmanuel Vadot Indicate how data is packed within the slot. For example, 32 slot 103*8cc087a1SEmmanuel Vadot width in case of sample bit width is 24TDM Invert the sync. 104*8cc087a1SEmmanuel Vadot 0 = MSB 105*8cc087a1SEmmanuel Vadot 1 = LSB 106*8cc087a1SEmmanuel Vadot 107*8cc087a1SEmmanuel Vadot required: 108*8cc087a1SEmmanuel Vadot - reg 109*8cc087a1SEmmanuel Vadot 110*8cc087a1SEmmanuel Vadot allOf: 111*8cc087a1SEmmanuel Vadot - if: 112*8cc087a1SEmmanuel Vadot properties: 113*8cc087a1SEmmanuel Vadot reg: 114*8cc087a1SEmmanuel Vadot contains: 115*8cc087a1SEmmanuel Vadot # TDM DAI ID range from PRIMARY_TDM_RX_0 - QUINARY_TDM_TX_7 116*8cc087a1SEmmanuel Vadot items: 117*8cc087a1SEmmanuel Vadot minimum: 24 118*8cc087a1SEmmanuel Vadot maximum: 103 119*8cc087a1SEmmanuel Vadot then: 120*8cc087a1SEmmanuel Vadot required: 121*8cc087a1SEmmanuel Vadot - qcom,tdm-sync-mode 122*8cc087a1SEmmanuel Vadot - qcom,tdm-sync-src 123*8cc087a1SEmmanuel Vadot - qcom,tdm-data-out 124*8cc087a1SEmmanuel Vadot - qcom,tdm-invert-sync 125*8cc087a1SEmmanuel Vadot - qcom,tdm-data-delay 126*8cc087a1SEmmanuel Vadot - qcom,tdm-data-align 127*8cc087a1SEmmanuel Vadot 128*8cc087a1SEmmanuel Vadot - if: 129*8cc087a1SEmmanuel Vadot properties: 130*8cc087a1SEmmanuel Vadot reg: 131*8cc087a1SEmmanuel Vadot contains: 132*8cc087a1SEmmanuel Vadot # MI2S DAI ID range PRIMARY_MI2S_RX - QUATERNARY_MI2S_TX and 133*8cc087a1SEmmanuel Vadot # QUINARY_MI2S_RX - QUINARY_MI2S_TX 134*8cc087a1SEmmanuel Vadot items: 135*8cc087a1SEmmanuel Vadot oneOf: 136*8cc087a1SEmmanuel Vadot - minimum: 16 137*8cc087a1SEmmanuel Vadot maximum: 23 138*8cc087a1SEmmanuel Vadot - minimum: 127 139*8cc087a1SEmmanuel Vadot maximum: 128 140*8cc087a1SEmmanuel Vadot then: 141*8cc087a1SEmmanuel Vadot required: 142*8cc087a1SEmmanuel Vadot - qcom,sd-lines 143*8cc087a1SEmmanuel Vadot 144*8cc087a1SEmmanuel Vadot additionalProperties: false 145*8cc087a1SEmmanuel Vadot 146*8cc087a1SEmmanuel Vadotrequired: 147*8cc087a1SEmmanuel Vadot - compatible 148*8cc087a1SEmmanuel Vadot - reg 149*8cc087a1SEmmanuel Vadot - "#sound-dai-cells" 150*8cc087a1SEmmanuel Vadot - "#address-cells" 151*8cc087a1SEmmanuel Vadot - "#size-cells" 152*8cc087a1SEmmanuel Vadot 153*8cc087a1SEmmanuel VadotadditionalProperties: false 154*8cc087a1SEmmanuel Vadot 155*8cc087a1SEmmanuel Vadotexamples: 156*8cc087a1SEmmanuel Vadot - | 157*8cc087a1SEmmanuel Vadot #include <dt-bindings/soc/qcom,apr.h> 158*8cc087a1SEmmanuel Vadot #include <dt-bindings/sound/qcom,q6afe.h> 159*8cc087a1SEmmanuel Vadot apr { 160*8cc087a1SEmmanuel Vadot #address-cells = <1>; 161*8cc087a1SEmmanuel Vadot #size-cells = <0>; 162*8cc087a1SEmmanuel Vadot apr-service@4 { 163*8cc087a1SEmmanuel Vadot reg = <APR_SVC_AFE>; 164*8cc087a1SEmmanuel Vadot #address-cells = <1>; 165*8cc087a1SEmmanuel Vadot #size-cells = <0>; 166*8cc087a1SEmmanuel Vadot q6afedai@1 { 167*8cc087a1SEmmanuel Vadot compatible = "qcom,q6afe-dais"; 168*8cc087a1SEmmanuel Vadot reg = <1>; 169*8cc087a1SEmmanuel Vadot #address-cells = <1>; 170*8cc087a1SEmmanuel Vadot #size-cells = <0>; 171*8cc087a1SEmmanuel Vadot #sound-dai-cells = <1>; 172*8cc087a1SEmmanuel Vadot 173*8cc087a1SEmmanuel Vadot dai@22 { 174*8cc087a1SEmmanuel Vadot reg = <QUATERNARY_MI2S_RX>; 175*8cc087a1SEmmanuel Vadot qcom,sd-lines = <0 1 2 3>; 176*8cc087a1SEmmanuel Vadot }; 177*8cc087a1SEmmanuel Vadot }; 178*8cc087a1SEmmanuel Vadot }; 179*8cc087a1SEmmanuel Vadot }; 180*8cc087a1SEmmanuel Vadot - | 181*8cc087a1SEmmanuel Vadot #include <dt-bindings/soc/qcom,gpr.h> 182*8cc087a1SEmmanuel Vadot gpr { 183*8cc087a1SEmmanuel Vadot compatible = "qcom,gpr"; 184*8cc087a1SEmmanuel Vadot #address-cells = <1>; 185*8cc087a1SEmmanuel Vadot #size-cells = <0>; 186*8cc087a1SEmmanuel Vadot qcom,domain = <GPR_DOMAIN_ID_ADSP>; 187*8cc087a1SEmmanuel Vadot service@1 { 188*8cc087a1SEmmanuel Vadot compatible = "qcom,q6apm"; 189*8cc087a1SEmmanuel Vadot reg = <GPR_APM_MODULE_IID>; 190*8cc087a1SEmmanuel Vadot #address-cells = <1>; 191*8cc087a1SEmmanuel Vadot #size-cells = <0>; 192*8cc087a1SEmmanuel Vadot q6apmdai@1 { 193*8cc087a1SEmmanuel Vadot compatible = "qcom,q6apm-lpass-dais"; 194*8cc087a1SEmmanuel Vadot reg = <1>; 195*8cc087a1SEmmanuel Vadot #address-cells = <1>; 196*8cc087a1SEmmanuel Vadot #size-cells = <0>; 197*8cc087a1SEmmanuel Vadot #sound-dai-cells = <1>; 198*8cc087a1SEmmanuel Vadot 199*8cc087a1SEmmanuel Vadot dai@22 { 200*8cc087a1SEmmanuel Vadot reg = <QUATERNARY_MI2S_RX>; 201*8cc087a1SEmmanuel Vadot qcom,sd-lines = <0 1 2 3>; 202*8cc087a1SEmmanuel Vadot }; 203*8cc087a1SEmmanuel Vadot }; 204*8cc087a1SEmmanuel Vadot }; 205*8cc087a1SEmmanuel Vadot }; 206