Loading arch/arm/mach-msm/pcie.c +0 −6 Original line number Diff line number Diff line Loading @@ -1451,9 +1451,6 @@ static int msm_pcie_pm_suspend(struct pci_dev *dev, u32 rc_idx, msm_pcie_disable(rc_idx, PM_PIPE_CLK | PM_CLK | PM_VREG); PCIE_DBG("enabling wake_n\n"); enable_irq(msm_pcie_dev[rc_idx].wake_n); return ret; } Loading @@ -1478,9 +1475,6 @@ static int msm_pcie_pm_resume(struct pci_dev *dev, u32 rc_idx, { int ret; PCIE_DBG("disabling wake_n\n"); disable_irq(msm_pcie_dev[rc_idx].wake_n); spin_lock_irqsave(&msm_pcie_dev[rc_idx].cfg_lock, msm_pcie_dev[rc_idx].irqsave_flags); msm_pcie_dev[rc_idx].cfg_access = true; Loading arch/arm/mach-msm/pcie.h +3 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ #include <linux/platform_device.h> #include <linux/regulator/consumer.h> #include <linux/types.h> #include <linux/pm_wakeup.h> #include <mach/msm_pcie.h> #define MSM_PCIE_MAX_VREG 3 Loading Loading @@ -169,6 +170,8 @@ struct msm_pcie_dev_t { bool user_suspend; struct pci_saved_state *saved_state; struct wakeup_source ws; bool l1ss_supported; bool aux_clk_sync; }; Loading arch/arm/mach-msm/pcie_irq.c +14 −4 Original line number Diff line number Diff line Loading @@ -39,7 +39,13 @@ static irqreturn_t handle_wake_irq(int irq, void *data) { PCIE_DBG("\n"); struct msm_pcie_dev_t *dev = data; PCIE_DBG("PCIe WAKE is asserted by Endpoint\n"); __pm_stay_awake(&dev->ws); __pm_relax(&dev->ws); return IRQ_HANDLED; } Loading Loading @@ -322,6 +328,9 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) struct device *pdev = &dev->pdev->dev; PCIE_DBG("\n"); wakeup_source_init(&dev->ws, "pcie_wakeup_source"); /* register handler for physical MSI interrupt line */ rc = devm_request_irq(pdev, dev->irq[MSM_PCIE_INT_MSI].num, handle_msi_irq, Loading @@ -346,9 +355,6 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) return rc; } /* PCIE_WAKE_N should be enabled only during system suspend */ disable_irq(dev->wake_n); /* Create a virtual domain of interrupts */ dev->irq_domain = irq_domain_add_linear(dev->pdev->dev.of_node, PCIE_MSI_NR_IRQS, Loading @@ -356,6 +362,7 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) &dev); if (!dev->irq_domain) { pr_err("PCIe: Unable to initialize irq domain\n"); disable_irq(dev->wake_n); return PTR_ERR(dev->irq_domain); } Loading @@ -367,4 +374,7 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) void msm_pcie_irq_deinit(struct msm_pcie_dev_t *dev) { PCIE_DBG("\n"); wakeup_source_trash(&dev->ws); disable_irq(dev->wake_n); } Loading
arch/arm/mach-msm/pcie.c +0 −6 Original line number Diff line number Diff line Loading @@ -1451,9 +1451,6 @@ static int msm_pcie_pm_suspend(struct pci_dev *dev, u32 rc_idx, msm_pcie_disable(rc_idx, PM_PIPE_CLK | PM_CLK | PM_VREG); PCIE_DBG("enabling wake_n\n"); enable_irq(msm_pcie_dev[rc_idx].wake_n); return ret; } Loading @@ -1478,9 +1475,6 @@ static int msm_pcie_pm_resume(struct pci_dev *dev, u32 rc_idx, { int ret; PCIE_DBG("disabling wake_n\n"); disable_irq(msm_pcie_dev[rc_idx].wake_n); spin_lock_irqsave(&msm_pcie_dev[rc_idx].cfg_lock, msm_pcie_dev[rc_idx].irqsave_flags); msm_pcie_dev[rc_idx].cfg_access = true; Loading
arch/arm/mach-msm/pcie.h +3 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ #include <linux/platform_device.h> #include <linux/regulator/consumer.h> #include <linux/types.h> #include <linux/pm_wakeup.h> #include <mach/msm_pcie.h> #define MSM_PCIE_MAX_VREG 3 Loading Loading @@ -169,6 +170,8 @@ struct msm_pcie_dev_t { bool user_suspend; struct pci_saved_state *saved_state; struct wakeup_source ws; bool l1ss_supported; bool aux_clk_sync; }; Loading
arch/arm/mach-msm/pcie_irq.c +14 −4 Original line number Diff line number Diff line Loading @@ -39,7 +39,13 @@ static irqreturn_t handle_wake_irq(int irq, void *data) { PCIE_DBG("\n"); struct msm_pcie_dev_t *dev = data; PCIE_DBG("PCIe WAKE is asserted by Endpoint\n"); __pm_stay_awake(&dev->ws); __pm_relax(&dev->ws); return IRQ_HANDLED; } Loading Loading @@ -322,6 +328,9 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) struct device *pdev = &dev->pdev->dev; PCIE_DBG("\n"); wakeup_source_init(&dev->ws, "pcie_wakeup_source"); /* register handler for physical MSI interrupt line */ rc = devm_request_irq(pdev, dev->irq[MSM_PCIE_INT_MSI].num, handle_msi_irq, Loading @@ -346,9 +355,6 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) return rc; } /* PCIE_WAKE_N should be enabled only during system suspend */ disable_irq(dev->wake_n); /* Create a virtual domain of interrupts */ dev->irq_domain = irq_domain_add_linear(dev->pdev->dev.of_node, PCIE_MSI_NR_IRQS, Loading @@ -356,6 +362,7 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) &dev); if (!dev->irq_domain) { pr_err("PCIe: Unable to initialize irq domain\n"); disable_irq(dev->wake_n); return PTR_ERR(dev->irq_domain); } Loading @@ -367,4 +374,7 @@ int32_t msm_pcie_irq_init(struct msm_pcie_dev_t *dev) void msm_pcie_irq_deinit(struct msm_pcie_dev_t *dev) { PCIE_DBG("\n"); wakeup_source_trash(&dev->ws); disable_irq(dev->wake_n); }