mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 22:40:54 -04:00
cnss2: Handle resume request while suspend in progress
PCIE callback for wake IRQ can occur during suspend in progress. Update cnss2 driver to handle resume request in this scenario. Change-Id: Ia76fd4b2d14e00ba5cad41018bda081d8b7dde83 Signed-off-by: Manikandan Mohan <manikand@codeaurora.org>
This commit is contained in:
parent
8c86f95982
commit
7855b64b85
1 changed files with 5 additions and 2 deletions
|
|
@ -2532,6 +2532,7 @@ static void cnss_pci_event_cb(struct msm_pcie_notify *notify)
|
|||
{
|
||||
struct pci_dev *pci_dev;
|
||||
struct cnss_pci_data *pci_priv;
|
||||
struct device *dev;
|
||||
|
||||
if (!notify)
|
||||
return;
|
||||
|
|
@ -2543,6 +2544,7 @@ static void cnss_pci_event_cb(struct msm_pcie_notify *notify)
|
|||
pci_priv = cnss_get_pci_priv(pci_dev);
|
||||
if (!pci_priv)
|
||||
return;
|
||||
dev = &pci_priv->pci_dev->dev;
|
||||
|
||||
switch (notify->event) {
|
||||
case MSM_PCIE_EVENT_LINKDOWN:
|
||||
|
|
@ -2551,8 +2553,9 @@ static void cnss_pci_event_cb(struct msm_pcie_notify *notify)
|
|||
break;
|
||||
case MSM_PCIE_EVENT_WAKEUP:
|
||||
complete(&pci_priv->wake_event);
|
||||
if (cnss_pci_get_monitor_wake_intr(pci_priv) &&
|
||||
cnss_pci_get_auto_suspended(pci_priv)) {
|
||||
if ((cnss_pci_get_monitor_wake_intr(pci_priv) &&
|
||||
cnss_pci_get_auto_suspended(pci_priv)) ||
|
||||
dev->power.runtime_status == RPM_SUSPENDING) {
|
||||
cnss_pci_set_monitor_wake_intr(pci_priv, false);
|
||||
cnss_pci_pm_request_resume(pci_priv);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue