All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ansuel Smith <ansuelsmth@gmail.com>
To: Andrew Lunn <andrew@lunn.ch>,
	Vivien Didelot <vivien.didelot@gmail.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Vladimir Oltean <olteanv@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	Rob Herring <robh+dt@kernel.org>, John Crispin <john@phrozen.org>,
	netdev@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Cc: Ansuel Smith <ansuelsmth@gmail.com>
Subject: [PATCH 2/2] dt-bindings: net: dsa: qca8k: improve port definition documentation
Date: Fri, 12 Nov 2021 17:57:52 +0100	[thread overview]
Message-ID: <20211112165752.1704-2-ansuelsmth@gmail.com> (raw)
In-Reply-To: <20211112165752.1704-1-ansuelsmth@gmail.com>

Clean and improve port definition for qca8k documentation by referencing
the dsa generic port definition and adding the additional specific port
definition.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
---
 .../devicetree/bindings/net/dsa/qca8k.yaml    | 82 ++++++-------------
 1 file changed, 23 insertions(+), 59 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
index 48de0ace265d..9eb24cdf6cd4 100644
--- a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
@@ -99,65 +99,29 @@ patternProperties:
         type: object
         description: Ethernet switch ports
 
-        properties:
-          reg:
-            description: Port number
-
-          label:
-            description:
-              Describes the label associated with this port, which will become
-              the netdev name
-            $ref: /schemas/types.yaml#/definitions/string
-
-          link:
-            description:
-              Should be a list of phandles to other switch's DSA port. This
-              port is used as the outgoing port towards the phandle ports. The
-              full routing information must be given, not just the one hop
-              routes to neighbouring switches
-            $ref: /schemas/types.yaml#/definitions/phandle-array
-
-          ethernet:
-            description:
-              Should be a phandle to a valid Ethernet device node.  This host
-              device is what the switch port is connected to
-            $ref: /schemas/types.yaml#/definitions/phandle
-
-          phy-handle: true
-
-          phy-mode: true
-
-          fixed-link: true
-
-          mac-address: true
-
-          sfp: true
-
-          qca,sgmii-rxclk-falling-edge:
-            $ref: /schemas/types.yaml#/definitions/flag
-            description:
-              Set the receive clock phase to falling edge. Mostly commonly used on
-              the QCA8327 with CPU port 0 set to SGMII.
-
-          qca,sgmii-txclk-falling-edge:
-            $ref: /schemas/types.yaml#/definitions/flag
-            description:
-              Set the transmit clock phase to falling edge.
-
-          qca,sgmii-enable-pll:
-            $ref: /schemas/types.yaml#/definitions/flag
-            description:
-              For SGMII CPU port, explicitly enable PLL, TX and RX chain along with
-              Signal Detection. On the QCA8327 this should not be enabled, otherwise
-              the SGMII port will not initialize. When used on the QCA8337, revision 3
-              or greater, a warning will be displayed. When the CPU port is set to
-              SGMII on the QCA8337, it is advised to set this unless a communication
-              issue is observed.
-
-        required:
-          - reg
-
-        additionalProperties: false
+        allOf:
+          - $ref: dsa-port.yaml#
+          - properties:
+              qca,sgmii-rxclk-falling-edge:
+                $ref: /schemas/types.yaml#/definitions/flag
+                description:
+                  Set the receive clock phase to falling edge. Mostly commonly used on
+                  the QCA8327 with CPU port 0 set to SGMII.
+
+              qca,sgmii-txclk-falling-edge:
+                $ref: /schemas/types.yaml#/definitions/flag
+                description:
+                  Set the transmit clock phase to falling edge.
+
+              qca,sgmii-enable-pll:
+                $ref: /schemas/types.yaml#/definitions/flag
+                description:
+                  For SGMII CPU port, explicitly enable PLL, TX and RX chain along with
+                  Signal Detection. On the QCA8327 this should not be enabled, otherwise
+                  the SGMII port will not initialize. When used on the QCA8337, revision 3
+                  or greater, a warning will be displayed. When the CPU port is set to
+                  SGMII on the QCA8337, it is advised to set this unless a communication
+                  issue is observed.
 
 oneOf:
   - required:
-- 
2.32.0


  reply	other threads:[~2021-11-12 16:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-12 16:57 [PATCH 1/2] dt-bindings: net: dsa: split generic port definition from dsa.yaml Ansuel Smith
2021-11-12 16:57 ` Ansuel Smith [this message]
2021-11-29 21:20   ` [PATCH 2/2] dt-bindings: net: dsa: qca8k: improve port definition documentation Rob Herring
2021-11-29 21:18 ` [PATCH 1/2] dt-bindings: net: dsa: split generic port definition from dsa.yaml Rob Herring
2021-11-29 22:24   ` Ansuel Smith

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211112165752.1704-2-ansuelsmth@gmail.com \
    --to=ansuelsmth@gmail.com \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=f.fainelli@gmail.com \
    --cc=john@phrozen.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=robh+dt@kernel.org \
    --cc=vivien.didelot@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.