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