diff mbox series

[net-next] net: pcs: lynx: no need to read LPA in lynx_pcs_get_state_2500basex()

Message ID 20240513115345.2452799-1-vladimir.oltean@nxp.com (mailing list archive)
State Accepted
Commit afd29f36aaf733985df1ba162424581b8b8853b4
Delegated to: Netdev Maintainers
Headers show
Series [net-next] net: pcs: lynx: no need to read LPA in lynx_pcs_get_state_2500basex() | expand

Checks

Context Check Description
netdev/series_format success Single patches do not need cover letters
netdev/tree_selection success Clearly marked for net-next
netdev/ynl success Generated files up to date; no warnings/errors; no diff in generated;
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 925 this patch: 925
netdev/build_tools success No tools touched, skip
netdev/cc_maintainers success CCed 8 of 8 maintainers
netdev/build_clang success Errors and warnings before: 936 this patch: 936
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 936 this patch: 936
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 13 lines checked
netdev/build_clang_rust success No Rust files in patch. Skipping build
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0
netdev/contest success net-next-2024-05-13--18-00 (tests: 1019)

Commit Message

Vladimir Oltean May 13, 2024, 11:53 a.m. UTC
Nothing useful is done with the LPA variable in lynx_pcs_get_state_2500basex(),
we can just remove the read.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
 drivers/net/pcs/pcs-lynx.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comments

Andrew Lunn May 13, 2024, 4:18 p.m. UTC | #1
On Mon, May 13, 2024 at 02:53:45PM +0300, Vladimir Oltean wrote:
> Nothing useful is done with the LPA variable in lynx_pcs_get_state_2500basex(),
> we can just remove the read.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

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

    Andrew
patchwork-bot+netdevbpf@kernel.org May 14, 2024, midnight UTC | #2
Hello:

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

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.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> ---
>  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!
diff mbox series

Patch

diff --git a/drivers/net/pcs/pcs-lynx.c b/drivers/net/pcs/pcs-lynx.c
index 853b8c138718..b79aedad855b 100644
--- a/drivers/net/pcs/pcs-lynx.c
+++ b/drivers/net/pcs/pcs-lynx.c
@@ -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;
 	}