All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
To: Mark Brown <broonie@kernel.org>, Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
Cc: Linux-ALSA <alsa-devel@alsa-project.org>,
	devicetree@vger.kernel.org,
	Geert Uytterhoeven <geert+renesas@glider.be>
Subject: [PATCH v3 08/11] ASoC: dt-bindings: renesas,rsnd: add missing playback/capture
Date: Mon, 23 Jan 2023 05:25:52 +0000	[thread overview]
Message-ID: <87h6wh7rfj.wl-kuninori.morimoto.gx@renesas.com> (raw)
In-Reply-To: <87sfg17rjq.wl-kuninori.morimoto.gx@renesas.com>

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

renesas,rsnd.yaml is possible to use ports/port/endpoint if it is using
Audio Graph Card/Card2 for sound. The schema is defined under
audio-graph-port.yaml.

rsnd driver needs "playback/capture" property under endpoint, but it is not
defined in audio-graph-port.yaml. This patch adds missing "playback/capture"
properties under endpoint.

Without this patch, we will get below warning

${LINUX}/arch/arm64/boot/dts/renesas/r8a77950-salvator-x.dtb: sound@ec500000: ports:port@0:endpoint: Unevaluated properties are not allowed ('playback', 'capture' were unexpected)
	From schema: ${LINUX}/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 .../bindings/sound/renesas,rsnd.yaml          | 25 ++++++++++++++++---
 1 file changed, 22 insertions(+), 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml
index cb90463c7297..6ea8dd74932c 100644
--- a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml
+++ b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml
@@ -113,15 +113,34 @@ properties:
         - pattern: '^clk_(a|b|c|i)$'
 
   ports:
-    $ref: /schemas/graph.yaml#/properties/ports
+    $ref: audio-graph-port.yaml#/definitions/port-base
+    unevaluatedProperties: false
     patternProperties:
       '^port(@[0-9a-f]+)?$':
-        $ref: audio-graph-port.yaml#
+        $ref: audio-graph-port.yaml#/definitions/port-base
         unevaluatedProperties: false
+        patternProperties:
+          "^endpoint(@[0-9a-f]+)?":
+            $ref: audio-graph-port.yaml#/definitions/endpoint-base
+            properties:
+              playback:
+                $ref: /schemas/types.yaml#/definitions/phandle-array
+              capture:
+                $ref: /schemas/types.yaml#/definitions/phandle-array
+            unevaluatedProperties: false
 
   port:
-    $ref: audio-graph-port.yaml#
+    $ref: audio-graph-port.yaml#/definitions/port-base
     unevaluatedProperties: false
+    patternProperties:
+      "^endpoint(@[0-9a-f]+)?":
+        $ref: audio-graph-port.yaml#/definitions/endpoint-base
+        properties:
+          playback:
+            $ref: /schemas/types.yaml#/definitions/phandle-array
+          capture:
+            $ref: /schemas/types.yaml#/definitions/phandle-array
+        unevaluatedProperties: false
 
   rcar_sound,dvc:
     description: DVC subnode.
-- 
2.25.1


WARNING: multiple messages have this Message-ID (diff)
From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
To: Mark Brown <broonie@kernel.org>, Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
Cc: devicetree@vger.kernel.org,
	Linux-ALSA <alsa-devel@alsa-project.org>,
	Geert Uytterhoeven <geert+renesas@glider.be>
Subject: [PATCH v3 08/11] ASoC: dt-bindings: renesas, rsnd: add missing playback/capture
Date: Mon, 23 Jan 2023 05:25:52 +0000	[thread overview]
Message-ID: <87h6wh7rfj.wl-kuninori.morimoto.gx@renesas.com> (raw)
In-Reply-To: <87sfg17rjq.wl-kuninori.morimoto.gx@renesas.com>

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

renesas,rsnd.yaml is possible to use ports/port/endpoint if it is using
Audio Graph Card/Card2 for sound. The schema is defined under
audio-graph-port.yaml.

rsnd driver needs "playback/capture" property under endpoint, but it is not
defined in audio-graph-port.yaml. This patch adds missing "playback/capture"
properties under endpoint.

Without this patch, we will get below warning

${LINUX}/arch/arm64/boot/dts/renesas/r8a77950-salvator-x.dtb: sound@ec500000: ports:port@0:endpoint: Unevaluated properties are not allowed ('playback', 'capture' were unexpected)
	From schema: ${LINUX}/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 .../bindings/sound/renesas,rsnd.yaml          | 25 ++++++++++++++++---
 1 file changed, 22 insertions(+), 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml
index cb90463c7297..6ea8dd74932c 100644
--- a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml
+++ b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml
@@ -113,15 +113,34 @@ properties:
         - pattern: '^clk_(a|b|c|i)$'
 
   ports:
-    $ref: /schemas/graph.yaml#/properties/ports
+    $ref: audio-graph-port.yaml#/definitions/port-base
+    unevaluatedProperties: false
     patternProperties:
       '^port(@[0-9a-f]+)?$':
-        $ref: audio-graph-port.yaml#
+        $ref: audio-graph-port.yaml#/definitions/port-base
         unevaluatedProperties: false
+        patternProperties:
+          "^endpoint(@[0-9a-f]+)?":
+            $ref: audio-graph-port.yaml#/definitions/endpoint-base
+            properties:
+              playback:
+                $ref: /schemas/types.yaml#/definitions/phandle-array
+              capture:
+                $ref: /schemas/types.yaml#/definitions/phandle-array
+            unevaluatedProperties: false
 
   port:
-    $ref: audio-graph-port.yaml#
+    $ref: audio-graph-port.yaml#/definitions/port-base
     unevaluatedProperties: false
+    patternProperties:
+      "^endpoint(@[0-9a-f]+)?":
+        $ref: audio-graph-port.yaml#/definitions/endpoint-base
+        properties:
+          playback:
+            $ref: /schemas/types.yaml#/definitions/phandle-array
+          capture:
+            $ref: /schemas/types.yaml#/definitions/phandle-array
+        unevaluatedProperties: false
 
   rcar_sound,dvc:
     description: DVC subnode.
-- 
2.25.1


  parent reply	other threads:[~2023-01-23  5:25 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-23  5:23 [PATCH v3 00/11] ASoC: dt-bindings: audio-graph-port related update Kuninori Morimoto
2023-01-23  5:23 ` Kuninori Morimoto
2023-01-23  5:23 ` [PATCH v3 01/11] ASoC: dt-bindings: audio-graph-port: use definitions for port/endpoint Kuninori Morimoto
2023-01-23  5:23   ` Kuninori Morimoto
2023-01-23  5:24 ` [PATCH v3 02/11] ASoC: dt-bindings: audio-graph-port: add definitions/ports Kuninori Morimoto
2023-01-23  5:24   ` Kuninori Morimoto
2023-01-23  5:25 ` [PATCH v3 03/11] ASoC: dt-bindings: audio-graph-port: add missing mclk-fs Kuninori Morimoto
2023-01-23  5:25   ` Kuninori Morimoto
2023-01-23  5:25 ` [PATCH v3 04/11] ASoC: dt-bindings: audio-graph-port: add clocks on endpoint Kuninori Morimoto
2023-01-23  5:25   ` Kuninori Morimoto
2023-01-23  5:25 ` [PATCH v3 05/11] ASoC: dt-bindings: audio-graph-port: remove prefix Kuninori Morimoto
2023-01-23  5:25   ` Kuninori Morimoto
2023-01-23  5:25 ` [PATCH v3 06/11] ASoC: dt-bindings: ti,pcm3168a: Convert to json-schema Kuninori Morimoto
2023-01-23  5:25   ` [PATCH v3 06/11] ASoC: dt-bindings: ti, pcm3168a: " Kuninori Morimoto
2023-01-23  5:25 ` [PATCH v3 07/11] ASoC: dt-bindings: ak4613: enable Of-graph (Audio-Graph-Card) style Kuninori Morimoto
2023-01-23  5:25   ` Kuninori Morimoto
2023-01-23  5:25 ` Kuninori Morimoto [this message]
2023-01-23  5:25   ` [PATCH v3 08/11] ASoC: dt-bindings: renesas, rsnd: add missing playback/capture Kuninori Morimoto
2023-01-23  5:26 ` [PATCH v3 09/11] ASoC: dt-bindings: renesas,rsnd: tidyup rcar_sound,src Kuninori Morimoto
2023-01-23  5:26   ` [PATCH v3 09/11] ASoC: dt-bindings: renesas, rsnd: tidyup rcar_sound, src Kuninori Morimoto
2023-01-23  5:26 ` [PATCH v3 10/11] ASoC: dt-bindings: renesas,rsnd: #sound-dai-cells is not mandatory Kuninori Morimoto
2023-01-23  5:26   ` [PATCH v3 10/11] ASoC: dt-bindings: renesas, rsnd: " Kuninori Morimoto
2023-01-23  5:27 ` [PATCH v3 11/11] ASoC: dt-bindings: simple-card: add missing #address-cells/#size-cells Kuninori Morimoto
2023-01-23  5:27   ` Kuninori Morimoto
2023-01-30 21:00 ` [PATCH v3 00/11] ASoC: dt-bindings: audio-graph-port related update Mark Brown
2023-01-30 21:00   ` Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87h6wh7rfj.wl-kuninori.morimoto.gx@renesas.com \
    --to=kuninori.morimoto.gx@renesas.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=geert+renesas@glider.be \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.