diff options
Diffstat (limited to 'include/linux/pci.h')
-rw-r--r-- | include/linux/pci.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index b20ffb65300f..c1a2bc8e09de 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -396,6 +396,21 @@ struct pci_driver { | |||
396 | */ | 396 | */ |
397 | #define pci_module_init pci_register_driver | 397 | #define pci_module_init pci_register_driver |
398 | 398 | ||
399 | /** | ||
400 | * PCI_VDEVICE - macro used to describe a specific pci device in short form | ||
401 | * @vend: the vendor name | ||
402 | * @dev: the 16 bit PCI Device ID | ||
403 | * | ||
404 | * This macro is used to create a struct pci_device_id that matches a | ||
405 | * specific PCI device. The subvendor, and subdevice fields will be set | ||
406 | * to PCI_ANY_ID. The macro allows the next field to follow as the device | ||
407 | * private data. | ||
408 | */ | ||
409 | |||
410 | #define PCI_VDEVICE(vendor, device) \ | ||
411 | PCI_VENDOR_ID_##vendor, (device), \ | ||
412 | PCI_ANY_ID, PCI_ANY_ID, 0, 0 | ||
413 | |||
399 | /* these external functions are only available when PCI support is enabled */ | 414 | /* these external functions are only available when PCI support is enabled */ |
400 | #ifdef CONFIG_PCI | 415 | #ifdef CONFIG_PCI |
401 | 416 | ||
@@ -787,6 +802,7 @@ enum pci_fixup_pass { | |||
787 | pci_fixup_header, /* After reading configuration header */ | 802 | pci_fixup_header, /* After reading configuration header */ |
788 | pci_fixup_final, /* Final phase of device fixups */ | 803 | pci_fixup_final, /* Final phase of device fixups */ |
789 | pci_fixup_enable, /* pci_enable_device() time */ | 804 | pci_fixup_enable, /* pci_enable_device() time */ |
805 | pci_fixup_resume, /* pci_enable_device() time */ | ||
790 | }; | 806 | }; |
791 | 807 | ||
792 | /* Anonymous variables would be nice... */ | 808 | /* Anonymous variables would be nice... */ |
@@ -805,6 +821,9 @@ enum pci_fixup_pass { | |||
805 | #define DECLARE_PCI_FIXUP_ENABLE(vendor, device, hook) \ | 821 | #define DECLARE_PCI_FIXUP_ENABLE(vendor, device, hook) \ |
806 | DECLARE_PCI_FIXUP_SECTION(.pci_fixup_enable, \ | 822 | DECLARE_PCI_FIXUP_SECTION(.pci_fixup_enable, \ |
807 | vendor##device##hook, vendor, device, hook) | 823 | vendor##device##hook, vendor, device, hook) |
824 | #define DECLARE_PCI_FIXUP_RESUME(vendor, device, hook) \ | ||
825 | DECLARE_PCI_FIXUP_SECTION(.pci_fixup_resume, \ | ||
826 | resume##vendor##device##hook, vendor, device, hook) | ||
808 | 827 | ||
809 | 828 | ||
810 | void pci_fixup_device(enum pci_fixup_pass pass, struct pci_dev *dev); | 829 | void pci_fixup_device(enum pci_fixup_pass pass, struct pci_dev *dev); |