0499220d6d
DT properties which can have multiple entries need to specify what the entries are and define how many entries there can be. In the case of only a single entry, just 'maxItems: 1' is sufficient. Add the missing entry constraints. These were found with a modified meta-schema. Unfortunately, there are a few cases where the size constraints are not defined such as common bindings, so the meta-schema can't be part of the normal checks. Cc: Jens Axboe <axboe@kernel.dk> Cc: Stephen Boyd <sboyd@kernel.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: MyungJoo Ham <myungjoo.ham@samsung.com> Cc: Chanwoo Choi <cw00.choi@samsung.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com> Cc: Jonathan Cameron <jic23@kernel.org> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Marc Zyngier <maz@kernel.org> Cc: Mauro Carvalho Chehab <mchehab@kernel.org> Cc: Chen-Yu Tsai <wens@csie.org> Cc: Ulf Hansson <ulf.hansson@linaro.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jakub Kicinski <kuba@kernel.org> Cc: Sebastian Reichel <sre@kernel.org> Cc: Ohad Ben-Cohen <ohad@wizery.com> Cc: Bjorn Andersson <bjorn.andersson@linaro.org> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Acked-by: Sebastian Reichel <sre@kernel.org> Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> #for-iio Acked-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Suman Anna <s-anna@ti.com> Acked-by: Paul Cercueil <paul@crapouillou.net> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Acked-by: Bartosz Golaszewski <bgolaszewski@baylibre.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20210104230253.2805217-1-robh@kernel.org Signed-off-by: Rob Herring <robh@kernel.org>
113 lines
2.7 KiB
YAML
113 lines
2.7 KiB
YAML
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
|
|
%YAML 1.2
|
|
---
|
|
$id: http://devicetree.org/schemas/sound/samsung,midas-audio.yaml#
|
|
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
|
|
|
title: Samsung Midas audio complex with WM1811 codec
|
|
|
|
maintainers:
|
|
- Sylwester Nawrocki <s.nawrocki@samsung.com>
|
|
|
|
properties:
|
|
compatible:
|
|
const: samsung,midas-audio
|
|
|
|
model:
|
|
$ref: /schemas/types.yaml#/definitions/string
|
|
description: The user-visible name of this sound complex.
|
|
|
|
cpu:
|
|
type: object
|
|
properties:
|
|
sound-dai:
|
|
$ref: /schemas/types.yaml#/definitions/phandle-array
|
|
maxItems: 1
|
|
description: phandle to the I2S controller
|
|
required:
|
|
- sound-dai
|
|
|
|
codec:
|
|
type: object
|
|
properties:
|
|
sound-dai:
|
|
$ref: /schemas/types.yaml#/definitions/phandle-array
|
|
maxItems: 1
|
|
description: phandle to the WM1811 CODEC
|
|
required:
|
|
- sound-dai
|
|
|
|
samsung,audio-routing:
|
|
$ref: /schemas/types.yaml#/definitions/non-unique-string-array
|
|
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 WM1811's pins (as documented in its binding), and the jacks
|
|
on the board: HP, SPK, Main Mic, Sub Mic, Headset Mic.
|
|
|
|
mic-bias-supply:
|
|
description: Supply for the micbias on the Main microphone
|
|
|
|
submic-bias-supply:
|
|
description: Supply for the micbias on the Sub microphone
|
|
|
|
fm-sel-gpios:
|
|
maxItems: 1
|
|
description: GPIO pin for FM selection
|
|
|
|
lineout-sel-gpios:
|
|
maxItems: 1
|
|
description: GPIO pin for line out selection
|
|
|
|
required:
|
|
- compatible
|
|
- model
|
|
- cpu
|
|
- codec
|
|
- samsung,audio-routing
|
|
- mic-bias-supply
|
|
- submic-bias-supply
|
|
|
|
additionalProperties: false
|
|
|
|
examples:
|
|
- |
|
|
#include <dt-bindings/gpio/gpio.h>
|
|
|
|
sound {
|
|
compatible = "samsung,midas-audio";
|
|
model = "Midas";
|
|
|
|
fm-sel-gpios = <&gpaa0 3 GPIO_ACTIVE_HIGH>;
|
|
|
|
mic-bias-supply = <&mic_bias_reg>;
|
|
submic-bias-supply = <&submic_bias_reg>;
|
|
|
|
samsung,audio-routing =
|
|
"HP", "HPOUT1L",
|
|
"HP", "HPOUT1R",
|
|
|
|
"SPK", "SPKOUTLN",
|
|
"SPK", "SPKOUTLP",
|
|
"SPK", "SPKOUTRN",
|
|
"SPK", "SPKOUTRP",
|
|
|
|
"RCV", "HPOUT2N",
|
|
"RCV", "HPOUT2P",
|
|
|
|
"IN1LP", "Main Mic",
|
|
"IN1LN", "Main Mic",
|
|
"IN1RP", "Sub Mic",
|
|
"IN1LP", "Sub Mic";
|
|
|
|
cpu {
|
|
sound-dai = <&i2s0>;
|
|
};
|
|
|
|
codec {
|
|
sound-dai = <&wm1811>;
|
|
};
|
|
|
|
};
|