diff options
author | Ben Hutchings <ben@decadent.org.uk> | 2015-02-23 21:37:52 +0000 |
---|---|---|
committer | Ben Hutchings <ben@decadent.org.uk> | 2015-03-06 00:39:17 +0000 |
commit | 3edc6373939d16ff2b4d54aa12059d004bf62884 (patch) | |
tree | 5c4e9cc80fa2dd32ba3faa17348265828f6d5547 | |
parent | fd623507bdcee1f7a387ae86adb7a66b431dd056 (diff) |
PCI: quirks: Fix backport of quirk_io()
Commit 06cf35f903aa ('PCI: Handle read-only BARs on AMD CS553x
devices') added the function quirk_io() which calls
pcibios_bus_to_resource().
Prior to Linux 3.14, pcibios_bus_to_resource() takes a pointer to
struct pci_dev and looks up the device's bus itself, so we need
to pass dev not dev->bus.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
-rw-r--r-- | drivers/pci/quirks.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c index 127dfe5d67e1..481b184ee5e8 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c @@ -409,7 +409,7 @@ static void quirk_io(struct pci_dev *dev, int pos, unsigned size, /* Convert from PCI bus to resource space */ bus_region.start = region; bus_region.end = region + size - 1; - pcibios_bus_to_resource(dev->bus, res, &bus_region); + pcibios_bus_to_resource(dev, res, &bus_region); dev_info(&dev->dev, FW_BUG "%s quirk: reg 0x%x: %pR\n", name, PCI_BASE_ADDRESS_0 + (pos << 2), res); |