info-vax@ucbvax.ARPA (07/16/85)
From: GKN%OAK.SAINET.MFENET@LLL-MFE.ARPA
Umm, er, ah... boy, does my foot taste good!
As it turns out, if you're willing to ignore FCP/ACP type I/O requests
you CAN cancel another process' current I/O request. What you have to
do amounts to not a whole lot of code:
Locate the UCB of the device for which you wish to cancel I/O
SETIPL to UCB$B_FIPL
Grab UCB$L_IRP and stick it in R3
Grab the channel index out of the IRP and stick it in R2
Grab the PCB out of the IRP and stick it in R4
Stick your favorite reason code in R8 (CAN$C_CANCEL or _DASSGN)
Call the driver's cancel I/O routine (DDT$L_CANCEL)
IOC$IOPOST takes care of the stuff that requires process context, as it
turns out. Oh well, I learned something new this time.
gkn
------------------------------------------
Arpa: GKN%OAK.SAInet@LLL-MFE
USPS: Gerard K. Newman
Science Applications International
800 Oak Ridge Turnpike
Oak Ridge, TN 37830
AT&T: (615) 482-9031