diff options
author | Peter Oruba <peter.oruba@amd.com> | 2007-05-15 07:59:13 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-07-11 19:02:07 -0400 |
commit | d556ad4bbe75faf17b239e151a9f003322b2e851 (patch) | |
tree | 794e4f21a9c6e76328feccf313e4d268d3ec5146 /include | |
parent | e4585da22ad04a055cbb5c863a37aa8cc02eac89 (diff) |
PCI: add PCI-X/PCI-Express read control interfaces
This patch introduces an interface to read and write PCI-X / PCI-Express
maximum read byte count values from PCI config space. There is a second
function that returns the maximum _designed_ read byte count, which marks the
maximum value for a device, since some drivers try to set MMRBC to the
highest allowed value and rely on such a function.
Based on patch set by Stephen Hemminger <shemminger@linux-foundation.org>
Cc: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Peter Oruba <peter.oruba@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/pci.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index 086a0e5a6318..ac403d74a222 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -111,7 +111,8 @@ enum pcie_reset_state { | |||
111 | 111 | ||
112 | typedef unsigned short __bitwise pci_bus_flags_t; | 112 | typedef unsigned short __bitwise pci_bus_flags_t; |
113 | enum pci_bus_flags { | 113 | enum pci_bus_flags { |
114 | PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, | 114 | PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, |
115 | PCI_BUS_FLAGS_NO_MMRBC = (__force pci_bus_flags_t) 2, | ||
115 | }; | 116 | }; |
116 | 117 | ||
117 | struct pci_cap_saved_state { | 118 | struct pci_cap_saved_state { |
@@ -549,6 +550,10 @@ void pci_intx(struct pci_dev *dev, int enable); | |||
549 | void pci_msi_off(struct pci_dev *dev); | 550 | void pci_msi_off(struct pci_dev *dev); |
550 | int pci_set_dma_mask(struct pci_dev *dev, u64 mask); | 551 | int pci_set_dma_mask(struct pci_dev *dev, u64 mask); |
551 | int pci_set_consistent_dma_mask(struct pci_dev *dev, u64 mask); | 552 | int pci_set_consistent_dma_mask(struct pci_dev *dev, u64 mask); |
553 | int pcix_get_max_mmrbc(struct pci_dev *dev); | ||
554 | int pcix_get_mmrbc(struct pci_dev *dev); | ||
555 | int pcix_set_mmrbc(struct pci_dev *dev, int mmrbc); | ||
556 | int pcie_set_readrq(struct pci_dev *dev, int rq); | ||
552 | void pci_update_resource(struct pci_dev *dev, struct resource *res, int resno); | 557 | void pci_update_resource(struct pci_dev *dev, struct resource *res, int resno); |
553 | int __must_check pci_assign_resource(struct pci_dev *dev, int i); | 558 | int __must_check pci_assign_resource(struct pci_dev *dev, int i); |
554 | int __must_check pci_assign_resource_fixed(struct pci_dev *dev, int i); | 559 | int __must_check pci_assign_resource_fixed(struct pci_dev *dev, int i); |