Skip to contentSkip to conversation

net: pcs: lynx: no need to read LPA in lynx_pcs_get_state_2500basex()

PATCH Applied Vladimir Oltean 3 participants 3 messages May 13, 2024 – May 14, 2024

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: pcs: lynx: no need to read LPA in lynx_pcs_get_state_2500basex()

Nothing useful is done with the LPA variable in lynx_pcs_get_state_2500basex(), we can just remove the read.

---
 drivers/net/pcs/pcs-lynx.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/net/pcs/pcs-lynx.c +2 -3
index 853b8c138718..b79aedad855b 100644
@@ -61,11 +61,10 @@ static void lynx_pcs_get_state_usxgmii(struct mdio_device *pcs,
 static void lynx_pcs_get_state_2500basex(struct mdio_device *pcs,
 					 struct phylink_link_state *state)
 {
-	int bmsr, lpa;
+	int bmsr;
 
 	bmsr = mdiodev_read(pcs, MII_BMSR);
-	lpa = mdiodev_read(pcs, MII_LPA);
-	if (bmsr < 0 || lpa < 0) {
+	if (bmsr < 0) {
 		state->link = false;
 		return;
 	}
Signature · 1 line
2.34.1
#2 lore raw
In reply to Vladimir Oltean
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Quoted 7 lines · On Mon, 13 May 2024 14:53:45 +0300 you wrote:

Nothing useful is done with the LPA variable in lynx_pcs_get_state_2500basex(), we can just remove the read.

---
 drivers/net/pcs/pcs-lynx.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Here is the summary with links:
- [net-next] net: pcs: lynx: no need to read LPA in lynx_pcs_get_state_2500basex()

    https://git.kernel.org/netdev/net-next/c/afd29f36aaf7

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html