mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 05:39:54 -04:00
msm: ep_pcie: Changes to acquire wakelock as part of PERST IRQ
Changes to acquire wakelock as part of PERST deassert in non enumerated scenario. Change-Id: Ica992e12fe827e29416fbe56469d7be8b92ff5c5 Signed-off-by: Subramanian Ananthanarayanan <skananth@codeaurora.org> Signed-off-by: Gauri Joshi <gaurjosh@codeaurora.org>
This commit is contained in:
parent
4966230ae8
commit
49401bbfc2
1 changed files with 12 additions and 0 deletions
|
|
@ -2330,6 +2330,18 @@ static irqreturn_t ep_pcie_handle_perst_irq(int irq, void *data)
|
|||
"PCIe V%d: PCIe is not enumerated yet; PERST is %sasserted\n",
|
||||
dev->rev, perst ? "de" : "");
|
||||
if (perst) {
|
||||
/*
|
||||
* Hold a wakelock to avoid delay during
|
||||
* link enablement in PCIE layer in non
|
||||
* enumerated scenario.
|
||||
*/
|
||||
if (!atomic_read(&dev->ep_pcie_dev_wake)) {
|
||||
pm_stay_awake(&dev->pdev->dev);
|
||||
atomic_set(&dev->ep_pcie_dev_wake, 1);
|
||||
EP_PCIE_DBG(dev,
|
||||
"PCIe V%d: Acquired wakelock\n",
|
||||
dev->rev);
|
||||
}
|
||||
/* start work for link enumeration with the host side */
|
||||
schedule_work(&dev->handle_perst_work);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue