From: Kyle Switch <kyle.switch@motor-comm.com>
To: andrew@lunn.ch, olteanv@gmail.com, davem@davemloft.net,
edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
mmyangfl@gmail.com, horms@kernel.org, linux@armlinux.org.uk,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: devicetree@vger.kernel.org, krzk+dt@kernel.org,
conor+dt@kernel.org, david.laight.linux@gmail.com,
ming.xu@motor-comm.com, xiaolin.xu@motor-comm.com,
jianmin.wang@motor-comm.com, wei.zhang@gl-inet.com,
sijia.huang@gl-inet.com
Subject: [PATCH net-next v18 4/6] dt-bindings: net: dsa: add Motorcomm YT9224
Date: Wed, 2 Dec 2026 16:40:20 +0800 [thread overview]
Message-ID: <20261202084022.3716891-5-kyle.switch@motor-comm.com> (raw)
In-Reply-To: <20261202084022.3716891-1-kyle.switch@motor-comm.com>
Add a device tree binding for the Motorcomm YT9224, a member of the
YT922x Ethernet switch family. It has 4 internal GbE PHYs on ports 4-7
and 2 SerDes ports on ports 0 and 8. Any port can be used as the CPU
port.
The YT9224 port layout differs from the YT921x family described by
motorcomm,yt921x.yaml (internal PHYs on ports 0-7, SerDes on 8-9), so
give it its own binding instead of extending the existing one. This
also avoids the dt_binding_check failure caused by yt921x.yaml
declaring compatible as a const for motorcomm,yt9215.
Also add the new binding file to the Motorcomm YT921x switch driver
MAINTAINERS entry so that it is covered by get_maintainer.pl.
Signed-off-by: Kyle Switch <kyle.switch@motor-comm.com>
---
.../bindings/net/dsa/motorcomm,yt9224.yaml | 142 ++++++++++++++++++
MAINTAINERS | 1 +
2 files changed, 143 insertions(+)
create mode 100644 Documentation/devicetree/bindings/net/dsa/motorcomm,yt9224.yaml
diff --git a/Documentation/devicetree/bindings/net/dsa/motorcomm,yt9224.yaml b/Documentation/devicetree/bindings/net/dsa/motorcomm,yt9224.yaml
new file mode 100644
index 000000000000..01b61b47d372
--- /dev/null
+++ b/Documentation/devicetree/bindings/net/dsa/motorcomm,yt9224.yaml
@@ -0,0 +1,142 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/net/dsa/motorcomm,yt9224.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Motorcomm YT9224 Ethernet switch
+
+maintainers:
+ - Kyle Switch <kyle.switch@motor-comm.com>
+
+description: |
+ The Motorcomm YT9224 is a member of the YT922x Ethernet switch family,
+ with 4 internal GbE PHYs (Port 4-7) and 2 SerDes ports (Port 0 and 8).
+
+ Any port can be used as the CPU port.
+
+properties:
+ compatible:
+ const: motorcomm,yt9224
+
+ reg:
+ enum: [0x0, 0x1d]
+
+ mdio:
+ $ref: /schemas/net/mdio.yaml#
+ unevaluatedProperties: false
+ description:
+ Internal MDIO bus for the internal GbE PHYs. PHY 4-7 are used for
+ Port 4-7 respectively.
+
+ mdio-external:
+ $ref: /schemas/net/mdio.yaml#
+ unevaluatedProperties: false
+ description:
+ External MDIO bus to access external components. External PHYs for
+ the SerDes ports (Port 0 and 8) are expected to be connected to the
+ external MDIO bus, but that is not a hard limitation from the chip.
+
+required:
+ - compatible
+ - reg
+
+allOf:
+ - $ref: dsa.yaml#/$defs/ethernet-ports
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/gpio/gpio.h>
+ #include <dt-bindings/leds/common.h>
+
+ mdio {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ switch@1d {
+ compatible = "motorcomm,yt9224";
+ /* default 0x1d, alternate 0x0 */
+ reg = <0x1d>;
+
+ mdio {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ sw_phy4: phy@4 {
+ reg = <0x4>;
+ };
+
+ sw_phy5: phy@5 {
+ reg = <0x5>;
+ };
+
+ sw_phy6: phy@6 {
+ reg = <0x6>;
+ };
+
+ sw_phy7: phy@7 {
+ reg = <0x7>;
+ };
+ };
+
+ ethernet-ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ /* SerDes port 0 */
+ ethernet-port@0 {
+ reg = <0>;
+ label = "wan";
+ phy-mode = "2500base-x";
+
+ fixed-link {
+ speed = <2500>;
+ full-duplex;
+ };
+ };
+
+ /* Internal PHY ports 4-7 */
+ ethernet-port@4 {
+ reg = <4>;
+ label = "lan1";
+ phy-mode = "internal";
+ phy-handle = <&sw_phy4>;
+ };
+
+ ethernet-port@5 {
+ reg = <5>;
+ label = "lan2";
+ phy-mode = "internal";
+ phy-handle = <&sw_phy5>;
+ };
+
+ ethernet-port@6 {
+ reg = <6>;
+ label = "lan3";
+ phy-mode = "internal";
+ phy-handle = <&sw_phy6>;
+ };
+
+ ethernet-port@7 {
+ reg = <7>;
+ label = "lan4";
+ phy-mode = "internal";
+ phy-handle = <&sw_phy7>;
+ };
+
+ /* SerDes port 8, CPU port */
+ ethernet-port@8 {
+ reg = <8>;
+ phy-mode = "usxgmii";
+ ethernet = <ð0>;
+
+ fixed-link {
+ speed = <5000>;
+ full-duplex;
+ };
+ };
+ };
+ };
+ };
diff --git a/MAINTAINERS b/MAINTAINERS
index 9336fa93ce38..864777388be6 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -18937,6 +18937,7 @@ M: David Yang <mmyangfl@gmail.com>
L: netdev@vger.kernel.org
S: Maintained
F: Documentation/devicetree/bindings/net/dsa/motorcomm,yt921x.yaml
+F: Documentation/devicetree/bindings/net/dsa/motorcomm,yt9224.yaml
F: Documentation/networking/devlink/yt921x.rst
F: drivers/net/dsa/motorcomm/
F: net/dsa/tag_yt921x.c
--
2.25.1
next prev parent reply other threads:[~2026-12-02 8:40 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-02 8:40 [PATCH net-next v18 0/6] net: dsa: motorcomm: add support yt922x driver Kyle Switch
2026-12-02 8:40 ` [PATCH net-next v18 1/6] net: dsa: motorcomm: initialize dsa_switch based on chipid Kyle Switch
2026-12-02 8:40 ` [PATCH net-next v18 2/6] net: dsa: motorcomm: use max_ports in series for port bounds checking Kyle Switch
2026-12-02 8:40 ` [PATCH net-next v18 3/6] net: dsa: motorcomm: use GENMASK_U32() for mbus phy_mask Kyle Switch
2026-12-02 8:40 ` Kyle Switch [this message]
2026-12-02 8:40 ` [PATCH net-next v18 5/6] net: dsa: tag_yt922x: add support for Motorcomm YT922x tags Kyle Switch
2026-12-02 8:40 ` [PATCH net-next v18 6/6] net: dsa: motorcomm: Add support for Motorcomm YT922x Kyle Switch
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=20261202084022.3716891-5-kyle.switch@motor-comm.com \
--to=kyle.switch@motor-comm.com \
--cc=andrew@lunn.ch \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=david.laight.linux@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=jianmin.wang@motor-comm.com \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=ming.xu@motor-comm.com \
--cc=mmyangfl@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=olteanv@gmail.com \
--cc=pabeni@redhat.com \
--cc=sijia.huang@gl-inet.com \
--cc=wei.zhang@gl-inet.com \
--cc=xiaolin.xu@motor-comm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®