diff mbox series

[32/70] net/e1000/base: modify the wrong return value

Message ID 20200622064634.70941-33-guinanx.sun@intel.com (mailing list archive)
State Superseded, archived
Delegated to: Qi Zhang
Headers show
Series update e1000 base code | expand


Context Check Description
ci/Intel-compilation success Compilation OK
ci/checkpatch success coding style OK

Commit Message

Guinan Sun June 22, 2020, 6:45 a.m. UTC
Make 'init_phy_hw_reset_generic' method to be closest to the
upstream method. Fix the return value to be same as in upstream.
Fix unable to handle kernel NULL pointer dereference at 0x0 caused
to kernel panic.

Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
Signed-off-by: Guinan Sun <guinanx.sun@intel.com>
 drivers/net/e1000/base/e1000_phy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series


diff --git a/drivers/net/e1000/base/e1000_phy.c b/drivers/net/e1000/base/e1000_phy.c
index 73e2ecda8..bcb3df2f3 100644
--- a/drivers/net/e1000/base/e1000_phy.c
+++ b/drivers/net/e1000/base/e1000_phy.c
@@ -2905,7 +2905,7 @@  s32 e1000_phy_hw_reset_generic(struct e1000_hw *hw)
-	return phy->ops.get_cfg_done(hw);
+	return ret_val;