mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH net-next v1 0/2] Add support for RTL8261c
@ 2026-05-28  7:52 javen
  2026-05-28  7:52 ` [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261 javen
  2026-05-28  7:52 ` [PATCH net-next v1 2/2] net: phy: realtek: load firmware for RTL8261C javen
  0 siblings, 2 replies; 16+ messages in thread
From: javen @ 2026-05-28  7:52 UTC (permalink / raw)
  To: andrew, hkallweit1, linux, davem, edumazet, kuba, pabeni, freddy_gu
  Cc: netdev, linux-kernel, daniel, vladimir.oltean, Javen Xu

From: Javen Xu <javen_xu@realsil.com.cn>

Add support for RTL8261c and add support for loading firmware.

Javen Xu (2):
  net: phy: realtek: add support for RTL8261
  net: phy: realtek: load firmware for RTL8261C

 drivers/net/phy/realtek/realtek_main.c | 536 +++++++++++++++++++++++++
 1 file changed, 536 insertions(+)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261
@ 2026-06-03  2:32 Javen
  2026-06-03  2:57 ` Andrew Lunn
  0 siblings, 1 reply; 16+ messages in thread
From: Javen @ 2026-06-03  2:32 UTC (permalink / raw)
  To: nb
  Cc: andrew, daniel, davem, edumazet, 顾晓军,
	hkallweit1, Javen, kuba, linux-kernel, linux, netdev, pabeni,
	vladimir.oltean

Hi, Nicolai

>> +/* Concatenated 4-bit speed code values (SPD_H << 2 | SPD_L) */
>> +#define RTL8261X_SPEED_CODE_500M	0x3	/* H=0, L=3 */
>> +#define RTL8261X_SPEED_CODE_1000M	0x7	/* H=1, L=3 */
>> +#define RTL8261X_SPEED_CODE_2500M	0x8	/* H=2, L=0 */
>> +#define RTL8261X_SPEED_CODE_5000M	0x9	/* H=2, L=1 */
>> +#define RTL8261X_SPEED_500		500
>
> 500 MBit/s isnt a standard rate which also isnt represented in ethtool.
> Is this just for documentation or intended to be used? If yes, how?

Giga-lite (500M) is a Realtek-proprietary speed: when two Realtek PHYs supporting Giga-lite are connected and the higher speed is disabled or unstable, auto-negotiation may fall back to 500M. Since ethtool has no SPEED_500 definition, the driver reports SPEED_UNKNOWN for this case.  So we add this.

>> +
>> +static int rtl8261x_get_features(struct phy_device *phydev)
>> +{
>> +	int ret;
>> +
>> +	ret = genphy_c45_pma_read_abilities(phydev);
>> +	if (ret)
>> +		return ret;
>> +	/*
>> +	 * Supplement Multi-Gig speeds that may not be automatically detected
>> +	 * RTL8261X supports 2.5G/5G in addition to standard 10G
>> +	 */
>> +	linkmode_set_bit(ETHTOOL_LINK_MODE_2500baseT_Full_BIT,
>> +			 phydev->supported);
>> +	linkmode_set_bit(ETHTOOL_LINK_MODE_5000baseT_Full_BIT,
>> +			 phydev->supported);
>
>Feature bits for 2.5 and 5 GBit/s are set unconditionally - even for the 
>generic variant.
>Do all variants have these capabilities? If not better add check for at 
l>east the generic one.

Thank you for pointing this out.
We can confirm that RTL8261C and RTL8261D support 2.5G and 5G.

For this patch only support for RTL8261C, I will remove the code associated with RTL8261D. And other suggestions are all accepted.
Thanks for your time.

BRs,
Javen

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2026-06-04  7:30 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-05-28  7:52 [PATCH net-next v1 0/2] Add support for RTL8261c javen
2026-05-28  7:52 ` [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261 javen
2026-05-28  9:37   ` Nicolai Buchwitz
2026-05-29  0:51     ` Andrew Lunn
2026-06-03  2:35       ` Javen
2026-05-28 12:39   ` Andrew Lunn
2026-05-28 12:42   ` Andrew Lunn
2026-05-28 16:56   ` Aleksander Jan Bajkowski
2026-05-28  7:52 ` [PATCH net-next v1 2/2] net: phy: realtek: load firmware for RTL8261C javen
2026-05-28  9:08   ` Nicolai Buchwitz
2026-05-28 12:20   ` Daniel Golle
2026-06-01  5:38     ` Javen
2026-05-29  1:01   ` Andrew Lunn
2026-06-03  2:32 [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261 Javen
2026-06-03  2:57 ` Andrew Lunn
2026-06-04  7:28   ` Javen

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®