Commit ba323f6b authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Jakub Kicinski

dt-bindings: nfc: use spi-peripheral-props.yaml

Instead of listing directly properties typical for SPI peripherals,
reference the spi-peripheral-props.yaml schema.  This allows using all
properties typical for SPI-connected devices, even these which device
bindings author did not tried yet.

Remove the spi-* properties which now come via spi-peripheral-props.yaml
schema, except for the cases when device schema adds some constraints
like maximum frequency.

While changing additionalProperties->unevaluatedProperties, put it in
typical place, just before example DTS.
Signed-off-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Acked-by: default avatarRob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220727164130.385411-1-krzysztof.kozlowski@linaro.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 92b54e09
...@@ -58,7 +58,6 @@ properties: ...@@ -58,7 +58,6 @@ properties:
spi-cpha: true spi-cpha: true
spi-cpol: true spi-cpol: true
spi-max-frequency: true
required: required:
- compatible - compatible
...@@ -85,6 +84,7 @@ allOf: ...@@ -85,6 +84,7 @@ allOf:
contains: contains:
const: marvell,nfc-spi const: marvell,nfc-spi
then: then:
$ref: /schemas/spi/spi-peripheral-props.yaml#
properties: properties:
break-control: false break-control: false
flow-control: false flow-control: false
...@@ -108,7 +108,7 @@ allOf: ...@@ -108,7 +108,7 @@ allOf:
spi-max-frequency: false spi-max-frequency: false
reg: false reg: false
additionalProperties: false unevaluatedProperties: false
examples: examples:
- | - |
......
...@@ -30,8 +30,6 @@ properties: ...@@ -30,8 +30,6 @@ properties:
reg: reg:
maxItems: 1 maxItems: 1
spi-max-frequency: true
uicc-present: uicc-present:
type: boolean type: boolean
description: | description: |
...@@ -55,10 +53,11 @@ then: ...@@ -55,10 +53,11 @@ then:
properties: properties:
spi-max-frequency: false spi-max-frequency: false
else: else:
$ref: /schemas/spi/spi-peripheral-props.yaml#
required: required:
- spi-max-frequency - spi-max-frequency
additionalProperties: false unevaluatedProperties: false
examples: examples:
- | - |
......
...@@ -25,8 +25,6 @@ properties: ...@@ -25,8 +25,6 @@ properties:
st95hfvin-supply: st95hfvin-supply:
description: ST95HF transceiver's Vin regulator supply description: ST95HF transceiver's Vin regulator supply
spi-max-frequency: true
required: required:
- compatible - compatible
- enable-gpio - enable-gpio
...@@ -34,7 +32,10 @@ required: ...@@ -34,7 +32,10 @@ required:
- reg - reg
- spi-max-frequency - spi-max-frequency
additionalProperties: false allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples: examples:
- | - |
......
...@@ -40,8 +40,6 @@ properties: ...@@ -40,8 +40,6 @@ properties:
reg: reg:
maxItems: 1 maxItems: 1
spi-max-frequency: true
ti,enable-gpios: ti,enable-gpios:
minItems: 1 minItems: 1
maxItems: 2 maxItems: 2
...@@ -65,7 +63,10 @@ required: ...@@ -65,7 +63,10 @@ required:
- ti,enable-gpios - ti,enable-gpios
- vin-supply - vin-supply
additionalProperties: false allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples: examples:
- | - |
......
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