Skip to content

Commit

Permalink
dt-bindings: Another round of adding missing 'additionalProperties/un…
Browse files Browse the repository at this point in the history
…evalutatedProperties'

Another round of wack-a-mole. The json-schema default is additional
unknown properties are allowed, but for DT all properties should be
defined.

Signed-off-by: Rob Herring <robh@kernel.org>
  • Loading branch information
Rob Herring committed Oct 26, 2020
1 parent 6229836 commit f84e2c5
Show file tree
Hide file tree
Showing 17 changed files with 39 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ required:
- reset-gpios
- ports

additionalProperties: false

examples:
- |
#include <dt-bindings/gpio/gpio.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ required:
- "#address-cells"
- "#size-cells"

additionalProperties: false

examples:
- |
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/iio/adc/lltc,ltc2497.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ required:
- reg
- vref-supply

additionalProperties: false

examples:
- |
i2c {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ required:
- compatible
- reg

additionalProperties: false

examples:
- |
i2c0 {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ required:
- ti,sci-dev-id
- ti,interrupt-ranges

unevaluatedProperties: false

examples:
- |
bus {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ required:
- ti,sci-dev-id
- ti,interrupt-ranges

unevaluatedProperties: false

examples:
- |
main_gpio_intr: interrupt-controller0 {
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/leds/backlight/common.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,5 @@ properties:
that a LED can be made so bright that it gets damaged or causes damage
due to restrictions in a specific system, such as mounting conditions.
$ref: /schemas/types.yaml#definitions/uint32

additionalProperties: true
8 changes: 8 additions & 0 deletions Documentation/devicetree/bindings/leds/leds-lp50xx.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,12 @@ properties:
vled-supply:
description: LED supply.

'#address-cells':
const: 1

'#size-cells':
const: 0

patternProperties:
'^multi-led@[0-9a-f]$':
type: object
Expand All @@ -69,6 +75,8 @@ required:
- compatible
- reg

additionalProperties: false

examples:
- |
#include <dt-bindings/gpio/gpio.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ required:
- clocks
- clock-names

unevaluatedProperties: false

examples:
- |
#include <dt-bindings/interrupt-controller/arm-gic.h>
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/mmc/sdhci-am654.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,8 @@ required:
- clock-names
- ti,otap-del-sel-legacy

unevaluatedProperties: false

examples:
- |
#include <dt-bindings/interrupt-controller/irq.h>
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/net/intel,dwmac-plat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ required:
- clocks
- clock-names

unevaluatedProperties: false

examples:
# FIXME: Remove defines and include the correct header file
# once it is available in mainline.
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/net/ti,dp83822.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ properties:
required:
- reg

unevaluatedProperties: false

examples:
- |
mdio0 {
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/phy/ti,omap-usb2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ required:
- clocks
- clock-names

additionalProperties: false

examples:
- |
usb0_phy: phy@4100000 {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ patternProperties:
"^mode-.*$":
$ref: /schemas/types.yaml#/definitions/uint32

additionalProperties: false

examples:
- |
reboot-mode {
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/regulator/mps,mp886x.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ required:
- enable-gpios
- mps,fb-voltage-divider

unevaluatedProperties: false

examples:
- |
#include <dt-bindings/gpio/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/regulator/pfuze100.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ required:
- compatible
- reg

additionalProperties: false

examples:
- |
i2c {
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/sound/realtek,rt1015p.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ properties:
required:
- compatible

additionalProperties: false

examples:
- |
#include <dt-bindings/gpio/gpio.h>
Expand Down

0 comments on commit f84e2c5

Please sign in to comment.