diff options
author | Samuel Holland <samuel@sholland.org> | 2021-03-22 05:47:03 +0100 |
---|---|---|
committer | Maxime Ripard <maxime@cerno.tech> | 2021-05-11 10:17:50 +0200 |
commit | 5bd15031337f544891185361899db40961d9044e (patch) | |
tree | b5300381ea3078f9e5796496edf55cbe84a5d973 /Documentation/devicetree/bindings/timer | |
parent | ARM: dts: sun8i: r40: add devicetree for Forlinx FETA40i-C & OKA40i-C (diff) | |
download | linux-5bd15031337f544891185361899db40961d9044e.tar.xz linux-5bd15031337f544891185361899db40961d9044e.zip |
dt-bindings: timer: Simplify conditional expressions
The sun4i timer IP block has a variable number of interrupts based on
the compatible. Use enums to combine the two sections for the existing
3-interrupt variants, and to simplify adding new compatible strings.
Acked-by: Maxime Ripard <maxime@cerno.tech>
Signed-off-by: Samuel Holland <samuel@sholland.org>
Reviewed-by: Rob Herring <robh@kernel.org>
Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20210322044707.19479-2-samuel@sholland.org
Diffstat (limited to 'Documentation/devicetree/bindings/timer')
-rw-r--r-- | Documentation/devicetree/bindings/timer/allwinner,sun4i-a10-timer.yaml | 25 |
1 files changed, 7 insertions, 18 deletions
diff --git a/Documentation/devicetree/bindings/timer/allwinner,sun4i-a10-timer.yaml b/Documentation/devicetree/bindings/timer/allwinner,sun4i-a10-timer.yaml index 1c7cf32e7ac2..3462598e609d 100644 --- a/Documentation/devicetree/bindings/timer/allwinner,sun4i-a10-timer.yaml +++ b/Documentation/devicetree/bindings/timer/allwinner,sun4i-a10-timer.yaml @@ -34,8 +34,8 @@ allOf: - if: properties: compatible: - items: - const: allwinner,sun4i-a10-timer + enum: + - allwinner,sun4i-a10-timer then: properties: @@ -46,8 +46,8 @@ allOf: - if: properties: compatible: - items: - const: allwinner,sun8i-a23-timer + enum: + - allwinner,sun8i-a23-timer then: properties: @@ -58,20 +58,9 @@ allOf: - if: properties: compatible: - items: - const: allwinner,sun8i-v3s-timer - - then: - properties: - interrupts: - minItems: 3 - maxItems: 3 - - - if: - properties: - compatible: - items: - const: allwinner,suniv-f1c100s-timer + enum: + - allwinner,sun8i-v3s-timer + - allwinner,suniv-f1c100s-timer then: properties: |