Specifications
System Macros Invoked by Drivers
SPI$QUEUE_COMMAND
SPI$QUEUE_COMMAND
Initiates a new I/O to the port driver for queued SCSI-2 command tagged
requests.
Format
SPI$QUEUE_COMMAND
Description
The SPI$QUEUE_COMMAND initiates a new I/O to the port driver for queued
SCSI-2 command tagged requests. This macro is similar to the SPI$SEND_
COMMAND, but SPI$QUEUE_COMMAND does not wait for command
completion in the device before returning to the class driver.
A class driver first calls SPI$ALLOCATE_COMMAND_BUFFER to allocate a port
command buffer and then formats a SCSI command descriptor block in the buffer
before invoking this macro. The class driver may need to call SPI$MAP_BUFFER
to allocate and map user buffer resources. To execute a burst of I/O requests, the
class driver may call SPI$QUEUE_COMMAND for each request without waiting
for any of these I/Os to complete. Each request must use a different SCDRP and
separately allocate the needed resources. When the I/O request completes, the
port driver then returns SCSI status to the class driver.
Table 2–8 lists the inputs to the SPI$QUEUE_COMMAND macro.
Table 2–8 Inputs to the SPI$QUEUE_COMMAND Macro
Location Contents
R0 Queue characteristics (constants, QCHAR$K_xxx).
R3 Address of the UCB.
R4 Address of the SPDT.
R5 Address of the SCDRP. The class driver must provide values
in the following fields:
SCDRP$L_CMD_PTR Address of the port command
buffer. The first longword of the
port command buffer contains the
number of bytes in the buffer,
not including the count longword.
Subsequent bytes contain the
SCSI command descriptor block.
SCDRP$L_BCNT Size in bytes of the mapped
process buffer.
SCDRP$W_PAD_BCNT Number of bytes to make the
size of the buffer equal to the
data length value required in the
command.
(continued on next page)
2–81