public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value
@ 2026-03-01 21:13 Luiz Angelo Daros de Luca
  2026-03-01 23:32 ` Linus Walleij
  2026-03-03  4:45 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Luiz Angelo Daros de Luca @ 2026-03-01 21:13 UTC (permalink / raw)
  To: Linus Walleij, Alvin Šipraga, Andrew Lunn, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni
  Cc: netdev, linux-kernel, Mieczyslaw Nalewaj,
	Luiz Angelo Daros de Luca

From: Mieczyslaw Nalewaj <namiltd@yahoo.com>

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>
Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
---
 drivers/net/dsa/realtek/rtl8365mb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/dsa/realtek/rtl8365mb.c b/drivers/net/dsa/realtek/rtl8365mb.c
index c575e164368c..f938a3f701cc 100644
--- a/drivers/net/dsa/realtek/rtl8365mb.c
+++ b/drivers/net/dsa/realtek/rtl8365mb.c
@@ -769,7 +769,7 @@ static int rtl8365mb_phy_ocp_write(struct realtek_priv *priv, int phy,
 out:
 	rtl83xx_unlock(priv);
 
-	return 0;
+	return ret;
 }
 
 static int rtl8365mb_phy_read(struct realtek_priv *priv, int phy, int regnum)

---
base-commit: 01857fc712f6469cab9cc578120cdc80f1c2a634
change-id: 20260301-realtek_namiltd_fix1-ee240981460d

Best regards,
-- 
Luiz Angelo Daros de Luca <luizluca@gmail.com>


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

* Re: [PATCH net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value
  2026-03-01 21:13 [PATCH net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value Luiz Angelo Daros de Luca
@ 2026-03-01 23:32 ` Linus Walleij
  2026-03-03  4:45 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Linus Walleij @ 2026-03-01 23:32 UTC (permalink / raw)
  To: Luiz Angelo Daros de Luca
  Cc: Alvin Šipraga, Andrew Lunn, Vladimir Oltean, David S. Miller,
	Eric Dumazet, Jakub Kicinski, Paolo Abeni, netdev, linux-kernel,
	Mieczyslaw Nalewaj

On Sun, Mar 1, 2026 at 10:13 PM Luiz Angelo Daros de Luca
<luizluca@gmail.com> wrote:

> From: Mieczyslaw Nalewaj <namiltd@yahoo.com>
>
> 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>
> Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>

Reviewed-by: Linus Walleij <linusw@kernel.org>

Yours,
Linus Walleij

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

* Re: [PATCH net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value
  2026-03-01 21:13 [PATCH net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value Luiz Angelo Daros de Luca
  2026-03-01 23:32 ` Linus Walleij
@ 2026-03-03  4:45 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-03-03  4:45 UTC (permalink / raw)
  To: Luiz Angelo Daros de Luca
  Cc: linusw, alsi, andrew, olteanv, davem, edumazet, kuba, pabeni,
	netdev, linux-kernel, namiltd

Hello:

This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Sun, 01 Mar 2026 18:13:14 -0300 you wrote:
> From: Mieczyslaw Nalewaj <namiltd@yahoo.com>
> 
> 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>
> Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
> 
> [...]

Here is the summary with links:
  - [net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value
    https://git.kernel.org/netdev/net/c/7cbe98f7bef9

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2026-03-03  4:45 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-01 21:13 [PATCH net-next] net: dsa: realtek: rtl8365mb: fix rtl8365mb_phy_ocp_write return value Luiz Angelo Daros de Luca
2026-03-01 23:32 ` Linus Walleij
2026-03-03  4:45 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox