Specifications

Operating System Routines
IOC$DIAGBUFILL
IOC$DIAGBUFILL
Fills a diagnostic buffer if the original $QIO request specified such a buffer.
Module
IOSUBNPAG
Input
Location Contents
R4 Address of device’s CSR
R5 Address of UCB
UCB$L_IRP Address of current IRP
IRP$W_STS IRP$V_DIAGBUF set if a diagnostic buffer exists
IRP$L_DIAGBUF Address of diagnostic buffer, if one is present
UCB$B_ERTCNT Final error retry count
UCB$L_DDB Address of DDB
DDB$L_DDT Address of DDT
DDT$L_REGDUMP Address of drivers register-dumping routine
EXE$GQ_SYSTIME Current system time (time at I/O request
completion)
Output
Location Contents
R0, R1 Destroyed
R2 Address of DDT
R3 Address of IRP
R4 Address of device’s CSR
R5 Address of UCB
Synchronization
The caller of IOC$DIAGBUFILL may be executing at or above fork IPL and
must hold the corresponding fork lock in a multiprocessing environment.
IOC$DIAGBUFILL returns control to its caller at the callers IPL. The caller
retains any spinlocks it held at the time of the call.
Description
A device driver fork process calls IOC$DIAGBUFILL at the end of I/O
processing but before releasing the I/O channel. IOC$DIAGBUFILL stores
the I/O completion time and the final error retry count in the diagnostic buffer.
(IOC$INITIATE has already placed the I/O initiation time in the first quadword
of the buffer.) IOC$DIAGBUFILL then calls the drivers register-dumping
routine, which fills the remainder of the buffer, and returns to its caller.
3–91