dt-bindings: net: Add missing (unevaluated|additional)Properties on child nodes
Subsystems (6)
Rob Herring
maintainerPATCH v2 1/1 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.
---
v2:
- Add microchip,sparx5-switch.yaml and sunplus,sp7021-emac.yaml
--- .../bindings/net/cortina,gemini-ethernet.yaml | 1 + .../bindings/net/microchip,sparx5-switch.yaml | 34 ++++++------------- .../bindings/net/sunplus,sp7021-emac.yaml | 2 ++ .../bindings/net/ti,cpsw-switch.yaml | 4 +++ .../bindings/net/ti,k3-am654-cpsw-nuss.yaml | 1 + .../bindings/net/ti,k3-am654-cpts.yaml | 1 + 6 files changed, 19 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/net/cortina,gemini-ethernet.yaml +1 -0
@@ -37,6 +37,7 @@ properties: patternProperties: "^ethernet-port@[0-9]+$": type: object + unevaluatedProperties: false description: contains the resources for ethernet port allOf: - $ref: ethernet-controller.yaml#
Documentation/devicetree/bindings/net/microchip,sparx5-switch.yaml +10 -24
@@ -74,16 +74,20 @@ properties: ethernet-ports: type: object + additionalProperties: false + + properties: + '#address-cells': + const: 1 + '#size-cells': + const: 0 + patternProperties: "^port@[0-9a-f]+$": - type: object + $ref: /schemas/net/ethernet-controller.yaml# + unevaluatedProperties: false properties: - '#address-cells': - const: 1 - '#size-cells': - const: 0 - reg: description: Switch port number
@@ -93,29 +97,11 @@ properties: phandle of a Ethernet SerDes PHY. This defines which SerDes 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: description: Specifies bandwidth in Mbit/s allocated to the port. $ref: "/schemas/types.yaml#/definitions/uint32" 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: description: Index of the ports Signal Detect SGPIO in the set of 384 SGPIOs
Documentation/devicetree/bindings/net/sunplus,sp7021-emac.yaml +2 -0
@@ -32,6 +32,7 @@ properties: ethernet-ports: type: object + additionalProperties: false description: Ethernet ports to PHY properties:
@@ -44,6 +45,7 @@ properties: patternProperties: "^port@[0-1]$": type: object + additionalProperties: false description: Port to PHY properties:
Documentation/devicetree/bindings/net/ti,cpsw-switch.yaml +4 -0
@@ -77,6 +77,8 @@ properties: ethernet-ports: type: object + additionalProperties: false + properties: '#address-cells': const: 1
@@ -89,6 +91,7 @@ properties: description: CPSW external ports $ref: ethernet-controller.yaml# + unevaluatedProperties: false properties: reg:
@@ -117,6 +120,7 @@ properties: cpts: type: object + unevaluatedProperties: false description: The Common Platform Time Sync (CPTS) module
Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml +1 -0
@@ -115,6 +115,7 @@ properties: description: CPSWxG NUSS external ports $ref: ethernet-controller.yaml# + unevaluatedProperties: false properties: reg:
Documentation/devicetree/bindings/net/ti,k3-am654-cpts.yaml +1 -0
@@ -95,6 +95,7 @@ properties: refclk-mux: type: object + additionalProperties: false description: CPTS reference clock multiplexer clock properties: '#clock-cells':
Signature · 1 line
2.34.1
This patch was applied to netdev/net-next.git (master) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net-next.git (master) by Jakub Kicinski <[email protected]>:
Quoted 10 lines · On Thu, 25 Aug 2022 14:26:07 -0500 you wrote:
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 Rob Herring <[email protected]>---
v2:
- Add microchip,sparx5-switch.yaml and sunplus,sp7021-emac.yaml[...]
Here is the summary with links:
- [v2] dt-bindings: net: Add missing (unevaluated|additional)Properties on child nodes
https://git.kernel.org/netdev/net-next/c/057062adb49b
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html