aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/usb.h2
-rw-r--r--include/linux/usb/cdc.h7
-rw-r--r--include/linux/usb/ch9.h20
-rw-r--r--include/linux/usb/serial.h6
-rw-r--r--include/linux/usb_usual.h4
-rw-r--r--include/linux/usbdevice_fs.h4
-rw-r--r--include/scsi/scsi_device.h1
7 files changed, 30 insertions, 14 deletions
diff --git a/include/linux/usb.h b/include/linux/usb.h
index b5c226a87ed8..a8e8d1ecebb1 100644
--- a/include/linux/usb.h
+++ b/include/linux/usb.h
@@ -935,7 +935,7 @@ struct usb_iso_packet_descriptor {
935 unsigned int offset; 935 unsigned int offset;
936 unsigned int length; /* expected length */ 936 unsigned int length; /* expected length */
937 unsigned int actual_length; 937 unsigned int actual_length;
938 unsigned int status; 938 int status;
939}; 939};
940 940
941struct urb; 941struct urb;
diff --git a/include/linux/usb/cdc.h b/include/linux/usb/cdc.h
index ba617c372455..956edf3bbecb 100644
--- a/include/linux/usb/cdc.h
+++ b/include/linux/usb/cdc.h
@@ -73,6 +73,13 @@ struct usb_cdc_acm_descriptor {
73 __u8 bmCapabilities; 73 __u8 bmCapabilities;
74} __attribute__ ((packed)); 74} __attribute__ ((packed));
75 75
76/* capabilities from 5.2.3.3 */
77
78#define USB_CDC_COMM_FEATURE 0x01
79#define USB_CDC_CAP_LINE 0x02
80#define USB_CDC_CAP_BRK 0x04
81#define USB_CDC_CAP_NOTIFY 0x08
82
76/* "Union Functional Descriptor" from CDC spec 5.2.3.8 */ 83/* "Union Functional Descriptor" from CDC spec 5.2.3.8 */
77struct usb_cdc_union_desc { 84struct usb_cdc_union_desc {
78 __u8 bLength; 85 __u8 bLength;
diff --git a/include/linux/usb/ch9.h b/include/linux/usb/ch9.h
index ae7833749fa2..245c72531228 100644
--- a/include/linux/usb/ch9.h
+++ b/include/linux/usb/ch9.h
@@ -367,7 +367,7 @@ struct usb_debug_descriptor {
367 /* bulk endpoints with 8 byte maxpacket */ 367 /* bulk endpoints with 8 byte maxpacket */
368 __u8 bDebugInEndpoint; 368 __u8 bDebugInEndpoint;
369 __u8 bDebugOutEndpoint; 369 __u8 bDebugOutEndpoint;
370}; 370} __attribute__((packed));
371 371
372/*-------------------------------------------------------------------------*/ 372/*-------------------------------------------------------------------------*/
373 373
@@ -396,7 +396,7 @@ struct usb_security_descriptor {
396 396
397 __le16 wTotalLength; 397 __le16 wTotalLength;
398 __u8 bNumEncryptionTypes; 398 __u8 bNumEncryptionTypes;
399}; 399} __attribute__((packed));
400 400
401/*-------------------------------------------------------------------------*/ 401/*-------------------------------------------------------------------------*/
402 402
@@ -410,7 +410,7 @@ struct usb_key_descriptor {
410 __u8 tTKID[3]; 410 __u8 tTKID[3];
411 __u8 bReserved; 411 __u8 bReserved;
412 __u8 bKeyData[0]; 412 __u8 bKeyData[0];
413}; 413} __attribute__((packed));
414 414
415/*-------------------------------------------------------------------------*/ 415/*-------------------------------------------------------------------------*/
416 416
@@ -426,7 +426,7 @@ struct usb_encryption_descriptor {
426#define USB_ENC_TYPE_RSA_1 3 /* rsa3072/sha1 auth */ 426#define USB_ENC_TYPE_RSA_1 3 /* rsa3072/sha1 auth */
427 __u8 bEncryptionValue; /* use in SET_ENCRYPTION */ 427 __u8 bEncryptionValue; /* use in SET_ENCRYPTION */
428 __u8 bAuthKeyIndex; 428 __u8 bAuthKeyIndex;
429}; 429} __attribute__((packed));
430 430
431 431
432/*-------------------------------------------------------------------------*/ 432/*-------------------------------------------------------------------------*/
@@ -438,7 +438,7 @@ struct usb_bos_descriptor {
438 438
439 __le16 wTotalLength; 439 __le16 wTotalLength;
440 __u8 bNumDeviceCaps; 440 __u8 bNumDeviceCaps;
441}; 441} __attribute__((packed));
442 442
443/*-------------------------------------------------------------------------*/ 443/*-------------------------------------------------------------------------*/
444 444
@@ -447,7 +447,7 @@ struct usb_dev_cap_header {
447 __u8 bLength; 447 __u8 bLength;
448 __u8 bDescriptorType; 448 __u8 bDescriptorType;
449 __u8 bDevCapabilityType; 449 __u8 bDevCapabilityType;
450}; 450} __attribute__((packed));
451 451
452#define USB_CAP_TYPE_WIRELESS_USB 1 452#define USB_CAP_TYPE_WIRELESS_USB 1
453 453
@@ -475,7 +475,7 @@ struct usb_wireless_cap_descriptor { /* Ultra Wide Band */
475 __u8 bmFFITXPowerInfo; /* FFI power levels */ 475 __u8 bmFFITXPowerInfo; /* FFI power levels */
476 __le16 bmBandGroup; 476 __le16 bmBandGroup;
477 __u8 bReserved; 477 __u8 bReserved;
478}; 478} __attribute__((packed));
479 479
480/*-------------------------------------------------------------------------*/ 480/*-------------------------------------------------------------------------*/
481 481
@@ -496,7 +496,7 @@ struct usb_wireless_ep_comp_descriptor {
496#define USB_ENDPOINT_SWITCH_NO 0 496#define USB_ENDPOINT_SWITCH_NO 0
497#define USB_ENDPOINT_SWITCH_SWITCH 1 497#define USB_ENDPOINT_SWITCH_SWITCH 1
498#define USB_ENDPOINT_SWITCH_SCALE 2 498#define USB_ENDPOINT_SWITCH_SCALE 2
499}; 499} __attribute__((packed));
500 500
501/*-------------------------------------------------------------------------*/ 501/*-------------------------------------------------------------------------*/
502 502
@@ -512,7 +512,7 @@ struct usb_handshake {
512 __u8 CDID[16]; 512 __u8 CDID[16];
513 __u8 nonce[16]; 513 __u8 nonce[16];
514 __u8 MIC[8]; 514 __u8 MIC[8];
515}; 515} __attribute__((packed));
516 516
517/*-------------------------------------------------------------------------*/ 517/*-------------------------------------------------------------------------*/
518 518
@@ -524,7 +524,7 @@ struct usb_connection_context {
524 __u8 CHID[16]; /* persistent host id */ 524 __u8 CHID[16]; /* persistent host id */
525 __u8 CDID[16]; /* device id (unique w/in host context) */ 525 __u8 CDID[16]; /* device id (unique w/in host context) */
526 __u8 CK[16]; /* connection key */ 526 __u8 CK[16]; /* connection key */
527}; 527} __attribute__((packed));
528 528
529/*-------------------------------------------------------------------------*/ 529/*-------------------------------------------------------------------------*/
530 530
diff --git a/include/linux/usb/serial.h b/include/linux/usb/serial.h
index 33dcd8576696..32acbae28d24 100644
--- a/include/linux/usb/serial.h
+++ b/include/linux/usb/serial.h
@@ -54,6 +54,8 @@
54 * @write_wait: a wait_queue_head_t used by the port. 54 * @write_wait: a wait_queue_head_t used by the port.
55 * @work: work queue entry for the line discipline waking up. 55 * @work: work queue entry for the line discipline waking up.
56 * @open_count: number of times this port has been opened. 56 * @open_count: number of times this port has been opened.
57 * @throttled: nonzero if the read urb is inactive to throttle the device
58 * @throttle_req: nonzero if the tty wants to throttle us
57 * 59 *
58 * This structure is used by the usb-serial core and drivers for the specific 60 * This structure is used by the usb-serial core and drivers for the specific
59 * ports of a device. 61 * ports of a device.
@@ -88,6 +90,8 @@ struct usb_serial_port {
88 wait_queue_head_t write_wait; 90 wait_queue_head_t write_wait;
89 struct work_struct work; 91 struct work_struct work;
90 int open_count; 92 int open_count;
93 char throttled;
94 char throttle_req;
91 struct device dev; 95 struct device dev;
92}; 96};
93#define to_usb_serial_port(d) container_of(d, struct usb_serial_port, dev) 97#define to_usb_serial_port(d) container_of(d, struct usb_serial_port, dev)
@@ -269,6 +273,8 @@ extern int usb_serial_generic_write_room (struct usb_serial_port *port);
269extern int usb_serial_generic_chars_in_buffer (struct usb_serial_port *port); 273extern int usb_serial_generic_chars_in_buffer (struct usb_serial_port *port);
270extern void usb_serial_generic_read_bulk_callback (struct urb *urb); 274extern void usb_serial_generic_read_bulk_callback (struct urb *urb);
271extern void usb_serial_generic_write_bulk_callback (struct urb *urb); 275extern void usb_serial_generic_write_bulk_callback (struct urb *urb);
276extern void usb_serial_generic_throttle (struct usb_serial_port *port);
277extern void usb_serial_generic_unthrottle (struct usb_serial_port *port);
272extern void usb_serial_generic_shutdown (struct usb_serial *serial); 278extern void usb_serial_generic_shutdown (struct usb_serial *serial);
273extern int usb_serial_generic_register (int debug); 279extern int usb_serial_generic_register (int debug);
274extern void usb_serial_generic_deregister (void); 280extern void usb_serial_generic_deregister (void);
diff --git a/include/linux/usb_usual.h b/include/linux/usb_usual.h
index 2ae76fe52ff7..1b792b9286ba 100644
--- a/include/linux/usb_usual.h
+++ b/include/linux/usb_usual.h
@@ -46,7 +46,9 @@
46 US_FLAG(MAX_SECTORS_64, 0x00000400) \ 46 US_FLAG(MAX_SECTORS_64, 0x00000400) \
47 /* Sets max_sectors to 64 */ \ 47 /* Sets max_sectors to 64 */ \
48 US_FLAG(IGNORE_DEVICE, 0x00000800) \ 48 US_FLAG(IGNORE_DEVICE, 0x00000800) \
49 /* Don't claim device */ 49 /* Don't claim device */ \
50 US_FLAG(CAPACITY_HEURISTICS, 0x00001000) \
51 /* sometimes sizes is too big */
50 52
51#define US_FLAG(name, value) US_FL_##name = value , 53#define US_FLAG(name, value) US_FL_##name = value ,
52enum { US_DO_ALL_FLAGS }; 54enum { US_DO_ALL_FLAGS };
diff --git a/include/linux/usbdevice_fs.h b/include/linux/usbdevice_fs.h
index 617d8a1c59ae..342dd5a7e8bb 100644
--- a/include/linux/usbdevice_fs.h
+++ b/include/linux/usbdevice_fs.h
@@ -159,9 +159,9 @@ struct usbdevfs_ioctl32 {
159#define USBDEVFS_SUBMITURB32 _IOR('U', 10, struct usbdevfs_urb32) 159#define USBDEVFS_SUBMITURB32 _IOR('U', 10, struct usbdevfs_urb32)
160#define USBDEVFS_DISCARDURB _IO('U', 11) 160#define USBDEVFS_DISCARDURB _IO('U', 11)
161#define USBDEVFS_REAPURB _IOW('U', 12, void *) 161#define USBDEVFS_REAPURB _IOW('U', 12, void *)
162#define USBDEVFS_REAPURB32 _IOW('U', 12, u32) 162#define USBDEVFS_REAPURB32 _IOW('U', 12, __u32)
163#define USBDEVFS_REAPURBNDELAY _IOW('U', 13, void *) 163#define USBDEVFS_REAPURBNDELAY _IOW('U', 13, void *)
164#define USBDEVFS_REAPURBNDELAY32 _IOW('U', 13, u32) 164#define USBDEVFS_REAPURBNDELAY32 _IOW('U', 13, __u32)
165#define USBDEVFS_DISCSIGNAL _IOR('U', 14, struct usbdevfs_disconnectsignal) 165#define USBDEVFS_DISCSIGNAL _IOR('U', 14, struct usbdevfs_disconnectsignal)
166#define USBDEVFS_CLAIMINTERFACE _IOR('U', 15, unsigned int) 166#define USBDEVFS_CLAIMINTERFACE _IOR('U', 15, unsigned int)
167#define USBDEVFS_RELEASEINTERFACE _IOR('U', 16, unsigned int) 167#define USBDEVFS_RELEASEINTERFACE _IOR('U', 16, unsigned int)
diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h
index ebf31b16dc49..9dd37e2f5a84 100644
--- a/include/scsi/scsi_device.h
+++ b/include/scsi/scsi_device.h
@@ -122,6 +122,7 @@ struct scsi_device {
122 unsigned no_uld_attach:1; /* disable connecting to upper level drivers */ 122 unsigned no_uld_attach:1; /* disable connecting to upper level drivers */
123 unsigned select_no_atn:1; 123 unsigned select_no_atn:1;
124 unsigned fix_capacity:1; /* READ_CAPACITY is too high by 1 */ 124 unsigned fix_capacity:1; /* READ_CAPACITY is too high by 1 */
125 unsigned guess_capacity:1; /* READ_CAPACITY might be too high by 1 */
125 unsigned retry_hwerror:1; /* Retry HARDWARE_ERROR */ 126 unsigned retry_hwerror:1; /* Retry HARDWARE_ERROR */
126 127
127 unsigned int device_blocked; /* Device returned QUEUE_FULL. */ 128 unsigned int device_blocked; /* Device returned QUEUE_FULL. */