1 /**************************************************************************
3 * This file should be source compatible with the Adaptec winaspi.h
4 * All DOS ASPI structures are the same as WINASPI
10 /* Include base aspi defs */
15 #endif /* #ifdef __cplusplus */
25 typedef struct tagSRB16_HaInquiry
{
30 WORD SRB_55AASignature
;
31 WORD SRB_ExtBufferSize
;
34 BYTE HA_ManagerId
[16];
35 BYTE HA_Identifier
[16];
38 } SRB_HaInquiry16
, *PSRB_HaInquiry16
, *LPSRB_HaInquiry16
;
40 typedef struct tagSRB16_GDEVBlock
{
41 BYTE SRB_Cmd
; /* ASPI command code = SC_GET_DEV_TYPE */
42 BYTE SRB_Status
; /* ASPI command status byte */
43 BYTE SRB_HaId
; /* ASPI host adapter number */
44 BYTE SRB_Flags
; /* ASPI request flags */
45 DWORD SRB_Hdr_Rsvd
; /* Reserved, MUST = 0 */
46 BYTE SRB_Target
; /* Target's SCSI ID */
47 BYTE SRB_Lun
; /* Target's LUN number */
48 BYTE SRB_DeviceType
; /* Target's peripheral device type */
49 } SRB_GDEVBlock16
, *PSRB_GDEVBlock16
, *LPSRB_GDEVBlock16
;
52 typedef struct tagSRB16_ExecSCSICmd
{
53 BYTE SRB_Cmd
; /* ASPI command code (W) */
54 BYTE SRB_Status
; /* ASPI command status byte (R) */
55 BYTE SRB_HaId
; /* ASPI host adapter number (W) */
56 BYTE SRB_Flags
; /* ASPI request flags (W) */
57 DWORD SRB_Hdr_Rsvd
; /* Reserved, MUST = 0 (-) */
58 BYTE SRB_Target
; /* Target's SCSI ID (W) */
59 BYTE SRB_Lun
; /* Target's LUN number (W) */
60 DWORD SRB_BufLen
; /* Data Allocation LengthPG (W/R)*/
61 BYTE SRB_SenseLen
; /* Sense Allocation Length (W) */
62 SEGPTR SRB_BufPointer
; /* Data Buffer Pointer (W) */
63 DWORD SRB_Rsvd1
; /* Reserved, MUST = 0 (-/W)*/
64 BYTE SRB_CDBLen
; /* CDB Length = 6 (W) */
65 BYTE SRB_HaStat
; /* Host Adapter Status (R) */
66 BYTE SRB_TargStat
; /* Target Status (R) */
67 FARPROC16 SRB_PostProc
; /* Post routine (W) */
68 BYTE SRB_Rsvd2
[34]; /* Reserved, MUST = 0 */
69 BYTE CDBByte
[1]; /* SCSI CBD - variable length (W) */
70 /* variable example for 6 byte cbd
71 * BYTE CDBByte[6]; * SCSI CDB (W) *
72 * BYTE SenseArea6[SENSE_LEN]; * Request Sense buffer (R) *
74 } SRB_ExecSCSICmd16
, *PSRB_ExecSCSICmd16
, *LPSRB_ExecSCSICmd16
;
76 typedef struct tagSRB16_Abort
{
77 BYTE SRB_Cmd
; /* ASPI command code = SC_ABORT_SRB */
78 BYTE SRB_Status
; /* ASPI command status byte */
79 BYTE SRB_HaId
; /* ASPI host adapter number */
80 BYTE SRB_Flags
; /* ASPI request flags */
81 DWORD SRB_Hdr_Rsvd
; /* Reserved, MUST = 0 */
82 SEGPTR SRB_ToAbort
; /* Pointer to SRB to abort */
83 } SRB_Abort16
, *PSRB_Abort16
, *LPSRB_Abort16
;
86 typedef struct tagSRB16_BusDeviceReset
{
87 BYTE SRB_Cmd
; /* ASPI command code = SC_RESET_DEV */
88 BYTE SRB_Status
; /* ASPI command status byte */
89 BYTE SRB_HaId
; /* ASPI host adapter number */
90 BYTE SRB_Flags
; /* ASPI request flags */
91 DWORD SRB_Hdr_Rsvd
; /* Reserved, MUST = 0 */
92 BYTE SRB_Target
; /* Target's SCSI ID */
93 BYTE SRB_Lun
; /* Target's LUN number */
94 BYTE SRB_ResetRsvd1
[14]; /* Reserved, MUST = 0 */
95 BYTE SRB_HaStat
; /* Host Adapter Status */
96 BYTE SRB_TargStat
; /* Target Status */
97 FARPROC16 SRB_PostProc
; /* Post routine */
98 BYTE SRB_ResetRsvd2
[34]; /* Reserved, MUST = 0 */
99 } SRB_BusDeviceReset16
, *PSRB_BusDeviceReset16
, *LPSRB_BusDeviceReset16
;
102 typedef struct tagSRB16_Common
{
103 BYTE SRB_Cmd
; /* ASPI command code = SC_ABORT_SRB */
104 BYTE SRB_Status
; /* ASPI command status byte */
105 BYTE SRB_HaId
; /* ASPI host adapter number */
106 BYTE SRB_Flags
; /* ASPI request flags */
107 DWORD SRB_Hdr_Rsvd
; /* Reserved, MUST = 0 */
108 } SRB_Common16
, *PSRB_Common16
, *LPSRB_Common16
;
110 typedef union tagSRB16
{
112 SRB_HaInquiry16 inquiry
;
113 SRB_ExecSCSICmd16 cmd
;
115 SRB_BusDeviceReset16 reset
;
116 SRB_GDEVBlock16 devtype
;
121 extern WORD WINAPI
SendASPICommand16(SEGPTR
);
122 extern WORD WINAPI
GetASPISupportInfo16(void);
126 #endif /* #ifdef __cplusplus */
128 #endif /* __WINE_WINASPI_H */