1b66cd835SJai Luthra# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 2b66cd835SJai Luthra# Copyright (C) 2022 Texas Instruments Incorporated 3b66cd835SJai Luthra%YAML 1.2 4b66cd835SJai Luthra--- 5b66cd835SJai Luthra$id: http://devicetree.org/schemas/sound/ti,tlv320aic3x.yaml# 6b66cd835SJai Luthra$schema: http://devicetree.org/meta-schemas/core.yaml# 7b66cd835SJai Luthra 8b66cd835SJai Luthratitle: Texas Instruments TLV320AIC3x Codec 9b66cd835SJai Luthra 10b66cd835SJai Luthradescription: | 11b66cd835SJai Luthra TLV320AIC3x are a series of low-power stereo audio codecs with stereo 12b66cd835SJai Luthra headphone amplifier, as well as multiple inputs and outputs programmable in 13b66cd835SJai Luthra single-ended or fully differential configurations. 14b66cd835SJai Luthra 15b66cd835SJai Luthra The serial control bus supports SPI or I2C protocols, while the serial audio 16b66cd835SJai Luthra data bus is programmable for I2S, left/right-justified, DSP, or TDM modes. 17b66cd835SJai Luthra 18b66cd835SJai Luthra The following pins can be referred in the sound node's audio routing property: 19b66cd835SJai Luthra 20b66cd835SJai Luthra CODEC output pins: 21b66cd835SJai Luthra LLOUT 22b66cd835SJai Luthra RLOUT 23b66cd835SJai Luthra MONO_LOUT 24b66cd835SJai Luthra HPLOUT 25b66cd835SJai Luthra HPROUT 26b66cd835SJai Luthra HPLCOM 27b66cd835SJai Luthra HPRCOM 28b66cd835SJai Luthra 29b66cd835SJai Luthra CODEC input pins for TLV320AIC3104: 30b66cd835SJai Luthra MIC2L 31b66cd835SJai Luthra MIC2R 32b66cd835SJai Luthra LINE1L 33b66cd835SJai Luthra LINE1R 34b66cd835SJai Luthra 35b66cd835SJai Luthra CODEC input pins for other compatible codecs: 36b66cd835SJai Luthra MIC3L 37b66cd835SJai Luthra MIC3R 38b66cd835SJai Luthra LINE1L 39b66cd835SJai Luthra LINE2L 40b66cd835SJai Luthra LINE1R 41b66cd835SJai Luthra LINE2R 42b66cd835SJai Luthra 43b66cd835SJai Luthramaintainers: 44b66cd835SJai Luthra - Jai Luthra <j-luthra@ti.com> 45b66cd835SJai Luthra 46b66cd835SJai Luthraproperties: 47b66cd835SJai Luthra compatible: 48b66cd835SJai Luthra enum: 49b66cd835SJai Luthra - ti,tlv320aic3x 50b66cd835SJai Luthra - ti,tlv320aic33 51b66cd835SJai Luthra - ti,tlv320aic3007 52b66cd835SJai Luthra - ti,tlv320aic3106 53b66cd835SJai Luthra - ti,tlv320aic3104 54b66cd835SJai Luthra 55b66cd835SJai Luthra reg: 56b66cd835SJai Luthra maxItems: 1 57b66cd835SJai Luthra 58b66cd835SJai Luthra reset-gpios: 59b66cd835SJai Luthra maxItems: 1 60b66cd835SJai Luthra description: 61b66cd835SJai Luthra GPIO specification for the active low RESET input. 62b66cd835SJai Luthra 63b66cd835SJai Luthra gpio-reset: 64*a3f6df1bSRob Herring $ref: /schemas/types.yaml#/definitions/uint32-matrix 65b66cd835SJai Luthra maxItems: 1 66b66cd835SJai Luthra description: 67b66cd835SJai Luthra Deprecated, please use reset-gpios instead. 68b66cd835SJai Luthra deprecated: true 69b66cd835SJai Luthra 70b66cd835SJai Luthra ai3x-gpio-func: 71b66cd835SJai Luthra description: AIC3X_GPIO1 & AIC3X_GPIO2 Functionality 72b66cd835SJai Luthra $ref: /schemas/types.yaml#/definitions/uint32-array 73b66cd835SJai Luthra maxItems: 2 74b66cd835SJai Luthra 75b66cd835SJai Luthra ai3x-micbias-vg: 76b66cd835SJai Luthra description: MicBias required voltage. If node is omitted then MicBias is powered down. 77b66cd835SJai Luthra $ref: /schemas/types.yaml#/definitions/uint32 78b66cd835SJai Luthra oneOf: 79b66cd835SJai Luthra - const: 1 80b66cd835SJai Luthra description: MICBIAS output is powered to 2.0V. 81b66cd835SJai Luthra - const: 2 82b66cd835SJai Luthra description: MICBIAS output is powered to 2.5V. 83b66cd835SJai Luthra - const: 3 84b66cd835SJai Luthra description: MICBIAS output is connected to AVDD. 85b66cd835SJai Luthra 86b66cd835SJai Luthra ai3x-ocmv: 87b66cd835SJai Luthra description: Output Common-Mode Voltage selection. 88b66cd835SJai Luthra $ref: /schemas/types.yaml#/definitions/uint32 89b66cd835SJai Luthra oneOf: 90b66cd835SJai Luthra - const: 0 91b66cd835SJai Luthra description: 1.35V 92b66cd835SJai Luthra - const: 1 93b66cd835SJai Luthra description: 1.5V 94b66cd835SJai Luthra - const: 2 95b66cd835SJai Luthra description: 1.65V 96b66cd835SJai Luthra - const: 3 97b66cd835SJai Luthra description: 1.8V 98b66cd835SJai Luthra 99b66cd835SJai Luthra AVDD-supply: 100b66cd835SJai Luthra description: Analog DAC voltage. 101b66cd835SJai Luthra 102b66cd835SJai Luthra IOVDD-supply: 103b66cd835SJai Luthra description: I/O voltage. 104b66cd835SJai Luthra 105b66cd835SJai Luthra DRVDD-supply: 106b66cd835SJai Luthra description: ADC analog and output driver voltage. 107b66cd835SJai Luthra 108b66cd835SJai Luthra DVDD-supply: 109b66cd835SJai Luthra description: Digital core voltage. 110b66cd835SJai Luthra 111b66cd835SJai Luthra '#sound-dai-cells': 112b66cd835SJai Luthra const: 0 113b66cd835SJai Luthra 114b6e98cf4SJai Luthra clocks: 115b6e98cf4SJai Luthra maxItems: 1 116b6e98cf4SJai Luthra 117b6e98cf4SJai Luthra port: 118b6e98cf4SJai Luthra $ref: audio-graph-port.yaml# 119b6e98cf4SJai Luthra unevaluatedProperties: false 120b6e98cf4SJai Luthra 121b66cd835SJai Luthrarequired: 122b66cd835SJai Luthra - compatible 123b66cd835SJai Luthra - reg 124b66cd835SJai Luthra 125b66cd835SJai LuthraadditionalProperties: false 126b66cd835SJai Luthra 127b66cd835SJai Luthraexamples: 128b66cd835SJai Luthra - | 129b66cd835SJai Luthra #include <dt-bindings/gpio/gpio.h> 130b66cd835SJai Luthra i2c { 131b66cd835SJai Luthra #address-cells = <1>; 132b66cd835SJai Luthra #size-cells = <0>; 133b66cd835SJai Luthra 134b66cd835SJai Luthra tlv320aic3x_i2c: audio-codec@1b { 135b66cd835SJai Luthra compatible = "ti,tlv320aic3x"; 136b66cd835SJai Luthra reg = <0x1b>; 137b66cd835SJai Luthra 138b66cd835SJai Luthra reset-gpios = <&gpio1 17 GPIO_ACTIVE_LOW>; 139b66cd835SJai Luthra 140b66cd835SJai Luthra AVDD-supply = <®ulator>; 141b66cd835SJai Luthra IOVDD-supply = <®ulator>; 142b66cd835SJai Luthra DRVDD-supply = <®ulator>; 143b66cd835SJai Luthra DVDD-supply = <®ulator>; 144b66cd835SJai Luthra }; 145b66cd835SJai Luthra }; 146b66cd835SJai Luthra 147b66cd835SJai Luthra - | 148b66cd835SJai Luthra #include <dt-bindings/gpio/gpio.h> 149b66cd835SJai Luthra spi { 150b66cd835SJai Luthra #address-cells = <1>; 151b66cd835SJai Luthra #size-cells = <0>; 152b66cd835SJai Luthra 153b66cd835SJai Luthra tlv320aic3x_spi: audio-codec@0 { 154b66cd835SJai Luthra compatible = "ti,tlv320aic3x"; 155b66cd835SJai Luthra reg = <0>; /* CS number */ 156b66cd835SJai Luthra #sound-dai-cells = <0>; 157b66cd835SJai Luthra 158b66cd835SJai Luthra AVDD-supply = <®ulator>; 159b66cd835SJai Luthra IOVDD-supply = <®ulator>; 160b66cd835SJai Luthra DRVDD-supply = <®ulator>; 161b66cd835SJai Luthra DVDD-supply = <®ulator>; 162b66cd835SJai Luthra ai3x-ocmv = <0>; 163b66cd835SJai Luthra }; 164b66cd835SJai Luthra }; 165b66cd835SJai Luthra 166b66cd835SJai Luthra... 167