summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorMark Rustad <mark.d.rustad@intel.com>2014-03-31 14:58:39 -0700
committerBjorn Helgaas <bhelgaas@google.com>2014-04-24 17:25:16 -0600
commitc1309040967e200d3ea6415ae54cf6a69d7ad996 (patch)
tree386f3778bff0a55cc09db778d18852ce4f397bbb /include
parent7ee4910ab31c4b1fafb7e4f273cbe9340ac953aa (diff)
downloadlinux-c1309040967e200d3ea6415ae54cf6a69d7ad996.tar.bz2
PCI: Use designated initialization in PCI_VDEVICE
By using designated initialization in PCI_VDEVICE, like other similar macros, many "missing initializer" warnings that appear when compiling with W=2 can be silenced. Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Tested-by: Kavindya Deegala <kavindya.s.deegala@intel.com> Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/pci.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h
index aab57b4abe7f..a95aac7ad37f 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -680,8 +680,8 @@ struct pci_driver {
/**
* PCI_VDEVICE - macro used to describe a specific pci device in short form
- * @vendor: the vendor name
- * @device: the 16 bit PCI Device ID
+ * @vend: the vendor name
+ * @dev: the 16 bit PCI Device ID
*
* This macro is used to create a struct pci_device_id that matches a
* specific PCI device. The subvendor, and subdevice fields will be set
@@ -689,9 +689,9 @@ struct pci_driver {
* private data.
*/
-#define PCI_VDEVICE(vendor, device) \
- PCI_VENDOR_ID_##vendor, (device), \
- PCI_ANY_ID, PCI_ANY_ID, 0, 0
+#define PCI_VDEVICE(vend, dev) \
+ .vendor = PCI_VENDOR_ID_##vend, .device = (dev), \
+ .subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID, 0, 0
/* these external functions are only available when PCI support is enabled */
#ifdef CONFIG_PCI