[PATCH 0/1][SRU][OEM-B] Timeout waiting for hardware access

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[PATCH 0/1][SRU][OEM-B] Timeout waiting for hardware access

AceLan Kao
BugLink: https://bugs.launchpad.net/bugs/1842388

[Impact]
There is a new feature added from stable kernel
3fa98d338296 ("PCI / PM: Allow runtime PM without callback functions")
and this feature lead to the backport-iwlwifi dkms driver fails to resume
from runtime suspended.

[Fix]
iwlwifi driver fails if pci_finish_runtime_suspend() is called, so check
if runtime_suspend() function is provided before calling this function.

[Test]
Verified on Dell Precision 5540, wifi keeps working even after S3 test.

[Regression]
Low. pci_finish_runtime_suspend() puts the PCI device into a low power
state, it doesn't hurt if we don't call it, and it passes the 30 times S3
test, so it should be fine to not to call it if runtime_suspend function
is not provided.

AceLan Kao (1):
  UBUNTU: SAUCE: PCI/PM: Don't call pci_finish_runtime_suspend()

 drivers/pci/pci-driver.c | 4 ++++
 1 file changed, 4 insertions(+)

--
2.17.1


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

[PATCH 1/1][SRU][OEM-B] UBUNTU: SAUCE: PCI/PM: Don't call pci_finish_runtime_suspend()

AceLan Kao
BugLink: https://bugs.launchpad.net/bugs/1842388

Don't call pci_finish_runtime_suspend() if runtime PM callback functions
are not provided. It leads to backport-iwlwifi driver fails to wakes up
from runtime suspend.

This commit could be reverted after backport-iwlwifi-dkms 7906 driver is
released in Ubuntu archive.

Signed-off-by: AceLan Kao <[hidden email]>
---
 drivers/pci/pci-driver.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c
index 34327a5ddf4c..e0809aff63bf 100644
--- a/drivers/pci/pci-driver.c
+++ b/drivers/pci/pci-driver.c
@@ -1323,6 +1323,10 @@ static int pci_pm_runtime_suspend(struct device *dev)
 
  if (!pci_dev->state_saved) {
  pci_save_state(pci_dev);
+
+ if (!pm || !pm->runtime_suspend)
+ return -ENOSYS;
+
  pci_finish_runtime_suspend(pci_dev);
  }
 
--
2.17.1


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team