diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2012-06-20 18:41:16 -0400 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2012-06-20 19:28:53 -0400 |
commit | 809a3bf9f34cb6d0c0383b31b3495fa1ed3508a6 (patch) | |
tree | bf12b30a6c9c717cafe158d80e2df16b56004dce /drivers | |
parent | dfb117b3e50c52c7b3416db4a4569224b8db80bb (diff) |
PCI: remove useless pcix_set_mmrbc() dev->bus check
For a valid pci_dev, dev->bus != NULL always, so remove this
unnecessary test.
Found by Coverity (CID 101680).
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/pci/pci.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index b9e93cf1eb40..7f1310e58534 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c | |||
@@ -3395,8 +3395,7 @@ int pcix_set_mmrbc(struct pci_dev *dev, int mmrbc) | |||
3395 | 3395 | ||
3396 | o = (cmd & PCI_X_CMD_MAX_READ) >> 2; | 3396 | o = (cmd & PCI_X_CMD_MAX_READ) >> 2; |
3397 | if (o != v) { | 3397 | if (o != v) { |
3398 | if (v > o && dev->bus && | 3398 | if (v > o && (dev->bus->bus_flags & PCI_BUS_FLAGS_NO_MMRBC)) |
3399 | (dev->bus->bus_flags & PCI_BUS_FLAGS_NO_MMRBC)) | ||
3400 | return -EIO; | 3399 | return -EIO; |
3401 | 3400 | ||
3402 | cmd &= ~PCI_X_CMD_MAX_READ; | 3401 | cmd &= ~PCI_X_CMD_MAX_READ; |