[PATCH 1/1] ASoC: dt-bindings: audio-graph-port: enable both flag/phandle for bitclock/frame-master

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Kuninori Morimoto <kuninori.morimoto.gx@xxxxxxxxxxx>

snd_soc_daifmt_parse_clock_provider_raw() is handling both
bitclock/frame-master, and is supporting both flag/phandle.
Current DT is assuming it is flag style.
This patch allows both case.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@xxxxxxxxxxx>
---
 .../bindings/sound/audio-graph-port.yaml      | 23 +++++++++++++++++--
 1 file changed, 21 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml
index 43e7f86e3b23..6c3645a0d36b 100644
--- a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml
+++ b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml
@@ -14,6 +14,24 @@ select: false
 allOf:
   - $ref: /schemas/graph.yaml#/$defs/port-base
 
+definitions:
+  flag_or_phandle:
+    oneOf:
+      - type: boolean
+        const: true
+      - type: 'null'
+      - type: array
+        minItems: 1
+        maxItems: 1
+        items:
+          type: array
+          items:
+            phandle: true
+            type: integer
+            maximum: 0xffffffff
+          minItems: 1
+          maxItems: 1
+
 properties:
   prefix:
     description: "device name prefix"
@@ -42,10 +60,11 @@ patternProperties:
         $ref: /schemas/types.yaml#/definitions/flag
       frame-master:
         description: Indicates dai-link frame master.
-        $ref: /schemas/types.yaml#/definitions/phandle
+        $ref: "#/definitions/flag_or_phandle"
       bitclock-master:
         description: Indicates dai-link bit clock master
-        $ref: /schemas/types.yaml#/definitions/phandle
+        $ref: "#/definitions/flag_or_phandle"
+
       dai-format:
         description: audio format.
         items:
-- 
2.25.1




[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux