Commit 7cfa9770 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Daniel Lezcano

dt-bindings: thermal: rcar-thermal: Improve schema validation

- Factor out common required properties,
  - "interrupts", "clocks", and "power-domains" are required on R-Mobile
    APE6, too,
  - Invert logic to simplify descriptions.
Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: default avatarNiklas Söderlund <niklas.soderlund@ragnatech.se>
Reviewed-by: default avatarAmit Kucheria <amit.kucheria@linaro.org>
Reviewed-by: default avatarRob Herring <robh@kernel.org>
Signed-off-by: default avatarDaniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20201028153541.1736279-1-geert+renesas@glider.be
parent 236761f1
...@@ -62,25 +62,35 @@ properties: ...@@ -62,25 +62,35 @@ properties:
"#thermal-sensor-cells": "#thermal-sensor-cells":
const: 0 const: 0
if: required:
properties: - compatible
compatible: - reg
contains:
enum: allOf:
- renesas,thermal-r8a73a4 # R-Mobile APE6 - if:
- renesas,thermal-r8a7779 # R-Car H1 not:
then: properties:
required: compatible:
- compatible contains:
- reg enum:
else: - renesas,thermal-r8a73a4 # R-Mobile APE6
required: - renesas,thermal-r8a7779 # R-Car H1
- compatible then:
- reg required:
- interrupts - resets
- clocks - '#thermal-sensor-cells'
- power-domains
- resets - if:
not:
properties:
compatible:
contains:
const: renesas,thermal-r8a7779 # R-Car H1
then:
required:
- interrupts
- clocks
- power-domains
additionalProperties: false additionalProperties: false
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment