dt-bindings: sifive-l2-cache: Fix 'select' matching
Subsystems (3)
Rob Herring
maintainerPATCH 1/1 dt-bindings: sifive-l2-cache: Fix 'select' matching
When the schema fixups are applied to 'select' the result is a single entry is required for a match, but that will never match as there should be 2 entries. Also, a 'select' schema should have the widest possible match, so use 'contains' which matches the compatible string(s) in any position and not just the first position.
--- .../devicetree/bindings/riscv/sifive-l2-cache.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
Documentation/devicetree/bindings/riscv/sifive-l2-cache.yaml +4 -4
@@ -24,10 +24,10 @@ allOf: select: properties: compatible: - items: - - enum: - - sifive,fu540-c000-ccache - - sifive,fu740-c000-ccache + contains: + enum: + - sifive,fu540-c000-ccache + - sifive,fu740-c000-ccache required: - compatible
Signature · 1 line
2.30.2
Palmer Dabbelt
maintainerQuoted 27 lines · On Tue, 17 Aug 2021 10:47:55 PDT (-0700), [email protected] wrote:
When the schema fixups are applied to 'select' the result is a single entry is required for a match, but that will never match as there should be 2 entries. Also, a 'select' schema should have the widest possible match, so use 'contains' which matches the compatible string(s) in any position and not just the first position.
Fixes 993dcfac64eb ("dt-bindings: riscv: sifive-l2-cache: convert bindings to json-schema")Cc Paul Walmsley <[email protected]>Cc Palmer Dabbelt <[email protected]>Cc Albert Ou <[email protected]>Cc Sagar Kadam <[email protected]>Cc Yash Shah <[email protected]>Signed-off-by Rob Herring <[email protected]>--- .../devicetree/bindings/riscv/sifive-l2-cache.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)Documentation/devicetree/bindings/riscv/sifive-l2-cache.yaml +0
-1@@ -24,10 +24,10 @@ allOf: select: properties: compatible: - items:
Documentation/devicetree/bindings/riscv/sifive-l2-cache.yaml allOf: · line 33
Quoted 10 lines
Documentation/devicetree/bindings/riscv/sifive-l2-cache.yaml +4
-3- - enum: - - sifive,fu540-c000-ccache - - sifive,fu740-c000-ccache + contains: + enum: + - sifive,fu540-c000-ccache + - sifive,fu740-c000-ccache required: - compatible
Thanks, this is on fixes.