diff options
Diffstat (limited to 'include/linux/pci.h')
-rw-r--r-- | include/linux/pci.h | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index 4e4203a96312..8c230cbcbb48 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -49,7 +49,7 @@ | |||
49 | #include <linux/compiler.h> | 49 | #include <linux/compiler.h> |
50 | #include <linux/errno.h> | 50 | #include <linux/errno.h> |
51 | #include <linux/kobject.h> | 51 | #include <linux/kobject.h> |
52 | #include <asm/atomic.h> | 52 | #include <linux/atomic.h> |
53 | #include <linux/device.h> | 53 | #include <linux/device.h> |
54 | #include <linux/io.h> | 54 | #include <linux/io.h> |
55 | #include <linux/irqreturn.h> | 55 | #include <linux/irqreturn.h> |
@@ -251,7 +251,8 @@ struct pci_dev { | |||
251 | u8 revision; /* PCI revision, low byte of class word */ | 251 | u8 revision; /* PCI revision, low byte of class word */ |
252 | u8 hdr_type; /* PCI header type (`multi' flag masked out) */ | 252 | u8 hdr_type; /* PCI header type (`multi' flag masked out) */ |
253 | u8 pcie_cap; /* PCI-E capability offset */ | 253 | u8 pcie_cap; /* PCI-E capability offset */ |
254 | u8 pcie_type; /* PCI-E device/port type */ | 254 | u8 pcie_type:4; /* PCI-E device/port type */ |
255 | u8 pcie_mpss:3; /* PCI-E Max Payload Size Supported */ | ||
255 | u8 rom_base_reg; /* which config register controls the ROM */ | 256 | u8 rom_base_reg; /* which config register controls the ROM */ |
256 | u8 pin; /* which interrupt pin this device uses */ | 257 | u8 pin; /* which interrupt pin this device uses */ |
257 | 258 | ||
@@ -617,6 +618,16 @@ struct pci_driver { | |||
617 | /* these external functions are only available when PCI support is enabled */ | 618 | /* these external functions are only available when PCI support is enabled */ |
618 | #ifdef CONFIG_PCI | 619 | #ifdef CONFIG_PCI |
619 | 620 | ||
621 | extern void pcie_bus_configure_settings(struct pci_bus *bus, u8 smpss); | ||
622 | |||
623 | enum pcie_bus_config_types { | ||
624 | PCIE_BUS_PERFORMANCE, | ||
625 | PCIE_BUS_SAFE, | ||
626 | PCIE_BUS_PEER2PEER, | ||
627 | }; | ||
628 | |||
629 | extern enum pcie_bus_config_types pcie_bus_config; | ||
630 | |||
620 | extern struct bus_type pci_bus_type; | 631 | extern struct bus_type pci_bus_type; |
621 | 632 | ||
622 | /* Do NOT directly access these two variables, unless you are arch specific pci | 633 | /* Do NOT directly access these two variables, unless you are arch specific pci |
@@ -796,10 +807,13 @@ int pcix_get_mmrbc(struct pci_dev *dev); | |||
796 | int pcix_set_mmrbc(struct pci_dev *dev, int mmrbc); | 807 | int pcix_set_mmrbc(struct pci_dev *dev, int mmrbc); |
797 | int pcie_get_readrq(struct pci_dev *dev); | 808 | int pcie_get_readrq(struct pci_dev *dev); |
798 | int pcie_set_readrq(struct pci_dev *dev, int rq); | 809 | int pcie_set_readrq(struct pci_dev *dev, int rq); |
810 | int pcie_get_mps(struct pci_dev *dev); | ||
811 | int pcie_set_mps(struct pci_dev *dev, int mps); | ||
799 | int __pci_reset_function(struct pci_dev *dev); | 812 | int __pci_reset_function(struct pci_dev *dev); |
800 | int pci_reset_function(struct pci_dev *dev); | 813 | int pci_reset_function(struct pci_dev *dev); |
801 | void pci_update_resource(struct pci_dev *dev, int resno); | 814 | void pci_update_resource(struct pci_dev *dev, int resno); |
802 | int __must_check pci_assign_resource(struct pci_dev *dev, int i); | 815 | int __must_check pci_assign_resource(struct pci_dev *dev, int i); |
816 | int __must_check pci_reassign_resource(struct pci_dev *dev, int i, resource_size_t add_size, resource_size_t align); | ||
803 | int pci_select_bars(struct pci_dev *dev, unsigned long flags); | 817 | int pci_select_bars(struct pci_dev *dev, unsigned long flags); |
804 | 818 | ||
805 | /* ROM control related routines */ | 819 | /* ROM control related routines */ |
@@ -843,8 +857,8 @@ void pci_enable_ido(struct pci_dev *dev, unsigned long type); | |||
843 | void pci_disable_ido(struct pci_dev *dev, unsigned long type); | 857 | void pci_disable_ido(struct pci_dev *dev, unsigned long type); |
844 | 858 | ||
845 | enum pci_obff_signal_type { | 859 | enum pci_obff_signal_type { |
846 | PCI_EXP_OBFF_SIGNAL_L0, | 860 | PCI_EXP_OBFF_SIGNAL_L0 = 0, |
847 | PCI_EXP_OBFF_SIGNAL_ALWAYS, | 861 | PCI_EXP_OBFF_SIGNAL_ALWAYS = 1, |
848 | }; | 862 | }; |
849 | int pci_enable_obff(struct pci_dev *dev, enum pci_obff_signal_type); | 863 | int pci_enable_obff(struct pci_dev *dev, enum pci_obff_signal_type); |
850 | void pci_disable_obff(struct pci_dev *dev); | 864 | void pci_disable_obff(struct pci_dev *dev); |
@@ -879,7 +893,7 @@ void pdev_enable_device(struct pci_dev *); | |||
879 | void pdev_sort_resources(struct pci_dev *, struct resource_list *); | 893 | void pdev_sort_resources(struct pci_dev *, struct resource_list *); |
880 | int pci_enable_resources(struct pci_dev *, int mask); | 894 | int pci_enable_resources(struct pci_dev *, int mask); |
881 | void pci_fixup_irqs(u8 (*)(struct pci_dev *, u8 *), | 895 | void pci_fixup_irqs(u8 (*)(struct pci_dev *, u8 *), |
882 | int (*)(struct pci_dev *, u8, u8)); | 896 | int (*)(const struct pci_dev *, u8, u8)); |
883 | #define HAVE_PCI_REQ_REGIONS 2 | 897 | #define HAVE_PCI_REQ_REGIONS 2 |
884 | int __must_check pci_request_regions(struct pci_dev *, const char *); | 898 | int __must_check pci_request_regions(struct pci_dev *, const char *); |
885 | int __must_check pci_request_regions_exclusive(struct pci_dev *, const char *); | 899 | int __must_check pci_request_regions_exclusive(struct pci_dev *, const char *); |