Intel Extensible Firmware Interface User Manual
Page 528

Extensible Firmware Interface Specification
13-8
12/01/02
Version 1.10
Description
The
EFI_SCSI_PASS_THRU_PROTOCOL.PassThru()
function sends the SCSI Request
Packet specified by
Packet
to the SCSI device specified by
Target
and
Lun
. If the driver
supports nonblocking I/O and
Event
is not
NULL
, then the driver will return immediately after the
command is sent to the selected device, and will later signal
Event
when the command has
completed. If the driver supports nonblocking I/O and
Event
is
NULL
, then the driver will send
the command to the selected device and block until it is complete. If the driver does not support
nonblocking I/O, the
Event
parameter is ignored, and the driver will send the command to the
selected device and block until it is complete.
If
Packet
is successfully sent to the SCSI device, then
EFI_SUCCESS
is returned.
If
Packet
cannot be sent because there are too many packets already queued up, then
EFI_NOT_READY
is returned. The caller may retry
Packet
at a later time.
If a device error occurs while sending the
Packet
, then
EFI_DEVICE_ERROR
is returned.
If a timeout occurs during the execution of
Packet
, then
EFI_TIMEOUT
is returned.
If
Target
or
Lun
are not in a valid range for the SCSI channel, then
EFI_INVALID_PARAMETER
is returned. If
DataBuffer
or
SenseData
do not meet the
alignment requirement specified by the
IoAlign
field of the
structure, then
EFI_INVALID_PARAMETER
is returned. If any of the other fields of
Packet
are
invalid, then
EFI_INVALID_PARAMETER
is returned.
If the data buffer described by
DataBuffer
and
TransferLength
is too big to be transferred
in a single command, then no data is transferred and
EFI_BAD_BUFFER_SIZE
is returned. The
number of bytes that can be transferred in a single command are returned in
TransferLength
.
If the command described in
Packet
is not supported by the host adapter, then
EFI_UNSUPPORTED
is returned.
If
EFI_SUCCESS
,
EFI_WARN_BUFFER_TOO_SMALL
,
EFI_DEVICE_ERROR
, or
EFI_TIMEOUT
is returned, then the caller must examine the status fields in
Packet
in the
following precedence order:
HostAdapterStatus
followed by
TargetStatus
followed by
SenseDataLength
, followed by
SenseData
. If nonblocking I/O is being used, then the status
fields in
Packet
will not be valid until the
Event
associated with
Packet
is signaled.
If
EFI_NOT_READY
,
EFI_INVALID_PARAMETER
or
EFI_UNSUPPORTED
is returned, then
Packet
was never sent, so the status fields in
Packet
are not valid. If nonblocking I/O is being
used, the
Event
associated with
Packet
will not be signaled.