* [PATCH] igb: e1000_82575: add an error code check in igb_set_d0_lplu_state_82575
@ 2023-10-20 9:24 Su Hui
2023-10-23 16:52 ` Simon Horman
0 siblings, 1 reply; 3+ messages in thread
From: Su Hui @ 2023-10-20 9:24 UTC (permalink / raw)
To: jesse.brandeburg, anthony.l.nguyen, davem, edumazet, kuba, pabeni
Cc: Su Hui, intel-wired-lan, netdev, linux-kernel, kernel-janitors
igb_set_d0_lplu_state_82575() check all phy->ops.read_reg()'s return value
except this one, just fix this.
Signed-off-by: Su Hui <suhui@nfschina.com>
---
drivers/net/ethernet/intel/igb/e1000_82575.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/intel/igb/e1000_82575.c b/drivers/net/ethernet/intel/igb/e1000_82575.c
index 8d6e44ee1895..e765d5ee3661 100644
--- a/drivers/net/ethernet/intel/igb/e1000_82575.c
+++ b/drivers/net/ethernet/intel/igb/e1000_82575.c
@@ -978,6 +978,9 @@ static s32 igb_set_d0_lplu_state_82575(struct e1000_hw *hw, bool active)
/* When LPLU is enabled, we should disable SmartSpeed */
ret_val = phy->ops.read_reg(hw, IGP01E1000_PHY_PORT_CONFIG,
&data);
+ if (ret_val)
+ goto out;
+
data &= ~IGP01E1000_PSCFR_SMART_SPEED;
ret_val = phy->ops.write_reg(hw, IGP01E1000_PHY_PORT_CONFIG,
data);
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Intel-wired-lan] [PATCH] igb: e1000_82575: add an error code check in igb_set_d0_lplu_state_82575
2023-10-20 9:24 [PATCH] igb: e1000_82575: add an error code check in igb_set_d0_lplu_state_82575 Su Hui
@ 2023-10-23 16:52 ` Simon Horman
0 siblings, 0 replies; 3+ messages in thread
From: Simon Horman @ 2023-10-23 16:52 UTC (permalink / raw)
To: Su Hui
Cc: intel-wired-lan, kernel-janitors, jesse.brandeburg, linux-kernel,
edumazet, anthony.l.nguyen, netdev, kuba, pabeni, davem
On Fri, Oct 20, 2023 at 05:24:31PM +0800, Su Hui wrote:
> igb_set_d0_lplu_state_82575() check all phy->ops.read_reg()'s return value
> except this one, just fix this.
>
> Signed-off-by: Su Hui <suhui@nfschina.com>
Reviewed-by: Simon Horman <horms@kernel.org>
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] igb: e1000_82575: add an error code check in igb_set_d0_lplu_state_82575
@ 2023-10-23 16:52 ` Simon Horman
0 siblings, 0 replies; 3+ messages in thread
From: Simon Horman @ 2023-10-23 16:52 UTC (permalink / raw)
To: Su Hui
Cc: jesse.brandeburg, anthony.l.nguyen, davem, edumazet, kuba, pabeni,
intel-wired-lan, netdev, linux-kernel, kernel-janitors
On Fri, Oct 20, 2023 at 05:24:31PM +0800, Su Hui wrote:
> igb_set_d0_lplu_state_82575() check all phy->ops.read_reg()'s return value
> except this one, just fix this.
>
> Signed-off-by: Su Hui <suhui@nfschina.com>
Reviewed-by: Simon Horman <horms@kernel.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-10-23 16:52 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-20 9:24 [PATCH] igb: e1000_82575: add an error code check in igb_set_d0_lplu_state_82575 Su Hui
2023-10-23 16:52 ` [Intel-wired-lan] " Simon Horman
2023-10-23 16:52 ` Simon Horman
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.