diff options
author | Ben Hutchings <ben@decadent.org.uk> | 2014-02-09 23:34:11 +0000 |
---|---|---|
committer | Ben Hutchings <ben@decadent.org.uk> | 2014-02-15 19:20:16 +0000 |
commit | ef0d53ff3d8cf6630d38f61f1a071740714be7af (patch) | |
tree | 05dd80ff3b58e86a4453027067160da97d032d0d | |
parent | 87ca19a6b005ebe848dedeecebf4ffe2bf714bcd (diff) |
pci: Add PCI_DEVICE_SUB() macro
This was added as part of commit 3d567e0e291c ('tg3: Set 10_100_ONLY
flag for additional 10/100 Mbps devices') upstream and is needed by
the following patch to ahci.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
-rw-r--r-- | include/linux/pci.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index 7cda65b5f798..fe76a74ae0b3 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -590,6 +590,20 @@ struct pci_driver { .subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID /** + * PCI_DEVICE_SUB - macro used to describe a specific pci device with subsystem + * @vend: the 16 bit PCI Vendor ID + * @dev: the 16 bit PCI Device ID + * @subvend: the 16 bit PCI Subvendor ID + * @subdev: the 16 bit PCI Subdevice ID + * + * This macro is used to create a struct pci_device_id that matches a + * specific device with subsystem information. + */ +#define PCI_DEVICE_SUB(vend, dev, subvend, subdev) \ + .vendor = (vend), .device = (dev), \ + .subvendor = (subvend), .subdevice = (subdev) + +/** * PCI_DEVICE_CLASS - macro used to describe a specific pci device class * @dev_class: the class, subclass, prog-if triple for this device * @dev_class_mask: the class mask for this device |