staging/comedi/adl: Convert pci_table entries to PCI_DEVICE (if PCI_ANY_ID is used)
authorPeter Huewe <peterhuewe@gmx.de>
Sun, 6 Nov 2011 23:54:01 +0000 (00:54 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sun, 27 Nov 2011 02:39:37 +0000 (18:39 -0800)
This patch converts pci_table entries to use the PCI_DEVICE macro,
if .subvendor and .subdevice are set to PCI_ANY_ID,
and thus improves readablity.

Since the driver_data field isn't used anywhere we can also drop the
assignments for class, class_mask and driver_data.

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/comedi/drivers/adl_pci7230.c
drivers/staging/comedi/drivers/adl_pci7296.c
drivers/staging/comedi/drivers/adl_pci7432.c
drivers/staging/comedi/drivers/adl_pci8164.c
drivers/staging/comedi/drivers/adl_pci9111.c

index 72a7258b5b9279c8eef9eed8f8d0e64aed742bc5..20d570554fa49bec9649b93b8da274800de87080 100644 (file)
@@ -44,15 +44,7 @@ Configuration Options:
 #define PCI_DEVICE_ID_PCI7230 0x7230
 
 static DEFINE_PCI_DEVICE_TABLE(adl_pci7230_pci_table) = {
-       {
-               PCI_VENDOR_ID_ADLINK,
-               PCI_DEVICE_ID_PCI7230,
-               PCI_ANY_ID,
-               PCI_ANY_ID,
-               0,
-               0,
-               0
-       },
+       { PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI7230) },
        {0}
 };
 
index f28fe6bec050948985143f1d1a1720687cd27d20..9a2320537bdb25e553edc8a582972de7e4e9445b 100644 (file)
@@ -49,10 +49,8 @@ Configuration Options:
 #define PCI_DEVICE_ID_PCI7296 0x7296
 
 static DEFINE_PCI_DEVICE_TABLE(adl_pci7296_pci_table) = {
-       {
-       PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI7296, PCI_ANY_ID,
-                   PCI_ANY_ID, 0, 0, 0}, {
-       0}
+       { PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI7296) },
+       {0}
 };
 
 MODULE_DEVICE_TABLE(pci, adl_pci7296_pci_table);
index 262da7b29b281bb86a44480b53a3fb0927cc5749..86ee2197604130abb5e76cda73e1d10b4ffbaed4 100644 (file)
@@ -44,10 +44,8 @@ Configuration Options:
 #define PCI_DEVICE_ID_PCI7432 0x7432
 
 static DEFINE_PCI_DEVICE_TABLE(adl_pci7432_pci_table) = {
-       {
-       PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI7432, PCI_ANY_ID,
-                   PCI_ANY_ID, 0, 0, 0}, {
-       0}
+       { PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI7432) },
+       {0}
 };
 
 MODULE_DEVICE_TABLE(pci, adl_pci7432_pci_table);
index 767a594935c713d512940e2ac2eaf6437ceb06d7..3b83d65bc1bc69e3f1db115913b4f1069fd11123 100644 (file)
@@ -57,10 +57,8 @@ Configuration Options:
 #define PCI_DEVICE_ID_PCI8164 0x8164
 
 static DEFINE_PCI_DEVICE_TABLE(adl_pci8164_pci_table) = {
-       {
-       PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI8164, PCI_ANY_ID,
-                   PCI_ANY_ID, 0, 0, 0}, {
-       0}
+       { PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_PCI8164) },
+       {0}
 };
 
 MODULE_DEVICE_TABLE(pci, adl_pci8164_pci_table);
index fc48bae42ab7168b45aba9008482659c3d40a110..2a9bd88a4abb7a657cad0e31fce05fea4208ade3 100644 (file)
@@ -311,10 +311,8 @@ static const struct comedi_lrange pci9111_hr_ai_range = {
 };
 
 static DEFINE_PCI_DEVICE_TABLE(pci9111_pci_table) = {
-       { PCI_VENDOR_ID_ADLINK, PCI9111_HR_DEVICE_ID, PCI_ANY_ID, PCI_ANY_ID,
-         0, 0, 0 },
-       /* { PCI_VENDOR_ID_ADLINK, PCI9111_HG_DEVICE_ID, PCI_ANY_ID, PCI_ANY_ID,
-        *   0, 0, 0 }, */
+       { PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI9111_HR_DEVICE_ID) },
+       /* { PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI9111_HG_DEVICE_ID) }, */
        { 0 }
 };