* [PATCH] media: dt-bindings: mediatek,vcodec-subdev-decoder: Fix child node if/then schemas
@ 2026-10-19 21:24 Rob Herring (Arm)
0 siblings, 0 replies; only message in thread
From: Rob Herring (Arm) @ 2026-10-19 21:24 UTC (permalink / raw)
To: Tiffany Lin, Andrew-CT Chen, Yunfei Dong, Mauro Carvalho Chehab,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Hans Verkuil, Chen-Yu Tsai,
Allen-KH Cheng
Cc: Kyrie Wu, linux-media, devicetree, linux-kernel, linux-arm-kernel,
linux-mediatek
The if/then schemas in mediatek,vcodec-subdev-decoder are all at the
wrong level as they apply to child nodes. The clock-names schemas
applies to the parent node, but the clock-names properties are in the
child nodes. Move the clock-names definitions to the child node
clock-names property. This exposes that the MT8186 clocks are not
documented, so add them as well.
The interrupts if/then schema is never true as the parent compatible
will never match the child compatible. The subschema also belongs in the
child node.
Fixes: 3fbf1eac01b5 ("media: dt-bindings: media: mediatek: vcodec: Adds decoder dt-bindings for lat soc")
Closes: https://sashiko.dev/#/bug/linux-5ab90035-1914-412f-8310-097fb05bda15
Fixes: 355e9472ccb0 ("media: dt-bindings: media: mediatek: vcodec: adapt to the 'clock-names' of different platforms")
Closes: https://sashiko.dev/#/bug/linux-caa6adb1-38de-4889-9517-2beede7c8f96
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
---
.../media/mediatek,vcodec-subdev-decoder.yaml | 77 ++++++++-----------
1 file changed, 31 insertions(+), 46 deletions(-)
diff --git a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
index d1d209cbbd43..6033ecffd707 100644
--- a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
+++ b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
@@ -135,8 +135,26 @@ patternProperties:
maxItems: 5
clock-names:
- minItems: 4
- maxItems: 5
+ oneOf:
+ - description: MT8186 clocks
+ items:
+ - const: vdec-sel
+ - const: vdec-soc-vdec
+ - const: vdec
+ - const: vdec-top
+ - description: MT8192 clocks
+ items:
+ - const: sel
+ - const: soc-vdec
+ - const: soc-lat
+ - const: vdec
+ - const: top
+ - description: MT8195 clocks
+ items:
+ - const: sel
+ - const: vdec
+ - const: lat
+ - const: top
assigned-clocks:
maxItems: 1
@@ -159,6 +177,17 @@ patternProperties:
additionalProperties: false
+ if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - mediatek,mtk-vcodec-core
+ - mediatek,mtk-vcodec-lat
+ then:
+ required:
+ - interrupts
+
required:
- compatible
- reg
@@ -166,50 +195,6 @@ required:
- mediatek,scp
- ranges
-if:
- properties:
- compatible:
- contains:
- enum:
- - mediatek,mtk-vcodec-core
- - mediatek,mtk-vcodec-lat
-
-then:
- required:
- - interrupts
-
-allOf:
- - if:
- properties:
- compatible:
- contains:
- enum:
- - mediatek,mt8192-vcodec-dec
- then:
- properties:
- clock-names:
- items:
- - const: sel
- - const: soc-vdec
- - const: soc-lat
- - const: vdec
- - const: top
-
- - if:
- properties:
- compatible:
- contains:
- enum:
- - mediatek,mt8195-vcodec-dec
- then:
- properties:
- clock-names:
- items:
- - const: sel
- - const: vdec
- - const: lat
- - const: top
-
additionalProperties: false
examples:
--
2.53.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-10-19 21:24 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-19 21:24 [PATCH] media: dt-bindings: mediatek,vcodec-subdev-decoder: Fix child node if/then schemas Rob Herring (Arm)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox