2 Keyspan USB to Serial Converter driver
4 (C) Copyright (C) 2000-2001
5 Hugh Blemings <hugh@blemings.org>
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
12 See http://misc.nu/hugh/keyspan.html for more information.
14 Code in this driver inspired by and in a number of places taken
15 from Brian Warner's original Keyspan-PDA driver.
17 This driver has been put together with the support of Innosys, Inc.
18 and Keyspan, Inc the manufacturers of the Keyspan USB-serial products.
21 Thanks to Paulus for miscellaneous tidy ups, some largish chunks
22 of much nicer and/or completely new code and (perhaps most uniquely)
23 having the patience to sit down and explain why and where he'd changed
26 Tip 'o the hat to IBM (and previously Linuxcare :) for supporting
27 staff in their work on open source projects.
29 See keyspan.c for update history.
33 #ifndef __LINUX_USB_SERIAL_KEYSPAN_H
34 #define __LINUX_USB_SERIAL_KEYSPAN_H
37 /* Function prototypes for Keyspan serial converter */
38 static int keyspan_open (struct usb_serial_port *port,
40 static void keyspan_close (struct usb_serial_port *port,
42 static int keyspan_startup (struct usb_serial *serial);
43 static void keyspan_shutdown (struct usb_serial *serial);
44 static void keyspan_rx_throttle (struct usb_serial_port *port);
45 static void keyspan_rx_unthrottle (struct usb_serial_port *port);
46 static int keyspan_write_room (struct usb_serial_port *port);
48 static int keyspan_write (struct usb_serial_port *port,
50 const unsigned char *buf,
53 static void keyspan_send_setup (struct usb_serial_port *port,
57 static int keyspan_chars_in_buffer (struct usb_serial_port *port);
58 static int keyspan_ioctl (struct usb_serial_port *port,
62 static void keyspan_set_termios (struct usb_serial_port *port,
64 static void keyspan_break_ctl (struct usb_serial_port *port,
66 static int keyspan_fake_startup (struct usb_serial *serial);
68 static int keyspan_usa19_calc_baud (u32 baud_rate, u32 baudclk,
69 u8 *rate_hi, u8 *rate_low,
70 u8 *prescaler, int portnum);
72 static int keyspan_usa19w_calc_baud (u32 baud_rate, u32 baudclk,
73 u8 *rate_hi, u8 *rate_low,
74 u8 *prescaler, int portnum);
76 static int keyspan_usa28_calc_baud (u32 baud_rate, u32 baudclk,
77 u8 *rate_hi, u8 *rate_low,
78 u8 *prescaler, int portnum);
80 static int keyspan_usa19hs_calc_baud (u32 baud_rate, u32 baudclk,
81 u8 *rate_hi, u8 *rate_low,
82 u8 *prescaler, int portnum);
84 static int keyspan_usa28_send_setup (struct usb_serial *serial,
85 struct usb_serial_port *port,
87 static int keyspan_usa26_send_setup (struct usb_serial *serial,
88 struct usb_serial_port *port,
90 static int keyspan_usa49_send_setup (struct usb_serial *serial,
91 struct usb_serial_port *port,
94 static int keyspan_usa90_send_setup (struct usb_serial *serial,
95 struct usb_serial_port *port,
98 /* Struct used for firmware - increased size of data section
99 to allow Keyspan's 'C' firmware struct to be used unmodified */
100 struct ezusb_hex_record {
106 /* Conditionally include firmware images, if they aren't
107 included create a null pointer instead. Current
108 firmware images aren't optimised to remove duplicate
109 addresses in the image itself. */
110 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA28
111 #include "keyspan_usa28_fw.h"
113 static const struct ezusb_hex_record *keyspan_usa28_firmware = NULL;
116 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA28X
117 #include "keyspan_usa28x_fw.h"
119 static const struct ezusb_hex_record *keyspan_usa28x_firmware = NULL;
122 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA28XA
123 #include "keyspan_usa28xa_fw.h"
125 static const struct ezusb_hex_record *keyspan_usa28xa_firmware = NULL;
128 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA28XB
129 #include "keyspan_usa28xb_fw.h"
131 static const struct ezusb_hex_record *keyspan_usa28xb_firmware = NULL;
134 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA19
135 #include "keyspan_usa19_fw.h"
137 static const struct ezusb_hex_record *keyspan_usa19_firmware = NULL;
140 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA19QI
141 #include "keyspan_usa19qi_fw.h"
143 static const struct ezusb_hex_record *keyspan_usa19qi_firmware = NULL;
146 #ifdef CONFIG_USB_SERIAL_KEYSPAN_MPR
147 #include "keyspan_mpr_fw.h"
149 static const struct ezusb_hex_record *keyspan_mpr_firmware = NULL;
152 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA19QW
153 #include "keyspan_usa19qw_fw.h"
155 static const struct ezusb_hex_record *keyspan_usa19qw_firmware = NULL;
158 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA18X
159 #include "keyspan_usa18x_fw.h"
161 static const struct ezusb_hex_record *keyspan_usa18x_firmware = NULL;
164 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA19W
165 #include "keyspan_usa19w_fw.h"
167 static const struct ezusb_hex_record *keyspan_usa19w_firmware = NULL;
170 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA49W
171 #include "keyspan_usa49w_fw.h"
173 static const struct ezusb_hex_record *keyspan_usa49w_firmware = NULL;
176 #ifdef CONFIG_USB_SERIAL_KEYSPAN_USA49WLC
177 #include "keyspan_usa49wlc_fw.h"
179 static const struct ezusb_hex_record *keyspan_usa49wlc_firmware = NULL;
182 /* Values used for baud rate calculation - device specific */
183 #define KEYSPAN_INVALID_BAUD_RATE (-1)
184 #define KEYSPAN_BAUD_RATE_OK (0)
185 #define KEYSPAN_USA18X_BAUDCLK (12000000L) /* a guess */
186 #define KEYSPAN_USA19_BAUDCLK (12000000L)
187 #define KEYSPAN_USA19W_BAUDCLK (24000000L)
188 #define KEYSPAN_USA19HS_BAUDCLK (14769231L)
189 #define KEYSPAN_USA28_BAUDCLK (1843200L)
190 #define KEYSPAN_USA28X_BAUDCLK (12000000L)
191 #define KEYSPAN_USA49W_BAUDCLK (48000000L)
193 /* Some constants used to characterise each device. */
194 #define KEYSPAN_MAX_NUM_PORTS (4)
195 #define KEYSPAN_MAX_FLIPS (2)
197 /* Device info for the Keyspan serial converter, used
198 by the overall usb-serial probe function */
199 #define KEYSPAN_VENDOR_ID (0x06cd)
201 /* Product IDs for the products supported, pre-renumeration */
202 #define keyspan_usa18x_pre_product_id 0x0105
203 #define keyspan_usa19_pre_product_id 0x0103
204 #define keyspan_usa19qi_pre_product_id 0x010b
205 #define keyspan_mpr_pre_product_id 0x011b
206 #define keyspan_usa19qw_pre_product_id 0x0118
207 #define keyspan_usa19w_pre_product_id 0x0106
208 #define keyspan_usa28_pre_product_id 0x0101
209 #define keyspan_usa28x_pre_product_id 0x0102
210 #define keyspan_usa28xa_pre_product_id 0x0114
211 #define keyspan_usa28xb_pre_product_id 0x0113
212 #define keyspan_usa49w_pre_product_id 0x0109
213 #define keyspan_usa49wlc_pre_product_id 0x011a
215 /* Product IDs post-renumeration. Note that the 28x and 28xb
216 have the same id's post-renumeration but behave identically
217 so it's not an issue. */
218 #define keyspan_usa18x_product_id 0x0112
219 #define keyspan_usa19_product_id 0x0107
220 #define keyspan_usa19qi_product_id 0x010c
221 #define keyspan_usa19hs_product_id 0x0121
222 #define keyspan_mpr_product_id 0x011c
223 #define keyspan_usa19qw_product_id 0x0119
224 #define keyspan_usa19w_product_id 0x0108
225 #define keyspan_usa28_product_id 0x010f
226 #define keyspan_usa28x_product_id 0x0110
227 #define keyspan_usa28xa_product_id 0x0115
228 #define keyspan_usa28xb_product_id 0x0110
229 #define keyspan_usa49w_product_id 0x010a
230 #define keyspan_usa49wlc_product_id 0x012a
233 struct keyspan_device_details {
234 /* product ID value */
237 enum {msg_usa26, msg_usa28, msg_usa49, msg_usa90} msg_format;
239 /* Number of physical ports */
242 /* 1 if endpoint flipping used on input, 0 if not */
245 /* 1 if endpoint flipping used on output, 0 if not */
246 int outdat_endp_flip;
248 /* Table mapping input data endpoint IDs to physical
249 port number and flip if used */
250 int indat_endpoints[KEYSPAN_MAX_NUM_PORTS];
252 /* Same for output endpoints */
253 int outdat_endpoints[KEYSPAN_MAX_NUM_PORTS];
255 /* Input acknowledge endpoints */
256 int inack_endpoints[KEYSPAN_MAX_NUM_PORTS];
258 /* Output control endpoints */
259 int outcont_endpoints[KEYSPAN_MAX_NUM_PORTS];
261 /* Endpoint used for input status */
264 /* Endpoint used for global control functions */
265 int glocont_endpoint;
267 int (*calculate_baud_rate) (u32 baud_rate, u32 baudclk,
268 u8 *rate_hi, u8 *rate_low, u8 *prescaler, int portnum);
272 /* Now for each device type we setup the device detail
273 structure with the appropriate information (provided
274 in Keyspan's documentation) */
276 static const struct keyspan_device_details usa18x_device_details = {
277 product_id: keyspan_usa18x_product_id,
278 msg_format: msg_usa26,
282 indat_endpoints: {0x81},
283 outdat_endpoints: {0x01},
284 inack_endpoints: {0x85},
285 outcont_endpoints: {0x05},
286 instat_endpoint: 0x87,
287 glocont_endpoint: 0x07,
288 calculate_baud_rate: keyspan_usa19w_calc_baud,
289 baudclk: KEYSPAN_USA18X_BAUDCLK,
292 static const struct keyspan_device_details usa19_device_details = {
293 product_id: keyspan_usa19_product_id,
294 msg_format: msg_usa28,
298 indat_endpoints: {0x81},
299 outdat_endpoints: {0x01},
300 inack_endpoints: {0x83},
301 outcont_endpoints: {0x03},
302 instat_endpoint: 0x84,
303 glocont_endpoint: -1,
304 calculate_baud_rate: keyspan_usa19_calc_baud,
305 baudclk: KEYSPAN_USA19_BAUDCLK,
308 static const struct keyspan_device_details usa19qi_device_details = {
309 product_id: keyspan_usa19qi_product_id,
310 msg_format: msg_usa28,
314 indat_endpoints: {0x81},
315 outdat_endpoints: {0x01},
316 inack_endpoints: {0x83},
317 outcont_endpoints: {0x03},
318 instat_endpoint: 0x84,
319 glocont_endpoint: -1,
320 calculate_baud_rate: keyspan_usa28_calc_baud,
321 baudclk: KEYSPAN_USA19_BAUDCLK,
324 static const struct keyspan_device_details mpr_device_details = {
325 product_id: keyspan_mpr_product_id,
326 msg_format: msg_usa28,
330 indat_endpoints: {0x81},
331 outdat_endpoints: {0x01},
332 inack_endpoints: {0x83},
333 outcont_endpoints: {0x03},
334 instat_endpoint: 0x84,
335 glocont_endpoint: -1,
336 calculate_baud_rate: keyspan_usa28_calc_baud,
337 baudclk: KEYSPAN_USA19_BAUDCLK,
341 static const struct keyspan_device_details usa19qw_device_details = {
342 product_id: keyspan_usa19qw_product_id,
343 msg_format: msg_usa26,
347 indat_endpoints: {0x81},
348 outdat_endpoints: {0x01},
349 inack_endpoints: {0x85},
350 outcont_endpoints: {0x05},
351 instat_endpoint: 0x87,
352 glocont_endpoint: 0x07,
353 calculate_baud_rate: keyspan_usa19w_calc_baud,
354 baudclk: KEYSPAN_USA19W_BAUDCLK,
357 static const struct keyspan_device_details usa19w_device_details = {
358 product_id: keyspan_usa19w_product_id,
359 msg_format: msg_usa26,
363 indat_endpoints: {0x81},
364 outdat_endpoints: {0x01},
365 inack_endpoints: {0x85},
366 outcont_endpoints: {0x05},
367 instat_endpoint: 0x87,
368 glocont_endpoint: 0x07,
369 calculate_baud_rate: keyspan_usa19w_calc_baud,
370 baudclk: KEYSPAN_USA19W_BAUDCLK,
373 static const struct keyspan_device_details usa19hs_device_details = {
374 product_id: keyspan_usa19hs_product_id,
375 msg_format: msg_usa90,
379 indat_endpoints: {0x81},
380 outdat_endpoints: {0x01},
381 inack_endpoints: {-1},
382 outcont_endpoints: {0x02},
383 instat_endpoint: 0x82,
384 glocont_endpoint: -1,
385 calculate_baud_rate: keyspan_usa19hs_calc_baud,
386 baudclk: KEYSPAN_USA19HS_BAUDCLK,
389 static const struct keyspan_device_details usa28_device_details = {
390 product_id: keyspan_usa28_product_id,
391 msg_format: msg_usa28,
395 indat_endpoints: {0x81, 0x83},
396 outdat_endpoints: {0x01, 0x03},
397 inack_endpoints: {0x85, 0x86},
398 outcont_endpoints: {0x05, 0x06},
399 instat_endpoint: 0x87,
400 glocont_endpoint: 0x07,
401 calculate_baud_rate: keyspan_usa28_calc_baud,
402 baudclk: KEYSPAN_USA28_BAUDCLK,
405 static const struct keyspan_device_details usa28x_device_details = {
406 product_id: keyspan_usa28x_product_id,
407 msg_format: msg_usa26,
411 indat_endpoints: {0x81, 0x83},
412 outdat_endpoints: {0x01, 0x03},
413 inack_endpoints: {0x85, 0x86},
414 outcont_endpoints: {0x05, 0x06},
415 instat_endpoint: 0x87,
416 glocont_endpoint: 0x07,
417 calculate_baud_rate: keyspan_usa19w_calc_baud,
418 baudclk: KEYSPAN_USA28X_BAUDCLK,
421 static const struct keyspan_device_details usa28xa_device_details = {
422 product_id: keyspan_usa28xa_product_id,
423 msg_format: msg_usa26,
427 indat_endpoints: {0x81, 0x83},
428 outdat_endpoints: {0x01, 0x03},
429 inack_endpoints: {0x85, 0x86},
430 outcont_endpoints: {0x05, 0x06},
431 instat_endpoint: 0x87,
432 glocont_endpoint: 0x07,
433 calculate_baud_rate: keyspan_usa19w_calc_baud,
434 baudclk: KEYSPAN_USA28X_BAUDCLK,
437 /* We don't need a separate entry for the usa28xb as it appears as a 28x anyway */
439 static const struct keyspan_device_details usa49w_device_details = {
440 product_id: keyspan_usa49w_product_id,
441 msg_format: msg_usa49,
445 indat_endpoints: {0x81, 0x82, 0x83, 0x84},
446 outdat_endpoints: {0x01, 0x02, 0x03, 0x04},
447 inack_endpoints: {-1, -1, -1, -1},
448 outcont_endpoints: {-1, -1, -1, -1},
449 instat_endpoint: 0x87,
450 glocont_endpoint: 0x07,
451 calculate_baud_rate: keyspan_usa19w_calc_baud,
452 baudclk: KEYSPAN_USA49W_BAUDCLK,
455 static const struct keyspan_device_details usa49wlc_device_details = {
456 product_id: keyspan_usa49wlc_product_id,
457 msg_format: msg_usa49,
461 indat_endpoints: {0x81, 0x82, 0x83, 0x84},
462 outdat_endpoints: {0x01, 0x02, 0x03, 0x04},
463 inack_endpoints: {-1, -1, -1, -1},
464 outcont_endpoints: {-1, -1, -1, -1},
465 instat_endpoint: 0x87,
466 glocont_endpoint: 0x07,
467 calculate_baud_rate: keyspan_usa19w_calc_baud,
468 baudclk: KEYSPAN_USA19W_BAUDCLK,
471 static const struct keyspan_device_details *keyspan_devices[] = {
472 &usa18x_device_details,
473 &usa19_device_details,
474 &usa19qi_device_details,
476 &usa19qw_device_details,
477 &usa19w_device_details,
478 &usa19hs_device_details,
479 &usa28_device_details,
480 &usa28x_device_details,
481 &usa28xa_device_details,
482 /* 28xb not required as it renumerates as a 28x */
483 &usa49w_device_details,
484 &usa49wlc_device_details,
488 static __devinitdata struct usb_device_id keyspan_ids_combined[] = {
489 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_pre_product_id) },
490 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_pre_product_id) },
491 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_pre_product_id) },
492 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_pre_product_id) },
493 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_pre_product_id) },
494 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_mpr_pre_product_id) },
495 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_pre_product_id) },
496 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_pre_product_id) },
497 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xa_pre_product_id) },
498 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xb_pre_product_id) },
499 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49w_pre_product_id) },
500 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49wlc_pre_product_id) },
501 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_product_id) },
502 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_product_id) },
503 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_product_id) },
504 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_product_id) },
505 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_product_id) },
506 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19hs_product_id) },
507 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_mpr_product_id) },
508 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_product_id) },
509 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_product_id) },
510 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xa_product_id) },
511 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xb_product_id) },
512 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49w_product_id)},
513 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49wlc_product_id)},
514 { } /* Terminating entry */
517 MODULE_DEVICE_TABLE(usb, keyspan_ids_combined);
519 /* usb_device_id table for the pre-firmware download keyspan devices */
520 static struct usb_device_id keyspan_pre_ids[] = {
521 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_pre_product_id) },
522 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_pre_product_id) },
523 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_pre_product_id) },
524 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_pre_product_id) },
525 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_pre_product_id) },
526 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_mpr_pre_product_id) },
527 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_pre_product_id) },
528 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_pre_product_id) },
529 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xa_pre_product_id) },
530 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xb_pre_product_id) },
531 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49w_pre_product_id) },
532 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49wlc_pre_product_id) },
533 { } /* Terminating entry */
536 static struct usb_device_id keyspan_1port_ids[] = {
537 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_product_id) },
538 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_product_id) },
539 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_product_id) },
540 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_product_id) },
541 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_product_id) },
542 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19hs_product_id) },
543 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_mpr_product_id) },
544 { } /* Terminating entry */
547 static struct usb_device_id keyspan_2port_ids[] = {
548 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_product_id) },
549 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_product_id) },
550 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xa_product_id) },
551 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xb_product_id) },
552 { } /* Terminating entry */
555 static struct usb_device_id keyspan_4port_ids[] = {
556 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49w_product_id) },
557 { USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa49wlc_product_id)},
558 { } /* Terminating entry */
561 /* Structs for the devices, pre and post renumeration. */
562 static struct usb_serial_device_type keyspan_pre_device = {
564 name: "Keyspan - (without firmware)",
565 id_table: keyspan_pre_ids,
566 num_interrupt_in: NUM_DONT_CARE,
567 num_bulk_in: NUM_DONT_CARE,
568 num_bulk_out: NUM_DONT_CARE,
570 startup: keyspan_fake_startup,
573 static struct usb_serial_device_type keyspan_1port_device = {
575 name: "Keyspan 1 port adapter",
576 id_table: keyspan_1port_ids,
577 num_interrupt_in: NUM_DONT_CARE,
578 num_bulk_in: NUM_DONT_CARE,
579 num_bulk_out: NUM_DONT_CARE,
582 close: keyspan_close,
583 write: keyspan_write,
584 write_room: keyspan_write_room,
585 chars_in_buffer: keyspan_chars_in_buffer,
586 throttle: keyspan_rx_throttle,
587 unthrottle: keyspan_rx_unthrottle,
588 ioctl: keyspan_ioctl,
589 set_termios: keyspan_set_termios,
590 break_ctl: keyspan_break_ctl,
591 startup: keyspan_startup,
592 shutdown: keyspan_shutdown,
595 static struct usb_serial_device_type keyspan_2port_device = {
597 name: "Keyspan 2 port adapter",
598 id_table: keyspan_2port_ids,
599 num_interrupt_in: NUM_DONT_CARE,
600 num_bulk_in: NUM_DONT_CARE,
601 num_bulk_out: NUM_DONT_CARE,
604 close: keyspan_close,
605 write: keyspan_write,
606 write_room: keyspan_write_room,
607 chars_in_buffer: keyspan_chars_in_buffer,
608 throttle: keyspan_rx_throttle,
609 unthrottle: keyspan_rx_unthrottle,
610 ioctl: keyspan_ioctl,
611 set_termios: keyspan_set_termios,
612 break_ctl: keyspan_break_ctl,
613 startup: keyspan_startup,
614 shutdown: keyspan_shutdown,
617 static struct usb_serial_device_type keyspan_4port_device = {
619 name: "Keyspan 4 port adapter",
620 id_table: keyspan_4port_ids,
621 num_interrupt_in: NUM_DONT_CARE,
626 close: keyspan_close,
627 write: keyspan_write,
628 write_room: keyspan_write_room,
629 chars_in_buffer: keyspan_chars_in_buffer,
630 throttle: keyspan_rx_throttle,
631 unthrottle: keyspan_rx_unthrottle,
632 ioctl: keyspan_ioctl,
633 set_termios: keyspan_set_termios,
634 break_ctl: keyspan_break_ctl,
635 startup: keyspan_startup,
636 shutdown: keyspan_shutdown,