lkml.org 
[lkml]   [2021]   [Dec]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH net-next] dt-bindings: net: lan966x: Add additional properties for lan966x
Date
This patch updates the dt-bindings for lan966x switch.
It adds the properties 'additionalProperties' and
'unevaluatedProperties' for ethernet-ports and ports nodes. In this way
it is not possible to add more properties to these nodes.

Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
---
.../bindings/net/microchip,lan966x-switch.yaml | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/microchip,lan966x-switch.yaml b/Documentation/devicetree/bindings/net/microchip,lan966x-switch.yaml
index d54dc183a033..5bee665d5fcf 100644
--- a/Documentation/devicetree/bindings/net/microchip,lan966x-switch.yaml
+++ b/Documentation/devicetree/bindings/net/microchip,lan966x-switch.yaml
@@ -56,12 +56,21 @@ properties:

ethernet-ports:
type: object
+
+ properties:
+ '#address-cells':
+ const: 1
+ '#size-cells':
+ const: 0
+
+ additionalProperties: false
+
patternProperties:
"^port@[0-9a-f]+$":
type: object

- allOf:
- - $ref: "http://devicetree.org/schemas/net/ethernet-controller.yaml#"
+ $ref: "/schemas/net/ethernet-controller.yaml#"
+ unevaluatedProperties: false

properties:
'#address-cells':
--
2.33.0
\
 
 \ /
  Last update: 2021-12-02 12:05    [W:2.233 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site