; ******************************************************************************************************************************** ; Created: 17-APR-1997 22:18:23 by OpenVMS SDL EV1-52 ; Source: 28-SEP-1994 12:58:58 $64$DUA2530:[SCSI.SRC]MODEDEF.SDL;1 ; ******************************************************************************************************************************** .MACRO $MODEDEF,$GBL $DEFINI MODE,$GBL ; ; Mode Sense Field Descriptor /* Describe specific field in mode pg ; $EQU MODE_DESC$M_PREFERRED <^X1> $EQU MODE_DESC$M_REQUIRED <^X2> $EQU MODE_DESC$M_IFMISSING <^X4> $EQU MODE_DESC$M_IFMISMATCH <^X8> $EQU MODE_DESC$M_DESPTR <^X10> $EQU MODE_DESC$M_ACTPTR <^X20> $EQU MODE_DESC$M_LAST <^X40> $EQU MODE_DESC$M_FILL1 <^XFFFFFF80> $EQU MODE_DESC$C_MATCH 0 ; They match $EQU MODE_DESC$C_FIXED 1 ; Field is read-only (unchangeable) $EQU MODE_DESC$C_MISMATCH 2 ; Mismatch $EQU MODE_DESC$C_MISSING 3 ; Field is missing $EQU MODE_DESC$C_BADDSC 4 ; Bad descriptor $EQU MODE_DESC$C_INCOMPLETE 5 ; Incomplete field returned ; $EQU MODE_DESC$M_CURRENT_PHASE <^X1> $EQU MODE_DESC$M_CHANGE_PHASE <^X2> $EQU MODE_DESC$M_SELECT_PHASE <^X4> $EQU MODE_DESC$M_VERIFY_PHASE <^X8> $EQU MODE_DESC$M_FILL2 <^XFFFFFFF0> $EQU MODE_DESC$S_FIELD_DESCRIPTOR 40 $EQU MODE_DESC$L_BOFF 0 ; Byte offset of field in page $EQU MODE_DESC$L_BIT_OFFSET 4 ; Starting bit position within byte $EQU MODE_DESC$L_BIT_SIZE 8 ; Size of field in bits $EQU MODE_DESC$S_FLAGS 4 $EQU MODE_DESC$R_FLAGS 12 ; $EQU MODE_DESC$V_PREFERRED 0 ; Indicates nice-to-have bit $EQU MODE_DESC$V_REQUIRED 1 ; Indicates must-have bit $EQU MODE_DESC$V_IFMISSING 2 ; If field missing, error exit $EQU MODE_DESC$V_IFMISMATCH 3 ; If mismatch, error exit $EQU MODE_DESC$V_DESPTR 4 ; DESIRED is a ptr, not value $EQU MODE_DESC$V_ACTPTR 5 ; ACTUAL is a ptr, not value $EQU MODE_DESC$V_LAST 6 ; Mark last desc for this page ; $EQU MODE_DESC$S_DESIRED 8 $EQU MODE_DESC$L_DESIRED 16 ; Desired value (or ptr to it) $EQU MODE_DESC$S_ACTUAL 8 $EQU MODE_DESC$L_ACTUAL 24 ; Actual value (or ptr to it) $EQU MODE_DESC$L_REASON 32 ; Reason for mismatch of Desired/Actual ; $EQU MODE_DESC$S_RESERVED 4 $EQU MODE_DESC$R_RESERVED 36 $EQU MODE_DESC$V_CURRENT_PHASE 0 ; Mode_sense current completed $EQU MODE_DESC$V_CHANGE_PHASE 1 ; Mode_sense chngable completed $EQU MODE_DESC$V_SELECT_PHASE 2 ; Mode_select completed $EQU MODE_DESC$V_VERIFY_PHASE 3 ; In verify pass of Mode Sense ; ; ; ; ; Mode Sense Argument Descriptor ; $EQU MPA_ARGS$S_SCSI_MPA 60 $EQU MPA_ARGS$PS_FIELD_DESC 0 ; Pointer to (array of) field descriptors $EQU MPA_ARGS$L_DESCRIPTOR_COUNT 4 ; Count of descriptors $EQU MPA_ARGS$PS_CURR_DESC_PTR 8 ; Pointer to current descriptor $EQU MPA_ARGS$PS_BUFFER_PTR 12 ; Pointer to mode sense buffer $EQU MPA_ARGS$L_BUFFER_SIZE 16 ; Size of mode sense buffer $EQU MPA_ARGS$PS_PAGE_DATA_PTR 20 ; Ptr to mode sense data, minus hdr $EQU MPA_ARGS$L_PAGE_SIZE 24 ; Size of mode sense data $EQU MPA_ARGS$PS_SELECT_BUFF_PTR 28 ; Pointer to mode select buff, incl hdr $EQU MPA_ARGS$L_SELECT_BUFF_SIZE 32 ; Size of select buff, incl hdr $EQU MPA_ARGS$PS_SELECT_DATA_PTR 36 ; Pointer to mode select data, minus hdr $EQU MPA_ARGS$L_SELECT_DATA_SIZE 40 ; Size of select data, minus hdr $EQU MPA_ARGS$PS_VALUE_BUFFER_PTR 44 ; Alt buffer to return changeable data $EQU MPA_ARGS$L_ERROR 48 ; Most recent error $EQU MPA_ARGS$L_FIELD_ERROR 52 ; Worst potential error $EQU MPA_ARGS$B_PAGE_CODE 56 ; Indicates which mode page $EQU MPA_ARGS$B_VERIFY_IN_PROGRESS 57 ; Verify pass in progress $EQU MPA_ARGS$B_TEN_BYTE_CMD 58 ; 10-byte mode sense/select flag $EQU MPA_ARGS$B_REQ_BITS_PRESENT 59 ; At least one desc has REQ set ; ; Unique BOFF values to identify fields in mode page header or block descriptor $EQU MODE_DESC$C_LENGTH_BOFF -1 ; Mode data length $EQU MODE_DESC$C_MEDTYP_BOFF -2 ; Medium type $EQU MODE_DESC$C_DEVPAR_BOFF -3 ; Device-specific param $EQU MODE_DESC$C_BDLEN_BOFF -4 ; Block descriptor length $EQU MODE_DESC$C_DENS_BOFF -5 ; (First) block descriptor dens $EQU MODE_DESC$C_BLKLEN_BOFF -6 ; (First) block descriptor blklen $DEFEND MODE,$GBL,DEF .ENDM