[PATCH v2] PCI: clean up dead code in pcie_get_mps()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



v1->v2: rename patch name and update patch log
        the v1 patch https://patchwork.kernel.org/patch/2837637/

After commit 59875ae489, pcie_get_mps() will never
return negative value. So we can remove two lines
of dead code.

Signed-off-by: Yijing Wang <wangyijing@xxxxxxxxxx>
---
 drivers/pci/pci.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index 10e3c4e..86beb31 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -3919,8 +3919,6 @@ int pcie_set_readrq(struct pci_dev *dev, int rq)
 	if (pcie_bus_config == PCIE_BUS_PERFORMANCE) {
 		int mps = pcie_get_mps(dev);
 
-		if (mps < 0)
-			return mps;
 		if (mps < rq)
 			rq = mps;
 	}
-- 
1.7.1


--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux