From b209174c43bc0b6a4cb6f4af44a1b25d85d543c6 Mon Sep 17 00:00:00 2001 From: Markus Stockhausen Date: Wed, 7 Jan 2026 07:52:12 +0100 Subject: [PATCH] realtek: phy: use lock helpers No need to open code bus locking. Signed-off-by: Markus Stockhausen Link: https://github.com/openwrt/openwrt/pull/21435 Signed-off-by: Stijn Tintel --- .../linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/target/linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c b/target/linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c index d06ae04836..b6d2aba00f 100644 --- a/target/linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c +++ b/target/linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c @@ -453,12 +453,11 @@ static bool __rtl8214fc_media_is_fibre(struct phy_device *phydev) static bool rtl8214fc_media_is_fibre(struct phy_device *phydev) { - struct mii_bus *bus = phydev->mdio.bus; int ret; - mutex_lock(&bus->mdio_lock); + phy_lock_mdio_bus(phydev); ret = __rtl8214fc_media_is_fibre(phydev); - mutex_unlock(&bus->mdio_lock); + phy_unlock_mdio_bus(phydev); return ret; }