Print this page
701 UNMAP support for COMSTAR
Contributed by: Sumit Gupta <sumit.gupta@nexenta.com>
Reviewed by: Garrett D'Amore <garrett@nexenta.com>
| Split |
Close |
| Expand all |
| Collapse all |
--- old/usr/src/uts/common/sys/scsi/generic/commands.h
+++ new/usr/src/uts/common/sys/scsi/generic/commands.h
1 1 /*
2 2 * CDDL HEADER START
3 3 *
4 4 * The contents of this file are subject to the terms of the
5 5 * Common Development and Distribution License (the "License").
6 6 * You may not use this file except in compliance with the License.
7 7 *
8 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 * or http://www.opensolaris.org/os/licensing.
10 10 * See the License for the specific language governing permissions
11 11 * and limitations under the License.
12 12 *
13 13 * When distributing Covered Code, include this CDDL HEADER in each
|
↓ open down ↓ |
13 lines elided |
↑ open up ↑ |
14 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 * If applicable, add the following below this CDDL HEADER, with the
16 16 * fields enclosed by brackets "[]" replaced with your own identifying
17 17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 18 *
19 19 * CDDL HEADER END
20 20 */
21 21
22 22 /*
23 23 * Copyright (c) 1990, 2010, Oracle and/or its affiliates. All rights reserved.
24 + *
25 + * Copyright 2011 Nexenta Systems, Inc. All rights reserved.
24 26 */
25 27
26 28 #ifndef _SYS_SCSI_GENERIC_COMMANDS_H
27 29 #define _SYS_SCSI_GENERIC_COMMANDS_H
28 30
29 31 #ifdef __cplusplus
30 32 extern "C" {
31 33 #endif
32 34
33 35 /*
34 36 * Standard SCSI Command Definitions
35 37 *
36 38 * Macros to determine known command sizes
37 39 */
38 40 #define CDB_GROUPID(cmd) ((cmd >> 5) & 0x7)
39 41 #define CDB_GROUPID_0 0
40 42 #define CDB_GROUPID_1 1
41 43 #define CDB_GROUPID_2 2
42 44 #define CDB_GROUPID_3 3
43 45 #define CDB_GROUPID_4 4
44 46 #define CDB_GROUPID_5 5
45 47 #define CDB_GROUPID_6 6
46 48 #define CDB_GROUPID_7 7
47 49
48 50 #define CDB_GROUP0 6 /* 6-byte cdb's */
49 51 #define CDB_GROUP1 10 /* 10-byte cdb's */
50 52 #define CDB_GROUP2 10 /* 10-byte cdb's */
51 53 #define CDB_GROUP3 0 /* reserved */
52 54 #define CDB_GROUP4 16 /* 16-byte cdb's */
53 55 #define CDB_GROUP5 12 /* 12-byte cdb's */
54 56 #define CDB_GROUP6 0 /* reserved */
55 57 #define CDB_GROUP7 0 /* reserved */
56 58
57 59 /*
58 60 * Generic Command Definitions
59 61 * NOTE: CDROM commands are defined in cdio.h
60 62 */
61 63
62 64 /*
63 65 * Group 0 Commands (CDB range 0x00 - 0x1F)
64 66 */
65 67 #define SCMD_GROUP0 0x00
66 68
67 69 /*
68 70 * Group 0 commands, All Devices
69 71 */
70 72 #define SCMD_TEST_UNIT_READY 0x00
71 73 #define SCMD_REQUEST_SENSE 0x03
72 74 #define SCMD_INQUIRY 0x12
73 75 #define SCMD_COPY 0x18
74 76 #define SCMD_GDIAG 0x1C /* receive diagnostic results */
75 77 #define SCMD_SDIAG 0x1D /* send diagnostic results */
76 78
77 79 /*
78 80 * Group 0 commands, Direct Access Devices
79 81 */
80 82 /* SCMD_TEST_UNIT_READY 0x00 */
81 83 #define SCMD_REZERO_UNIT 0x01
82 84 /* SCMD_REQUEST_SENSE 0x03 */
83 85 #define SCMD_FORMAT 0x04
84 86 #define SCMD_REASSIGN_BLOCK 0x07
85 87 #define SCMD_READ 0x08
86 88 #define SCMD_WRITE 0x0a
87 89 #define SCMD_SEEK 0x0b
88 90 /* SCMD_INQUIRY 0x12 */
89 91 #define SCMD_MODE_SELECT 0x15
90 92 #define SCMD_RESERVE 0x16
91 93 #define SCMD_RELEASE 0x17
92 94 /* SCMD_COPY 0x18 */
93 95 #define SCMD_MODE_SENSE 0x1a
94 96 #define SCMD_START_STOP 0x1b
95 97 /* SCMD_GDIAG 0x1C */
96 98 /* SCMD_SDIAG 0x1D */
97 99 #define SCMD_DOORLOCK 0x1E /* Prevent/Allow Medium Removal */
98 100
99 101 /*
100 102 * Group 0 commands, Sequential Access Devices
101 103 */
102 104 /* SCMD_TEST_UNIT_READY 0x00 */
103 105 #define SCMD_REWIND 0x01 /* Note similarity to SCMD_REZERO */
104 106 /* SCMD_REQUEST_SENSE 0x03 */
105 107 #define SCMD_READ_BLKLIM 0x05
106 108 /* SCMD_READ 0x08 */
107 109 /* SCMD_WRITE 0x0a */
108 110 #define SCMD_TRK_SEL 0x0b /* Note similarity to SCMD_SEEK */
109 111 #define SCMD_READ_REVERSE 0x0f
110 112 #define SCMD_WRITE_FILE_MARK 0x10
111 113 #define SCMD_SPACE 0x11
112 114 /* SCMD_INQUIRY 0x12 */
113 115 #define SCMD_VERIFY_G0 0x13
114 116 #define SCMD_RECOVER_BUF 0x14
115 117 /* SCMD_MODE_SELECT 0x15 */
116 118 /* SCMD_RESERVE 0x16 */
117 119 /* SCMD_RELEASE 0x17 */
118 120 /* SCMD_COPY 0x18 */
119 121 #define SCMD_ERASE 0x19
120 122 /* SCMD_MODE_SENSE 0x1a */
121 123 #define SCMD_LOAD 0x1b /* Note similarity to SCMD_START_STOP */
122 124 /* SCMD_GDIAG 0x1c */
123 125 /* SCMD_SDIAG 0x1d */
124 126 /* SCMD_DOORLOCK 0x1e */
125 127
126 128
127 129 /*
128 130 * Group 0 commands, Printer Devices
129 131 */
130 132 /* SCMD_TEST_UNIT_READY 0x00 */
131 133 /* SCMD_REQUEST_SENSE 0x03 */
132 134 /* SCMD_FORMAT 0x04 */
133 135 #define SCMD_PRINT 0x0a /* Note similarity to SCMD_WRITE */
134 136 #define SCMD_SLEW_PRINT 0x0b /* ? similar to SCMD_SEEK ? */
135 137 #define SCMD_FLUSH_PRINT_BUF 0x10 /* ? similar to SCMD_WRITE_FILE_MARK */
136 138 /* SCMD_INQUIRY 0x12 */
137 139 /* SCMD_RECOVER_BUF 0x14 */
138 140 /* SCMD_MODE_SELECT 0x15 */
139 141 /* SCMD_RESERVE 0x16 */
140 142 /* SCMD_RELEASE 0x17 */
141 143 /* SCMD_COPY 0x18 */
142 144 /* SCMD_MODE_SENSE 0x1a */
143 145 #define SCMD_STOP_PRINT 0x1b /* Note similarity to SCMD_START_STOP */
144 146 /* SCMD_GDIAG 0x1c */
145 147 /* SCMD_SDIAG 0x1d */
146 148
147 149 /*
148 150 * Group 0 commands, Processor Devices
149 151 */
150 152 /* SCMD_TEST_UNIT_READY 0x00 */
151 153 /* SCMD_REQUEST_SENSE 0x03 */
152 154 #define SCMD_RECEIVE 0x08 /* Note similarity to SCMD_READ */
153 155 #define SCMD_SEND 0x0a /* Note similarity to SCMD_WRITE */
154 156 /* SCMD_INQUIRY 0x12 */
155 157 /* SCMD_COPY 0x18 */
156 158 /* SCMD_MODE_SENSE 0x1a */
157 159 /* SCMD_GDIAG 0x1c */
158 160 /* SCMD_SDIAG 0x1d */
159 161
160 162 /*
161 163 * Group 0 commands, WORM Devices
162 164 */
163 165 /* SCMD_TEST_UNIT_READY 0x00 */
164 166 /* SCMD_REZERO_UNIT 0x01 */
165 167 /* SCMD_REQUEST_SENSE 0x03 */
166 168 /* SCMD_REASSIGN_BLOCK 0x07 */
167 169 /* SCMD_READ 0x08 */
168 170 /* SCMD_WRITE 0x0a */
169 171 /* SCMD_SEEK 0x0b */
170 172 /* SCMD_INQUIRY 0x12 */
171 173 /* SCMD_MODE_SELECT 0x15 */
172 174 /* SCMD_RESERVE 0x16 */
173 175 /* SCMD_RELEASE 0x17 */
174 176 /* SCMD_COPY 0x18 */
175 177 /* SCMD_MODE_SENSE 0x1a */
176 178 /* SCMD_START_STOP 0x1b */
177 179 /* SCMD_GDIAG 0x1C */
178 180 /* SCMD_SDIAG 0x1D */
179 181 /* SCMD_DOORLOCK 0x1E */
180 182
181 183 /*
182 184 * Group 0 commands, Read Only Devices
183 185 */
184 186 /* SCMD_TEST_UNIT_READY 0x00 */
185 187 /* SCMD_REZERO_UNIT 0x01 */
186 188 /* SCMD_REQUEST_SENSE 0x03 */
187 189 /* SCMD_REASSIGN_BLOCK 0x07 */
188 190 /* SCMD_READ 0x08 */
189 191 /* SCMD_SEEK 0x0b */
190 192 /* SCMD_INQUIRY 0x12 */
191 193 /* SCMD_MODE_SELECT 0x15 */
192 194 /* SCMD_RESERVE 0x16 */
193 195 /* SCMD_RELEASE 0x17 */
194 196 /* SCMD_COPY 0x18 */
195 197 /* SCMD_MODE_SENSE 0x1a */
196 198 /* SCMD_START_STOP 0x1b */
197 199 /* SCMD_GDIAG 0x1C */
198 200 /* SCMD_SDIAG 0x1D */
199 201 /* SCMD_DOORLOCK 0x1E */
200 202
201 203 /*
202 204 * Group 1 Commands (CDB range 0x20 - 0x3F)
203 205 */
204 206 #define SCMD_GROUP1 0x20
205 207
206 208 /*
207 209 * Group 1 Commands, All Devices
208 210 */
209 211 #define SCMD_COMPARE 0x39
210 212 #define SCMD_COPY_VERIFY 0x3A
211 213 #define SCMD_PERSISTENT_RESERVE_IN 0x5E
212 214 #define SCMD_PERSISTENT_RESERVE_OUT 0x5F
213 215 #define SCMD_PRIN SCMD_PERSISTENT_RESERVE_IN
214 216 #define SCMD_PROUT SCMD_PERSISTENT_RESERVE_OUT
215 217
216 218 /*
217 219 * Group 1 Commands, Direct Access Devices
218 220 */
219 221 #define SCMD_READ_FORMAT_CAP 0x23
220 222 #define SCMD_READ_CAPACITY 0x25
221 223 #define SCMD_READ_G1 0x28 /* Note that only the group changed */
222 224 #define SCMD_WRITE_G1 0x2a /* Note that only the group changed */
223 225 #define SCMD_SEEK_G1 0x2b /* Note that only the group changed */
224 226 #define SCMD_WRITE_VERIFY 0x2e
225 227 #define SCMD_VERIFY 0x2f
|
↓ open down ↓ |
192 lines elided |
↑ open up ↑ |
226 228 #define SCMD_SEARCH_HIGH 0x30
227 229 #define SCMD_SEARCH_EQUAL 0x31
228 230 #define SCMD_SEARCH_LOW 0x32
229 231 #define SCMD_SET_LIMITS 0x33
230 232 #define SCMD_SYNCHRONIZE_CACHE 0x35
231 233 #define SCMD_READ_DEFECT_LIST 0x37
232 234 #define SCMD_WRITE_BUFFER 0x3B
233 235 #define SCMD_READ_BUFFER 0x3c
234 236 #define SCMD_READ_LONG 0x3E
235 237 #define SCMD_WRITE_LONG 0x3F
238 +#define SCMD_WRITE_SAME_G1 0x41
239 +#define SCMD_UNMAP 0x42
240 +#define SCMD_GET_CONFIGURATION 0x46
241 +#define SCMD_LOG_SELECT_G1 0x4c
242 +#define SCMD_LOG_SENSE_G1 0x4d
236 243 #define SCMD_RESERVE_G1 0x56
237 244 #define SCMD_RELEASE_G1 0x57
238 245 #define SCMD_MODE_SELECT_G1 0x55
239 246 #define SCMD_MODE_SENSE_G1 0x5A
240 -#define SCMD_GET_CONFIGURATION 0x46
241 -#define SCMD_LOG_SELECT_G1 0x4C
242 -#define SCMD_LOG_SENSE_G1 0x4d
243 247
244 248
245 249 /*
246 250 * Group 1 Commands, Sequential Access Devices
247 251 */
248 252 #define SCMD_LOCATE 0x2B /* Note similarity to SCMD_SEEK_G1 */
249 253 #define SCMD_READ_POSITION 0x34
250 254 #define SCMD_REPORT_DENSITIES 0x44
251 255
252 256 /*
253 257 * Group 1 Commands, Printer Devices
254 258 */
255 259 /* (None Defined) */
256 260
257 261 /*
258 262 * Group 1 Commands, Processor Devices
259 263 */
260 264 /* (None Defined) */
261 265
262 266 /*
263 267 * Group 1 Commands, WORM Devices
264 268 */
265 269 /* SCMD_READ_CAPACITY 0x25 */
266 270 /* SCMD_READ_G1 0x28 */
267 271 /* SCMD_WRITE_G1 0x2a */
268 272 /* SCMD_SEEK_G1 0x2b */
269 273 /* SCMD_WRITE_VERIFY 0x2e */
270 274 /* SCMD_VERIFY 0x2f */
271 275 /* SCMD_SEARCH_HIGH 0x30 */
272 276 /* SCMD_SEARCH_EQUAL 0x31 */
273 277 /* SCMD_SEARCH_LOW 0x32 */
274 278 /* SCMD_SET_LIMITS 0x33 */
275 279
276 280 /*
277 281 * Group 1 Commands, Read Only Devices
278 282 */
279 283 /* SCMD_READ_CAPACITY 0x25 */
280 284 /* SCMD_READ_G1 0x28 */
281 285 /* SCMD_SEEK_G1 0x2b */
282 286 /* SCMD_VERIFY 0x2f */
283 287 /* SCMD_SEARCH_HIGH 0x30 */
284 288 /* SCMD_SEARCH_EQUAL 0x31 */
285 289 /* SCMD_SEARCH_LOW 0x32 */
286 290 /* SCMD_SET_LIMITS 0x33 */
287 291
288 292 /*
289 293 * Group 1 Commands, MMC Devices
290 294 */
291 295
292 296 /* GET EVENT STATUS NOTIFICATION, MMC-3 5.6 */
293 297 #define SCMD_GET_EVENT_STATUS_NOTIFICATION 0x4a
294 298
295 299 /* event header */
296 300 #define SD_GESN_HEADER_LEN 4
297 301 #define SD_GESN_HEADER_NEA 0x80 /* byte 2 */
298 302 #define SD_GESN_HEADER_CLASS 0x07 /* byte 2 */
299 303
300 304 /* media class event class and event data that follows the header */
301 305 #define SD_GESN_MEDIA_CLASS 4
302 306
303 307 #define SD_GESN_MEDIA_DATA_LEN 4
304 308 #define SD_GESN_MEDIA_EVENT_CODE 0x0f /* byte 0 */
305 309 #define SD_GESN_MEDIA_EVENT_STATUS_PRESENT 0x02 /* byte 1 */
306 310 #define SD_GESN_MEDIA_EVENT_STATUS_TRAY_OPEN 0x01 /* byte 1 */
307 311
308 312 /* media event code */
309 313 #define SD_GESN_MEDIA_EVENT_NOCHG 0
310 314 #define SD_GESN_MEDIA_EVENT_EJECTREQUEST 1
311 315 #define SD_GESN_MEDIA_EVENT_NEWMEDIA 2
312 316 #define SD_GESN_MEDIA_EVENT_MEDIAREMOVAL 3
313 317 #define SD_GESN_MEDIA_EVENT_MEDIACHANGED 4
314 318 #define SD_GESN_MEDIA_EVENT_BGFORMATCOMPLETED 5
315 319 #define SD_GESN_MEDIA_EVENT_BGFORMATRESTARTED 6
316 320
317 321
318 322 /*
319 323 * Group 3 Commands
320 324 */
321 325 #define SCMD_VAR_LEN 0x7f
322 326
323 327 /*
324 328 * Group 4 Commands, All Devices
325 329 */
|
↓ open down ↓ |
73 lines elided |
↑ open up ↑ |
326 330 #define SCMD_GROUP4 0x80
327 331 #define SCMD_EXTENDED_COPY 0x83
328 332 #define SCMD_VERIFY_G4 0x8f
329 333
330 334 /*
331 335 * Group 4 Commands, Direct Access Devices
332 336 */
333 337 #define SCMD_READ_G4 0x88
334 338 #define SCMD_WRITE_G4 0x8a
335 339 #define SCMD_WRITE_VERIFY_G4 0x8e
340 +#define SCMD_WRITE_SAME_G4 0x93
336 341 #define SCMD_SVC_ACTION_IN_G4 0x9e
337 342 #define SCMD_SVC_ACTION_OUT_G4 0x9f
338 343
339 344 /*
340 345 * Group 4 Service Actions for Service Action In (16)
341 346 */
342 347 #define SSVC_ACTION_READ_CAPACITY_G4 0x10
343 348 #define SSVC_ACTION_READ_LONG_G4 0x11
344 349
345 350 /*
346 351 * Group 4 Service Actions for Service Action Out (16)
347 352 */
348 353 #define SSVC_ACTION_WRITE_LONG_G4 0x11
349 354
350 355 /*
351 356 * Group 4 Commands, Sequential Access Devics
352 357 */
353 358 #define SCMD_WRITE_FILE_MARK_G4 0x80
354 359 #define SCMD_READ_REVERSE_G4 0x81
355 360 #define SCMD_READ_ATTRIBUTE 0x8c
356 361 #define SCMD_WRITE_ATTRIBUTE 0x8d
357 362 #define SCMD_SPACE_G4 0x91
358 363 #define SCMD_LOCATE_G4 0x92
359 364
360 365 /*
361 366 * Group 5 commands.
362 367 */
363 368 #define SCMD_GROUP5 0xA0
364 369 #define SCMD_REPORT_LUNS 0xA0
365 370 #define SCMD_SECURITY_PROTO_IN 0xA2
366 371 #define SCMD_MAINTENANCE_IN 0xA3
367 372 #define SCMD_MAINTENANCE_OUT 0xA4
368 373 #define SCMD_READ_G5 0xA8
369 374 #define SCMD_WRITE_G5 0xAA
370 375 #define SCMD_SVC_ACTION_OUT_G5 0xA9
371 376 #define SCMD_SVC_ACTION_IN_G5 0xAB
372 377 #define SCMD_GET_PERFORMANCE 0xAC
373 378 #define SCMD_WRITE_VERIFY_G5 0xAE
374 379 #define SCMD_VERIFY_G5 0xAF
375 380 #define SCMD_SECURITY_PROTO_OUT 0xB5
376 381
377 382 /*
378 383 * Group 5 Service Actions for Maintenance In (12)
379 384 */
380 385 #define SSVC_ACTION_GET_TARGET_PORT_GROUPS 0x0a
381 386 #define SSVC_ACTION_GET_SUPPORTED_OPERATIONS 0x0c
382 387 #define SSVC_SCTION_GET_SUPPORTED_MANAGEMENT 0x0d
383 388 #define SSVC_ACTION_GET_TIMESTAMP 0x0f
384 389
385 390 /*
386 391 * Group 5 Service Actions for Maintenance Out (12)
387 392 */
388 393 #define SSVC_ACTION_SET_DEVICE_IDENTIFIER 0x06
389 394 #define SSVC_ACTION_SET_PRIORITY 0x0e
390 395 #define SSVC_ACTION_SET_TARGET_PORT_GROUPS 0x0a
391 396 #define SSVC_ACTION_SET_TIMESTAMP 0x0f
392 397
393 398 /*
394 399 * Group 5 Service Actions for Service Action In (12)
395 400 */
396 401 #define SSVC_ACTION_READ_MEDIA_SERIAL 0x01
397 402 /*
398 403 * scsi_key_strings for SCMD_ definitions
399 404 * NOTE: see SCSI_CMDS_KEY_STRINGS_CDIO in cdio.h for additional
400 405 * command-to-string translations.
401 406 */
402 407 #define SCSI_CMDS_KEY_STRINGS \
403 408 /* 0x00 */ SCMD_TEST_UNIT_READY, "test_unit_ready", \
404 409 /* 0x01 */ SCMD_REWIND | \
405 410 SCMD_REZERO_UNIT, "rezero/rewind", \
406 411 /* 0x03 */ SCMD_REQUEST_SENSE, "request_sense", \
407 412 /* 0x04 */ SCMD_FORMAT, "format", \
408 413 /* 0x05 */ SCMD_READ_BLKLIM, "read_block_limits", \
409 414 /* 0x07 */ SCMD_REASSIGN_BLOCK, "reassign", \
410 415 /* 0x08 */ SCMD_READ | \
411 416 SCMD_RECEIVE, "read", \
412 417 /* 0x0a */ SCMD_PRINT | \
413 418 SCMD_SEND | \
414 419 SCMD_WRITE, "write", \
415 420 /* 0x0b */ SCMD_SEEK | \
416 421 SCMD_SLEW_PRINT | \
417 422 SCMD_TRK_SEL, "seek", \
418 423 /* 0x0f */ SCMD_READ_REVERSE, "read_reverse", \
419 424 /* 0x10 */ SCMD_WRITE_FILE_MARK | \
420 425 SCMD_FLUSH_PRINT_BUF, "write_file_mark", \
421 426 /* 0x11 */ SCMD_SPACE, "space", \
422 427 /* 0x12 */ SCMD_INQUIRY, "inquiry", \
423 428 /* 0x13 */ SCMD_VERIFY_G0, "verify", \
424 429 /* 0x14 */ SCMD_RECOVER_BUF, "recover_buffer_data", \
425 430 /* 0x15 */ SCMD_MODE_SELECT, "mode_select", \
426 431 /* 0x16 */ SCMD_RESERVE, "reserve", \
427 432 /* 0x17 */ SCMD_RELEASE, "release", \
428 433 /* 0x18 */ SCMD_COPY, "copy", \
429 434 /* 0x19 */ SCMD_ERASE, "erase_tape", \
430 435 /* 0x1a */ SCMD_MODE_SENSE, "mode_sense", \
431 436 /* 0x1b */ SCMD_LOAD | \
432 437 SCMD_START_STOP | \
433 438 SCMD_STOP_PRINT, "load/start/stop", \
434 439 /* 0x1c */ SCMD_GDIAG, "get_diagnostic_results", \
435 440 /* 0x1d */ SCMD_SDIAG, "send_diagnostic_command", \
436 441 /* 0x1e */ SCMD_DOORLOCK, "door_lock", \
437 442 /* 0x23 */ SCMD_READ_FORMAT_CAP, "read_format_capacity", \
438 443 /* 0x25 */ SCMD_READ_CAPACITY, "read_capacity", \
439 444 /* 0x28 */ SCMD_READ_G1, "read(10)", \
440 445 /* 0x2a */ SCMD_WRITE_G1, "write(10)", \
441 446 /* 0x2b */ SCMD_SEEK_G1 | \
442 447 SCMD_LOCATE, "seek(10)", \
443 448 /* 0x2e */ SCMD_WRITE_VERIFY, "write_verify", \
444 449 /* 0x2f */ SCMD_VERIFY, "verify(10)", \
445 450 /* 0x30 */ SCMD_SEARCH_HIGH, "search_data_high", \
446 451 /* 0x31 */ SCMD_SEARCH_EQUAL, "search_data_equal", \
447 452 /* 0x32 */ SCMD_SEARCH_LOW, "search_data_low", \
|
↓ open down ↓ |
102 lines elided |
↑ open up ↑ |
448 453 /* 0x33 */ SCMD_SET_LIMITS, "set_limits", \
449 454 /* 0x34 */ SCMD_READ_POSITION, "read_position", \
450 455 /* 0x35 */ SCMD_SYNCHRONIZE_CACHE, "synchronize_cache", \
451 456 /* 0x37 */ SCMD_READ_DEFECT_LIST, "read_defect_data", \
452 457 /* 0x39 */ SCMD_COMPARE, "compare", \
453 458 /* 0x3a */ SCMD_COPY_VERIFY, "copy_verify", \
454 459 /* 0x3b */ SCMD_WRITE_BUFFER, "write_buffer", \
455 460 /* 0x3c */ SCMD_READ_BUFFER, "read_buffer", \
456 461 /* 0x3e */ SCMD_READ_LONG, "read_long", \
457 462 /* 0x3f */ SCMD_WRITE_LONG, "write_long", \
463 +/* 0x41 */ SCMD_WRITE_SAME_G1, "write_same(10)", \
464 +/* 0x42 */ SCMD_UNMAP, "unmap", \
458 465 /* 0x44 */ SCMD_REPORT_DENSITIES | \
459 466 /* SCMD_READ_HEADER (from cdio.h) | */ \
460 467 0, "report_densities/read_header", \
461 468 /* 0x4c */ SCMD_LOG_SELECT_G1, "log_select", \
462 469 /* 0x4d */ SCMD_LOG_SENSE_G1, "log_sense", \
463 470 /* 0x55 */ SCMD_MODE_SELECT_G1, "mode_select(10)", \
464 471 /* 0x56 */ SCMD_RESERVE_G1, "reserve(10)", \
465 472 /* 0x57 */ SCMD_RELEASE_G1, "release(10)", \
466 473 /* 0x5a */ SCMD_MODE_SENSE_G1, "mode_sense(10)", \
467 474 /* 0x5e */ SCMD_PERSISTENT_RESERVE_IN, "persistent_reserve_in", \
468 475 /* 0x5f */ SCMD_PERSISTENT_RESERVE_OUT, "persistent_reserve_out", \
469 476 /* 0x80 */ SCMD_WRITE_FILE_MARK_G4, "write_file_mark(16)", \
|
↓ open down ↓ |
2 lines elided |
↑ open up ↑ |
470 477 /* 0x81 */ SCMD_READ_REVERSE_G4, "read_reverse(16)", \
471 478 /* 0x83 */ SCMD_EXTENDED_COPY, "extended_copy", \
472 479 /* 0x88 */ SCMD_READ_G4, "read(16)", \
473 480 /* 0x8a */ SCMD_WRITE_G4, "write(16)", \
474 481 /* 0x8c */ SCMD_READ_ATTRIBUTE, "read_attribute", \
475 482 /* 0x8d */ SCMD_WRITE_ATTRIBUTE, "write_attribute", \
476 483 /* 0x8e */ SCMD_WRITE_VERIFY_G4, "write_verify(16)", \
477 484 /* 0x8f */ SCMD_VERIFY_G4, "verify(16)", \
478 485 /* 0x91 */ SCMD_SPACE_G4, "space(16)", \
479 486 /* 0x92 */ SCMD_LOCATE_G4, "locate(16)", \
487 +/* 0x92 */ SCMD_WRITE_SAME_G4, "write_same(16)", \
480 488 /* 0x9e */ SCMD_SVC_ACTION_IN_G4, "service_action_in(16)", \
481 489 /* 0x9f */ SCMD_SVC_ACTION_OUT_G4, "service_action_out(16)", \
482 490 /* 0xa0 */ SCMD_REPORT_LUNS, "report_luns", \
483 491 /* 0xa2 */ SCMD_SECURITY_PROTO_IN, "security_protocol_in", \
484 492 /* 0xa3 */ SCMD_MAINTENANCE_IN, "maintenance_in", \
485 493 /* 0xa4 */ SCMD_MAINTENANCE_OUT, "maintenance_out", \
486 494 /* 0xa8 */ SCMD_READ_G5, "read(12)", \
487 495 /* 0xa9 */ SCMD_SVC_ACTION_OUT_G5, "service_action_out(12)", \
488 496 /* 0xaa */ SCMD_WRITE_G5, "write(12)", \
489 497 /* 0xab */ SCMD_SVC_ACTION_IN_G5, "service_action_in(12)", \
490 498 /* 0xac */ SCMD_GET_PERFORMANCE, "get_performance", \
491 499 /* 0xAE */ SCMD_WRITE_VERIFY_G5, "write_verify(12)", \
492 500 /* 0xAF */ SCMD_VERIFY_G5, "verify(12)", \
493 501 /* 0xb5 */ SCMD_SECURITY_PROTO_OUT, "security_protocol_out" \
494 502 /* see cdio.h for additional command-to-string translations */
495 503
496 504 /* XXX not a command code, does not belong here */
497 505 #define ATAPI_CAPABILITIES 0x2A
498 506
499 507 #ifdef __cplusplus
500 508 }
501 509 #endif
502 510
503 511 /*
504 512 * Below are inclusions of files describing various command structures
505 513 * of interest.
506 514 */
507 515 #include <sys/scsi/generic/inquiry.h>
508 516 #include <sys/scsi/generic/sense.h>
509 517
510 518 /*
511 519 * Private Vendor Unique Commands - Each implementation provides this.
512 520 */
513 521 #include <sys/scsi/impl/commands.h>
514 522
515 523 #endif /* _SYS_SCSI_GENERIC_COMMANDS_H */
|
↓ open down ↓ |
26 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX