diff options
author | Keith Busch <keith.busch@intel.com> | 2017-04-28 19:02:48 +0300 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2017-05-23 02:42:02 +0300 |
commit | 993d668183fa49b63939a4f62a558d487fd50c22 (patch) | |
tree | 7cd6063f0953d50912fc4ef214e30dbcff46260d /drivers/pci/pcie | |
parent | 2ea659a9ef488125eb46da6eb571de5eae5c43f6 (diff) | |
download | linux-993d668183fa49b63939a4f62a558d487fd50c22.tar.xz |
PCI/DPC: Skip DPC event if device is not present
The DPC interupt may be executed on a device that is being removed. Skip
queuing event handling if the status is all 1's, which should be seen only
if the device is not present.
Signed-off-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/pcie')
-rw-r--r-- | drivers/pci/pcie/pcie-dpc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/pcie/pcie-dpc.c b/drivers/pci/pcie/pcie-dpc.c index 77d2ca99d2ec..0bf084357237 100644 --- a/drivers/pci/pcie/pcie-dpc.c +++ b/drivers/pci/pcie/pcie-dpc.c @@ -92,7 +92,7 @@ static irqreturn_t dpc_irq(int irq, void *context) pci_read_config_word(pdev, dpc->cap_pos + PCI_EXP_DPC_STATUS, &status); pci_read_config_word(pdev, dpc->cap_pos + PCI_EXP_DPC_SOURCE_ID, &source); - if (!status) + if (!status || status == (u16)(~0)) return IRQ_NONE; dev_info(&dpc->dev->device, "DPC containment event, status:%#06x source:%#06x\n", |