parport_serial.c 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485
  1. /*
  2. * Support for common PCI multi-I/O cards (which is most of them)
  3. *
  4. * Copyright (C) 2001 Tim Waugh <twaugh@redhat.com>
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU General Public License
  8. * as published by the Free Software Foundation; either version
  9. * 2 of the License, or (at your option) any later version.
  10. *
  11. *
  12. * Multi-function PCI cards are supposed to present separate logical
  13. * devices on the bus. A common thing to do seems to be to just use
  14. * one logical device with lots of base address registers for both
  15. * parallel ports and serial ports. This driver is for dealing with
  16. * that.
  17. *
  18. */
  19. #include <linux/types.h>
  20. #include <linux/module.h>
  21. #include <linux/init.h>
  22. #include <linux/pci.h>
  23. #include <linux/parport.h>
  24. #include <linux/parport_pc.h>
  25. #include <linux/serial.h>
  26. #include <linux/serialP.h>
  27. #include <linux/list.h>
  28. #include <linux/8250_pci.h>
  29. #include <asm/serial.h>
  30. enum parport_pc_pci_cards {
  31. titan_110l = 0,
  32. titan_210l,
  33. netmos_9xx5_combo,
  34. avlab_1s1p,
  35. avlab_1s1p_650,
  36. avlab_1s1p_850,
  37. avlab_1s2p,
  38. avlab_1s2p_650,
  39. avlab_1s2p_850,
  40. avlab_2s1p,
  41. avlab_2s1p_650,
  42. avlab_2s1p_850,
  43. siig_1s1p_10x,
  44. siig_2s1p_10x,
  45. siig_2p1s_20x,
  46. siig_1s1p_20x,
  47. siig_2s1p_20x,
  48. };
  49. /* each element directly indexed from enum list, above */
  50. struct parport_pc_pci {
  51. int numports;
  52. struct { /* BAR (base address registers) numbers in the config
  53. space header */
  54. int lo;
  55. int hi; /* -1 if not there, >6 for offset-method (max
  56. BAR is 6) */
  57. } addr[4];
  58. /* If set, this is called immediately after pci_enable_device.
  59. * If it returns non-zero, no probing will take place and the
  60. * ports will not be used. */
  61. int (*preinit_hook) (struct pci_dev *pdev, struct parport_pc_pci *card,
  62. int autoirq, int autodma);
  63. /* If set, this is called after probing for ports. If 'failed'
  64. * is non-zero we couldn't use any of the ports. */
  65. void (*postinit_hook) (struct pci_dev *pdev,
  66. struct parport_pc_pci *card, int failed);
  67. };
  68. static int __devinit netmos_parallel_init(struct pci_dev *dev, struct parport_pc_pci *card, int autoirq, int autodma)
  69. {
  70. /*
  71. * Netmos uses the subdevice ID to indicate the number of parallel
  72. * and serial ports. The form is 0x00PS, where <P> is the number of
  73. * parallel ports and <S> is the number of serial ports.
  74. */
  75. card->numports = (dev->subsystem_device & 0xf0) >> 4;
  76. return 0;
  77. }
  78. static struct parport_pc_pci cards[] __devinitdata = {
  79. /* titan_110l */ { 1, { { 3, -1 }, } },
  80. /* titan_210l */ { 1, { { 3, -1 }, } },
  81. /* netmos_9xx5_combo */ { 1, { { 2, -1 }, }, netmos_parallel_init },
  82. /* avlab_1s1p */ { 1, { { 1, 2}, } },
  83. /* avlab_1s1p_650 */ { 1, { { 1, 2}, } },
  84. /* avlab_1s1p_850 */ { 1, { { 1, 2}, } },
  85. /* avlab_1s2p */ { 2, { { 1, 2}, { 3, 4 },} },
  86. /* avlab_1s2p_650 */ { 2, { { 1, 2}, { 3, 4 },} },
  87. /* avlab_1s2p_850 */ { 2, { { 1, 2}, { 3, 4 },} },
  88. /* avlab_2s1p */ { 1, { { 2, 3}, } },
  89. /* avlab_2s1p_650 */ { 1, { { 2, 3}, } },
  90. /* avlab_2s1p_850 */ { 1, { { 2, 3}, } },
  91. /* siig_1s1p_10x */ { 1, { { 3, 4 }, } },
  92. /* siig_2s1p_10x */ { 1, { { 4, 5 }, } },
  93. /* siig_2p1s_20x */ { 2, { { 1, 2 }, { 3, 4 }, } },
  94. /* siig_1s1p_20x */ { 1, { { 1, 2 }, } },
  95. /* siig_2s1p_20x */ { 1, { { 2, 3 }, } },
  96. };
  97. static struct pci_device_id parport_serial_pci_tbl[] = {
  98. /* PCI cards */
  99. { PCI_VENDOR_ID_TITAN, PCI_DEVICE_ID_TITAN_110L,
  100. PCI_ANY_ID, PCI_ANY_ID, 0, 0, titan_110l },
  101. { PCI_VENDOR_ID_TITAN, PCI_DEVICE_ID_TITAN_210L,
  102. PCI_ANY_ID, PCI_ANY_ID, 0, 0, titan_210l },
  103. { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9735,
  104. PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9xx5_combo },
  105. { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9745,
  106. PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9xx5_combo },
  107. { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9835,
  108. PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9xx5_combo },
  109. { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9835,
  110. PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9xx5_combo },
  111. { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9845,
  112. PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9xx5_combo },
  113. { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9855,
  114. PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9xx5_combo },
  115. /* PCI_VENDOR_ID_AVLAB/Intek21 has another bunch of cards ...*/
  116. { 0x14db, 0x2110, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_1s1p},
  117. { 0x14db, 0x2111, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_1s1p_650},
  118. { 0x14db, 0x2112, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_1s1p_850},
  119. { 0x14db, 0x2140, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_1s2p},
  120. { 0x14db, 0x2141, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_1s2p_650},
  121. { 0x14db, 0x2142, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_1s2p_850},
  122. { 0x14db, 0x2160, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_2s1p},
  123. { 0x14db, 0x2161, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_2s1p_650},
  124. { 0x14db, 0x2162, PCI_ANY_ID, PCI_ANY_ID, 0, 0, avlab_2s1p_850},
  125. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_1S1P_10x_550,
  126. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_1s1p_10x },
  127. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_1S1P_10x_650,
  128. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_1s1p_10x },
  129. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_1S1P_10x_850,
  130. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_1s1p_10x },
  131. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2S1P_10x_550,
  132. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_10x },
  133. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2S1P_10x_650,
  134. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_10x },
  135. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2S1P_10x_850,
  136. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_10x },
  137. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2P1S_20x_550,
  138. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2p1s_20x },
  139. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2P1S_20x_650,
  140. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2p1s_20x },
  141. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2P1S_20x_850,
  142. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2p1s_20x },
  143. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_1S1P_20x_550,
  144. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_20x },
  145. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_1S1P_20x_650,
  146. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_1s1p_20x },
  147. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_1S1P_20x_850,
  148. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_1s1p_20x },
  149. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2S1P_20x_550,
  150. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_20x },
  151. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2S1P_20x_650,
  152. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_20x },
  153. { PCI_VENDOR_ID_SIIG, PCI_DEVICE_ID_SIIG_2S1P_20x_850,
  154. PCI_ANY_ID, PCI_ANY_ID, 0, 0, siig_2s1p_20x },
  155. { 0, } /* terminate list */
  156. };
  157. MODULE_DEVICE_TABLE(pci,parport_serial_pci_tbl);
  158. struct pci_board_no_ids {
  159. int flags;
  160. int num_ports;
  161. int base_baud;
  162. int uart_offset;
  163. int reg_shift;
  164. int (*init_fn)(struct pci_dev *dev, struct pci_board_no_ids *board,
  165. int enable);
  166. int first_uart_offset;
  167. };
  168. static int __devinit siig10x_init_fn(struct pci_dev *dev, struct pci_board_no_ids *board, int enable)
  169. {
  170. return pci_siig10x_fn(dev, enable);
  171. }
  172. static int __devinit siig20x_init_fn(struct pci_dev *dev, struct pci_board_no_ids *board, int enable)
  173. {
  174. return pci_siig20x_fn(dev, enable);
  175. }
  176. static int __devinit netmos_serial_init(struct pci_dev *dev, struct pci_board_no_ids *board, int enable)
  177. {
  178. board->num_ports = dev->subsystem_device & 0xf;
  179. return 0;
  180. }
  181. static struct pci_board_no_ids pci_boards[] __devinitdata = {
  182. /*
  183. * PCI Flags, Number of Ports, Base (Maximum) Baud Rate,
  184. * Offset to get to next UART's registers,
  185. * Register shift to use for memory-mapped I/O,
  186. * Initialization function, first UART offset
  187. */
  188. // Cards not tested are marked n/t
  189. // If you have one of these cards and it works for you, please tell me..
  190. /* titan_110l */ { SPCI_FL_BASE1 | SPCI_FL_BASE_TABLE, 1, 921600 },
  191. /* titan_210l */ { SPCI_FL_BASE1 | SPCI_FL_BASE_TABLE, 2, 921600 },
  192. /* netmos_9xx5_combo */ { SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200, 0, 0, netmos_serial_init },
  193. /* avlab_1s1p (n/t) */ { SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200 },
  194. /* avlab_1s1p_650 (nt)*/{ SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200 },
  195. /* avlab_1s1p_850 (nt)*/{ SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200 },
  196. /* avlab_1s2p (n/t) */ { SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200 },
  197. /* avlab_1s2p_650 (nt)*/{ SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200 },
  198. /* avlab_1s2p_850 (nt)*/{ SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 1, 115200 },
  199. /* avlab_2s1p (n/t) */ { SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 2, 115200 },
  200. /* avlab_2s1p_650 (nt)*/{ SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 2, 115200 },
  201. /* avlab_2s1p_850 (nt)*/{ SPCI_FL_BASE0 | SPCI_FL_BASE_TABLE, 2, 115200 },
  202. /* siig_1s1p_10x */ { SPCI_FL_BASE2, 1, 460800, 0, 0, siig10x_init_fn },
  203. /* siig_2s1p_10x */ { SPCI_FL_BASE2, 1, 921600, 0, 0, siig10x_init_fn },
  204. /* siig_2p1s_20x */ { SPCI_FL_BASE0, 1, 921600, 0, 0, siig20x_init_fn },
  205. /* siig_1s1p_20x */ { SPCI_FL_BASE0, 1, 921600, 0, 0, siig20x_init_fn },
  206. /* siig_2s1p_20x */ { SPCI_FL_BASE0, 1, 921600, 0, 0, siig20x_init_fn },
  207. };
  208. struct parport_serial_private {
  209. int num_ser;
  210. int line[20];
  211. struct pci_board_no_ids ser;
  212. int num_par;
  213. struct parport *port[PARPORT_MAX];
  214. struct parport_pc_pci par;
  215. };
  216. static int __devinit get_pci_port (struct pci_dev *dev,
  217. struct pci_board_no_ids *board,
  218. struct serial_struct *req,
  219. int idx)
  220. {
  221. unsigned long port;
  222. int base_idx;
  223. int max_port;
  224. int offset;
  225. base_idx = SPCI_FL_GET_BASE(board->flags);
  226. if (board->flags & SPCI_FL_BASE_TABLE)
  227. base_idx += idx;
  228. if (board->flags & SPCI_FL_REGION_SZ_CAP) {
  229. max_port = pci_resource_len(dev, base_idx) / 8;
  230. if (idx >= max_port)
  231. return 1;
  232. }
  233. offset = board->first_uart_offset;
  234. /* Timedia/SUNIX uses a mixture of BARs and offsets */
  235. /* Ugh, this is ugly as all hell --- TYT */
  236. if(dev->vendor == PCI_VENDOR_ID_TIMEDIA ) /* 0x1409 */
  237. switch(idx) {
  238. case 0: base_idx=0;
  239. break;
  240. case 1: base_idx=0; offset=8;
  241. break;
  242. case 2: base_idx=1;
  243. break;
  244. case 3: base_idx=1; offset=8;
  245. break;
  246. case 4: /* BAR 2*/
  247. case 5: /* BAR 3 */
  248. case 6: /* BAR 4*/
  249. case 7: base_idx=idx-2; /* BAR 5*/
  250. }
  251. port = pci_resource_start(dev, base_idx) + offset;
  252. if ((board->flags & SPCI_FL_BASE_TABLE) == 0)
  253. port += idx * (board->uart_offset ? board->uart_offset : 8);
  254. if (pci_resource_flags (dev, base_idx) & IORESOURCE_IO) {
  255. int high_bits_offset = ((sizeof(long)-sizeof(int))*8);
  256. req->port = port;
  257. if (high_bits_offset)
  258. req->port_high = port >> high_bits_offset;
  259. else
  260. req->port_high = 0;
  261. return 0;
  262. }
  263. req->io_type = SERIAL_IO_MEM;
  264. req->iomem_base = ioremap(port, board->uart_offset);
  265. req->iomem_reg_shift = board->reg_shift;
  266. req->port = 0;
  267. return req->iomem_base ? 0 : 1;
  268. }
  269. /* Register the serial port(s) of a PCI card. */
  270. static int __devinit serial_register (struct pci_dev *dev,
  271. const struct pci_device_id *id)
  272. {
  273. struct pci_board_no_ids *board;
  274. struct parport_serial_private *priv = pci_get_drvdata (dev);
  275. struct serial_struct serial_req;
  276. int base_baud;
  277. int k;
  278. int success = 0;
  279. priv->ser = pci_boards[id->driver_data];
  280. board = &priv->ser;
  281. if (board->init_fn && ((board->init_fn) (dev, board, 1) != 0))
  282. return 1;
  283. base_baud = board->base_baud;
  284. if (!base_baud)
  285. base_baud = BASE_BAUD;
  286. memset (&serial_req, 0, sizeof (serial_req));
  287. for (k = 0; k < board->num_ports; k++) {
  288. int line;
  289. if (priv->num_ser == ARRAY_SIZE (priv->line)) {
  290. printk (KERN_WARNING
  291. "parport_serial: %s: only %u serial lines "
  292. "supported (%d reported)\n", pci_name (dev),
  293. ARRAY_SIZE (priv->line), board->num_ports);
  294. break;
  295. }
  296. serial_req.irq = dev->irq;
  297. if (get_pci_port (dev, board, &serial_req, k))
  298. break;
  299. serial_req.flags = ASYNC_SKIP_TEST | ASYNC_AUTOPROBE;
  300. serial_req.baud_base = base_baud;
  301. line = register_serial (&serial_req);
  302. if (line < 0) {
  303. printk (KERN_DEBUG
  304. "parport_serial: register_serial failed\n");
  305. continue;
  306. }
  307. priv->line[priv->num_ser++] = line;
  308. success = 1;
  309. }
  310. return success ? 0 : 1;
  311. }
  312. /* Register the parallel port(s) of a PCI card. */
  313. static int __devinit parport_register (struct pci_dev *dev,
  314. const struct pci_device_id *id)
  315. {
  316. struct parport_pc_pci *card;
  317. struct parport_serial_private *priv = pci_get_drvdata (dev);
  318. int i = id->driver_data, n;
  319. int success = 0;
  320. priv->par = cards[id->driver_data];
  321. card = &priv->par;
  322. if (card->preinit_hook &&
  323. card->preinit_hook (dev, card, PARPORT_IRQ_NONE, PARPORT_DMA_NONE))
  324. return -ENODEV;
  325. for (n = 0; n < card->numports; n++) {
  326. struct parport *port;
  327. int lo = card->addr[n].lo;
  328. int hi = card->addr[n].hi;
  329. unsigned long io_lo, io_hi;
  330. if (priv->num_par == ARRAY_SIZE (priv->port)) {
  331. printk (KERN_WARNING
  332. "parport_serial: %s: only %u parallel ports "
  333. "supported (%d reported)\n", pci_name (dev),
  334. ARRAY_SIZE (priv->port), card->numports);
  335. break;
  336. }
  337. io_lo = pci_resource_start (dev, lo);
  338. io_hi = 0;
  339. if ((hi >= 0) && (hi <= 6))
  340. io_hi = pci_resource_start (dev, hi);
  341. else if (hi > 6)
  342. io_lo += hi; /* Reinterpret the meaning of
  343. "hi" as an offset (see SYBA
  344. def.) */
  345. /* TODO: test if sharing interrupts works */
  346. printk (KERN_DEBUG "PCI parallel port detected: %04x:%04x, "
  347. "I/O at %#lx(%#lx)\n",
  348. parport_serial_pci_tbl[i].vendor,
  349. parport_serial_pci_tbl[i].device, io_lo, io_hi);
  350. port = parport_pc_probe_port (io_lo, io_hi, PARPORT_IRQ_NONE,
  351. PARPORT_DMA_NONE, dev);
  352. if (port) {
  353. priv->port[priv->num_par++] = port;
  354. success = 1;
  355. }
  356. }
  357. if (card->postinit_hook)
  358. card->postinit_hook (dev, card, !success);
  359. return success ? 0 : 1;
  360. }
  361. static int __devinit parport_serial_pci_probe (struct pci_dev *dev,
  362. const struct pci_device_id *id)
  363. {
  364. struct parport_serial_private *priv;
  365. int err;
  366. priv = kmalloc (sizeof *priv, GFP_KERNEL);
  367. if (!priv)
  368. return -ENOMEM;
  369. priv->num_ser = priv->num_par = 0;
  370. pci_set_drvdata (dev, priv);
  371. err = pci_enable_device (dev);
  372. if (err) {
  373. pci_set_drvdata (dev, NULL);
  374. kfree (priv);
  375. return err;
  376. }
  377. if (parport_register (dev, id)) {
  378. pci_set_drvdata (dev, NULL);
  379. kfree (priv);
  380. return -ENODEV;
  381. }
  382. if (serial_register (dev, id)) {
  383. int i;
  384. for (i = 0; i < priv->num_par; i++)
  385. parport_pc_unregister_port (priv->port[i]);
  386. pci_set_drvdata (dev, NULL);
  387. kfree (priv);
  388. return -ENODEV;
  389. }
  390. return 0;
  391. }
  392. static void __devexit parport_serial_pci_remove (struct pci_dev *dev)
  393. {
  394. struct parport_serial_private *priv = pci_get_drvdata (dev);
  395. int i;
  396. // Serial ports
  397. for (i = 0; i < priv->num_ser; i++) {
  398. unregister_serial (priv->line[i]);
  399. if (priv->ser.init_fn)
  400. (priv->ser.init_fn) (dev, &priv->ser, 0);
  401. }
  402. pci_set_drvdata (dev, NULL);
  403. // Parallel ports
  404. for (i = 0; i < priv->num_par; i++)
  405. parport_pc_unregister_port (priv->port[i]);
  406. kfree (priv);
  407. return;
  408. }
  409. static struct pci_driver parport_serial_pci_driver = {
  410. .name = "parport_serial",
  411. .id_table = parport_serial_pci_tbl,
  412. .probe = parport_serial_pci_probe,
  413. .remove = __devexit_p(parport_serial_pci_remove),
  414. };
  415. static int __init parport_serial_init (void)
  416. {
  417. return pci_module_init (&parport_serial_pci_driver);
  418. }
  419. static void __exit parport_serial_exit (void)
  420. {
  421. pci_unregister_driver (&parport_serial_pci_driver);
  422. return;
  423. }
  424. MODULE_AUTHOR("Tim Waugh <twaugh@redhat.com>");
  425. MODULE_DESCRIPTION("Driver for common parallel+serial multi-I/O PCI cards");
  426. MODULE_LICENSE("GPL");
  427. module_init(parport_serial_init);
  428. module_exit(parport_serial_exit);