summaryrefslogtreecommitdiff
path: root/drivers/pci
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2017-04-14 21:11:27 +0200
committerBjorn Helgaas <bhelgaas@google.com>2017-04-20 08:53:52 -0500
commit48f52d1a8ca9f1aff3ffad8e35b6c56eafa17b9b (patch)
treefd1683aeb9b51a1be0e80a316b6e3b96806929bb /drivers/pci
parentc8d8096abc84b544dd4f37f12e929d5f8aadd160 (diff)
PCI: Call pcie_flr() from reset_chelsio_generic_dev()
Instead of copy & pasting and old version of the code. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci')
-rw-r--r--drivers/pci/quirks.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
index fd5ec86816aa..a3a0b5a0b72c 100644
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
@@ -3750,20 +3750,7 @@ static int reset_chelsio_generic_dev(struct pci_dev *dev, int probe)
PCI_MSIX_FLAGS_ENABLE |
PCI_MSIX_FLAGS_MASKALL);
- /*
- * Start of pcie_flr() code sequence. This reset code is a copy of
- * the guts of pcie_flr() because that's not an exported function.
- */
-
- if (!pci_wait_for_pending_transaction(dev))
- dev_err(&dev->dev, "transaction is not cleared; proceeding with reset anyway\n");
-
- pcie_capability_set_word(dev, PCI_EXP_DEVCTL, PCI_EXP_DEVCTL_BCR_FLR);
- msleep(100);
-
- /*
- * End of pcie_flr() code sequence.
- */
+ pcie_flr(dev);
/*
* Restore the configuration information (BAR values, etc.) including