diff options
| author | Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> | 2025-03-21 18:21:14 +0200 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-04-10 14:41:38 +0200 |
| commit | 5f4d2ebc2ea2e1cf0579eeb2f6efde8939e2087e (patch) | |
| tree | 6670d97de2a2061c9ecc0a4b097b211781de6a62 | |
| parent | a9f3ea13761eb528bfce5a281d7703ad5997cf32 (diff) | |
| download | linux-5f4d2ebc2ea2e1cf0579eeb2f6efde8939e2087e.tar.gz linux-5f4d2ebc2ea2e1cf0579eeb2f6efde8939e2087e.tar.bz2 linux-5f4d2ebc2ea2e1cf0579eeb2f6efde8939e2087e.zip | |
PCI: pciehp: Don't enable HPIE when resuming in poll mode
[ Upstream commit 527664f738afb6f2c58022cd35e63801e5dc7aec ]
PCIe hotplug can operate in poll mode without interrupt handlers using a
polling kthread only. eb34da60edee ("PCI: pciehp: Disable hotplug
interrupt during suspend") failed to consider that and enables HPIE
(Hot-Plug Interrupt Enable) unconditionally when resuming the Port.
Only set HPIE if non-poll mode is in use. This makes
pcie_enable_interrupt() match how pcie_enable_notification() already
handles HPIE.
Link: https://lore.kernel.org/r/20250321162114.3939-1-ilpo.jarvinen@linux.intel.com
Fixes: eb34da60edee ("PCI: pciehp: Disable hotplug interrupt during suspend")
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Lukas Wunner <lukas@wunner.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
| -rw-r--r-- | drivers/pci/hotplug/pciehp_hpc.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c index bb5a8d9f03ad..28ab393af1c0 100644 --- a/drivers/pci/hotplug/pciehp_hpc.c +++ b/drivers/pci/hotplug/pciehp_hpc.c @@ -842,7 +842,9 @@ void pcie_enable_interrupt(struct controller *ctrl) { u16 mask; - mask = PCI_EXP_SLTCTL_HPIE | PCI_EXP_SLTCTL_DLLSCE; + mask = PCI_EXP_SLTCTL_DLLSCE; + if (!pciehp_poll_mode) + mask |= PCI_EXP_SLTCTL_HPIE; pcie_write_cmd(ctrl, mask, mask); } |
