diff options
Diffstat (limited to 'include/linux/usb/uas.h')
-rw-r--r-- | include/linux/usb/uas.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/include/linux/usb/uas.h b/include/linux/usb/uas.h index 9a988e413694..5499ab5c94bd 100644 --- a/include/linux/usb/uas.h +++ b/include/linux/usb/uas.h | |||
@@ -20,6 +20,28 @@ enum { | |||
20 | IU_ID_WRITE_READY = 0x07, | 20 | IU_ID_WRITE_READY = 0x07, |
21 | }; | 21 | }; |
22 | 22 | ||
23 | enum { | ||
24 | TMF_ABORT_TASK = 0x01, | ||
25 | TMF_ABORT_TASK_SET = 0x02, | ||
26 | TMF_CLEAR_TASK_SET = 0x04, | ||
27 | TMF_LOGICAL_UNIT_RESET = 0x08, | ||
28 | TMF_I_T_NEXUS_RESET = 0x10, | ||
29 | TMF_CLEAR_ACA = 0x40, | ||
30 | TMF_QUERY_TASK = 0x80, | ||
31 | TMF_QUERY_TASK_SET = 0x81, | ||
32 | TMF_QUERY_ASYNC_EVENT = 0x82, | ||
33 | }; | ||
34 | |||
35 | enum { | ||
36 | RC_TMF_COMPLETE = 0x00, | ||
37 | RC_INVALID_INFO_UNIT = 0x02, | ||
38 | RC_TMF_NOT_SUPPORTED = 0x04, | ||
39 | RC_TMF_FAILED = 0x05, | ||
40 | RC_TMF_SUCCEEDED = 0x08, | ||
41 | RC_INCORRECT_LUN = 0x09, | ||
42 | RC_OVERLAPPED_TAG = 0x0a, | ||
43 | }; | ||
44 | |||
23 | struct command_iu { | 45 | struct command_iu { |
24 | __u8 iu_id; | 46 | __u8 iu_id; |
25 | __u8 rsvd1; | 47 | __u8 rsvd1; |
@@ -32,6 +54,16 @@ struct command_iu { | |||
32 | __u8 cdb[16]; /* XXX: Overflow-checking tools may misunderstand */ | 54 | __u8 cdb[16]; /* XXX: Overflow-checking tools may misunderstand */ |
33 | }; | 55 | }; |
34 | 56 | ||
57 | struct task_mgmt_iu { | ||
58 | __u8 iu_id; | ||
59 | __u8 rsvd1; | ||
60 | __be16 tag; | ||
61 | __u8 function; | ||
62 | __u8 rsvd2; | ||
63 | __be16 task_tag; | ||
64 | struct scsi_lun lun; | ||
65 | }; | ||
66 | |||
35 | /* | 67 | /* |
36 | * Also used for the Read Ready and Write Ready IUs since they have the | 68 | * Also used for the Read Ready and Write Ready IUs since they have the |
37 | * same first four bytes | 69 | * same first four bytes |
@@ -47,6 +79,14 @@ struct sense_iu { | |||
47 | __u8 sense[SCSI_SENSE_BUFFERSIZE]; | 79 | __u8 sense[SCSI_SENSE_BUFFERSIZE]; |
48 | }; | 80 | }; |
49 | 81 | ||
82 | struct response_ui { | ||
83 | __u8 iu_id; | ||
84 | __u8 rsvd1; | ||
85 | __be16 tag; | ||
86 | __be16 add_response_info; | ||
87 | __u8 response_code; | ||
88 | }; | ||
89 | |||
50 | struct usb_pipe_usage_descriptor { | 90 | struct usb_pipe_usage_descriptor { |
51 | __u8 bLength; | 91 | __u8 bLength; |
52 | __u8 bDescriptorType; | 92 | __u8 bDescriptorType; |