1 // SPDX-License-Identifier: GPL-2.0
3 * Probe module for 8250/16550-type Exar chips PCI serial ports.
5 * Based on drivers/tty/serial/8250/8250_pci.c,
7 * Copyright (C) 2017 Sudip Mukherjee, All Rights Reserved.
9 #include <linux/acpi.h>
10 #include <linux/dmi.h>
12 #include <linux/kernel.h>
13 #include <linux/module.h>
14 #include <linux/pci.h>
15 #include <linux/property.h>
16 #include <linux/serial_core.h>
17 #include <linux/serial_reg.h>
18 #include <linux/slab.h>
19 #include <linux/string.h>
20 #include <linux/tty.h>
21 #include <linux/8250_pci.h>
23 #include <asm/byteorder.h>
27 #define PCI_DEVICE_ID_COMMTECH_4224PCI335 0x0002
28 #define PCI_DEVICE_ID_COMMTECH_4222PCI335 0x0004
29 #define PCI_DEVICE_ID_COMMTECH_2324PCI335 0x000a
30 #define PCI_DEVICE_ID_COMMTECH_2328PCI335 0x000b
31 #define PCI_DEVICE_ID_COMMTECH_4224PCIE 0x0020
32 #define PCI_DEVICE_ID_COMMTECH_4228PCIE 0x0021
33 #define PCI_DEVICE_ID_COMMTECH_4222PCIE 0x0022
34 #define PCI_DEVICE_ID_EXAR_XR17V4358 0x4358
35 #define PCI_DEVICE_ID_EXAR_XR17V8358 0x8358
37 #define UART_EXAR_INT0 0x80
38 #define UART_EXAR_8XMODE 0x88 /* 8X sampling rate select */
40 #define UART_EXAR_FCTR 0x08 /* Feature Control Register */
41 #define UART_FCTR_EXAR_IRDA 0x10 /* IrDa data encode select */
42 #define UART_FCTR_EXAR_485 0x20 /* Auto 485 half duplex dir ctl */
43 #define UART_FCTR_EXAR_TRGA 0x00 /* FIFO trigger table A */
44 #define UART_FCTR_EXAR_TRGB 0x60 /* FIFO trigger table B */
45 #define UART_FCTR_EXAR_TRGC 0x80 /* FIFO trigger table C */
46 #define UART_FCTR_EXAR_TRGD 0xc0 /* FIFO trigger table D programmable */
48 #define UART_EXAR_TXTRG 0x0a /* Tx FIFO trigger level write-only */
49 #define UART_EXAR_RXTRG 0x0b /* Rx FIFO trigger level write-only */
51 #define UART_EXAR_MPIOINT_7_0 0x8f /* MPIOINT[7:0] */
52 #define UART_EXAR_MPIOLVL_7_0 0x90 /* MPIOLVL[7:0] */
53 #define UART_EXAR_MPIO3T_7_0 0x91 /* MPIO3T[7:0] */
54 #define UART_EXAR_MPIOINV_7_0 0x92 /* MPIOINV[7:0] */
55 #define UART_EXAR_MPIOSEL_7_0 0x93 /* MPIOSEL[7:0] */
56 #define UART_EXAR_MPIOOD_7_0 0x94 /* MPIOOD[7:0] */
57 #define UART_EXAR_MPIOINT_15_8 0x95 /* MPIOINT[15:8] */
58 #define UART_EXAR_MPIOLVL_15_8 0x96 /* MPIOLVL[15:8] */
59 #define UART_EXAR_MPIO3T_15_8 0x97 /* MPIO3T[15:8] */
60 #define UART_EXAR_MPIOINV_15_8 0x98 /* MPIOINV[15:8] */
61 #define UART_EXAR_MPIOSEL_15_8 0x99 /* MPIOSEL[15:8] */
62 #define UART_EXAR_MPIOOD_15_8 0x9a /* MPIOOD[15:8] */
64 #define UART_EXAR_RS485_DLY(x) ((x) << 4)
67 * IOT2040 MPIO wiring semantics:
85 /* IOT2040 MPIOs 0..7 */
86 #define IOT2040_UART_MODE_RS232 0x01
87 #define IOT2040_UART_MODE_RS485 0x02
88 #define IOT2040_UART_MODE_RS422 0x03
89 #define IOT2040_UART_TERMINATE_BUS 0x04
91 #define IOT2040_UART1_MASK 0x0f
92 #define IOT2040_UART2_SHIFT 4
94 #define IOT2040_UARTS_DEFAULT_MODE 0x11 /* both RS232 */
95 #define IOT2040_UARTS_GPIO_LO_MODE 0x88 /* reserved pins as input */
97 /* IOT2040 MPIOs 8..15 */
98 #define IOT2040_UARTS_ENABLE 0x03
99 #define IOT2040_UARTS_GPIO_HI_MODE 0xF8 /* enable & LED as outputs */
103 struct exar8250_platform
{
104 int (*rs485_config
)(struct uart_port
*, struct serial_rs485
*);
105 int (*register_gpio
)(struct pci_dev
*, struct uart_8250_port
*);
109 * struct exar8250_board - board information
110 * @num_ports: number of serial ports
111 * @reg_shift: describes UART register mapping in PCI memory
112 * @setup: quirk run at ->probe() stage
113 * @exit: quirk run at ->remove() stage
115 struct exar8250_board
{
116 unsigned int num_ports
;
117 unsigned int reg_shift
;
118 int (*setup
)(struct exar8250
*, struct pci_dev
*,
119 struct uart_8250_port
*, int);
120 void (*exit
)(struct pci_dev
*pcidev
);
125 struct exar8250_board
*board
;
130 static int default_setup(struct exar8250
*priv
, struct pci_dev
*pcidev
,
131 int idx
, unsigned int offset
,
132 struct uart_8250_port
*port
)
134 const struct exar8250_board
*board
= priv
->board
;
135 unsigned int bar
= 0;
137 port
->port
.iotype
= UPIO_MEM
;
138 port
->port
.mapbase
= pci_resource_start(pcidev
, bar
) + offset
;
139 port
->port
.membase
= priv
->virt
+ offset
;
140 port
->port
.regshift
= board
->reg_shift
;
146 pci_fastcom335_setup(struct exar8250
*priv
, struct pci_dev
*pcidev
,
147 struct uart_8250_port
*port
, int idx
)
149 unsigned int offset
= idx
* 0x200;
150 unsigned int baud
= 1843200;
154 port
->port
.uartclk
= baud
* 16;
156 err
= default_setup(priv
, pcidev
, idx
, offset
, port
);
160 p
= port
->port
.membase
;
162 writeb(0x00, p
+ UART_EXAR_8XMODE
);
163 writeb(UART_FCTR_EXAR_TRGD
, p
+ UART_EXAR_FCTR
);
164 writeb(32, p
+ UART_EXAR_TXTRG
);
165 writeb(32, p
+ UART_EXAR_RXTRG
);
168 * Setup Multipurpose Input/Output pins.
171 switch (pcidev
->device
) {
172 case PCI_DEVICE_ID_COMMTECH_4222PCI335
:
173 case PCI_DEVICE_ID_COMMTECH_4224PCI335
:
174 writeb(0x78, p
+ UART_EXAR_MPIOLVL_7_0
);
175 writeb(0x00, p
+ UART_EXAR_MPIOINV_7_0
);
176 writeb(0x00, p
+ UART_EXAR_MPIOSEL_7_0
);
178 case PCI_DEVICE_ID_COMMTECH_2324PCI335
:
179 case PCI_DEVICE_ID_COMMTECH_2328PCI335
:
180 writeb(0x00, p
+ UART_EXAR_MPIOLVL_7_0
);
181 writeb(0xc0, p
+ UART_EXAR_MPIOINV_7_0
);
182 writeb(0xc0, p
+ UART_EXAR_MPIOSEL_7_0
);
185 writeb(0x00, p
+ UART_EXAR_MPIOINT_7_0
);
186 writeb(0x00, p
+ UART_EXAR_MPIO3T_7_0
);
187 writeb(0x00, p
+ UART_EXAR_MPIOOD_7_0
);
194 pci_connect_tech_setup(struct exar8250
*priv
, struct pci_dev
*pcidev
,
195 struct uart_8250_port
*port
, int idx
)
197 unsigned int offset
= idx
* 0x200;
198 unsigned int baud
= 1843200;
200 port
->port
.uartclk
= baud
* 16;
201 return default_setup(priv
, pcidev
, idx
, offset
, port
);
205 pci_xr17c154_setup(struct exar8250
*priv
, struct pci_dev
*pcidev
,
206 struct uart_8250_port
*port
, int idx
)
208 unsigned int offset
= idx
* 0x200;
209 unsigned int baud
= 921600;
211 port
->port
.uartclk
= baud
* 16;
212 return default_setup(priv
, pcidev
, idx
, offset
, port
);
215 static void setup_gpio(struct pci_dev
*pcidev
, u8 __iomem
*p
)
218 * The Commtech adapters required the MPIOs to be driven low. The Exar
219 * devices will export them as GPIOs, so we pre-configure them safely
222 u8 dir
= pcidev
->vendor
== PCI_VENDOR_ID_EXAR
? 0xff : 0x00;
224 writeb(0x00, p
+ UART_EXAR_MPIOINT_7_0
);
225 writeb(0x00, p
+ UART_EXAR_MPIOLVL_7_0
);
226 writeb(0x00, p
+ UART_EXAR_MPIO3T_7_0
);
227 writeb(0x00, p
+ UART_EXAR_MPIOINV_7_0
);
228 writeb(dir
, p
+ UART_EXAR_MPIOSEL_7_0
);
229 writeb(0x00, p
+ UART_EXAR_MPIOOD_7_0
);
230 writeb(0x00, p
+ UART_EXAR_MPIOINT_15_8
);
231 writeb(0x00, p
+ UART_EXAR_MPIOLVL_15_8
);
232 writeb(0x00, p
+ UART_EXAR_MPIO3T_15_8
);
233 writeb(0x00, p
+ UART_EXAR_MPIOINV_15_8
);
234 writeb(dir
, p
+ UART_EXAR_MPIOSEL_15_8
);
235 writeb(0x00, p
+ UART_EXAR_MPIOOD_15_8
);
239 __xr17v35x_register_gpio(struct pci_dev
*pcidev
,
240 const struct property_entry
*properties
)
242 struct platform_device
*pdev
;
244 pdev
= platform_device_alloc("gpio_exar", PLATFORM_DEVID_AUTO
);
248 pdev
->dev
.parent
= &pcidev
->dev
;
249 ACPI_COMPANION_SET(&pdev
->dev
, ACPI_COMPANION(&pcidev
->dev
));
251 if (platform_device_add_properties(pdev
, properties
) < 0 ||
252 platform_device_add(pdev
) < 0) {
253 platform_device_put(pdev
);
260 static const struct property_entry exar_gpio_properties
[] = {
261 PROPERTY_ENTRY_U32("exar,first-pin", 0),
262 PROPERTY_ENTRY_U32("ngpios", 16),
266 static int xr17v35x_register_gpio(struct pci_dev
*pcidev
,
267 struct uart_8250_port
*port
)
269 if (pcidev
->vendor
== PCI_VENDOR_ID_EXAR
)
270 port
->port
.private_data
=
271 __xr17v35x_register_gpio(pcidev
, exar_gpio_properties
);
276 static int generic_rs485_config(struct uart_port
*port
,
277 struct serial_rs485
*rs485
)
279 bool is_rs485
= !!(rs485
->flags
& SER_RS485_ENABLED
);
280 u8 __iomem
*p
= port
->membase
;
283 value
= readb(p
+ UART_EXAR_FCTR
);
285 value
|= UART_FCTR_EXAR_485
;
287 value
&= ~UART_FCTR_EXAR_485
;
289 writeb(value
, p
+ UART_EXAR_FCTR
);
292 writeb(UART_EXAR_RS485_DLY(4), p
+ UART_MSR
);
294 port
->rs485
= *rs485
;
299 static const struct exar8250_platform exar8250_default_platform
= {
300 .register_gpio
= xr17v35x_register_gpio
,
301 .rs485_config
= generic_rs485_config
,
304 static int iot2040_rs485_config(struct uart_port
*port
,
305 struct serial_rs485
*rs485
)
307 bool is_rs485
= !!(rs485
->flags
& SER_RS485_ENABLED
);
308 u8 __iomem
*p
= port
->membase
;
309 u8 mask
= IOT2040_UART1_MASK
;
313 if (rs485
->flags
& SER_RS485_RX_DURING_TX
)
314 mode
= IOT2040_UART_MODE_RS422
;
316 mode
= IOT2040_UART_MODE_RS485
;
318 if (rs485
->flags
& SER_RS485_TERMINATE_BUS
)
319 mode
|= IOT2040_UART_TERMINATE_BUS
;
321 mode
= IOT2040_UART_MODE_RS232
;
324 if (port
->line
== 3) {
325 mask
<<= IOT2040_UART2_SHIFT
;
326 mode
<<= IOT2040_UART2_SHIFT
;
329 value
= readb(p
+ UART_EXAR_MPIOLVL_7_0
);
332 writeb(value
, p
+ UART_EXAR_MPIOLVL_7_0
);
334 return generic_rs485_config(port
, rs485
);
337 static const struct property_entry iot2040_gpio_properties
[] = {
338 PROPERTY_ENTRY_U32("exar,first-pin", 10),
339 PROPERTY_ENTRY_U32("ngpios", 1),
343 static int iot2040_register_gpio(struct pci_dev
*pcidev
,
344 struct uart_8250_port
*port
)
346 u8 __iomem
*p
= port
->port
.membase
;
348 writeb(IOT2040_UARTS_DEFAULT_MODE
, p
+ UART_EXAR_MPIOLVL_7_0
);
349 writeb(IOT2040_UARTS_GPIO_LO_MODE
, p
+ UART_EXAR_MPIOSEL_7_0
);
350 writeb(IOT2040_UARTS_ENABLE
, p
+ UART_EXAR_MPIOLVL_15_8
);
351 writeb(IOT2040_UARTS_GPIO_HI_MODE
, p
+ UART_EXAR_MPIOSEL_15_8
);
353 port
->port
.private_data
=
354 __xr17v35x_register_gpio(pcidev
, iot2040_gpio_properties
);
359 static const struct exar8250_platform iot2040_platform
= {
360 .rs485_config
= iot2040_rs485_config
,
361 .register_gpio
= iot2040_register_gpio
,
365 * For SIMATIC IOT2000, only IOT2040 and its variants have the Exar device,
366 * IOT2020 doesn't have. Therefore it is sufficient to match on the common
367 * board name after the device was found.
369 static const struct dmi_system_id exar_platforms
[] = {
372 DMI_EXACT_MATCH(DMI_BOARD_NAME
, "SIMATIC IOT2000"),
374 .driver_data
= (void *)&iot2040_platform
,
380 pci_xr17v35x_setup(struct exar8250
*priv
, struct pci_dev
*pcidev
,
381 struct uart_8250_port
*port
, int idx
)
383 const struct exar8250_platform
*platform
;
384 const struct dmi_system_id
*dmi_match
;
385 unsigned int offset
= idx
* 0x400;
386 unsigned int baud
= 7812500;
390 dmi_match
= dmi_first_match(exar_platforms
);
392 platform
= dmi_match
->driver_data
;
394 platform
= &exar8250_default_platform
;
396 port
->port
.uartclk
= baud
* 16;
397 port
->port
.rs485_config
= platform
->rs485_config
;
400 * Setup the UART clock for the devices on expansion slot to
401 * half the clock speed of the main chip (which is 125MHz)
404 port
->port
.uartclk
/= 2;
406 ret
= default_setup(priv
, pcidev
, idx
, offset
, port
);
410 p
= port
->port
.membase
;
412 writeb(0x00, p
+ UART_EXAR_8XMODE
);
413 writeb(UART_FCTR_EXAR_TRGD
, p
+ UART_EXAR_FCTR
);
414 writeb(128, p
+ UART_EXAR_TXTRG
);
415 writeb(128, p
+ UART_EXAR_RXTRG
);
418 /* Setup Multipurpose Input/Output pins. */
419 setup_gpio(pcidev
, p
);
421 ret
= platform
->register_gpio(pcidev
, port
);
427 static void pci_xr17v35x_exit(struct pci_dev
*pcidev
)
429 struct exar8250
*priv
= pci_get_drvdata(pcidev
);
430 struct uart_8250_port
*port
= serial8250_get_port(priv
->line
[0]);
431 struct platform_device
*pdev
= port
->port
.private_data
;
433 platform_device_unregister(pdev
);
434 port
->port
.private_data
= NULL
;
438 * These Exar UARTs have an extra interrupt indicator that could fire for a
439 * few interrupts that are not presented/cleared through IIR. One of which is
440 * a wakeup interrupt when coming out of sleep. These interrupts are only
441 * cleared by reading global INT0 or INT1 registers as interrupts are
442 * associated with channel 0. The INT[3:0] registers _are_ accessible from each
443 * channel's address space, but for the sake of bus efficiency we register a
444 * dedicated handler at the PCI device level to handle them.
446 static irqreturn_t
exar_misc_handler(int irq
, void *data
)
448 struct exar8250
*priv
= data
;
450 /* Clear all PCI interrupts by reading INT0. No effect on IIR */
451 readb(priv
->virt
+ UART_EXAR_INT0
);
453 /* Clear INT0 for Expansion Interface slave ports, too */
454 if (priv
->board
->num_ports
> 8)
455 readb(priv
->virt
+ 0x2000 + UART_EXAR_INT0
);
461 exar_pci_probe(struct pci_dev
*pcidev
, const struct pci_device_id
*ent
)
463 unsigned int nr_ports
, i
, bar
= 0, maxnr
;
464 struct exar8250_board
*board
;
465 struct uart_8250_port uart
;
466 struct exar8250
*priv
;
469 board
= (struct exar8250_board
*)ent
->driver_data
;
473 rc
= pcim_enable_device(pcidev
);
477 maxnr
= pci_resource_len(pcidev
, bar
) >> (board
->reg_shift
+ 3);
479 nr_ports
= board
->num_ports
? board
->num_ports
: pcidev
->device
& 0x0f;
481 priv
= devm_kzalloc(&pcidev
->dev
, sizeof(*priv
) +
482 sizeof(unsigned int) * nr_ports
,
488 priv
->virt
= pcim_iomap(pcidev
, bar
, 0);
492 pci_set_master(pcidev
);
494 rc
= pci_alloc_irq_vectors(pcidev
, 1, 1, PCI_IRQ_ALL_TYPES
);
498 memset(&uart
, 0, sizeof(uart
));
499 uart
.port
.flags
= UPF_SKIP_TEST
| UPF_BOOT_AUTOCONF
| UPF_SHARE_IRQ
501 uart
.port
.irq
= pci_irq_vector(pcidev
, 0);
502 uart
.port
.dev
= &pcidev
->dev
;
504 rc
= devm_request_irq(&pcidev
->dev
, uart
.port
.irq
, exar_misc_handler
,
505 IRQF_SHARED
, "exar_uart", priv
);
509 for (i
= 0; i
< nr_ports
&& i
< maxnr
; i
++) {
510 rc
= board
->setup(priv
, pcidev
, &uart
, i
);
512 dev_err(&pcidev
->dev
, "Failed to setup port %u\n", i
);
516 dev_dbg(&pcidev
->dev
, "Setup PCI port: port %lx, irq %d, type %d\n",
517 uart
.port
.iobase
, uart
.port
.irq
, uart
.port
.iotype
);
519 priv
->line
[i
] = serial8250_register_8250_port(&uart
);
520 if (priv
->line
[i
] < 0) {
521 dev_err(&pcidev
->dev
,
522 "Couldn't register serial port %lx, irq %d, type %d, error %d\n",
523 uart
.port
.iobase
, uart
.port
.irq
,
524 uart
.port
.iotype
, priv
->line
[i
]);
529 pci_set_drvdata(pcidev
, priv
);
533 static void exar_pci_remove(struct pci_dev
*pcidev
)
535 struct exar8250
*priv
= pci_get_drvdata(pcidev
);
538 for (i
= 0; i
< priv
->nr
; i
++)
539 serial8250_unregister_port(priv
->line
[i
]);
541 if (priv
->board
->exit
)
542 priv
->board
->exit(pcidev
);
545 static int __maybe_unused
exar_suspend(struct device
*dev
)
547 struct pci_dev
*pcidev
= to_pci_dev(dev
);
548 struct exar8250
*priv
= pci_get_drvdata(pcidev
);
551 for (i
= 0; i
< priv
->nr
; i
++)
552 if (priv
->line
[i
] >= 0)
553 serial8250_suspend_port(priv
->line
[i
]);
555 /* Ensure that every init quirk is properly torn down */
556 if (priv
->board
->exit
)
557 priv
->board
->exit(pcidev
);
562 static int __maybe_unused
exar_resume(struct device
*dev
)
564 struct pci_dev
*pcidev
= to_pci_dev(dev
);
565 struct exar8250
*priv
= pci_get_drvdata(pcidev
);
568 for (i
= 0; i
< priv
->nr
; i
++)
569 if (priv
->line
[i
] >= 0)
570 serial8250_resume_port(priv
->line
[i
]);
575 static SIMPLE_DEV_PM_OPS(exar_pci_pm
, exar_suspend
, exar_resume
);
577 static const struct exar8250_board pbn_fastcom335_2
= {
579 .setup
= pci_fastcom335_setup
,
582 static const struct exar8250_board pbn_fastcom335_4
= {
584 .setup
= pci_fastcom335_setup
,
587 static const struct exar8250_board pbn_fastcom335_8
= {
589 .setup
= pci_fastcom335_setup
,
592 static const struct exar8250_board pbn_connect
= {
593 .setup
= pci_connect_tech_setup
,
596 static const struct exar8250_board pbn_exar_ibm_saturn
= {
598 .setup
= pci_xr17c154_setup
,
601 static const struct exar8250_board pbn_exar_XR17C15x
= {
602 .setup
= pci_xr17c154_setup
,
605 static const struct exar8250_board pbn_exar_XR17V35x
= {
606 .setup
= pci_xr17v35x_setup
,
607 .exit
= pci_xr17v35x_exit
,
610 static const struct exar8250_board pbn_exar_XR17V4358
= {
612 .setup
= pci_xr17v35x_setup
,
613 .exit
= pci_xr17v35x_exit
,
616 static const struct exar8250_board pbn_exar_XR17V8358
= {
618 .setup
= pci_xr17v35x_setup
,
619 .exit
= pci_xr17v35x_exit
,
622 #define CONNECT_DEVICE(devid, sdevid, bd) { \
624 PCI_VENDOR_ID_EXAR, \
625 PCI_DEVICE_ID_EXAR_##devid, \
626 PCI_SUBVENDOR_ID_CONNECT_TECH, \
627 PCI_SUBDEVICE_ID_CONNECT_TECH_PCI_##sdevid), 0, 0, \
628 (kernel_ulong_t)&bd \
631 #define EXAR_DEVICE(vend, devid, bd) { \
632 PCI_VDEVICE(vend, PCI_DEVICE_ID_##devid), (kernel_ulong_t)&bd \
635 #define IBM_DEVICE(devid, sdevid, bd) { \
637 PCI_VENDOR_ID_EXAR, \
638 PCI_DEVICE_ID_EXAR_##devid, \
640 PCI_SUBDEVICE_ID_IBM_##sdevid), 0, 0, \
641 (kernel_ulong_t)&bd \
644 static const struct pci_device_id exar_pci_tbl
[] = {
645 CONNECT_DEVICE(XR17C152
, UART_2_232
, pbn_connect
),
646 CONNECT_DEVICE(XR17C154
, UART_4_232
, pbn_connect
),
647 CONNECT_DEVICE(XR17C158
, UART_8_232
, pbn_connect
),
648 CONNECT_DEVICE(XR17C152
, UART_1_1
, pbn_connect
),
649 CONNECT_DEVICE(XR17C154
, UART_2_2
, pbn_connect
),
650 CONNECT_DEVICE(XR17C158
, UART_4_4
, pbn_connect
),
651 CONNECT_DEVICE(XR17C152
, UART_2
, pbn_connect
),
652 CONNECT_DEVICE(XR17C154
, UART_4
, pbn_connect
),
653 CONNECT_DEVICE(XR17C158
, UART_8
, pbn_connect
),
654 CONNECT_DEVICE(XR17C152
, UART_2_485
, pbn_connect
),
655 CONNECT_DEVICE(XR17C154
, UART_4_485
, pbn_connect
),
656 CONNECT_DEVICE(XR17C158
, UART_8_485
, pbn_connect
),
658 IBM_DEVICE(XR17C152
, SATURN_SERIAL_ONE_PORT
, pbn_exar_ibm_saturn
),
660 /* Exar Corp. XR17C15[248] Dual/Quad/Octal UART */
661 EXAR_DEVICE(EXAR
, EXAR_XR17C152
, pbn_exar_XR17C15x
),
662 EXAR_DEVICE(EXAR
, EXAR_XR17C154
, pbn_exar_XR17C15x
),
663 EXAR_DEVICE(EXAR
, EXAR_XR17C158
, pbn_exar_XR17C15x
),
665 /* Exar Corp. XR17V[48]35[248] Dual/Quad/Octal/Hexa PCIe UARTs */
666 EXAR_DEVICE(EXAR
, EXAR_XR17V352
, pbn_exar_XR17V35x
),
667 EXAR_DEVICE(EXAR
, EXAR_XR17V354
, pbn_exar_XR17V35x
),
668 EXAR_DEVICE(EXAR
, EXAR_XR17V358
, pbn_exar_XR17V35x
),
669 EXAR_DEVICE(EXAR
, EXAR_XR17V4358
, pbn_exar_XR17V4358
),
670 EXAR_DEVICE(EXAR
, EXAR_XR17V8358
, pbn_exar_XR17V8358
),
671 EXAR_DEVICE(COMMTECH
, COMMTECH_4222PCIE
, pbn_exar_XR17V35x
),
672 EXAR_DEVICE(COMMTECH
, COMMTECH_4224PCIE
, pbn_exar_XR17V35x
),
673 EXAR_DEVICE(COMMTECH
, COMMTECH_4228PCIE
, pbn_exar_XR17V35x
),
675 EXAR_DEVICE(COMMTECH
, COMMTECH_4222PCI335
, pbn_fastcom335_2
),
676 EXAR_DEVICE(COMMTECH
, COMMTECH_4224PCI335
, pbn_fastcom335_4
),
677 EXAR_DEVICE(COMMTECH
, COMMTECH_2324PCI335
, pbn_fastcom335_4
),
678 EXAR_DEVICE(COMMTECH
, COMMTECH_2328PCI335
, pbn_fastcom335_8
),
681 MODULE_DEVICE_TABLE(pci
, exar_pci_tbl
);
683 static struct pci_driver exar_pci_driver
= {
684 .name
= "exar_serial",
685 .probe
= exar_pci_probe
,
686 .remove
= exar_pci_remove
,
690 .id_table
= exar_pci_tbl
,
692 module_pci_driver(exar_pci_driver
);
694 MODULE_LICENSE("GPL");
695 MODULE_DESCRIPTION("Exar Serial Driver");
696 MODULE_AUTHOR("Sudip Mukherjee <sudip.mukherjee@codethink.co.uk>");