Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value

Function rtl8365mb_phy_ocp_write() always returns 0, even when an error
occurs during register access. This patch fixes the return value to
propagate the actual error code from regmap operations.

Link: https://lore.kernel.org/netdev/a2dfde3c-d46f-434b-9d16-1e251e449068@yahoo.com/
Fixes: 2796728460b8 ("net: dsa: realtek: rtl8365mb: serialize indirect PHY register access")
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
Reviewed-by: Linus Walleij <linusw@kernel.org>
Link: https://patch.msgid.link/20260301-realtek_namiltd_fix1-v1-1-43a6bb707f9c@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Mieczyslaw Nalewaj and committed by
Jakub Kicinski
7cbe98f7 9439a661

+1 -1
+1 -1
drivers/net/dsa/realtek/rtl8365mb.c
··· 769 769 out: 770 770 rtl83xx_unlock(priv); 771 771 772 - return 0; 772 + return ret; 773 773 } 774 774 775 775 static int rtl8365mb_phy_read(struct realtek_priv *priv, int phy, int regnum)