/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright (c) 1996,2000 by Sun Microsystems, Inc.
* All rights reserved.
*/
#ifndef _SYS_SCSI_GENERIC_MESSAGE_H
#define _SYS_SCSI_GENERIC_MESSAGE_H
#pragma ident "%Z%%M% %I% %E% SMI"
#ifdef __cplusplus
extern "C" {
#endif
/*
* Defined Messages For Parallel SCSI.
*/
/*
* The SCSI specification defines message codes 0x00, 0x02-0x1F,
* as fixed single byte messages, 0x01 as indicating extended (multi-byte)
* messages, 0x20-0x2F as fixed two byte messages, and 0x80-0xFF
* as IDENTIFY messages.
*/
/*
* Message code 0x01 indicates an extended
* (two or more) byte message. The EXTENDED
* message byte is followed immediately by
* a message length byte and then an extended
* message code byte.
*
* Note: The EXTENDED IDENTIFY message is pre-SCSI-2.
*/
/*
* parallel protocol message optional flags
*/
/*
* Message codes 0x20-0x2F are fixed two byte messages.
*/
/*
* Codes 0x80-0xFF are identify messages, indicated
* by the setting of the most significant bit in the
* message (0x80).
*/
/*
* Initiators will set bit 6 in an Identify message
* to indicate whether or not they can accommodate
*/
/*
* ..so we can have a compound definition
* for Initiators that can accommodate
*/
/*
* Note: Following is ONLY applicable to pre-SCSI-3.
*
* Bit 5 of the identify message specifies that, if zero,
* that the IDENTIFY message is directed to a logical unit,
* and if one, that the IDENTIFY message is directed to a
* target routine that does not involve a logical unit.
*/
/*
* Note: Following is ONLY applicable to pre-SCSI-3.
*
* Bits 2-0 identify either the logical unit or the target
* routine number based upon whether MSG_LUNTAR is clear
* or set.
*/
/*
* Note: Following is ONLY applicable to pre-SCSI-3.
*
* Bits 4-3 are reserved and must be zero.
*/
/*
* These macros may be useful to quickly determine the
* length of a message based upon the message code.
*/
/*
* Note: IS_IDENTIFY_MSG is ONLY applicable to pre-SCSI-3.
* For SCSI-3, use IS_IDENTIFY_MSG_SCSI3.
*/
#ifdef __cplusplus
}
#endif
#endif /* _SYS_SCSI_GENERIC_MESSAGE_H */