[PATCH] net: phy: realtek: Add support for PHY LEDs on RTL8211F-VD

Kryštof Černý via B4 Relay posted 1 patch 2 weeks, 2 days ago
There is a newer version of this series
drivers/net/phy/realtek/realtek_main.c | 3 +++
1 file changed, 3 insertions(+)
[PATCH] net: phy: realtek: Add support for PHY LEDs on RTL8211F-VD
Posted by Kryštof Černý via B4 Relay 2 weeks, 2 days ago
From: Kryštof Černý <cleverline1mc@gmail.com>

Realtek RTL8211F-VD has the same LED configuration
and registers as RTL8211F.
Use the existing LED related functions for this chip,
so it is possible to also use the netdev trigger.

Tested on ROCK Pi E.

Signed-off-by: Kryštof Černý <cleverline1mc@gmail.com>
---
I have been trying to match LED behavior of RTL8211F-VD with RTL8211E
and found out the RTL8211F is supported already,
which by the look in datasheet matched the RTL8211F-VD.
So I have reused the functions and tested on ROCK Pi E.
---
 drivers/net/phy/realtek/realtek_main.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/phy/realtek/realtek_main.c b/drivers/net/phy/realtek/realtek_main.c
index 75565fbdbf6d..530b4e26d16e 100644
--- a/drivers/net/phy/realtek/realtek_main.c
+++ b/drivers/net/phy/realtek/realtek_main.c
@@ -2243,6 +2243,9 @@ static struct phy_driver realtek_drvs[] = {
 		.read_page	= rtl821x_read_page,
 		.write_page	= rtl821x_write_page,
 		.flags		= PHY_ALWAYS_CALL_SUSPEND,
+		.led_hw_is_supported = rtl8211x_led_hw_is_supported,
+		.led_hw_control_get = rtl8211f_led_hw_control_get,
+		.led_hw_control_set = rtl8211f_led_hw_control_set,
 	}, {
 		.name		= "Generic FE-GE Realtek PHY",
 		.match_phy_device = rtlgen_match_phy_device,

---
base-commit: 350adaf7fde9fdbd9aeed6d442a9ae90c6a3ab97
change-id: 20260216-rtl8211fvd-add-leds-72e5d666e921

Best regards,
-- 
Kryštof Černý <cleverline1mc@gmail.com>


Re: [PATCH] net: phy: realtek: Add support for PHY LEDs on RTL8211F-VD
Posted by Andrew Lunn 2 weeks, 2 days ago
On Mon, Feb 16, 2026 at 06:11:09PM +0100, Kryštof Černý via B4 Relay wrote:
> From: Kryštof Černý <cleverline1mc@gmail.com>
> 
> Realtek RTL8211F-VD has the same LED configuration
> and registers as RTL8211F.
> Use the existing LED related functions for this chip,
> so it is possible to also use the netdev trigger.
> 
> Tested on ROCK Pi E.
> 
> Signed-off-by: Kryštof Černý <cleverline1mc@gmail.com>

net-next is closed for the merge window. Please repost in two weeks
time.

https://www.kernel.org/doc/html/latest/process/maintainer-netdev.html

Please also set the subject line to indicate which tree this is for.

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew

---
pw-bot: cr