Skip to content

Commit 9756712

Browse files
committed
dt-bindings: More use 'enum' instead of 'oneOf' plus 'const' entries
'enum' is equivalent to 'oneOf' with a list of 'const' entries, but 'enum' is more concise and yields better error messages. Fix a couple more cases which have appeared. Cc: Rob Clark <robdclark@gmail.com> Cc: Sean Paul <sean@poorly.run> Cc: Mark Brown <broonie@kernel.org> Cc: Wim Van Sebroeck <wim@linux-watchdog.org> Cc: Guenter Roeck <linux@roeck-us.net> Cc: Jonathan Marek <jonathan@marek.ca> Cc: Aswath Govindraju <a-govindraju@ti.com> Cc: Marc Zyngier <maz@kernel.org> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: dri-devel@lists.freedesktop.org Cc: freedreno@lists.freedesktop.org Cc: linux-spi@vger.kernel.org Cc: linux-watchdog@vger.kernel.org Signed-off-by: Rob Herring <robh@kernel.org> Acked-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20210910165153.2843871-1-robh@kernel.org
1 parent 4a48b66 commit 9756712

3 files changed

Lines changed: 14 additions & 14 deletions

File tree

Documentation/devicetree/bindings/display/msm/dsi-phy-7nm.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ allOf:
1414

1515
properties:
1616
compatible:
17-
oneOf:
18-
- const: qcom,dsi-phy-7nm
19-
- const: qcom,dsi-phy-7nm-8150
20-
- const: qcom,sc7280-dsi-phy-7nm
17+
enum:
18+
- qcom,dsi-phy-7nm
19+
- qcom,dsi-phy-7nm-8150
20+
- qcom,sc7280-dsi-phy-7nm
2121

2222
reg:
2323
items:

Documentation/devicetree/bindings/spi/omap-spi.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,9 @@ unevaluatedProperties: false
8484
if:
8585
properties:
8686
compatible:
87-
oneOf:
88-
- const: ti,omap2-mcspi
89-
- const: ti,omap4-mcspi
87+
enum:
88+
- ti,omap2-mcspi
89+
- ti,omap4-mcspi
9090

9191
then:
9292
properties:

Documentation/devicetree/bindings/watchdog/maxim,max63xx.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ maintainers:
1515

1616
properties:
1717
compatible:
18-
oneOf:
19-
- const: maxim,max6369
20-
- const: maxim,max6370
21-
- const: maxim,max6371
22-
- const: maxim,max6372
23-
- const: maxim,max6373
24-
- const: maxim,max6374
18+
enum:
19+
- maxim,max6369
20+
- maxim,max6370
21+
- maxim,max6371
22+
- maxim,max6372
23+
- maxim,max6373
24+
- maxim,max6374
2525

2626
reg:
2727
description: This is a 1-byte memory-mapped address

0 commit comments

Comments
 (0)