* [PATCH net 1/1] e1000e: Check the PCIm state
@ 2021-06-24 19:02 Tony Nguyen
2021-06-24 22:10 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: Tony Nguyen @ 2021-06-24 19:02 UTC (permalink / raw)
To: davem, kuba
Cc: Sasha Neftin, netdev, anthony.l.nguyen, vitaly.lifshits,
Dvora Fuxbrumer
From: Sasha Neftin <sasha.neftin@intel.com>
Complete to commit def4ec6dce393e ("e1000e: PCIm function state support")
Check the PCIm state only on CSME systems. There is no point to do this
check on non CSME systems.
This patch fixes a generation a false-positive warning:
"Error in exiting dmoff"
Fixes: def4ec6dce39 ("e1000e: PCIm function state support")
Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
Tested-by: Dvora Fuxbrumer <dvorax.fuxbrumer@linux.intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
---
drivers/net/ethernet/intel/e1000e/netdev.c | 24 ++++++++++++----------
1 file changed, 13 insertions(+), 11 deletions(-)
diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c
index 88e9035b75cf..dc0ded7e5e61 100644
--- a/drivers/net/ethernet/intel/e1000e/netdev.c
+++ b/drivers/net/ethernet/intel/e1000e/netdev.c
@@ -5223,18 +5223,20 @@ static void e1000_watchdog_task(struct work_struct *work)
pm_runtime_resume(netdev->dev.parent);
/* Checking if MAC is in DMoff state*/
- pcim_state = er32(STATUS);
- while (pcim_state & E1000_STATUS_PCIM_STATE) {
- if (tries++ == dmoff_exit_timeout) {
- e_dbg("Error in exiting dmoff\n");
- break;
- }
- usleep_range(10000, 20000);
+ if (er32(FWSM) & E1000_ICH_FWSM_FW_VALID) {
pcim_state = er32(STATUS);
-
- /* Checking if MAC exited DMoff state */
- if (!(pcim_state & E1000_STATUS_PCIM_STATE))
- e1000_phy_hw_reset(&adapter->hw);
+ while (pcim_state & E1000_STATUS_PCIM_STATE) {
+ if (tries++ == dmoff_exit_timeout) {
+ e_dbg("Error in exiting dmoff\n");
+ break;
+ }
+ usleep_range(10000, 20000);
+ pcim_state = er32(STATUS);
+
+ /* Checking if MAC exited DMoff state */
+ if (!(pcim_state & E1000_STATUS_PCIM_STATE))
+ e1000_phy_hw_reset(&adapter->hw);
+ }
}
/* update snapshot of PHY registers on LSC */
--
2.26.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net 1/1] e1000e: Check the PCIm state
2021-06-24 19:02 [PATCH net 1/1] e1000e: Check the PCIm state Tony Nguyen
@ 2021-06-24 22:10 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-06-24 22:10 UTC (permalink / raw)
To: Tony Nguyen
Cc: davem, kuba, sasha.neftin, netdev, vitaly.lifshits,
dvorax.fuxbrumer
Hello:
This patch was applied to netdev/net.git (refs/heads/master):
On Thu, 24 Jun 2021 12:02:48 -0700 you wrote:
> From: Sasha Neftin <sasha.neftin@intel.com>
>
> Complete to commit def4ec6dce393e ("e1000e: PCIm function state support")
> Check the PCIm state only on CSME systems. There is no point to do this
> check on non CSME systems.
> This patch fixes a generation a false-positive warning:
> "Error in exiting dmoff"
>
> [...]
Here is the summary with links:
- [net,1/1] e1000e: Check the PCIm state
https://git.kernel.org/netdev/net/c/2e7256f12cdb
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-06-24 22:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-24 19:02 [PATCH net 1/1] e1000e: Check the PCIm state Tony Nguyen
2021-06-24 22:10 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).