From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=170.10.71.231 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796487843; b=clWJg45wb8us1YWo9B62Zy6ppvQz0lDQtxfiDEJ3HovLjslpXuEwNlB9xK+OlQsucGu6 mUGAlyl/iIzrKKp2Cqmjcd97D9SvKFQFxXl/KlRIr8/0/KCHsycMORuf8TivLw9PXXbp9 pE20qGPHCXQppF5B5ESWhscmfxCbCVteyDllLMeN+ROH4wV6ANDV8Ema1CkFv3Vy95Pff dvJiAxNgt6WfVuY8kBfRjR+gPa9i5ZxImCW7rA0zVapDABDfb/I6yZdcGHqJlbmIKjBqT OMcJcs7RjhslDvyltwOF6CYn2Z4DwpJ0OKV6w8wdwTOwy2rqaJsaxH8U03iC3vMZKpQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796487843; h=DMARC-Filter:DKIM-Signature:Received:Received:From:To:Cc:Subject: In-Reply-To:References:Date:Message-ID:MIME-Version:Content-Type: X-Report-Abuse:Feedback-ID:X-smtpcorp-track; bh=hAC5KKN7y6c8Us1QYAQ70UJwpT7iMPraO+zmran/sY8=; b=DkPNuQv5M4kyy3CbG2pezku4aFrlQUaz5X1Aq7iVWkAzSuzuUtWjwJcSmXJDe0oa7cEQ lDGeNqk8R+ntHQ6UnuAIyHuVzV35kafbgaE/ZJ5liqOUC4/U+3ZLVRhroVWYN7m1yPqqy lM7unyPfE6yih/xfYS+O/wdwWKH3QbYtYUIHrS+BeGDNIn8ip2xGg2+wAPtxu1G9yJhos +2E7Xb1N5lousime9sXaaN5EQYPwp5PQjwp+EGpc1HVLqoOUMi384veEhLkvHoUAsSqIL gsW0Nhu+PKqriv47CkOI5t6XC7DdeyKdH8I/Sdza+bGmi6b/qrd3Bu2Ziwh55J7/ihQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=dilluti0n.com; spf=pass smtp.mailfrom=em840244.dilluti0n.com; dkim=pass header.d=dilluti0n.com header.i=@dilluti0n.com header.a=rsa-sha256 header.s=s840244 header.b=arVqO+4D; arc=none smtp.remote-ip=170.10.71.231 Received: from a5i231.smtp2go.com (a5i231.smtp2go.com [170.10.71.231]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C397F606A31F for ; Sat, 5 Dec 2026 16:24:02 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org C397F606A31F Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=dilluti0n.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=em840244.dilluti0n.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=dilluti0n.com header.i=@dilluti0n.com header.a=rsa-sha256 header.s=s840244 header.b=arVqO+4D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dilluti0n.com; i=@dilluti0n.com; q=dns/txt; s=s840244; t=1796487841; h=from : subject : to : message-id : date : list-unsubscribe : list-unsubscribe-post; bh=hAC5KKN7y6c8Us1QYAQ70UJwpT7iMPraO+zmran/sY8=; b=arVqO+4DO8LKWrsJs4uheqWDdymxd4NXmTnrkfEVvHcQ+IwkG/a2iYbvRf3N0pi+T6vr7 614ypA2Bj/TB6z3SrA0bd4dl9838/T8se0hd/kZ/Rh8aR9hcNNzg+QHlAtt39A8UXijL6OI OISfFZlVaCEi9nu+mM6Ev1nCPfU0el9Vd9FmpaC9yWlstoMkUZrybCRb+bbjI6v/S4sLQ0G evpTXQzVwMp0io1MGb6g+D9b0pDccM0Z4f/hwdW8hzs1BhCmssYr5wsoY415kyW7M31zndK 8vqCZCHTMsZDftqbiSpL+hdXvvuMzQZeaZrc0JV2mQgu4nKt60uAJX0N3OhQ== Received: from [10.40.244.132] (helo=dilluti0n.com) by smtpcorp.com with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256:X25519) (Exim 4.100.1) (envelope-from ) id 1xZsYG-FnQW0hPkgMw-FN5F; Sat, 05 Dec 2026 16:23:57 +0000 Received: from localhost ( [10.42.0.2]) by dilluti0n.com (OpenSMTPD) with ESMTP id d0763f4f; Sat, 5 Dec 2026 16:23:43 +0000 (UTC) From: Hee-Suk Kim To: Maxime Chevallier , netdev@vger.kernel.org Cc: Andrew Lunn , Heiner Kallweit , Russell King , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Willem de Bruijn , Simon Horman , Daniel Golle , nic_swsd@realtek.com, Andrew Lunn , linux-kernel@vger.kernel.org, javen , =?utf-8?B?QmrDtnJuIFTDtnBlbA==?= Subject: Re: [PATCH net-next v2 1/4] net: ethtool: add 500baseT2 link mode In-Reply-To: <31418f01-3ec4-413e-8842-2717e04fefe7@bootlin.com> References: <20261205-giga-lite-v2-0-5b84410edb9f@dilluti0n.com> <20261205-giga-lite-v2-1-5b84410edb9f@dilluti0n.com> <31418f01-3ec4-413e-8842-2717e04fefe7@bootlin.com> Date: Sun, 06 Dec 2026 01:23:42 +0900 Message-ID: <87qzfvzofl.fsf@dilluti0n.com> X-Mailing-List: netdev@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain X-Report-Abuse: Please forward a copy of this message, including all headers, to Feedback-ID: 840244m:840244atORciv:840244sa_QQ-eHhd X-smtpcorp-track: 5sZaOaxqeRdj.MOtrty7fmDwq.kHORhQ8IEy- Maxime Chevallier writes: > Hi, > > On 12/5/26 05:00, Hee-Suk Kim wrote: >> Add ETHTOOL_LINK_MODE_500baseT2_Full_BIT and SPEED_500 for 500 Mbps >> over two pairs, together with the matching phylib link capability. >> >> Signed-off-by: Hee-Suk Kim > > [...] > >> @@ -295,6 +298,10 @@ unsigned long phy_caps_from_interface(phy_interface_t interface) >> { >> unsigned long link_caps = 0; >> >> + /* The only PHYs known to support 500baseT2 are attached over GMII */ >> + if (interface == PHY_INTERFACE_MODE_GMII) >> + link_caps |= BIT(LINK_CAPA_500FD); >> + > > This whole patch seems good to me, with all the phy_caps and all, the only question > I have is about the xMII mode used. Is it really GMII, or some tweaked version of it ? > > I guess the MAC to PHY mode on these setups isn't pure GMII, but likely a modified > of it, with a different clock rate ? at 1G the GMII is clocked at 125MHz, do you know > what's going on at 500M ? > I don't think it's really GMII. On these Realtek chips the PHY and MAC are integrated on a single chip, and r8169 just labels older chips as GMII/MII in rtl_init_phylink(): if (tp->mac_version < RTL_GIGA_MAC_VER_61) phy_mode = tp->supports_gmii ? PHY_INTERFACE_MODE_GMII : PHY_INTERFACE_MODE_MII; else phy_mode = PHY_INTERFACE_MODE_INTERNAL; That comment meant that the Realtek chips needing 500baseT2 are labeled GMII (all below VER_61 in this series), not that the xMII is really GMII. Giga Lite is the only known (and Realtek proprietary) way to do 500 Mbps over two pairs, so they are the only users of 500baseT2. > Does a PHY that supports 500BaseT2 also support other 2-pair modes, like 100BaseTX ? > IOW, can the xMII used here adapt for multiple speeds like GMII ? > > We may need a dedicated phy_interface_t value for the xMII here is what I mean :) Yes, it's a regular 10/100/1000 PHY with Giga Lite added on top. Since the MAC and PHY are integrated, I can't tell how the chip carries 500 Mbps between them. It seems to handle that internally. In the v1 tests [1], the link ran at ~94 or ~470 Mbps depending only on the Giga Lite enable bit (page 0xa42, reg 0x14, bit 9), regardless of the speed the kernel reported. A dedicated value would make sense if we knew what the bus is, but I have no information beyond the above, not even whether a standalone Realtek PHY with Giga Lite (if any) would use the same protocol as the integrated chips. The current patch works fine, since Realtek is the only user as mentioned above. So, unless you'd prefer a dedicated value, I'm thinking of rewording the comment to something like: /* Realtek's Giga Lite is the only supported 500baseT2 hardware. Its * PHY is integrated with the MAC and labeled as GMII by r8169. */ if (interface == PHY_INTERFACE_MODE_GMII) link_caps |= BIT(LINK_CAPA_500FD); A third option would be to switch the Giga Lite capable chips in r8169 to PHY_INTERFACE_MODE_INTERNAL, but I couldn't find what the GMII/MII labeling there is for, so I'm hesitant to drop it. Heiner or Javen may know more. [1] https://lore.kernel.org/r/20261010135356.85454-1-hskim@dilluti0n.com Thanks, hsk > > Maxime