ASoC: dt-bindings: samsung: convert to dtschema

Merge series from Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>:

Convert Samsung DT bindings to dtschema
This commit is contained in:
Mark Brown 2022-02-10 16:52:07 +00:00
Родитель b0d0e85f14 c1fc51ebb0
Коммит a61faea1a0
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 24D68B725D5487D0
9 изменённых файлов: 241 добавлений и 112 удалений

Просмотреть файл

@ -1,25 +0,0 @@
Audio Binding for Arndale boards
Required properties:
- compatible : Can be one of the following:
"samsung,arndale-rt5631",
"samsung,arndale-wm1811"
- samsung,audio-cpu: The phandle of the Samsung I2S controller
- samsung,audio-codec: The phandle of the audio codec
Optional:
- samsung,model: The name of the sound-card
Arndale Boards has many audio daughter cards, one of them is
rt5631/alc5631. Below example shows audio bindings for rt5631/
alc5631 based codec.
Example:
sound {
compatible = "samsung,arndale-rt5631";
samsung,audio-cpu = <&i2s0>
samsung,audio-codec = <&rt5631>;
};

Просмотреть файл

@ -31,6 +31,8 @@ properties:
description: |
phandles to the I2S controller and bluetooth codec,
in that order
required:
- sound-dai
codec:
type: object
@ -38,6 +40,8 @@ properties:
sound-dai:
$ref: /schemas/types.yaml#/definitions/phandle-array
description: phandle to the WM8994 CODEC
required:
- sound-dai
samsung,audio-routing:
$ref: /schemas/types.yaml#/definitions/non-unique-string-array

Просмотреть файл

@ -0,0 +1,45 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/samsung,arndale.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Insignal Arndale boards audio complex
maintainers:
- Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
- Sylwester Nawrocki <s.nawrocki@samsung.com>
properties:
compatible:
enum:
- samsung,arndale-alc5631
- samsung,arndale-rt5631
- samsung,arndale-wm1811
samsung,audio-codec:
description: Phandle to the audio codec.
$ref: /schemas/types.yaml#/definitions/phandle
samsung,audio-cpu:
description: Phandle to the Samsung I2S controller.
$ref: /schemas/types.yaml#/definitions/phandle
samsung,model:
description: The user-visible name of this sound complex.
$ref: /schemas/types.yaml#/definitions/string
required:
- compatible
- samsung,audio-codec
- samsung,audio-cpu
additionalProperties: false
examples:
- |
sound {
compatible = "samsung,arndale-rt5631";
samsung,audio-cpu = <&i2s0>;
samsung,audio-codec = <&rt5631>;
};

Просмотреть файл

@ -1,14 +0,0 @@
Samsung SMDK audio complex
Required properties:
- compatible : "samsung,smdk-wm8994"
- samsung,i2s-controller: The phandle of the Samsung I2S0 controller
- samsung,audio-codec: The phandle of the WM8994 audio codec
Example:
sound {
compatible = "samsung,smdk-wm8994";
samsung,i2s-controller = <&i2s0>;
samsung,audio-codec = <&wm8994>;
};

Просмотреть файл

@ -0,0 +1,38 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/samsung,smdk5250.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Samsung SMDK5250 audio complex with WM8994 codec
maintainers:
- Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
- Sylwester Nawrocki <s.nawrocki@samsung.com>
properties:
compatible:
const: samsung,smdk-wm8994
samsung,audio-codec:
description: Phandle to the audio codec.
$ref: /schemas/types.yaml#/definitions/phandle
samsung,i2s-controller:
description: Phandle to the Samsung I2S controller.
$ref: /schemas/types.yaml#/definitions/phandle
required:
- compatible
- samsung,audio-codec
- samsung,i2s-controller
additionalProperties: false
examples:
- |
sound {
compatible = "samsung,smdk-wm8994";
samsung,i2s-controller = <&i2s0>;
samsung,audio-codec = <&wm8994>;
};

Просмотреть файл

@ -0,0 +1,74 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/samsung,snow.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Google Snow audio complex with MAX9809x codec
maintainers:
- Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
- Sylwester Nawrocki <s.nawrocki@samsung.com>
properties:
compatible:
enum:
- google,snow-audio-max98090
- google,snow-audio-max98091
- google,snow-audio-max98095
codec:
type: object
properties:
sound-dai:
description: List of phandles to the CODEC and HDMI IP nodes.
items:
- description: Phandle to the MAX98090, MAX98091 or MAX98095 CODEC.
- description: Phandle to the HDMI IP block node.
required:
- sound-dai
cpu:
type: object
properties:
sound-dai:
description: Phandle to the Samsung I2S controller.
maxItems: 1
required:
- sound-dai
samsung,audio-codec:
description: Phandle to the audio codec.
$ref: /schemas/types.yaml#/definitions/phandle
deprecated: true
samsung,i2s-controller:
description: Phandle to the Samsung I2S controller.
$ref: /schemas/types.yaml#/definitions/phandle
deprecated: true
samsung,model:
description: The user-visible name of this sound complex.
$ref: /schemas/types.yaml#/definitions/string
required:
- compatible
- codec
- cpu
additionalProperties: false
examples:
- |
sound {
compatible = "google,snow-audio-max98095";
samsung,model = "Snow-I2S-MAX98095";
cpu {
sound-dai = <&i2s0 0>;
};
codec {
sound-dai = <&max98095 0>, <&hdmi>;
};
};

Просмотреть файл

@ -1,42 +0,0 @@
Samsung Exynos5433 TM2(E) audio complex with WM5110 codec
Required properties:
- compatible : "samsung,tm2-audio"
- model : the user-visible name of this sound complex
- audio-codec : the first entry should be phandle of the wm5110 audio
codec node, as described in ../mfd/arizona.txt;
the second entry should be phandle of the HDMI
transmitter node
- i2s-controller : the list of phandle and argument tuples pointing to
I2S controllers, the first entry should be I2S0 and
the second one I2S1
- audio-amplifier : the phandle of the MAX98504 amplifier
- samsung,audio-routing : a list of the connections between audio components;
each entry is a pair of strings, the first being the
connection's sink, the second being the connection's
source; valid names for sources and sinks are the
WM5110's and MAX98504's pins and the jacks on the
board: HP, SPK, Main Mic, Sub Mic, Third Mic,
Headset Mic
- mic-bias-gpios : GPIO pin that enables the Main Mic bias regulator
Example:
sound {
compatible = "samsung,tm2-audio";
audio-codec = <&wm5110>, <&hdmi>;
i2s-controller = <&i2s0 0>, <&i2s1 0>;
audio-amplifier = <&max98504>;
mic-bias-gpios = <&gpr3 2 0>;
model = "wm5110";
samsung,audio-routing =
"HP", "HPOUT1L",
"HP", "HPOUT1R",
"SPK", "SPKOUT",
"SPKOUT", "HPOUT2L",
"SPKOUT", "HPOUT2R",
"Main Mic", "MICBIAS2",
"IN1R", "Main Mic";
};

Просмотреть файл

@ -0,0 +1,80 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/samsung,tm2.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Samsung Exynos5433 TM2(E) audio complex with WM5110 codec
maintainers:
- Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
- Sylwester Nawrocki <s.nawrocki@samsung.com>
properties:
compatible:
const: samsung,tm2-audio
audio-amplifier:
description: Phandle to the MAX98504 amplifier.
$ref: /schemas/types.yaml#/definitions/phandle
audio-codec:
description: Phandles to the codecs.
$ref: /schemas/types.yaml#/definitions/phandle-array
items:
- description: Phandle to the WM5110 audio codec.
- description: Phandle to the HDMI transmitter node.
samsung,audio-routing:
description: |
List of the connections between audio components; each entry is
a pair of strings, the first being the connection's sink, the second
being the connection's source; valid names for sources and sinks are the
WM5110's and MAX98504's pins and the jacks on the board: HP, SPK, Main
Mic, Sub Mic, Third Mic, Headset Mic.
$ref: /schemas/types.yaml#/definitions/non-unique-string-array
i2s-controller:
description: Phandles to the I2S controllers.
$ref: /schemas/types.yaml#/definitions/phandle-array
items:
- description: Phandle to I2S0.
- description: Phandle to I2S1.
mic-bias-gpios:
description: GPIO pin that enables the Main Mic bias regulator.
model:
description: The user-visible name of this sound complex.
$ref: /schemas/types.yaml#/definitions/string
required:
- compatible
- audio-amplifier
- audio-codec
- samsung,audio-routing
- i2s-controller
- mic-bias-gpios
- model
additionalProperties: false
examples:
- |
#include <dt-bindings/gpio/gpio.h>
sound {
compatible = "samsung,tm2-audio";
audio-codec = <&wm5110>, <&hdmi>;
i2s-controller = <&i2s0 0>, <&i2s1 0>;
audio-amplifier = <&max98504>;
mic-bias-gpios = <&gpr3 2 GPIO_ACTIVE_HIGH>;
model = "wm5110";
samsung,audio-routing = "HP", "HPOUT1L",
"HP", "HPOUT1R",
"SPK", "SPKOUT",
"SPKOUT", "HPOUT2L",
"SPKOUT", "HPOUT2R",
"RCV", "HPOUT3L",
"RCV", "HPOUT3R";
};

Просмотреть файл

@ -1,31 +0,0 @@
Audio Binding for Snow boards
Required properties:
- compatible : Can be one of the following,
"google,snow-audio-max98090" or
"google,snow-audio-max98091" or
"google,snow-audio-max98095"
- samsung,i2s-controller (deprecated): The phandle of the Samsung I2S controller
- samsung,audio-codec (deprecated): The phandle of the audio codec
Required sub-nodes:
- 'cpu' subnode with a 'sound-dai' property containing the phandle of the I2S
controller
- 'codec' subnode with a 'sound-dai' property containing list of phandles
to the CODEC nodes, first entry must be the phandle of the MAX98090,
MAX98091 or MAX98095 CODEC (exact device type is indicated by the compatible
string) and the second entry must be the phandle of the HDMI IP block node
Optional:
- samsung,model: The name of the sound-card
Example:
sound {
compatible = "google,snow-audio-max98095";
samsung,model = "Snow-I2S-MAX98095";
samsung,i2s-controller = <&i2s0>;
samsung,audio-codec = <&max98095>;
};