diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2017-11-14 12:11:25 -0600 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2017-11-14 12:11:25 -0600 |
commit | 104d1e40cfcd69934f3f57c6abf13980eb703feb (patch) | |
tree | b57f657381267187610c1dbc2606de2142ceca7d /drivers/pci/pci.h | |
parent | 8dceeaf8fff35a0b70a8cf3ca66883ac4bf4c9dd (diff) | |
parent | a405f191f42ead45a03c000110a16683d30f7333 (diff) |
Merge branch 'pci/resource' into next
* pci/resource:
PCI: Fail pci_map_rom() if the option ROM is invalid
PCI: Move pci_map_rom() error path
x86/PCI: Enable a 64bit BAR on AMD Family 15h (Models 00-1f, 30-3f, 60-7f)
PCI: Add pci_resize_resource() for resizing BARs
PCI: Add resizable BAR infrastructure
PCI: Add PCI resource type mask #define
Diffstat (limited to 'drivers/pci/pci.h')
-rw-r--r-- | drivers/pci/pci.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h index 1db36f2e1ef5..186278fa6917 100644 --- a/drivers/pci/pci.h +++ b/drivers/pci/pci.h @@ -366,4 +366,12 @@ int acpi_get_rc_resources(struct device *dev, const char *hid, u16 segment, struct resource *res); #endif +u32 pci_rebar_get_possible_sizes(struct pci_dev *pdev, int bar); +int pci_rebar_get_current_size(struct pci_dev *pdev, int bar); +int pci_rebar_set_size(struct pci_dev *pdev, int bar, int size); +static inline u64 pci_rebar_size_to_bytes(int size) +{ + return 1ULL << (size + 20); +} + #endif /* DRIVERS_PCI_H */ |