diff options
Diffstat (limited to 'include/linux/pci.h')
-rw-r--r-- | include/linux/pci.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index 5d2281f661f7..0dd93bb62fbe 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -109,6 +109,14 @@ enum pcie_reset_state { | |||
109 | pcie_hot_reset = (__force pcie_reset_state_t) 3 | 109 | pcie_hot_reset = (__force pcie_reset_state_t) 3 |
110 | }; | 110 | }; |
111 | 111 | ||
112 | typedef unsigned short __bitwise pci_dev_flags_t; | ||
113 | enum pci_dev_flags { | ||
114 | /* INTX_DISABLE in PCI_COMMAND register disables MSI | ||
115 | * generation too. | ||
116 | */ | ||
117 | PCI_DEV_FLAGS_MSI_INTX_DISABLE_BUG = (__force pci_dev_flags_t) 1, | ||
118 | }; | ||
119 | |||
112 | typedef unsigned short __bitwise pci_bus_flags_t; | 120 | typedef unsigned short __bitwise pci_bus_flags_t; |
113 | enum pci_bus_flags { | 121 | enum pci_bus_flags { |
114 | PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, | 122 | PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, |
@@ -185,6 +193,7 @@ struct pci_dev { | |||
185 | unsigned int msix_enabled:1; | 193 | unsigned int msix_enabled:1; |
186 | unsigned int is_managed:1; | 194 | unsigned int is_managed:1; |
187 | unsigned int is_pcie:1; | 195 | unsigned int is_pcie:1; |
196 | pci_dev_flags_t dev_flags; | ||
188 | atomic_t enable_cnt; /* pci_enable_device has been called */ | 197 | atomic_t enable_cnt; /* pci_enable_device has been called */ |
189 | 198 | ||
190 | u32 saved_config_space[16]; /* config space saved at suspend time */ | 199 | u32 saved_config_space[16]; /* config space saved at suspend time */ |
@@ -479,8 +488,11 @@ extern void pci_sort_breadthfirst(void); | |||
479 | 488 | ||
480 | /* Generic PCI functions exported to card drivers */ | 489 | /* Generic PCI functions exported to card drivers */ |
481 | 490 | ||
491 | #ifdef CONFIG_PCI_LEGACY | ||
482 | struct pci_dev __deprecated *pci_find_device (unsigned int vendor, unsigned int device, const struct pci_dev *from); | 492 | struct pci_dev __deprecated *pci_find_device (unsigned int vendor, unsigned int device, const struct pci_dev *from); |
483 | struct pci_dev __deprecated *pci_find_slot (unsigned int bus, unsigned int devfn); | 493 | struct pci_dev __deprecated *pci_find_slot (unsigned int bus, unsigned int devfn); |
494 | #endif /* CONFIG_PCI_LEGACY */ | ||
495 | |||
484 | int pci_find_capability (struct pci_dev *dev, int cap); | 496 | int pci_find_capability (struct pci_dev *dev, int cap); |
485 | int pci_find_next_capability (struct pci_dev *dev, u8 pos, int cap); | 497 | int pci_find_next_capability (struct pci_dev *dev, u8 pos, int cap); |
486 | int pci_find_ext_capability (struct pci_dev *dev, int cap); | 498 | int pci_find_ext_capability (struct pci_dev *dev, int cap); |
@@ -622,7 +634,6 @@ static inline int __must_check pci_register_driver(struct pci_driver *driver) | |||
622 | void pci_unregister_driver(struct pci_driver *); | 634 | void pci_unregister_driver(struct pci_driver *); |
623 | void pci_remove_behind_bridge(struct pci_dev *); | 635 | void pci_remove_behind_bridge(struct pci_dev *); |
624 | struct pci_driver *pci_dev_driver(const struct pci_dev *); | 636 | struct pci_driver *pci_dev_driver(const struct pci_dev *); |
625 | const struct pci_device_id *pci_match_device(struct pci_driver *drv, struct pci_dev *dev); | ||
626 | const struct pci_device_id *pci_match_id(const struct pci_device_id *ids, struct pci_dev *dev); | 637 | const struct pci_device_id *pci_match_id(const struct pci_device_id *ids, struct pci_dev *dev); |
627 | int pci_scan_bridge(struct pci_bus *bus, struct pci_dev * dev, int max, int pass); | 638 | int pci_scan_bridge(struct pci_bus *bus, struct pci_dev * dev, int max, int pass); |
628 | 639 | ||
@@ -751,7 +762,6 @@ static inline void pci_unregister_driver(struct pci_driver *drv) { } | |||
751 | static inline int pci_find_capability (struct pci_dev *dev, int cap) {return 0; } | 762 | static inline int pci_find_capability (struct pci_dev *dev, int cap) {return 0; } |
752 | static inline int pci_find_next_capability (struct pci_dev *dev, u8 post, int cap) { return 0; } | 763 | static inline int pci_find_next_capability (struct pci_dev *dev, u8 post, int cap) { return 0; } |
753 | static inline int pci_find_ext_capability (struct pci_dev *dev, int cap) {return 0; } | 764 | static inline int pci_find_ext_capability (struct pci_dev *dev, int cap) {return 0; } |
754 | static inline const struct pci_device_id *pci_match_device(const struct pci_device_id *ids, const struct pci_dev *dev) { return NULL; } | ||
755 | 765 | ||
756 | /* Power management related routines */ | 766 | /* Power management related routines */ |
757 | static inline int pci_save_state(struct pci_dev *dev) { return 0; } | 767 | static inline int pci_save_state(struct pci_dev *dev) { return 0; } |