Specifications
Operating System Routines
IOC$IOPOST
Output
Location Contents
UCB$W_QLEN Decremented
PCB$W_DIOCNT Incremented for a direct-I/O request
PCB$W_BIOCNT Incremented for a buffered I/O request
JIB$L_BYTCNT Updated for buffered I/O request
CCB$W_IOC Decremented
CCB$L_DIRP Cleared if channel is idle
Synchronization
IOC$IOPOST executes in response to an interrupt granted at IPL$_IOPOST. It
performs some of its functions in a special kernel-mode AST that executes within
process context at IPL$_ASTDEL. It obtains and releases the various spinlocks
required to deallocate nonpaged pool and adjust process quotas.
Description
This interrupt service routine processes IRPs in the systemwide and local CPU
I/O postprocessing queues, gaining control when the processor grants a software
interrupt at IPL$_IOPOST. When the I/O postprocessing queues are empty,
IOC$IOPOST dismisses the interrupt with an REI instruction.
IOC$IOPOST performs several tasks to complete either a direct- or buffered-I/O
request:
• For a buffered-I/O read request, it copies data from the system buffer to the
process buffer. If it cannot write to the process buffer, it returns SS$_ACCVIO
status. For read and write requests, it releases the system buffer to nonpaged
pool.
• For a direct-I/O request, it unlocks those process buffer pages that were
locked for the I/O transfer. (If an IRPE exists, the unlocked pages include any
defined in the IRPE area descriptors.)
IOC$IOPOST performs the following tasks for both direct and buffered I/O
requests:
• Decrements the device’s pending-I/O queue length
• Adjusts direct-I/O or buffered-I/O quota use
• Sets an event flag if one was specified in the $QIO system service call
• Copies I/O completion status from the IRP to the process’s I/O status block (if
one was specified in the $QIO system service call).
• Queues a user mode AST (if specified) to the process
• Copies the diagnostic buffer (if specified) from system to process space and
releases the system buffer
• Deallocates the IRP and any IRPEs
Note that many of these operations are performed within process context by the
special kernel-mode AST IOC$IOPOST queues to the process.
3–95