Commit 057062ad authored by Rob Herring's avatar Rob Herring Committed by Jakub Kicinski

dt-bindings: net: Add missing (unevaluated|additional)Properties on child nodes

In order to ensure only documented properties are present, node schemas
must have unevaluatedProperties or additionalProperties set to false
(typically). Add missing properties/$refs as exposed by this addition.
Signed-off-by: default avatarRob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220825192609.1538463-1-robh@kernel.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 880b0dd9
...@@ -37,6 +37,7 @@ properties: ...@@ -37,6 +37,7 @@ properties:
patternProperties: patternProperties:
"^ethernet-port@[0-9]+$": "^ethernet-port@[0-9]+$":
type: object type: object
unevaluatedProperties: false
description: contains the resources for ethernet port description: contains the resources for ethernet port
allOf: allOf:
- $ref: ethernet-controller.yaml# - $ref: ethernet-controller.yaml#
......
...@@ -74,16 +74,20 @@ properties: ...@@ -74,16 +74,20 @@ properties:
ethernet-ports: ethernet-ports:
type: object type: object
additionalProperties: false
properties:
'#address-cells':
const: 1
'#size-cells':
const: 0
patternProperties: patternProperties:
"^port@[0-9a-f]+$": "^port@[0-9a-f]+$":
type: object $ref: /schemas/net/ethernet-controller.yaml#
unevaluatedProperties: false
properties: properties:
'#address-cells':
const: 1
'#size-cells':
const: 0
reg: reg:
description: Switch port number description: Switch port number
...@@ -93,29 +97,11 @@ properties: ...@@ -93,29 +97,11 @@ properties:
phandle of a Ethernet SerDes PHY. This defines which SerDes phandle of a Ethernet SerDes PHY. This defines which SerDes
instance will handle the Ethernet traffic. instance will handle the Ethernet traffic.
phy-mode:
description:
This specifies the interface used by the Ethernet SerDes towards
the PHY or SFP.
microchip,bandwidth: microchip,bandwidth:
description: Specifies bandwidth in Mbit/s allocated to the port. description: Specifies bandwidth in Mbit/s allocated to the port.
$ref: "/schemas/types.yaml#/definitions/uint32" $ref: "/schemas/types.yaml#/definitions/uint32"
maximum: 25000 maximum: 25000
phy-handle:
description:
phandle of a Ethernet PHY. This is optional and if provided it
points to the cuPHY used by the Ethernet SerDes.
sfp:
description:
phandle of an SFP. This is optional and used when not specifying
a cuPHY. It points to the SFP node that describes the SFP used by
the Ethernet SerDes.
managed: true
microchip,sd-sgpio: microchip,sd-sgpio:
description: description:
Index of the ports Signal Detect SGPIO in the set of 384 SGPIOs Index of the ports Signal Detect SGPIO in the set of 384 SGPIOs
......
...@@ -32,6 +32,7 @@ properties: ...@@ -32,6 +32,7 @@ properties:
ethernet-ports: ethernet-ports:
type: object type: object
additionalProperties: false
description: Ethernet ports to PHY description: Ethernet ports to PHY
properties: properties:
...@@ -44,6 +45,7 @@ properties: ...@@ -44,6 +45,7 @@ properties:
patternProperties: patternProperties:
"^port@[0-1]$": "^port@[0-1]$":
type: object type: object
additionalProperties: false
description: Port to PHY description: Port to PHY
properties: properties:
......
...@@ -77,6 +77,8 @@ properties: ...@@ -77,6 +77,8 @@ properties:
ethernet-ports: ethernet-ports:
type: object type: object
additionalProperties: false
properties: properties:
'#address-cells': '#address-cells':
const: 1 const: 1
...@@ -89,6 +91,7 @@ properties: ...@@ -89,6 +91,7 @@ properties:
description: CPSW external ports description: CPSW external ports
$ref: ethernet-controller.yaml# $ref: ethernet-controller.yaml#
unevaluatedProperties: false
properties: properties:
reg: reg:
...@@ -117,6 +120,7 @@ properties: ...@@ -117,6 +120,7 @@ properties:
cpts: cpts:
type: object type: object
unevaluatedProperties: false
description: description:
The Common Platform Time Sync (CPTS) module The Common Platform Time Sync (CPTS) module
......
...@@ -116,6 +116,7 @@ properties: ...@@ -116,6 +116,7 @@ properties:
description: CPSWxG NUSS external ports description: CPSWxG NUSS external ports
$ref: ethernet-controller.yaml# $ref: ethernet-controller.yaml#
unevaluatedProperties: false
properties: properties:
reg: reg:
......
...@@ -95,6 +95,7 @@ properties: ...@@ -95,6 +95,7 @@ properties:
refclk-mux: refclk-mux:
type: object type: object
additionalProperties: false
description: CPTS reference clock multiplexer clock description: CPTS reference clock multiplexer clock
properties: properties:
'#clock-cells': '#clock-cells':
......
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