[PATCH 1/2] serial: 8250_exar: Use PCI_DEVICE_DATA macro directly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The EXAR_DEVICE macro was converted to use PCI_DEVICE_DATA, having
this macro at doesn't add much, remove it.

Signed-off-by: Andrew Davis <afd@xxxxxx>
---
 drivers/tty/serial/8250/8250_exar.c | 65 +++++++++++++++--------------
 1 file changed, 34 insertions(+), 31 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_exar.c b/drivers/tty/serial/8250/8250_exar.c
index 64770c62bbec5..878d87f4202bd 100644
--- a/drivers/tty/serial/8250/8250_exar.c
+++ b/drivers/tty/serial/8250/8250_exar.c
@@ -818,8 +818,6 @@ static const struct exar8250_board pbn_exar_XR17V8358 = {
 		(kernel_ulong_t)&bd					\
 	}
 
-#define EXAR_DEVICE(vend, devid, bd) { PCI_DEVICE_DATA(vend, devid, &bd) }
-
 #define IBM_DEVICE(devid, sdevid, bd) {			\
 	PCI_DEVICE_SUB(					\
 		PCI_VENDOR_ID_EXAR,			\
@@ -830,13 +828,14 @@ static const struct exar8250_board pbn_exar_XR17V8358 = {
 	}
 
 static const struct pci_device_id exar_pci_tbl[] = {
-	EXAR_DEVICE(ACCESSIO, COM_2S, pbn_exar_XR17C15x),
-	EXAR_DEVICE(ACCESSIO, COM_4S, pbn_exar_XR17C15x),
-	EXAR_DEVICE(ACCESSIO, COM_8S, pbn_exar_XR17C15x),
-	EXAR_DEVICE(ACCESSIO, COM232_8, pbn_exar_XR17C15x),
-	EXAR_DEVICE(ACCESSIO, COM_2SM, pbn_exar_XR17C15x),
-	EXAR_DEVICE(ACCESSIO, COM_4SM, pbn_exar_XR17C15x),
-	EXAR_DEVICE(ACCESSIO, COM_8SM, pbn_exar_XR17C15x),
+	/* ACCES I/O Products */
+	{ PCI_DEVICE_DATA(ACCESSIO, COM_2S, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(ACCESSIO, COM_4S, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(ACCESSIO, COM_8S, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(ACCESSIO, COM232_8, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(ACCESSIO, COM_2SM, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(ACCESSIO, COM_4SM, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(ACCESSIO, COM_8SM, &pbn_exar_XR17C15x) },
 
 	CONNECT_DEVICE(XR17C152, UART_2_232, pbn_connect),
 	CONNECT_DEVICE(XR17C154, UART_4_232, pbn_connect),
@@ -854,30 +853,34 @@ static const struct pci_device_id exar_pci_tbl[] = {
 	IBM_DEVICE(XR17C152, SATURN_SERIAL_ONE_PORT, pbn_exar_ibm_saturn),
 
 	/* Exar Corp. XR17C15[248] Dual/Quad/Octal UART */
-	EXAR_DEVICE(EXAR, XR17C152, pbn_exar_XR17C15x),
-	EXAR_DEVICE(EXAR, XR17C154, pbn_exar_XR17C15x),
-	EXAR_DEVICE(EXAR, XR17C158, pbn_exar_XR17C15x),
+	{ PCI_DEVICE_DATA(EXAR, XR17C152, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(EXAR, XR17C154, &pbn_exar_XR17C15x) },
+	{ PCI_DEVICE_DATA(EXAR, XR17C158, &pbn_exar_XR17C15x) },
 
 	/* Exar Corp. XR17V[48]35[248] Dual/Quad/Octal/Hexa PCIe UARTs */
-	EXAR_DEVICE(EXAR, XR17V352, pbn_exar_XR17V35x),
-	EXAR_DEVICE(EXAR, XR17V354, pbn_exar_XR17V35x),
-	EXAR_DEVICE(EXAR, XR17V358, pbn_exar_XR17V35x),
-	EXAR_DEVICE(EXAR, XR17V4358, pbn_exar_XR17V4358),
-	EXAR_DEVICE(EXAR, XR17V8358, pbn_exar_XR17V8358),
-	EXAR_DEVICE(COMMTECH, 4222PCIE, pbn_fastcom35x_2),
-	EXAR_DEVICE(COMMTECH, 4224PCIE, pbn_fastcom35x_4),
-	EXAR_DEVICE(COMMTECH, 4228PCIE, pbn_fastcom35x_8),
-
-	EXAR_DEVICE(COMMTECH, 4222PCI335, pbn_fastcom335_2),
-	EXAR_DEVICE(COMMTECH, 4224PCI335, pbn_fastcom335_4),
-	EXAR_DEVICE(COMMTECH, 2324PCI335, pbn_fastcom335_4),
-	EXAR_DEVICE(COMMTECH, 2328PCI335, pbn_fastcom335_8),
-
-	EXAR_DEVICE(SEALEVEL, 710xC, pbn_exar_XR17V35x),
-	EXAR_DEVICE(SEALEVEL, 720xC, pbn_exar_XR17V35x),
-	EXAR_DEVICE(SEALEVEL, 740xC, pbn_exar_XR17V35x),
-	EXAR_DEVICE(SEALEVEL, 780xC, pbn_exar_XR17V35x),
-	EXAR_DEVICE(SEALEVEL, 716xC, pbn_exar_XR17V35x),
+	{ PCI_DEVICE_DATA(EXAR, XR17V352, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(EXAR, XR17V354, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(EXAR, XR17V358, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(EXAR, XR17V4358, &pbn_exar_XR17V4358) },
+	{ PCI_DEVICE_DATA(EXAR, XR17V8358, &pbn_exar_XR17V8358) },
+
+	/* Commtech PCIe cards */
+	{ PCI_DEVICE_DATA(COMMTECH, 4222PCIE, &pbn_fastcom35x_2) },
+	{ PCI_DEVICE_DATA(COMMTECH, 4224PCIE, &pbn_fastcom35x_4) },
+	{ PCI_DEVICE_DATA(COMMTECH, 4228PCIE, &pbn_fastcom35x_8) },
+
+	/* Commtech PCI cards */
+	{ PCI_DEVICE_DATA(COMMTECH, 4222PCI335, &pbn_fastcom335_2) },
+	{ PCI_DEVICE_DATA(COMMTECH, 4224PCI335, &pbn_fastcom335_4) },
+	{ PCI_DEVICE_DATA(COMMTECH, 2324PCI335, &pbn_fastcom335_4) },
+	{ PCI_DEVICE_DATA(COMMTECH, 2328PCI335, &pbn_fastcom335_8) },
+
+	/* Sealevel 7xxxC serial cards */
+	{ PCI_DEVICE_DATA(SEALEVEL, 710xC, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(SEALEVEL, 720xC, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(SEALEVEL, 740xC, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(SEALEVEL, 780xC, &pbn_exar_XR17V35x) },
+	{ PCI_DEVICE_DATA(SEALEVEL, 716xC, &pbn_exar_XR17V35x) },
 	{ 0, }
 };
 MODULE_DEVICE_TABLE(pci, exar_pci_tbl);
-- 
2.39.2




[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux