Commit 433649b7 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

Merge http://linux-isdn.bkbits.net/linux-2.5.make-usb

into kroah.com:/home/linux/linux/BK/work-2.5
parents 50724188 c2aff941
......@@ -1090,6 +1090,7 @@ static struct usb_driver usblp_driver = {
disconnect: usblp_disconnect,
fops: &usblp_fops,
minor: USBLP_MINOR_BASE,
num_minors: USBLP_MINORS,
id_table: usblp_ids,
};
......
......@@ -71,8 +71,10 @@ static ssize_t usb_driver_read(struct file *file, char *buf, size_t nbytes, loff
int minor = driver->fops ? driver->minor : -1;
if (minor == -1)
start += sprintf (start, " %s\n", driver->name);
else if (driver->num_minors == 1)
start += sprintf (start, " %3d: %s\n", minor, driver->name);
else
start += sprintf (start, "%3d-%3d: %s\n", minor, minor + 15, driver->name);
start += sprintf (start, "%3d-%3d: %s\n", minor, minor + driver->num_minors - 1, driver->name);
if (start > end) {
start += sprintf(start, "(truncated)\n");
break;
......
......@@ -59,7 +59,7 @@ LIST_HEAD(usb_driver_list);
devfs_handle_t usb_devfs_handle; /* /dev/usb dir. */
static struct usb_driver *usb_minors[16];
static struct usb_driver *usb_minors[256];
/**
* usb_register - register a USB driver
......@@ -72,12 +72,17 @@ static struct usb_driver *usb_minors[16];
*/
int usb_register(struct usb_driver *new_driver)
{
int i;
if (new_driver->fops != NULL) {
if (usb_minors[new_driver->minor/16]) {
for (i = new_driver->minor; i < new_driver->minor + new_driver->num_minors; ++i) {
if (usb_minors[i]) {
err("error registering %s driver", new_driver->name);
return -EINVAL;
}
usb_minors[new_driver->minor/16] = new_driver;
}
for (i = new_driver->minor; i < new_driver->minor + new_driver->num_minors; ++i)
usb_minors[i] = new_driver;
}
info("registered new driver %s", new_driver->name);
......@@ -172,10 +177,12 @@ static void usb_drivers_purge(struct usb_driver *driver,struct usb_device *dev)
void usb_deregister(struct usb_driver *driver)
{
struct list_head *tmp;
int i;
info("deregistering driver %s", driver->name);
if (driver->fops != NULL)
usb_minors[driver->minor/16] = NULL;
for (i = driver->minor; i < driver->minor + driver->num_minors; ++i)
usb_minors[i] = NULL;
/*
* first we remove the driver, to be sure it doesn't get used by
......@@ -2517,7 +2524,7 @@ int usb_new_device(struct usb_device *dev)
static int usb_open(struct inode * inode, struct file * file)
{
int minor = minor(inode->i_rdev);
struct usb_driver *c = usb_minors[minor/16];
struct usb_driver *c = usb_minors[minor];
int err = -ENODEV;
struct file_operations *old_fops, *new_fops = NULL;
......
......@@ -155,6 +155,7 @@ static struct usb_device_id hpusbscsi_usb_ids[] = {
{USB_DEVICE (0x03f0, 0x0701)}, /* HP 53xx */
{USB_DEVICE (0x03f0, 0x0801)}, /* HP 7400 */
{USB_DEVICE (0x0638, 0x026a)}, /*Scan Dual II */
{USB_DEVICE (0x0686, 0x4004)}, /*Minolta Elite II */
{} /* Terminating entry */
};
......@@ -596,3 +597,4 @@ static void issue_request_sense (struct hpusbscsi *hpusbscsi)
}
}
......@@ -933,6 +933,7 @@ static struct usb_driver mdc800_usb_driver =
disconnect: mdc800_usb_disconnect,
fops: &mdc800_device_ops,
minor: MDC800_DEVICE_MINOR_BASE,
num_minors: 1,
id_table: mdc800_table
};
......
......@@ -1100,6 +1100,7 @@ usb_driver scanner_driver = {
disconnect: disconnect_scanner,
fops: &usb_scanner_fops,
minor: SCN_BASE_MNR,
num_minors: SCN_MAX_MNR,
id_table: NULL, /* This would be scanner_device_ids, but we
need to check every USB device, in case
we match a user defined vendor/product ID. */
......
......@@ -681,7 +681,8 @@ static /* const */ struct usb_driver hiddev_driver = {
name: "hiddev",
probe: hiddev_usbd_probe,
fops: &hiddev_fops,
minor: HIDDEV_MINOR_BASE
minor: HIDDEV_MINOR_BASE,
num_minors: HIDDEV_MINORS,
};
int __init hiddev_init(void)
......
......@@ -801,6 +801,7 @@ static struct usb_driver dabusb_driver =
disconnect: dabusb_disconnect,
fops: &dabusb_fops,
minor: DABUSB_MINOR,
num_minors: NRDABUSB,
id_table: dabusb_ids,
};
......
......@@ -128,8 +128,6 @@ static struct usb_driver usb_dsbr100_driver = {
name: "dsbr100",
probe: usb_dsbr100_probe,
disconnect: usb_dsbr100_disconnect,
fops: NULL,
minor: 0,
id_table: usb_dsbr100_table,
};
......
......@@ -596,7 +596,7 @@ static int se401_start_stream(struct usb_se401 *se401)
for (i=0; i<SE401_NUMSBUF; i++) {
urb=usb_alloc_urb(0, GFP_KERNEL);
if(!urb)
return ENOMEM;
return -ENOMEM;
FILL_BULK_URB(urb, se401->dev,
usb_rcvbulkpipe(se401->dev, SE401_VIDEO_ENDPOINT),
......
......@@ -769,7 +769,7 @@ static int stv680_start_stream (struct usb_stv *stv680)
for (i = 0; i < STV680_NUMSBUF; i++) {
urb = usb_alloc_urb (0, GFP_KERNEL);
if (!urb)
return ENOMEM;
return -ENOMEM;
/* sbuf is urb->transfer_buffer, later gets memcpyed to scratch */
usb_fill_bulk_urb (urb, stv680->udev,
......
......@@ -2138,6 +2138,7 @@ static struct usb_driver auerswald_driver = {
disconnect: auerswald_disconnect,
fops: &auerswald_fops,
minor: AUER_MINOR_BASE,
num_minors: AUER_MAX_DEVICES,
id_table: auerswald_ids,
};
......
......@@ -517,6 +517,7 @@ static struct usb_driver rio_driver = {
disconnect: disconnect_rio,
fops: &usb_rio_fops,
minor: RIO_MINOR,
num_minors: 1,
id_table: rio_table,
};
......
......@@ -28,6 +28,8 @@ dep_tristate ' USB Keyspan USA-xxx Serial Driver' CONFIG_USB_SERIAL_KEYSPAN $CO
dep_mbool ' USB Keyspan USA-19 Firmware' CONFIG_USB_SERIAL_KEYSPAN_USA19 $CONFIG_USB_SERIAL_KEYSPAN
dep_mbool ' USB Keyspan USA-18X Firmware' CONFIG_USB_SERIAL_KEYSPAN_USA18X $CONFIG_USB_SERIAL_KEYSPAN
dep_mbool ' USB Keyspan USA-19W Firmware' CONFIG_USB_SERIAL_KEYSPAN_USA19W $CONFIG_USB_SERIAL_KEYSPAN
dep_mbool ' USB Keyspan USA-19QW Firmware' CONFIG_USB_SERIAL_KEYSPAN_USA19QW $CONFIG_USB_SERIAL_KEYSPAN
dep_mbool ' USB Keyspan USA-19QI Firmware' CONFIG_USB_SERIAL_KEYSPAN_USA19QI $CONFIG_USB_SERIAL_KEYSPAN
dep_mbool ' USB Keyspan USA-49W Firmware' CONFIG_USB_SERIAL_KEYSPAN_USA49W $CONFIG_USB_SERIAL_KEYSPAN
dep_tristate ' USB KL5KUSB105 (Palmconnect) Driver (EXPERIMENTAL)' CONFIG_USB_SERIAL_KLSI $CONFIG_USB_SERIAL $CONFIG_EXPERIMENTAL
dep_tristate ' USB MCT Single Port Serial Driver' CONFIG_USB_SERIAL_MCT_U232 $CONFIG_USB_SERIAL
......
This diff is collapsed.
......@@ -2,7 +2,7 @@
Keyspan USB to Serial Converter driver
(C) Copyright (C) 2000-2001
Hugh Blemings <hugh@misc.nu>
Hugh Blemings <hugh@blemings.org>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -72,11 +72,16 @@ static void keyspan_break_ctl (struct usb_serial_port *port,
static int keyspan_fake_startup (struct usb_serial *serial);
static int keyspan_usa19_calc_baud (u32 baud_rate, u32 baudclk,
u8 *rate_hi, u8 *rate_low, u8 *prescaler);
u8 *rate_hi, u8 *rate_low,
u8 *prescaler, int portnum);
static int keyspan_usa19w_calc_baud (u32 baud_rate, u32 baudclk,
u8 *rate_hi, u8 *rate_low, u8 *prescaler);
u8 *rate_hi, u8 *rate_low,
u8 *prescaler, int portnum);
static int keyspan_usa28_calc_baud (u32 baud_rate, u32 baudclk,
u8 *rate_hi, u8 *rate_low,
u8 *prescaler, int portnum);
//static void keyspan_usa19_setup_urbs (struct usb_serial *serial);
static int keyspan_usa28_send_setup (struct usb_serial *serial,
......@@ -134,6 +139,18 @@ struct ezusb_hex_record {
static const struct ezusb_hex_record *keyspan_usa19_firmware = NULL;
#endif
#ifdef CONFIG_USB_SERIAL_KEYSPAN_USA19QI
#include "keyspan_usa19qi_fw.h"
#else
static const struct ezusb_hex_record *keyspan_usa19qi_firmware = NULL;
#endif
#ifdef CONFIG_USB_SERIAL_KEYSPAN_USA19QW
#include "keyspan_usa19qw_fw.h"
#else
static const struct ezusb_hex_record *keyspan_usa19qw_firmware = NULL;
#endif
#ifdef CONFIG_USB_SERIAL_KEYSPAN_USA18X
#include "keyspan_usa18x_fw.h"
#else
......@@ -158,12 +175,11 @@ struct ezusb_hex_record {
#define KEYSPAN_USA18X_BAUDCLK (12000000L) /* a guess */
#define KEYSPAN_USA19_BAUDCLK (12000000L)
#define KEYSPAN_USA19W_BAUDCLK (24000000L)
#define KEYSPAN_USA28_BAUDCLK (1843200L)
#define KEYSPAN_USA28X_BAUDCLK (12000000L)
#define KEYSPAN_USA49W_BAUDCLK (48000000L)
/* Some constants used to characterise each device.
There is a four port device due later in the year,
we allow for it now in the following */
/* Some constants used to characterise each device. */
#define KEYSPAN_MAX_NUM_PORTS (4)
#define KEYSPAN_MAX_FLIPS (2)
......@@ -174,6 +190,8 @@ struct ezusb_hex_record {
/* Product IDs for the eight products supported, pre-renumeration */
#define keyspan_usa18x_pre_product_id 0x0105
#define keyspan_usa19_pre_product_id 0x0103
#define keyspan_usa19qi_pre_product_id 0x010b
#define keyspan_usa19qw_pre_product_id 0x0118
#define keyspan_usa19w_pre_product_id 0x0106
#define keyspan_usa28_pre_product_id 0x0101
#define keyspan_usa28x_pre_product_id 0x0102
......@@ -186,6 +204,8 @@ struct ezusb_hex_record {
so it's not an issue. */
#define keyspan_usa18x_product_id 0x0112
#define keyspan_usa19_product_id 0x0107
#define keyspan_usa19qi_product_id 0x010c
#define keyspan_usa19qw_product_id 0x0119
#define keyspan_usa19w_product_id 0x0108
#define keyspan_usa28_product_id 0x010f
#define keyspan_usa28x_product_id 0x0110
......@@ -229,9 +249,8 @@ struct keyspan_device_details {
int glocont_endpoint;
int (*calculate_baud_rate) (u32 baud_rate, u32 baudclk,
u8 *rate_hi, u8 *rate_low, u8 *prescaler);
u8 *rate_hi, u8 *rate_low, u8 *prescaler, int portnum);
u32 baudclk;
};
/* Now for each device type we setup the device detail
......@@ -270,6 +289,38 @@ static const struct keyspan_device_details usa19_device_details = {
KEYSPAN_USA19_BAUDCLK /* base baud clock */
};
static const struct keyspan_device_details usa19qi_device_details = {
keyspan_usa19qi_product_id, /* product ID */
msg_usa28, /* msg type*/
1, /* num ports */
1, /* indat endpoint flip */
1, /* outdat endpoint flip */
{0x81}, /* per port indat */
{0x01}, /* per port outdat */
{0x83}, /* per port inack */
{0x03}, /* per port outcont */
0x84, /* instat endpoint */
-1, /* glocont endpoint */
keyspan_usa28_calc_baud, /* calc baud rate */
KEYSPAN_USA19_BAUDCLK /* base baud clock */
};
static const struct keyspan_device_details usa19qw_device_details = {
keyspan_usa19qw_product_id, /* product ID */
msg_usa26, /* msg type*/
1, /* num ports */
0, /* indat endpoint flip */
1, /* outdat endpoint flip */
{0x81}, /* per port indat */
{0x01}, /* per port outdat */
{0x85}, /* per port inack */
{0x05}, /* per port outcont */
0x87, /* instat endpoint */
0x07, /* glocont endpoint */
keyspan_usa19w_calc_baud, /* calc baud rate */
KEYSPAN_USA19W_BAUDCLK /* base baud clock */
};
static const struct keyspan_device_details usa19w_device_details = {
keyspan_usa19w_product_id, /* product ID */
msg_usa26, /* msg type*/
......@@ -286,6 +337,22 @@ static const struct keyspan_device_details usa19w_device_details = {
KEYSPAN_USA19W_BAUDCLK /* base baud clock */
};
static const struct keyspan_device_details usa28_device_details = {
keyspan_usa28_product_id, /* product ID */
msg_usa28, /* msg type*/
2, /* num ports */
1, /* indat endpoint flip */
1, /* outdat endpoint flip */
{0x81, 0x83}, /* per port indat */
{0x01, 0x03}, /* per port outdat */
{0x85, 0x86}, /* per port inack */
{0x05, 0x06}, /* per port outcont */
0x87, /* instat endpoint */
0x07, /* glocont endpoint */
keyspan_usa28_calc_baud, /* calc baud rate */
KEYSPAN_USA28_BAUDCLK
};
static const struct keyspan_device_details usa28x_device_details = {
keyspan_usa28x_product_id, /* product ID */
msg_usa26, /* msg type*/
......@@ -339,9 +406,13 @@ static const struct keyspan_device_details usa49w_device_details = {
static const struct keyspan_device_details *keyspan_devices[] = {
&usa18x_device_details,
&usa19_device_details,
&usa19qi_device_details,
&usa19qw_device_details,
&usa19w_device_details,
&usa28_device_details,
&usa28x_device_details,
&usa28xa_device_details,
/* 28xb not required as it renumerates as a 28x */
&usa49w_device_details,
NULL
};
......@@ -350,6 +421,8 @@ static __devinitdata struct usb_device_id keyspan_ids_combined[] = {
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xa_pre_product_id) },
......@@ -358,6 +431,8 @@ static __devinitdata struct usb_device_id keyspan_ids_combined[] = {
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28xa_product_id) },
......@@ -376,6 +451,8 @@ MODULE_DEVICE_TABLE(usb, keyspan_ids_combined);
static __devinitdata struct usb_device_id keyspan_pre_ids[] = {
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa18x_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28_pre_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa28x_pre_product_id) },
......@@ -392,10 +469,8 @@ static __devinitdata struct usb_device_id keyspan_usa18x_ids[] = {
static __devinitdata struct usb_device_id keyspan_usa19_ids[] = {
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19_product_id) },
{ } /* Terminating entry */
};
static __devinitdata struct usb_device_id keyspan_usa19w_ids[] = {
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qi_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19qw_product_id) },
{ USB_DEVICE(KEYSPAN_VENDOR_ID, keyspan_usa19w_product_id) },
{ } /* Terminating entry */
};
......@@ -478,29 +553,6 @@ static struct usb_serial_device_type keyspan_usa19_device = {
};
static struct usb_serial_device_type keyspan_usa19w_device = {
owner: THIS_MODULE,
name: "Keyspan USA19W",
id_table: keyspan_usa19w_ids,
num_interrupt_in: NUM_DONT_CARE,
num_bulk_in: 3,
num_bulk_out: 4,
num_ports: 1,
open: keyspan_open,
close: keyspan_close,
write: keyspan_write,
write_room: keyspan_write_room,
chars_in_buffer: keyspan_chars_in_buffer,
throttle: keyspan_rx_throttle,
unthrottle: keyspan_rx_unthrottle,
ioctl: keyspan_ioctl,
set_termios: keyspan_set_termios,
break_ctl: keyspan_break_ctl,
startup: keyspan_startup,
shutdown: keyspan_shutdown,
};
static struct usb_serial_device_type keyspan_usa28_device = {
owner: THIS_MODULE,
name: "Keyspan USA28",
......@@ -511,9 +563,15 @@ static struct usb_serial_device_type keyspan_usa28_device = {
num_ports: 2,
open: keyspan_open,
close: keyspan_close,
write: keyspan_write,
write_room: keyspan_write_room,
chars_in_buffer: keyspan_chars_in_buffer,
throttle: keyspan_rx_throttle,
unthrottle: keyspan_rx_unthrottle,
ioctl: keyspan_ioctl,
set_termios: keyspan_set_termios,
startup: keyspan_startup,
shutdown: keyspan_shutdown,
};
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -44,7 +44,7 @@
Buffer formats for RX/TX data messages are not defined by
a structure, but are described here:
USB OUT (host -> USA26, transmit) messages contain a
USB OUT (host -> USAxx, transmit) messages contain a
REQUEST_ACK indicator (set to 0xff to request an ACK at the
completion of transmit; 0x00 otherwise), followed by data:
......@@ -52,25 +52,48 @@
with a total data length of 63.
USB IN (USA26 -> host, receive) messages contain either a zero
flag (indicating no error in any data bytes):
USB IN (USAxx -> host, receive) messages begin with a status
byte in which the 0x80 bit is either:
00 DAT DAT DAT ...
(a) 0x80 bit clear
indicates that the bytes following it are all data
bytes:
for a total of 63 data bytes, or a non-zero status flag (indicating
that all data bytes will be preceded by status flag):
STAT DATA DATA DATA DATA DATA ...
STAT DAT STAT DAT STAT DAT ...
for a total of up to 63 DATA bytes,
for a total of 32 data bytes. The valid bits in the STAT bytes are:
or:
(b) 0x80 bit set
indiates that the bytes following alternate data and
status bytes:
STAT DATA STAT DATA STAT DATA STAT DATA ...
for a total of up to 32 DATA bytes.
The valid bits in the STAT bytes are:
OVERRUN 0x02
PARITY 0x04
FRAMING 0x08
BREAK 0x10
Note: a "no status" RX data message (first byte zero) can serve as
a "break off" indicator.
Notes:
(1) The OVERRUN bit can appear in either (a) or (b) format
messages, but the but the PARITY/FRAMING/BREAK bits
only appear in (b) format messages.
(2) For the host to determine the exact point at which the
overrun occurred (to identify the point in the data
stream at which the data was lost), it needs to count
128 characters, starting at the first character of the
message in which OVERRUN was reported; the lost character(s)
would have been received between the 128th and 129th
characters.
(3) An RX data message in which the first byte has 0x80 clear
serves as a "break off" indicator.
revision history:
......@@ -80,6 +103,7 @@
1999apr14 add resetDataToggle to control message
2000jan04 merge with usa17msg.h
2000jun01 add extended BSD-style copyright text
2001jul05 change message format to improve OVERRUN case
Note on shared names:
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -41,14 +41,10 @@
4th revision: USA49W version
See usa26msg.h for description of message formats
Third revision: USA28X version (aka USA26)
Buffer formats for RX/TX data messages are not defined by
a structure, but are described here:
USB OUT (host -> USA26, transmit) messages contain a
USB OUT (host -> USAxx, transmit) messages contain a
REQUEST_ACK indicator (set to 0xff to request an ACK at the
completion of transmit; 0x00 otherwise), followed by data:
......@@ -56,17 +52,28 @@
with a total data length of 63.
USB IN (USA26 -> host, receive) messages contain either a zero
flag (indicating no error in any data bytes):
USB IN (USAxx -> host, receive) messages begin with a status
byte in which the 0x80 bit is either:
(a) 0x80 bit clear
indicates that the bytes following it are all data
bytes:
STAT DATA DATA DATA DATA DATA ...
for a total of up to 63 DATA bytes,
or:
00 DAT DAT DAT ...
(b) 0x80 bit set
indiates that the bytes following alternate data and
status bytes:
for a total of 63 data bytes, or a non-zero status flag (indicating
that all data bytes will be preceded by status flag):
STAT DATA STAT DATA STAT DATA STAT DATA ...
STAT DAT STAT DAT STAT DAT ...
for a total of up to 32 DATA bytes.
for a total of 32 data bytes. The valid bits in the STAT bytes are:
The valid bits in the STAT bytes are:
OVERRUN 0x02
PARITY 0x04
......@@ -75,9 +82,19 @@
Notes:
1. a "no status" RX data message (first byte zero) can serve as
a "break off" indicator.
2. a control message specifying disablePort will be answered
(1) The OVERRUN bit can appear in either (a) or (b) format
messages, but the but the PARITY/FRAMING/BREAK bits
only appear in (b) format messages.
(2) For the host to determine the exact point at which the
overrun occurred (to identify the point in the data
stream at which the data was lost), it needs to count
128 characters, starting at the first character of the
message in which OVERRUN was reported; the lost character(s)
would have been received between the 128th and 129th
characters.
(3) An RX data message in which the first byte has 0x80 clear
serves as a "break off" indicator.
(4) a control message specifying disablePort will be answered
with a status message, but no further status will be sent
until a control messages with enablePort is sent
......@@ -92,6 +109,7 @@
2000mar09 change to support 4 ports
2000may03 change external clocking to match USA-49W hardware
2000jun01 add extended BSD-style copyright text
2001jul05 change message format to improve OVERRUN case
*/
#ifndef __USA49MSG__
......
This diff is collapsed.
......@@ -187,6 +187,7 @@ static struct usb_driver skel_driver = {
disconnect: skel_disconnect,
fops: &skel_fops,
minor: USB_SKEL_MINOR_BASE,
num_minors: MAX_DEVICES,
id_table: skel_table,
};
......
......@@ -493,6 +493,8 @@ struct usb_device_id {
* @minor: Used with fops to simplify creating USB character devices.
* Such drivers have sixteen character devices, using the USB
* major number and starting with this minor number.
* @num_minors: Used with minor to specify how many minors are used by
* this driver.
* @ioctl: Used for drivers that want to talk to userspace through
* the "usbfs" filesystem. This lets devices provide ways to
* expose information to user space regardless of where they
......@@ -534,6 +536,7 @@ struct usb_driver {
struct file_operations *fops;
int minor;
int num_minors;
struct semaphore serialize;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment