Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: dt-bindings: ti,pcm3168a: Convert to json-schema

Convert the Texas Instruments PCM3168A Audio Codec Device Tree binding
documentation to json-schema.

Add missing properties.
Drop unneeded pinctrl properties from example.

Link: https://lore.kernel.org/r/cover.1669980383.git.geert+renesas@glider.be
Link: https://lore.kernel.org/r/87mt7qpylw.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/87k01d7rfv.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Geert Uytterhoeven and committed by
Mark Brown
13a7d9e9 f2a7ef1a

+107 -56
-56
Documentation/devicetree/bindings/sound/ti,pcm3168a.txt
··· 1 - Texas Instruments pcm3168a DT bindings 2 - 3 - This driver supports both SPI and I2C bus access for this codec 4 - 5 - Required properties: 6 - 7 - - compatible: "ti,pcm3168a" 8 - 9 - - clocks : Contains an entry for each entry in clock-names 10 - 11 - - clock-names : Includes the following entries: 12 - "scki" The system clock 13 - 14 - - VDD1-supply : Digital power supply regulator 1 (+3.3V) 15 - 16 - - VDD2-supply : Digital power supply regulator 2 (+3.3V) 17 - 18 - - VCCAD1-supply : ADC power supply regulator 1 (+5V) 19 - 20 - - VCCAD2-supply : ADC power supply regulator 2 (+5V) 21 - 22 - - VCCDA1-supply : DAC power supply regulator 1 (+5V) 23 - 24 - - VCCDA2-supply : DAC power supply regulator 2 (+5V) 25 - 26 - For required properties on SPI/I2C, consult SPI/I2C device tree documentation 27 - 28 - Optional properties: 29 - 30 - - reset-gpios : Optional reset gpio line connected to RST pin of the codec. 31 - The RST line is low active: 32 - RST = low: device power-down 33 - RST = high: device is enabled 34 - 35 - Examples: 36 - 37 - i2c0: i2c0@0 { 38 - 39 - ... 40 - 41 - pcm3168a: audio-codec@44 { 42 - compatible = "ti,pcm3168a"; 43 - reg = <0x44>; 44 - reset-gpios = <&gpio0 4 GPIO_ACTIVE_LOW>; 45 - clocks = <&clk_core CLK_AUDIO>; 46 - clock-names = "scki"; 47 - VDD1-supply = <&supply3v3>; 48 - VDD2-supply = <&supply3v3>; 49 - VCCAD1-supply = <&supply5v0>; 50 - VCCAD2-supply = <&supply5v0>; 51 - VCCDA1-supply = <&supply5v0>; 52 - VCCDA2-supply = <&supply5v0>; 53 - pinctrl-names = "default"; 54 - pinctrl-0 = <&dac_clk_pin>; 55 - }; 56 - };
+107
Documentation/devicetree/bindings/sound/ti,pcm3168a.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/sound/ti,pcm3168a.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Texas Instruments PCM3168A Audio Codec 8 + 9 + maintainers: 10 + - Damien Horsley <Damien.Horsley@imgtec.com> 11 + - Geert Uytterhoeven <geert+renesas@glider.be> 12 + - Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> 13 + 14 + description: 15 + The Texas Instruments PCM3168A is a 24-bit Multi-channel Audio CODEC with 16 + 96/192kHz sampling rate, supporting both SPI and I2C bus access. 17 + 18 + properties: 19 + compatible: 20 + const: ti,pcm3168a 21 + 22 + reg: 23 + maxItems: 1 24 + 25 + clocks: 26 + items: 27 + - description: System clock input 28 + 29 + clock-names: 30 + items: 31 + - const: scki 32 + 33 + reset-gpios: 34 + items: 35 + - description: | 36 + GPIO line connected to the active-low RST pin of the codec. 37 + RST = low: device power-down 38 + RST = high: device is enabled 39 + 40 + "#sound-dai-cells": 41 + enum: [0, 1] 42 + 43 + VDD1-supply: 44 + description: Digital power supply regulator 1 (+3.3V) 45 + 46 + VDD2-supply: 47 + description: Digital power supply regulator 2 (+3.3V) 48 + 49 + VCCAD1-supply: 50 + description: ADC power supply regulator 1 (+5V) 51 + 52 + VCCAD2-supply: 53 + description: ADC power supply regulator 2 (+5V) 54 + 55 + VCCDA1-supply: 56 + description: DAC power supply regulator 1 (+5V) 57 + 58 + VCCDA2-supply: 59 + description: DAC power supply regulator 2 (+5V) 60 + 61 + ports: 62 + $ref: audio-graph-port.yaml#/definitions/port-base 63 + properties: 64 + port@0: 65 + $ref: audio-graph-port.yaml# 66 + description: Audio input port. 67 + 68 + port@1: 69 + $ref: audio-graph-port.yaml# 70 + description: Audio output port. 71 + 72 + required: 73 + - compatible 74 + - reg 75 + - clocks 76 + - clock-names 77 + - VDD1-supply 78 + - VDD2-supply 79 + - VCCAD1-supply 80 + - VCCAD2-supply 81 + - VCCDA1-supply 82 + - VCCDA2-supply 83 + 84 + additionalProperties: false 85 + 86 + examples: 87 + - | 88 + #include <dt-bindings/gpio/gpio.h> 89 + 90 + i2c { 91 + #address-cells = <1>; 92 + #size-cells = <0>; 93 + 94 + pcm3168a: audio-codec@44 { 95 + compatible = "ti,pcm3168a"; 96 + reg = <0x44>; 97 + reset-gpios = <&gpio0 4 GPIO_ACTIVE_LOW>; 98 + clocks = <&clk_core 42>; 99 + clock-names = "scki"; 100 + VDD1-supply = <&supply3v3>; 101 + VDD2-supply = <&supply3v3>; 102 + VCCAD1-supply = <&supply5v0>; 103 + VCCAD2-supply = <&supply5v0>; 104 + VCCDA1-supply = <&supply5v0>; 105 + VCCDA2-supply = <&supply5v0>; 106 + }; 107 + };