TianoCore EDK2 master
Loading...
Searching...
No Matches
ScsiPassThruExt.h
Go to the documentation of this file.
1
11#ifndef __EXT_SCSI_PASS_THROUGH_PROTOCOL_H__
12#define __EXT_SCSI_PASS_THROUGH_PROTOCOL_H__
13
14#define EFI_EXT_SCSI_PASS_THRU_PROTOCOL_GUID \
15 { \
16 0x143b7632, 0xb81b, 0x4cb7, {0xab, 0xd3, 0xb6, 0x25, 0xa5, 0xb9, 0xbf, 0xfe } \
17 }
18
20
21#define TARGET_MAX_BYTES 0x10
22
23#define EFI_EXT_SCSI_PASS_THRU_ATTRIBUTES_PHYSICAL 0x0001
24#define EFI_EXT_SCSI_PASS_THRU_ATTRIBUTES_LOGICAL 0x0002
25#define EFI_EXT_SCSI_PASS_THRU_ATTRIBUTES_NONBLOCKIO 0x0004
26
27//
28// DataDirection
29//
30#define EFI_EXT_SCSI_DATA_DIRECTION_READ 0
31#define EFI_EXT_SCSI_DATA_DIRECTION_WRITE 1
32#define EFI_EXT_SCSI_DATA_DIRECTION_BIDIRECTIONAL 2
33//
34// HostAdapterStatus
35//
36#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_OK 0x00
37#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_TIMEOUT_COMMAND 0x09
38#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_TIMEOUT 0x0b
39#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_MESSAGE_REJECT 0x0d
40#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_BUS_RESET 0x0e
41#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_PARITY_ERROR 0x0f
42#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_REQUEST_SENSE_FAILED 0x10
43#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_SELECTION_TIMEOUT 0x11
44#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_DATA_OVERRUN_UNDERRUN 0x12
45#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_BUS_FREE 0x13
46#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_PHASE_ERROR 0x14
47#define EFI_EXT_SCSI_STATUS_HOST_ADAPTER_OTHER 0x7f
48//
49// TargetStatus
50//
51#define EFI_EXT_SCSI_STATUS_TARGET_GOOD 0x00
52#define EFI_EXT_SCSI_STATUS_TARGET_CHECK_CONDITION 0x02
53#define EFI_EXT_SCSI_STATUS_TARGET_CONDITION_MET 0x04
54#define EFI_EXT_SCSI_STATUS_TARGET_BUSY 0x08
55#define EFI_EXT_SCSI_STATUS_TARGET_INTERMEDIATE 0x10
56#define EFI_EXT_SCSI_STATUS_TARGET_INTERMEDIATE_CONDITION_MET 0x14
57#define EFI_EXT_SCSI_STATUS_TARGET_RESERVATION_CONFLICT 0x18
58#define EFI_EXT_SCSI_STATUS_TARGET_TASK_SET_FULL 0x28
59#define EFI_EXT_SCSI_STATUS_TARGET_ACA_ACTIVE 0x30
60#define EFI_EXT_SCSI_STATUS_TARGET_TASK_ABORTED 0x40
61
62typedef struct {
66 UINT32 AdapterId;
70 UINT32 Attributes;
74 UINT32 IoAlign;
76
77typedef struct {
86 UINT64 Timeout;
106 VOID *Cdb;
143
185typedef
189 IN UINT8 *Target,
190 IN UINT64 Lun,
192 IN EFI_EVENT Event OPTIONAL
193 );
194
221typedef
225 IN OUT UINT8 **Target,
226 IN OUT UINT64 *Lun
227 );
228
256typedef
260 IN UINT8 *Target,
261 IN UINT64 Lun,
262 OUT EFI_DEVICE_PATH_PROTOCOL **DevicePath
263 );
264
284typedef
288 IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
289 OUT UINT8 **Target,
290 OUT UINT64 *Lun
291 );
292
304typedef
308 );
309
329typedef
333 IN UINT8 *Target,
334 IN UINT64 Lun
335 );
336
359typedef
363 IN OUT UINT8 **Target
364 );
365
384};
385
386extern EFI_GUID gEfiExtScsiPassThruProtocolGuid;
387
388#endif
#define OPTIONAL
Definition: Base.h:290
#define IN
Definition: Base.h:279
#define OUT
Definition: Base.h:284
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_RESET_CHANNEL)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This)
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_BUILD_DEVICE_PATH)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN UINT8 *Target, IN UINT64 Lun, OUT EFI_DEVICE_PATH_PROTOCOL **DevicePath)
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_GET_TARGET_LUN)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN EFI_DEVICE_PATH_PROTOCOL *DevicePath, OUT UINT8 **Target, OUT UINT64 *Lun)
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_RESET_TARGET_LUN)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN UINT8 *Target, IN UINT64 Lun)
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_PASSTHRU)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN UINT8 *Target, IN UINT64 Lun, IN OUT EFI_EXT_SCSI_PASS_THRU_SCSI_REQUEST_PACKET *Packet, IN EFI_EVENT Event OPTIONAL)
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_GET_NEXT_TARGET_LUN)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN OUT UINT8 **Target, IN OUT UINT64 *Lun)
EFI_STATUS(EFIAPI * EFI_EXT_SCSI_PASS_THRU_GET_NEXT_TARGET)(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN OUT UINT8 **Target)
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29
VOID * EFI_EVENT
Definition: UefiBaseType.h:37
EFI_EXT_SCSI_PASS_THRU_MODE * Mode
Definition: Base.h:213