User`s manual

Functional Overview
SBCSCSI/D1 2-7
2
The first interrupt is generated by the SCRIPTS to notify the MPU code that the
SIOP is not busy with any SCSI bus activity. The MPU code dequeues the next
command structure (siop_struc) which is available for execution and initializes
some SCRIPTS control structures. Next, the MPU code invokes the
appropriate SCRIPTS entry point for the command request.
Control of the MPU is returned to the user after the SCRIPTS begin execution.
All SCSI bus activity is handled without MPU interruption except extended
messages (i.e., synchronous data transfer negotiations), disconnects (to save
the state of the physically threaded command request and, possibly, initiate
another command request to the SCSI bus), reselects (to restore the state of the
physically threaded command request), and error conditions. All of these
situations are detected by the SCRIPTS/SIOP and a corresponding interrupt
generated so the MPU code can resolve the issue.
The command request is finished when the device sends a command complete
message and then transitions to the BUS FREE phase. When this sequence of
events occurs, the SCRIPTS generate another interrupt to notify the MPU code
that the command is done. The MPU code updates some fields in the
command structure (siop_struc), updates Firmware queues, and then calls the
user's return status routine. At this point, the siop_struc is back in the control
of the user. The user may immediately call the Firmware through siop_cmd()
to send a new command request; however, it is recommended that the status
in the status.allstat field of the returned siop_struc be checked first to determine
if any immediate recovery actions are needed (i.e., send a SCSI request sense
command to the device) which might preempt the anticipated command
request.
Upon return from the user's return status routine, the MPU code enqueues the
next available command request for the device which just completed a request.
Finally, the Firmware initiates another command request to the SCSI bus if a
command structure (siop_struc) is available for execution.
Polled Mode
After the command structure (siop_struc) is enqueued, the Firmware calls
siop_int() where the MPU code waits for the command request to complete.
The MPU code resolves intermediate interrupt conditions for the command
request until the command complete interrupt is generated. These
intermediate interrupt conditions are the same as in interrupt mode and
consist of, but are not limited to, extended messages (i.e., synchronous data
transfer negotiations), disconnects (to save the state of the physically threaded
command request), reselects (to restore the state of the physically threaded
command request), and error conditions.