From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6AC03C982DA for ; Sun, 20 Sep 2026 17:03:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=crDZPtOjG5RQokcVkAqQ+QtmLBHParowOXEJ3xYYPsw=; b=lH5GDZm1/ol3Ov VK89DEKbjuBbG89qS3lRwJYkiuHukRARb3QQN8xG+yDC34CmbKKxUHrCwNG1t9i613QIXWU9Jtv6+ 6WkJwSiN48y6subd6yXqDUpsGczAtwCDVgI/le7274DhB5EUbqE+BtOTCVCFQuYOX0nKSEREYHB6R aRc71lMWkWMcxgdfFT0lmSHbcDr0yn4G7hCBEtSomCIF/ZojRNRO6qOuZF63yuo1gpLUGwWHkLdIK si54mhWl9GCY1G7rKREUtnbfvt5GGP91g3U0LQrhUs0kAvRCw928Axt4eaytwhP973gs4j0dQefj5 nCh/uEnuU7/4p/41Ngsw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.99.1 #2 (Red Hat Linux)) id 1x8Kx0-000000009q4-0GH2; Sun, 20 Sep 2026 17:03:38 +0000 Received: from mail-pz2-x06.google.com ([2607:f8b0:4864:3b::6]) by bombadil.infradead.org with esmtps (Exim 4.99.1 #2 (Red Hat Linux)) id 1x8Kwv-000000009io-3aPH for linux-phy@lists.infradead.org; Sun, 20 Sep 2026 17:03:36 +0000 Received: by mail-pz2-x06.google.com with SMTP id 41be03b00d2f7-cc4b14f0364so950500a12.1 for ; Sun, 20 Sep 2026 10:03:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1789923813; x=1790528613; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=IeBd/f+KYPaUD3mTxXbAK7RiokjVClr9ke91eN5DQPw=; b=pcxO3pSkj/R8Aa4weJWH9KmDBbsgzOC5RDksZ9I3T1R2DC3bmNBP8SEbBEe1smYJzs acJEE/M6m8jN4AQWnp/mLBPALi1XGY1q4ne5he5dEksF7rFMl31/6+iGqjdCi0CK1fUo yo7s5/P+nj28XQy1WVhXP27O64HWTqkXOhwsC/kGusgrw4ogfytC8EoODyuCMf4CVzUh zSvneETGPIIIHuzxH/DM7Ge1weAc43wTBCPlMMKSu3BQ6KoFe9CGpjsxzKrJeH+Wc/qp fkpacSkpJoevdB94X++/ltGHazpeYp5nbK56YP1hg0TGRr1+o/lQd9VBQM2p3NBeel+l b2Lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1789923813; x=1790528613; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=IeBd/f+KYPaUD3mTxXbAK7RiokjVClr9ke91eN5DQPw=; b=Kn7HAOndl6ySUM55KuDseU0To0rkHi9W5KRpLfc5mcRtE8H5FbN6Oln5rMjw4yw3ve QiilDiBQ2433zuArDpjv+aMU5tiJVm+m0DDQfrNtj9xW+3XSvxCDR9/w8tOgqLRzDY0+ HUAL7NyKkbuqAnO4YvjIuJOEy1/Bj3Q6ogJYcFJh+oePLtIo1n5L9zF6fbEVmU5dAUoL 0Z9jQb0cp5A8t8QN2uYdVnqNKiS5NX/mbeTFTBtf6iDBsw98CTz4sS5IAoct/Bt32tdi MoFyzr0XJ4VE4/hvpABuYuc9+qc5ZlRYuow9l+OkVxHqtvT5dfqGifHO7iHv+IwWikl2 88mg== X-Forwarded-Encrypted: i=1; AKwUvBy1fa4babZNn/ZPdFxks4TtGQ1su0pcVDcJ10Xa6duymshH7hGJBS0ake1kMmJ/m+LF9qYjdbWpXOw=@lists.infradead.org X-Gm-Message-State: AFuF++mJ0mVQXtSxitRBAN7o+DfF6d7poi2lcyQbVAebNfO/7auGfVQ8 OkiAW1a3N+N8Oq4CGPYAVFIf0rgrtKuh0gef5mMnmwrLOGyz24EtUdS/ X-Gm-Gg: AYBFou0t2jAkx1P2M2L/ZOR8NJUHIL5xuVmiK47nEnd1DL1o6ou3wzn2IXVz+a3Iod5 M6tNUHKXWoUxw7y9Jqk9gFmXRolcb58ZPOjJBCSZPdWd6ocsw85qExYzO2svapToKf9f3aBvvfT xBwhj9heqtFHkQrQ5cPizksGVf3fwMO0jQnQWAzI0yV1upnCogGsUNYIjrWMvaC9u07VFz3eLEq GNqYuX6TT3KiJZwYd3pr2lrQZPewsqnTlyCmmV7KVVR3dbjlaTRZvQqgrX0OPHtUNxnJMVdBO2Q iwZdfTfkNYKUjf90AunlAG/vQH3jZl5Xw1MKaGnBfnMJOAjSWCshLN5OyGuHms1hwsmR4KVTTvF T639DG8AHfeVwpadqXN76aftG23u/SpODaRbu0gleLa4KouL7+sc10F17SdZZ5CvrbMVyZHTQgG QHpWorqYOZ6IxO+dYXMshwvALXAexhdqh0RP31Eyfb6moz4GcE0TLEQ7+kjx6mLKps0J5qjw== X-Received: by 2002:a05:6a00:1249:b0:878:3783:8a83 with SMTP id d2e1a72fcca58-87837839389mr5176719b3a.53.1789923812897; Sun, 20 Sep 2026 10:03:32 -0700 (PDT) Received: from server.lan ([168.138.199.194]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-877a9d07425sm2140646b3a.42.2026.09.20.10.03.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 20 Sep 2026 10:03:32 -0700 (PDT) From: Coia Prant To: Andrew Lunn , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Heiko Stuebner , Vinod Koul , Maxime Chevallier , Maxime Coquelin , Alexandre Torgue , Lad Prabhakar , Romain Gantois , Heiner Kallweit , Coia Prant Cc: Neil Armstrong , Russell King , Shawn Lin , David Heidelberg , netdev@vger.kernel.org, linux-rockchip@lists.infradead.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-phy@lists.infradead.org, linux-renesas-soc@vger.kernel.org Subject: [PATCH net-next v9 10/11] arm64: dts: rockchip: rk3568-photonicat: enable SGMII LAN port Date: Mon, 21 Sep 2026 01:01:14 +0800 Message-ID: <20260920170116.3624104-11-coiaprant@gmail.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260920170116.3624104-1-coiaprant@gmail.com> References: <20260920170116.3624104-1-coiaprant@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260920_100333_919220_C0E65BFC X-CRM114-Status: GOOD ( 12.50 ) X-BeenThere: linux-phy@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux Phy Mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-phy" Errors-To: linux-phy-bounces+linux-phy=archiver.kernel.org@lists.infradead.org The Ariaboard Photonicat has a Motorcomm YT8521SC Gigabit Ethernet PHY connected to GMAC0 via XPCS SGMII. Enable the necessary nodes to make this port functional. Add rockchip,sgmii-mac-sel = <0> to the already enabled combphy2, to route the SGMII interface to GMAC0. RK3568 has three Combo PHYs that can carry SGMII; which one is wired to the XPCS is a board-level choice, and Photonicat uses combphy2. Enable the xpcs node and its port 0 sub-node, referencing combphy2 as the SerDes PHY. Add the mdio0 node with the YT8521SC PHY at address 3, including its reset GPIO and LED configuration. Also add LED configuration for the existing RGMII PHY on mdio1 for consistency. Signed-off-by: Coia Prant --- .../boot/dts/rockchip/rk3568-photonicat.dts | 74 ++++++++++++++++++- 1 file changed, 72 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3568-photonicat.dts b/arch/arm64/boot/dts/rockchip/rk3568-photonicat.dts index 58c1052ba8ef3..fdaa4a2a4328b 100644 --- a/arch/arm64/boot/dts/rockchip/rk3568-photonicat.dts +++ b/arch/arm64/boot/dts/rockchip/rk3568-photonicat.dts @@ -3,6 +3,7 @@ /dts-v1/; #include +#include #include #include #include "rk3568.dtsi" @@ -241,6 +242,7 @@ &combphy1 { }; &combphy2 { + rockchip,sgmii-mac-sel = <0>; status = "okay"; }; @@ -260,9 +262,18 @@ &cpu3 { cpu-supply = <&vdd_cpu>; }; -/* Motorcomm YT8521SC LAN port (require SGMII) */ +/* Motorcomm YT8521SC LAN port */ &gmac0 { - status = "disabled"; + assigned-clocks = <&cru SCLK_GMAC0_RX_TX>; + assigned-clock-parents = <&clk_gmac0_xpcs_mii>; + managed = "in-band-status"; + pcs-handle = <&xpcs_mii0>; + phy-handle = <&sgmii_phy>; + phy-mode = "sgmii"; + phy-supply = <&vcc_3v3>; + pinctrl-names = "default"; + pinctrl-0 = <&gmac0_miim>; + status = "okay"; }; /* Motorcomm YT8521SC WAN port */ @@ -341,6 +352,36 @@ &i2s0_8ch { status = "okay"; }; +&mdio0 { + sgmii_phy: ethernet-phy@3 { + compatible = "ethernet-phy-ieee802.3-c22"; + reg = <0x3>; + max-speed = <1000>; + reset-assert-us = <20000>; + reset-deassert-us = <100000>; + reset-gpios = <&gpio3 RK_PC6 GPIO_ACTIVE_LOW>; + + leds { + #address-cells = <1>; + #size-cells = <0>; + + led@1 { + reg = <1>; + color = ; + function = LED_FUNCTION_LAN; + default-state = "keep"; + }; + + led@2 { + reg = <2>; + color = ; + function = LED_FUNCTION_LAN; + default-state = "keep"; + }; + }; + }; +}; + &mdio1 { rgmii_phy: ethernet-phy@3 { compatible = "ethernet-phy-ieee802.3-c22"; @@ -350,6 +391,25 @@ rgmii_phy: ethernet-phy@3 { reset-gpios = <&gpio4 RK_PC0 GPIO_ACTIVE_LOW>; rx-internal-delay-ps = <1500>; tx-internal-delay-ps = <1500>; + + leds { + #address-cells = <1>; + #size-cells = <0>; + + led@1 { + reg = <1>; + color = ; + function = LED_FUNCTION_WAN; + default-state = "keep"; + }; + + led@2 { + reg = <2>; + color = ; + function = LED_FUNCTION_WAN; + default-state = "keep"; + }; + }; }; }; @@ -586,3 +646,13 @@ &xin32k { pinctrl-names = "default"; pinctrl-0 = <&clk32k_out1>; }; + +&xpcs { + phys = <&combphy2 PHY_TYPE_SGMII>; + phy-names = "serdes"; + status = "okay"; +}; + +&xpcs_mii0 { + status = "okay"; +}; -- 2.47.3 -- linux-phy mailing list linux-phy@lists.infradead.org https://lists.infradead.org/mailman/listinfo/linux-phy