1*e67e8565SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2*e67e8565SEmmanuel Vadot%YAML 1.2 3*e67e8565SEmmanuel Vadot--- 4*e67e8565SEmmanuel Vadot$id: http://devicetree.org/schemas/sound/ti,tlv320adc3xxx.yaml# 5*e67e8565SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6*e67e8565SEmmanuel Vadot 7*e67e8565SEmmanuel Vadottitle: Texas Instruments TLV320ADC3001/TLV320ADC3101 Stereo ADC 8*e67e8565SEmmanuel Vadot 9*e67e8565SEmmanuel Vadotmaintainers: 10*e67e8565SEmmanuel Vadot - Ricard Wanderlof <ricardw@axis.com> 11*e67e8565SEmmanuel Vadot 12*e67e8565SEmmanuel Vadotdescription: | 13*e67e8565SEmmanuel Vadot Texas Instruments TLV320ADC3001 and TLV320ADC3101 Stereo ADC 14*e67e8565SEmmanuel Vadot https://www.ti.com/product/TLV320ADC3001 15*e67e8565SEmmanuel Vadot https://www.ti.com/product/TLV320ADC3101 16*e67e8565SEmmanuel Vadot 17*e67e8565SEmmanuel Vadotproperties: 18*e67e8565SEmmanuel Vadot compatible: 19*e67e8565SEmmanuel Vadot enum: 20*e67e8565SEmmanuel Vadot - ti,tlv320adc3001 21*e67e8565SEmmanuel Vadot - ti,tlv320adc3101 22*e67e8565SEmmanuel Vadot 23*e67e8565SEmmanuel Vadot reg: 24*e67e8565SEmmanuel Vadot maxItems: 1 25*e67e8565SEmmanuel Vadot description: I2C address 26*e67e8565SEmmanuel Vadot 27*e67e8565SEmmanuel Vadot '#sound-dai-cells': 28*e67e8565SEmmanuel Vadot const: 0 29*e67e8565SEmmanuel Vadot 30*e67e8565SEmmanuel Vadot '#gpio-cells': 31*e67e8565SEmmanuel Vadot const: 2 32*e67e8565SEmmanuel Vadot 33*e67e8565SEmmanuel Vadot gpio-controller: true 34*e67e8565SEmmanuel Vadot 35*e67e8565SEmmanuel Vadot reset-gpios: 36*e67e8565SEmmanuel Vadot maxItems: 1 37*e67e8565SEmmanuel Vadot description: GPIO pin used for codec reset (RESET pin) 38*e67e8565SEmmanuel Vadot 39*e67e8565SEmmanuel Vadot clocks: 40*e67e8565SEmmanuel Vadot maxItems: 1 41*e67e8565SEmmanuel Vadot description: Master clock (MCLK) 42*e67e8565SEmmanuel Vadot 43*e67e8565SEmmanuel Vadot ti,dmdin-gpio1: 44*e67e8565SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 45*e67e8565SEmmanuel Vadot enum: 46*e67e8565SEmmanuel Vadot - 0 # ADC3XXX_GPIO_DISABLED - I/O buffers powered down and not used 47*e67e8565SEmmanuel Vadot - 1 # ADC3XXX_GPIO_INPUT - Various non-GPIO input functions 48*e67e8565SEmmanuel Vadot - 2 # ADC3XXX_GPIO_GPI - General purpose input 49*e67e8565SEmmanuel Vadot - 3 # ADC3XXX_GPIO_GPO - General purpose output 50*e67e8565SEmmanuel Vadot - 4 # ADC3XXX_GPIO_CLKOUT - Clock source set in CLKOUT_MUX reg 51*e67e8565SEmmanuel Vadot - 5 # ADC3XXX_GPIO_INT1 - INT1 output 52*e67e8565SEmmanuel Vadot - 6 # ADC3XXX_GPIO_SECONDARY_BCLK - Codec interface secondary BCLK 53*e67e8565SEmmanuel Vadot - 7 # ADC3XXX_GPIO_SECONDARY_WCLK - Codec interface secondary WCLK 54*e67e8565SEmmanuel Vadot default: 0 55*e67e8565SEmmanuel Vadot description: | 56*e67e8565SEmmanuel Vadot Configuration for DMDIN/GPIO1 pin. 57*e67e8565SEmmanuel Vadot 58*e67e8565SEmmanuel Vadot When ADC3XXX_GPIO_GPO is configured, this causes corresponding the 59*e67e8565SEmmanuel Vadot ALSA control "GPIOx Output" to appear, as a switch control. 60*e67e8565SEmmanuel Vadot 61*e67e8565SEmmanuel Vadot ti,dmclk-gpio2: 62*e67e8565SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 63*e67e8565SEmmanuel Vadot enum: 64*e67e8565SEmmanuel Vadot - 0 # ADC3XXX_GPIO_DISABLED - I/O buffers powered down and not used 65*e67e8565SEmmanuel Vadot - 1 # ADC3XXX_GPIO_INPUT - Various non-GPIO input functions 66*e67e8565SEmmanuel Vadot - 2 # ADC3XXX_GPIO_GPI - General purpose input 67*e67e8565SEmmanuel Vadot - 3 # ADC3XXX_GPIO_GPO - General purpose output 68*e67e8565SEmmanuel Vadot - 4 # ADC3XXX_GPIO_CLKOUT - Clock source set in CLKOUT_MUX reg 69*e67e8565SEmmanuel Vadot - 5 # ADC3XXX_GPIO_INT1 - INT1 output 70*e67e8565SEmmanuel Vadot - 6 # ADC3XXX_GPIO_SECONDARY_BCLK - Codec interface secondary BCLK 71*e67e8565SEmmanuel Vadot - 7 # ADC3XXX_GPIO_SECONDARY_WCLK - Codec interface secondary WCLK 72*e67e8565SEmmanuel Vadot default: 0 73*e67e8565SEmmanuel Vadot description: | 74*e67e8565SEmmanuel Vadot Configuration for DMCLK/GPIO2 pin. 75*e67e8565SEmmanuel Vadot 76*e67e8565SEmmanuel Vadot When ADC3XXX_GPIO_GPO is configured, this causes corresponding the 77*e67e8565SEmmanuel Vadot ALSA control "GPIOx Output" to appear, as a switch control. 78*e67e8565SEmmanuel Vadot 79*e67e8565SEmmanuel Vadot Note that there is currently no support for reading the GPIO pins as 80*e67e8565SEmmanuel Vadot inputs. 81*e67e8565SEmmanuel Vadot 82*e67e8565SEmmanuel Vadot ti,micbias1-vg: 83*e67e8565SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 84*e67e8565SEmmanuel Vadot enum: 85*e67e8565SEmmanuel Vadot - 0 # ADC3XXX_MICBIAS_OFF - Mic bias is powered down 86*e67e8565SEmmanuel Vadot - 1 # ADC3XXX_MICBIAS_2_0V - Mic bias is set to 2.0V 87*e67e8565SEmmanuel Vadot - 2 # ADC3XXX_MICBIAS_2_5V - Mic bias is set to 2.5V 88*e67e8565SEmmanuel Vadot - 3 # ADC3XXX_MICBIAS_AVDD - Mic bias is same as AVDD supply 89*e67e8565SEmmanuel Vadot default: 0 90*e67e8565SEmmanuel Vadot description: | 91*e67e8565SEmmanuel Vadot Mic bias voltage output on MICBIAS1 pin 92*e67e8565SEmmanuel Vadot 93*e67e8565SEmmanuel Vadot ti,micbias2-vg: 94*e67e8565SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 95*e67e8565SEmmanuel Vadot enum: 96*e67e8565SEmmanuel Vadot - 0 # ADC3XXX_MICBIAS_OFF - Mic bias is powered down 97*e67e8565SEmmanuel Vadot - 1 # ADC3XXX_MICBIAS_2_0V - Mic bias is set to 2.0V 98*e67e8565SEmmanuel Vadot - 2 # ADC3XXX_MICBIAS_2_5V - Mic bias is set to 2.5V 99*e67e8565SEmmanuel Vadot - 3 # ADC3XXX_MICBIAS_AVDD - Mic bias is same as AVDD supply 100*e67e8565SEmmanuel Vadot default: 0 101*e67e8565SEmmanuel Vadot description: | 102*e67e8565SEmmanuel Vadot Mic bias voltage output on MICBIAS2 pin 103*e67e8565SEmmanuel Vadot 104*e67e8565SEmmanuel Vadotrequired: 105*e67e8565SEmmanuel Vadot - compatible 106*e67e8565SEmmanuel Vadot - reg 107*e67e8565SEmmanuel Vadot - clocks 108*e67e8565SEmmanuel Vadot 109*e67e8565SEmmanuel VadotadditionalProperties: false 110*e67e8565SEmmanuel Vadot 111*e67e8565SEmmanuel Vadotexamples: 112*e67e8565SEmmanuel Vadot - | 113*e67e8565SEmmanuel Vadot 114*e67e8565SEmmanuel Vadot #include <dt-bindings/gpio/gpio.h> 115*e67e8565SEmmanuel Vadot #include <dt-bindings/sound/tlv320adc3xxx.h> 116*e67e8565SEmmanuel Vadot 117*e67e8565SEmmanuel Vadot i2c { 118*e67e8565SEmmanuel Vadot #address-cells = <1>; 119*e67e8565SEmmanuel Vadot #size-cells = <0>; 120*e67e8565SEmmanuel Vadot tlv320adc3101: audio-codec@18 { 121*e67e8565SEmmanuel Vadot compatible = "ti,tlv320adc3101"; 122*e67e8565SEmmanuel Vadot reg = <0x18>; 123*e67e8565SEmmanuel Vadot reset-gpios = <&gpio_pc 3 GPIO_ACTIVE_LOW>; 124*e67e8565SEmmanuel Vadot clocks = <&audio_mclk>; 125*e67e8565SEmmanuel Vadot gpio-controller; 126*e67e8565SEmmanuel Vadot #gpio-cells = <2>; 127*e67e8565SEmmanuel Vadot ti,dmdin-gpio1 = <ADC3XXX_GPIO_GPO>; 128*e67e8565SEmmanuel Vadot ti,micbias1-vg = <ADC3XXX_MICBIAS_AVDD>; 129*e67e8565SEmmanuel Vadot }; 130*e67e8565SEmmanuel Vadot }; 131*e67e8565SEmmanuel Vadot 132*e67e8565SEmmanuel Vadot audio_mclk: clock { 133*e67e8565SEmmanuel Vadot compatible = "fixed-clock"; 134*e67e8565SEmmanuel Vadot #clock-cells = <0>; 135*e67e8565SEmmanuel Vadot clock-frequency = <24576000>; 136*e67e8565SEmmanuel Vadot }; 137*e67e8565SEmmanuel Vadot... 138