Subject: Re: Done interrupt on RX01/02/50

From: [email-masked] (Charles Lasner)
Date: 11 Dec 1993 15:18:40 GMT

Just a few words on a subject some others touched on:  The DONE interrupt on
the RX interface means that the current function is complete, regardless of
what that function is.  Reading or writing are actually two-step processes.
The physical I/O phase of course needs an interrupt when it completes.  No one
need be lectured on the concept of interrupts.  But the other half of the
process always involves data shoveling based on the non-interrupting transfer
flag skip, yet done comes up at the end of the operation anyway.  Since the
code has to do the shoveling anyway, getting an interrupt at the end of the
data is extraneous, although lazy code can use the done interrupt instead of
counting the data.  On the RX01, there is one possible error, a parity error
in the interface, but that raises the ERROR flag, not necessarily the DONE
flag, so it's otherwise impossible to find any status to worry over when the
DONE flag raises after all the TRANSFER skips have been processed.  Note that
the transfers wouldn't have even initiated unless grosser problems had already 
been addressed long before the transfer even started, etc.  Thus, a DONE flag
interrupt handler just goes through the motions and finds no errors, and is
dismissed.  You have the nuisance value of stating that you are in a shoveling
phase, neither idle nor awaiting I/O completion, when that occurs.  Were there
no DONE interrupt in shoveling, the interrupt handler could be slightly
simplified.  Also, note that the speed of shoveling is potentially fast enough
to warrant foreground processing, but not so fast that you want it to occur in
an interrupt handler while interrupts are off.  Alternatively, it's part of
background processing and the DONE interrupt then becomes the switch to turn
off the shoveling process.  Either way, the shoveling process needs to be
interruptible to not hog the machine; the physical I/O wait for read or
write can be handled by conventional means like any other disk device, etc.

cjl