Specifications
Data Structures
1.19 Unit Control Block (UCB)
Table 1–22 (Cont.) Contents of Unit Control Block
Field Name Contents
UCB$L_IRP Address of IRP currently being processed on the device unit by the driver
fork process. IOC$INITIATE writes the address of an IRP into this field
before the routine creates a driver fork process to handle an I/O request.
From this field, a driver fork process obtains the address of the IRP being
processed.
The value contained in this field is not valid if the UCB$V_BSY bit in
UCB$L_STS is clear.
UCB$W_REFC* Reference count of processes that currently have process I/O channels
assigned to the device. The $ASSIGN and $ALLOC system services
increment this field. The $DASSGN and $DALLOC system services
decrement this field.
UCB$B_DIPL Interrupt priority level (IPL) at which the device requests hardware
interrupts. The DPT of every driver must specify a value for this field.
The driver-loading procedure writes this field when the procedure creates
the UCB. When the driver-loading procedure subsequently creates the
device lock’s spinlock structure (SPL), it moves the contents of this field into
SPL$B_IPL.
In a uniprocessing environment, device drivers raise IPL to device IPL
before reading or writing device registers or accessing other fields in the
UCB synchronized at device IPL. In a multiprocessing environment, drivers
obtain the device lock at UCB$L_DLCK, thereby also raising IPL to device
IPL in the process.
UCB$B_AMOD* Access mode at which allocation occurred, if the device is allocated. Written
by the $ALLOC and $DALLOC system services.
UCB$L_AMB* Associated mailbox UCB pointer. A spooled device uses this field for the
address of its associated device. Devices that are nonshareable and not file
oriented can use this field for the address of an associated mailbox.
UCB$L_STS Device unit status (formerly UCB$W_STS). Written by drivers,
IOC$REQCOM, IOC$CANCELIO, IOC$INITIATE, IOC$WFIKPCH,
IOC$WFIRLCH, EXE$INSIOQ, and EXE$TIMEOUT. This field is read by
drivers, the $QIO system service routines, IOC$REQCOM, IOC$INITIATE,
and EXE$TIMEOUT.
This longword includes the following bits:
UCB$V_TIM Timeout enabled.
UCB$V_INT Interrupts expected.
UCB$V_ERLOGIP Error log in progress.
UCB$V_CANCEL Cancel I/O on unit.
UCB$V_ONLINE Device is on line.
UCB$V_POWER Power has failed while unit was busy.
UCB$V_TIMOUT Unit is timed out.
UCB$V_INTTYPE Receiver interrupt.
UCB$V_BSY Unit is busy.
UCB$V_MOUNTING Device is being mounted.
UCB$V_DEADMO Deallocate device at dismount.
UCB$V_VALID Volume appears valid to software.
(continued on next page)
1–92