Skip to content

Commit d147085

Browse files
Kai-Heng Fengdavem330
authored andcommitted
e1000e: Use PME poll to circumvent unreliable ACPI wake
On some I219 devices, ethernet cable plugging detection only works once from PCI D3 state. Subsequent cable plugging does set PME bit correctly, but device still doesn't get woken up. Since I219 connects to the root complex directly, it relies on platform firmware (ACPI) to wake it up. In this case, the GPE from _PRW only works for first cable plugging but fails to notify the driver for subsequent plugging events. The issue was originally found on CNP, but the same issue can be found on ADL too. So workaround the issue by continuing use PME poll after first ACPI wake. As PME poll is always used, the runtime suspend restriction for CNP can also be removed. Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com> Tested-by: Naama Meir <naamax.meir@linux.intel.com> Acked-by: Sasha Neftin <sasha.neftin@intel.com> Reviewed-by: Simon Horman <simon.horman@corigine.com> Reviewed-by: Leon Romanovsky <leonro@nvidia.com> Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent ac8a529 commit d147085

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

  • drivers/net/ethernet/intel/e1000e

drivers/net/ethernet/intel/e1000e/netdev.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7021,6 +7021,8 @@ static __maybe_unused int e1000e_pm_runtime_resume(struct device *dev)
70217021
struct e1000_adapter *adapter = netdev_priv(netdev);
70227022
int rc;
70237023

7024+
pdev->pme_poll = true;
7025+
70247026
rc = __e1000_resume(pdev);
70257027
if (rc)
70267028
return rc;
@@ -7682,7 +7684,7 @@ static int e1000_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
76827684

76837685
dev_pm_set_driver_flags(&pdev->dev, DPM_FLAG_SMART_PREPARE);
76847686

7685-
if (pci_dev_run_wake(pdev) && hw->mac.type != e1000_pch_cnp)
7687+
if (pci_dev_run_wake(pdev))
76867688
pm_runtime_put_noidle(&pdev->dev);
76877689

76887690
return 0;

0 commit comments

Comments
 (0)