Thread (3 messages) 3 messages, 2 authors, 2022-05-17

RE: [Intel-wired-lan] [PATCH] igb: skip phy status check where unavailable

From: G, GurucharanX <hidden>
Date: 2022-05-17 06:24:47
Also in: lkml

-----Original Message-----
From: Intel-wired-lan <redacted> On Behalf Of
Kevin Mitchell
Sent: Saturday, April 30, 2022 5:26 AM
Cc: kevmitch@arista.com; intel-wired-lan@lists.osuosl.org; linux-
kernel@vger.kernel.org; Takuma Ueba [off-list ref]; Jeff Kirsher
[off-list ref]; netdev@vger.kernel.org; Jakub Kicinski
[off-list ref]; Paolo Abeni [off-list ref]; David S. Miller
[off-list ref]
Subject: [Intel-wired-lan] [PATCH] igb: skip phy status check where
unavailable

igb_read_phy_reg() will silently return, leaving phy_data untouched, if
hw->ops.read_reg isn't set. Depending on the uninitialized value of
phy_data, this led to the phy status check either succeeding immediately or
looping continuously for 2 seconds before emitting a noisy err-level timeout.
This message went out to the console even though there was no actual
problem.

Instead, first check if there is read_reg function pointer. If not, proceed
without trying to check the phy status register.

Fixes: b72f3f72005d ("igb: When GbE link up, wait for Remote receiver status
condition")
Signed-off-by: Kevin Mitchell <redacted>
---
 drivers/net/ethernet/intel/igb/igb_main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Tested-by: Gurucharan <redacted> (A Contingent worker at Intel)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help