162306a36Sopenharmony_ci/* 262306a36Sopenharmony_ci * This file is in the public domain. 362306a36Sopenharmony_ci * $FreeBSD: src/sys/cam/scsi/scsi_message.h,v 1.2 2000/05/01 20:21:29 peter Exp $ 462306a36Sopenharmony_ci */ 562306a36Sopenharmony_ci 662306a36Sopenharmony_ci/* Messages (1 byte) */ /* I/T (M)andatory or (O)ptional */ 762306a36Sopenharmony_ci#define MSG_SAVEDATAPOINTER 0x02 /* O/O */ 862306a36Sopenharmony_ci#define MSG_RESTOREPOINTERS 0x03 /* O/O */ 962306a36Sopenharmony_ci#define MSG_DISCONNECT 0x04 /* O/O */ 1062306a36Sopenharmony_ci#define MSG_MESSAGE_REJECT 0x07 /* M/M */ 1162306a36Sopenharmony_ci#define MSG_NOOP 0x08 /* M/M */ 1262306a36Sopenharmony_ci 1362306a36Sopenharmony_ci/* Messages (2 byte) */ 1462306a36Sopenharmony_ci#define MSG_SIMPLE_Q_TAG 0x20 /* O/O */ 1562306a36Sopenharmony_ci#define MSG_IGN_WIDE_RESIDUE 0x23 /* O/O */ 1662306a36Sopenharmony_ci 1762306a36Sopenharmony_ci/* Identify message */ /* M/M */ 1862306a36Sopenharmony_ci#define MSG_IDENTIFYFLAG 0x80 1962306a36Sopenharmony_ci#define MSG_IDENTIFY_DISCFLAG 0x40 2062306a36Sopenharmony_ci#define MSG_IDENTIFY(lun, disc) (((disc) ? 0xc0 : MSG_IDENTIFYFLAG) | (lun)) 2162306a36Sopenharmony_ci#define MSG_ISIDENTIFY(m) ((m) & MSG_IDENTIFYFLAG) 2262306a36Sopenharmony_ci#define MSG_IDENTIFY_LUNMASK 0x3F 2362306a36Sopenharmony_ci 2462306a36Sopenharmony_ci/* Extended messages (opcode and length) */ 2562306a36Sopenharmony_ci#define MSG_EXT_SDTR_LEN 0x03 2662306a36Sopenharmony_ci 2762306a36Sopenharmony_ci#define MSG_EXT_WDTR_LEN 0x02 2862306a36Sopenharmony_ci#define MSG_EXT_WDTR_BUS_8_BIT 0x00 2962306a36Sopenharmony_ci#define MSG_EXT_WDTR_BUS_16_BIT 0x01 3062306a36Sopenharmony_ci#define MSG_EXT_WDTR_BUS_32_BIT 0x02 /* Deprecated in SPI3 */ 3162306a36Sopenharmony_ci 3262306a36Sopenharmony_ci#define MSG_EXT_PPR_LEN 0x06 3362306a36Sopenharmony_ci#define MSG_EXT_PPR_PCOMP_EN 0x80 3462306a36Sopenharmony_ci#define MSG_EXT_PPR_RTI 0x40 3562306a36Sopenharmony_ci#define MSG_EXT_PPR_RD_STRM 0x20 3662306a36Sopenharmony_ci#define MSG_EXT_PPR_WR_FLOW 0x10 3762306a36Sopenharmony_ci#define MSG_EXT_PPR_HOLD_MCS 0x08 3862306a36Sopenharmony_ci#define MSG_EXT_PPR_QAS_REQ 0x04 3962306a36Sopenharmony_ci#define MSG_EXT_PPR_DT_REQ 0x02 4062306a36Sopenharmony_ci#define MSG_EXT_PPR_IU_REQ 0x01 41