Trailing-Edge
-
PDP-10 Archives
-
bb-x130a-sb
-
swierm.mac
There are 4 other files named swierm.mac in the archive. Click here to see a list.
TITLE .ERROR SWIL error message processing
SUBTTL Robert Houk/RDH
SEARCH SWIDEF, SWIL ;SWIL PACKAGE DEFINITIONS
SEARCH JOBDAT, MACTEN, UUOSYM ;STANDARD DEFINITIONS
SALL ;PRETTY LISTINGS
.DIREC FLBLST ;PRETTIER LISTINGS
TWOSEG 400000
Copyright (C) Digital Equipment Corporation 1984.
COMMENT \
Copyright (C) 1984
Digital Equipment Corporation, Maynard, Massachusetts, U.S.A.
This software is furnished under a license and may be used and copied only
in accordance with the terms of such license and with the inclusion of the
above copyright notice. This software or any other copies thereof may not
be provided or otherwise made available to any other person. No title to
and ownership of the software is hereby transferred.
The information in this software is subject to change without notice and
should not be construed as a commitment by Digital Equipment Corporation.
Digital assumes no responsibility for the use or reliability of its
software on equipment which is not supplied by Digital.
\
;SWIERM VERSION IDENTIFICATION
MAJVER==1 ;MAJOR VERSION LEVEL
MINVER==0 ;MINOR (MAINTENANCE RELEASE) LEVEL
CSTVER==0 ;CUSTOMER VERSION (WHO LAST . . .)
EDTVER==0 ;EDIT LEVEL
%%SERM==:<BYTE (3)CSTVER(9)MAJVER(6)MINVER(18)EDTVER>
IF2,< PURGE CSTVER,MAJVER,MINVER,EDTVER>
SUBTTL Junk error handling routines
.SPOPJ::POP P,.JBBLT ;POP OFF JUNK (PUSHJ TO OUTSTR/JRST)
MOVEI M0,$EDSTP ;FLAG FATAL ERROR
;SET ERROR CODE AND RETURN
.M0ERR::
M0ERR:; MOVEM M0,.IOERR(IO) ;SET ERROR
POPJ P, ;AND RETURN
.M1ERR::
M1ERR:; MOVEM M0,.IOERR(T1) ;SET ERROR
POPJ P, ;AND RETURN
.M0IOZ::
M0IOZ:; MOVEM M0,.IOERR(IO) ;SET ERROR
PUSHJ P,.IOABO## ;ZAP THE FILE
JFCL ;DUH?
POPJ P, ;RETURN
SUBTTL Error messages - File access errors
;ERPIN -- ISSUE ERROR MESSAGE FOR .IOPIN (OPEN) ERROR
;ERPOU -- ISSUE ERROR MESSAGE FOR .IOPOU (CREATE) ERROR
;ERFDL -- ISSUE ERROR MESSAGE FOR .IOFDL (DELETE) ERROR
;ERFPR -- ISSUE ERROR MESSAGE FOR .IOFPR (PRINT) ERROR
;ERFRN -- ISSUE ERROR MESSAGE FOR .IOFRN (RENAME) ERROR
;ERFSU -- ISSUE ERROR MESSAGE FOR .IOFSU (SUBMIT) ERROR
;Call is:
;
; MOVX M0,<COD>
; MOVX T1,<CDB>
; PUSHJ P,ERxxx
; return always
;
;Where <COD> is the 18-bit status/exception/error code; and <CDB> is the
;associated I/O CDB (contains file name, etc).
;
;These routines issue a textual error message to the command terminal.
;
;Preserves all registers.
;ERPIN - Issue .IOPIN file-access error
ENTRY .ERPIN
.ERPIN: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\opening \] ;OPEN-FOR-READ PARTICIPLE
PJRST ERFAE1 ;GO FINISH OFF
;ERPOU - Issue .IOPOU file-access error
ENTRY .ERPOU
.ERPOU: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\creating \] ;OPEN-FOR-WRITE PARTICIPLE
PJRST ERFAE1 ;GO FINISH OFF
;ERFDL - Issue .IOFDL file-access error
ENTRY .ERFDL
.ERFDL: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\deleting \] ;DELETE PARTICIPLE
PJRST ERFAE1 ;GO FINISH OFF
;ERFPR - Issue .IOFPR file-access error
ENTRY .ERFPR
.ERFPR: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\printing \] ;PRINT PARTICIPLE
PJRST ERFAE1 ;GO FINISH OFF
;ERFRN - Issue .IOFRN file-access error
ENTRY .ERFRN
.ERFRN: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\renaming \] ;RENAME PARTICIPLE
PJRST ERFAE1 ;GO FINISH OFF
;ERFSU - Issue .IOFSU file-access error
ENTRY .ERFSU
.ERFSU: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\submitting \] ;SUBMIT PARTICIPLE
PJRST ERFAE1 ;GO FINISH OFF
;COMMON CODE FOR FILE ACCESS ERRORS
;
;AC usage is as follows:
;
; P1 -1=fatal; 0=warning; 1=informational
; P2 address of "participle" text string
; P3 flags and address of reason text string
ERFAE1: PUSHJ P,.SACIO## ;SWITCH TO I/O CONTEXT
PUSHJ P,.SAVE4## ;SAVE THE PEAS
PUSHJ P,TSAV14## ;PROTECT CALLER'S T REGS
MOVE P2,M0 ;POSITION PARTICIPLE TEXT STRING ADDRESS
SETZ P1, ;ASSUME MERELY A WARNING
PUSHJ P,ONERCK## ;SEE IF USER WANTS TO CONTINUE AFTERWARD
SETO P1, ;NO, FATAL ERROR
MOVE P4,.IOFSC(IO) ;ADDRESS OF FILE SPEC BLOCK
DMOVE T3,.FXMOD(P4) ;/OKPROT AND /OKNONE VALUES
MOVE T2,.IOERR(IO) ;FETCH ERROR CODE BACK
CAIN T2,$EFPRT ;"PROTECTION FAILURE" ?
JRST ERFA10 ;YES, LOOK FOR /OKPROT
CAIN T2,$EFFNF ;"FILE NOT FOUND" ?
JRST ERFA20 ;YES, LOOK FOR /OKNONE
CAIE T2,$EFDNF ;"DIRECTORY NOT FOUND"
CAIN T2,$EFSNF ;"SUBDIRECTORY NOT FOUND" ?
JRST ERFA20 ;YES, LOOK FOR /OKNONE
CAIN T2,$EFUID ;"INVALID USERID"?
JRST ERFA33 ;YES, LOOK FOR /OKUID
JRST ERFAE2 ;PROCESS STANDARD ERROR MESSAGE
;PROTECTION FAILURE
ERFA10: TXNE T3,FX.PRT ;/OKPROT?
MOVEI P1,1 ;YES, FLAG JUST AN INFORMATIONAL MESSAGE THEN
JRST ERFAE2 ;PROCESS STANDARD ERROR MESSAGE
;FILE NOT FOUND
ERFA20: TXNE T3,FX.NOM ;/OKNONE?
MOVEI P1,1 ;YES, FLAG JUST AN INFORMATIONAL MESSAGE
JRST ERFAE2 ;PROCESS STANDARD ERROR MESSAGE
;INVALID USERID
ERFA33: TXNE T3,FX.UID ;/OKUID?
MOVEI P1,1 ;YES, FLAG JUST AN INFORMATIONAL MESSAGE
JRST ERFAE2 ;PROCESS STANDARD ERROR MESSAGE
;FIRST LOOK FOR SPECIAL-CASE TYPEOUT
ERFAE2: JSP T4,.CDISP## ;DISPATCH ON SPECIAL-CASE MESSAGES
ERFX10,,$EFNLA ;NETWORK LINK ABORTED
ERFX10,,$EINLA ;NETWORK LINK ABORTED (ALTERNATE)
ERFX20,,$EERDE ;DAP PROTOCOL ERROR
ERFX30,,$EFDAP ;BIZARRE DAP STATUS
0 ;NONE OTHERS
;NO SPECIAL-CASE TYPEOUT NEEDED
;FIND THE GENERAL ERROR REASON TEXT AND FLAGS
ERFAE4: MOVEI T4,ERFTBL ;FILE ACCESS ERROR TABLE
PUSHJ P,.CFIND## ;FIND ENTRY FOR THIS ERROR
JRST ERFAE6 ;NOT A KNOWN/EXPECTED FILE ACCESS ERROR
XMOVEI P4,(T1) ;ADDRESS REASON TEXT AND FLAGS
MOVE P3,(P4) ;REASON CODE ADDRESS AND FLAGS
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.FAE ;FIRE UP A NIPFAE ERROR MESSAGE
PUSHJ P,ERFAT ; FINISH OFF TEXT (FILE SPEC, ETC.)
PJRST EREXIT ;CAP OFF ERROR TEXT
;HERE FOR UNUSUAL ERROR/EXCEPTION CODE
ERFAE6: MOVEI T4,ERFTBU ;"UNUSUAL" ERROR TEXT TABLE
PUSHJ P,.CFIND## ;SEE IF KNOWN UNUSUAL ERROR
JRST ERFAE8 ;NO, UNKNOWN ERROR/EXCEPTION CODE
XMOVEI P4,(T1) ;ADDRESS OF FLG,,TEXT ADDRESS
HLRE P1,(P4) ;SET SEVERITY LEVEL
HRRZ T2,(P4) ;ADDRESS OF TEXT BODY
PUSHJ P,M.FAE ;NIPFAE ERROR MESSAGE
JFCL ;NOTHING MORE TO SAY HERE . . .
PJRST EREXIT ;CAP OFF THE ERROR/EXCEPTION TEXT
;HERE FOR UNKNOWN FILE ACCESS ERROR
ERFAE8: MOVEI T2,[ASCIZ\Unknown error/exception code = \]
PUSHJ P,M.FAE ;FIRE UP A NIPFAE ERROR MESSAGE
PUSHJ P,[MOVE T1,.IOERR(IO) ;FETCH THE UNKNOWN ERROR CODE
PJRST .TOCTW##] ;LIST IT (FOR WHAT IT'S WORTH)
PJRST EREXIT ;CAP OFF ERROR TEXT
;ERFX10 - SPECIAL CASE FOR "NETWORK LINK ABORTED"
ERFX10: MOVE P3,[EFF$NM![ASCIZ\Network link aborted (\]]
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.FAE ;FIRE UP A NIPFAE ERROR MESSAGE
CAIA ;FOLLOW UP ON TEXT
JRST EREXIT ;JUST <CR><LF> THE PREFIX
PUSHJ P,ERFAT ;DO MOST OF THE TEXT/FILE SPEC/ETC.
MOVE M0,.IOERR(IO) ;RETRIEVE BASE ERROR CODE AGAIN
MOVEI T4,ERFTBL ;GENERAL FILE-ACCESS ERROR TABLE
CAIN M0,$EINLA ;UNLESS "I/O" ERROR
MOVEI T4,ERITBL ;YEAH (E.G., TSK. "CONNECT REJECTED")
SKIPE T2,.IOER2(IO) ;PICK UP NETWORK ERROR "SUB-STATE"
PUSHJ P,.CFIND## ;GET SUB-REASON TEXT
MOVEI T1,[[ASCIZ\Unknown/unspecified\]]
HRRZ T1,(T1) ;ADDRESS OF TEXT STRING
PUSHJ P,.TSTRG## ;ISSUE SUB-STATE ERROR TEXT
PUSHJ P,.TRPRN## ;TYPE THE CLOSING ")"
PJRST EREXIT ;CAP OFF ERROR MESSAGE
;ERFX20 - SPECIAL CASE FOR "DAP PROTOCOL ERROR"
ERFX20: MOVE P3,[EFF$ND![ASCIZ\Remote-detected DAP protocol error\]]
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.FAE ;FIRE UP A NIPFAE ERROR MESSAGE
CAIA ;FOLLOW-UP ON TEXT
JRST EREXIT ;JUST <CR><LF> THE PREFIX
PUSHJ P,ERFAT ;DO MOST OF THE TEXT/FILE SPEC/ETC.
PUSHJ P,ERDE01 ;LIST DAP PROTOCOL ERROR STUFF
JRST EREXIT ;CAP OFF ERROR MESSAGE
;ERFX30 - SPECIAL CASE FOR "BIZARRE DAP STATUS"
ERFX30: MOVE P3,[EFF$ND![ASCIZ\Bizarre DAP error status\]]
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.FAE ;FIRE UP A NIPFAE ERROR MESSAGE
CAIA ;FOLLOW-UP ON TEXT
JRST EREXIT ;JUST <CR><LF> THE PREFIX
PUSHJ P,ERFAT ;DO MOST OF THE TEXT/FILE SPEC/ETC.
PUSHJ P,EDAP01 ;PRINT THE OFFENDING STATUS
JRST EREXIT ;CAP OFF ERROR MESSAGE
;HERE FOR TYPING THE JUICY STUFF
ERFAT: MOVE T1,P2 ;THE PARTICIPLE STRING ADDRESS
PUSHJ P,.TSTRG## ;TYPE THAT OUT
;RDH MOVEI T1,[ASCIZ\file \] ;ASSUME STANDARD FILE ACCESS
SETZ T1, ;RDH KEEP MESSAGES SHORT
TXNN P3,FX.UNM ;WANT NAME TYPED OUT?
MOVEI T1,[ASCIZ\directory \] ;NO, ESCALATE MESSAGE
TXNN P3,FX.UDR ;WANT DIRECTORY TYPED OUT?
MOVEI T1,[ASCIZ\device \] ;NO, ESCALATE MESSAGE
TXNN P3,FX.UDV ;WANT DEVICE TYPED OUT?
MOVEI T1,[ASCIZ\node \] ;NO, ESCALATE MESSAGE
CAIE T1,0 ;RDH KEEP MESSAGES SHORT
PUSHJ P,.TSTRG## ;ISSUE NEXT PART OF MESSAGE
MOVE T2,P3 ;COPY OF FLAGS
ANDX T2,FX.UXX ;REDUCE TO JUST FLAGS
PUSHJ P,TOCFS0## ;TYPE OUT FILE SPEC
JFCL ;DUH???
MOVEI T1,[ASCIZ\, \] ;SEPARATOR
PUSHJ P,.TSTRG## ;SEPARATE FILE SPEC FROM REASON TEXT
HRRZ T1,P3 ;ADDRESS OF REASON TEXT STRING
PJRST .TSTRG## ;CAP OFF ERROR MESSAGE
;HERE TO ISSUE NIPFAE ERROR MESSAGE
;Call is:
;
; MOVEI T2,<TXT>
; PUSHJ P,M.FAE
; FIRST return
; NOTEXT return
;
;Where <TXT> is the address of the text string to start up the error.
;
;M.FAE will print a NIPFAE error/warning/informational message. Register
;P1 is assumed to be the severity flag (-1 fatal; 0 warning; 1 informational)
;for the message. M.FAE only starts the message, the caller is responsible
;for terminating the message (i.e., the trailing ,<CR><LF>).
;
;On "FIRST" return, the user should append any subsidiary text desired to
;the basic text (such as typing the error code, file spec, etc.).
;
;On "NOTEXT" return, no further text should be typed, the message should
;immediately be finished (e.g., /MESSAGE:(PREFIX,NOFIRST)).
;
;Uses T1, T2, T3, T4
M.FAE: MOVE T1,['NIP',,'FAE'] ;MODULE AND MESSAGE CODES
HRL T2,[EXP "?", "%", "["]+1(P1) ;SEVERITY LEVEL
MOVE T3,.IOERR+1(IO) ;ADDRESS(+1) OF CALLER
PUSHJ P,.ERMSA## ;FIRE UP AN ERROR MESSAGE
TXNN T1,JWW.FL ;WANT "FIRST" LINE TEXT
AOS (P) ;NO, JUST .TCRLF IT
POPJ P, ;RETURN AS NEEDED.
;ERFTBL - STANDARD FILE ACCESS ERROR TABLE
DEFINE X(COD, FLG, TXT),<XWD [FLG![ASCIZ\TXT\]],COD>
EFF$ND==FX.UND ;WANT NODE TYPED
EFF$DV==EFF$ND!FX.UDV ;WANT NODE::DEV:
EFF$DR==EFF$DV!FX.UDR ;WANT NODE::DEV:[DIR]
EFF$NM==EFF$DR!FX.UNM!FX.UEX!FX.UGN ;WANT NODE::DEV:[DIR]NAM.EXT.GEN
ERFTBL: X $EFFNF,EFF$NM,<File not found>
X $EFDNF,EFF$NM,<Directory not found>
X $EFPRT,EFF$NM,<Protection failure>
X $EFFBM,EFF$NM,<File in use by other user>
X $EFAEF,EFF$NM,<Already existing file>
X $EFISU,EFF$NM,<Illegal sequence of UUOs>
X $EFRIB,EFF$NM,<RIB or directory read error>
X $EFNSF,EFF$NM,<Not a SAVE file>
X $EFNEC,EFF$NM,<Not enough core (memory)>
X $EFDNA,EFF$DV,<Device not available>
X $EFNSD,EFF$DV,<No such device>
X $EFILU,EFF$NM,<Illegal monitor call>
X $EFNRM,EFF$NM,<Device quota or storage exhausted>
X $EFWLK,EFF$DV,<Device is write-locked>
X $EFTBL,EFF$NM,<System capacity exceeded>
X $EFPOA,EFF$NM,<Partial allocation>
X $EFBNF,EFF$NM,<Block not free>
X $EFCSD,EFF$NM,<Can't supersede a directory file>
X $EFDNE,EFF$NM,<Can't delete non-empty directory file>
X $EFSNF,EFF$NM,<Sub-directory not found>
X $EFSLE,EFF$DV,<Search list empty>
X $EFLVL,EFF$NM,<Sub-directory nesting level exceeded>
X $EFNCE,EFF$NM,<NO-CREATE on for entire search list>
X $EFSNS,EFF$NM,<Segment not on swap space or job locked>
X $EFFCU,EFF$NM,<Can't update file>
X $EFLOH,EFF$NM,<Loseg overlaps hiseg>
X $EFNLI,EFF$NM,<Illegal if not logged-in>
X $EFFLK,EFF$NM,<File is "locked" by another user>
X $EFBED,EFF$NM,<Bad .EXE file directory>
X $EFBEE,EFF$NM,<Bad .EXE file extension>
X $EFDTB,EFF$NM,<Directory too big for .EXE file>
X $EFENC,EFF$DV,<Exceeded network capacity>
X $EFTNA,EFF$DV,<Task device not available>
; X $EFNSN,EFF$DV,<Undefined node name>
X $EFSIU,EFF$NM,<Sub-directory in use>
X $EFNDR,EFF$NM,<File has NO-DELETE set>
X $EFJCH,EFF$NM,<File has too many users>
X $EFSSL,EFF$NM,<Can't rename SFD to lower level>
X $EFCNO,EFF$NM,<I/O Channel not OPENed for access>
X $EFDDU,EFF$DV,<Device "down" and unuseable>
X $EFDRS,EFF$DV,<Device is restricted>
X $EFDCM,EFF$DV,<Device is controlled by the MDA process>
X $EFDAJ,EFF$DV,<Device is assigned to another job>
X $EFIDM,EFF$NM,<Illegal device data mode>
X $EFUOB,EFF$NM,<Undefined OPEN flags>
X $EFDUM,EFF$DV,<Device in use on MPX channel>
X $EFNPC,EFF$NM,<No per-process space for I/O channel table>
X $EFNFC,EFF$NM,<No free I/O channels>
X $EFUFF,EFF$NM,<Unknown FILOP. function>
X $EFCTB,EFF$NM,<Channel too big>
X $EFCIF,EFF$NM,<Channel illegal for specified function>
X $EFACR,EFF$NM,<Address check reading argument block>
X $EFACS,EFF$NM,<Address check writing argument block>
X $EFNZA,EFF$NM,<Negative or zero argument block length>
X $EFATS,EFF$NM,<Argument block too short>
X $EFRAE,EFF$NM,<Unspecified remote file access error>
X $EFRNS,EFF$NM,<Remote does not support requested action>
X $EFRNR,EFF$NM,<Remote does not support RENAME>
X $EFRND,EFF$NM,<Remote does not support DELETE>
X $EFRNX,EFF$NM,<Remote does not support EXECUTE>
X $EFRNL,EFF$NM,<Remote does not support DIRECTORY LIST>
X $EFRNW,EFF$NM,<Remote does not support wildcards>
X $EFRNC,EFF$NM,<Remote does not support file constraints>
X $EFRNG,EFF$NM,<Remote does not support GO/NOGO>
X $EFRNA,EFF$NM,<Remote does not support ACCOMP(RENAME)>
X $EFRFB,EFF$NM,<File spec string too big for DAP protocol>
X $EFRSB,EFF$NM,<String argument too big for DAP protocol>
X $EFABE,EFF$ND,<Argument block format error>
X $EFALF,EFF$ND,<Allocation failure>
X $EFBCN,EFF$ND,<Bad channel number>
X $EFBFT,EFF$ND,<Bad format type in process block>
X $EFCFE,EFF$ND,<Connect block format error>
X $EFIDL,EFF$ND,<Interrupt data too long>
X $EFIFM,EFF$ND,<Illegal flow control mode>
X $EFILF,EFF$ND,<Illegal NSP. function>
X $EFJQX,EFF$ND,<Job quota exceeded>
X $EFLQX,EFF$ND,<Link quota exceeded>
X $EFNCD,EFF$ND,<No connect data>
X $EFPIO,EFF$ND,<NSP Percentage input out of bounds>
X $EFPRV,EFF$ND,<Network privileges required>
X $EFSTB,EFF$ND,<NSP segment size too big>
X $EFNSN,EFF$ND,<No such node>
X $EFUXS,EFF$ND,<Unexpected NSP state: unspecified>
X $EFWNA,EFF$ND,<Wrong number of arguments>
X $EFWRS,EFF$ND,<Network link in wrong state>
X $EFCBL,EFF$ND,<NSP connect block length error>
X $EFPBL,EFF$ND,<NSP process block length error>
X $EFSBL,EFF$ND,<NSP string block length error>
X $EFUDS,EFF$ND,<Unexpected NSP state: disconnect sent>
X $EFUDC,EFF$ND,<Unexpected NSP state: disconnect confirmed>
X $EFUCF,EFF$ND,<Network link aborted ("No confidence")>
X $EFULK,EFF$ND,<Network link aborted ("No link")>
X $EFUCM,EFF$ND,<Network link aborted ("No communication")>
X $EFUNR,EFF$ND,<Unexpected NSP state: no resources>
X $EFRBO,EFF$ND,<Aborted by object>
X $EFDBO,EFF$ND,<Disconnected by object>
X $EFRES,EFF$ND,<Remote system resources exhausted>
X $EFUXN,EFF$ND,<Unknown remote object name>
X $EFRNS,EFF$ND,<Remote node is shutting down>
X $EFURO,EFF$ND,<No remote network (DAP) file service>
X $EFIOF,EFF$ND,<Connect rejected: illegal object format>
X $EFOTB,EFF$ND,<Remote network file service busy/full>
X $EFABM,EFF$ND,<Connect rejected: aborted by management>
X $EFABO,EFF$ND,<Remote network file service aborted network link>
X $EFINF,EFF$ND,<Connect rejected: invalid node name format>
X $EFLNS,EFF$ND,<Local host network shutting down>
X $EFUID,EFF$ND,<Invalid USERID and/or PASSWORD>
X $EFNRO,EFF$ND,<Remote network file service did not respond>
X $EFNUR,EFF$ND,<Node unreachable>
X $EFNLK,EFF$ND,<No link>
X $EFDSC,EFF$ND,<Disconnect complete>
X $EFIMG,EFF$ND,<Image field error>
X $EFUAC,EFF$ND,<Invalid ACCOUNT>
X $EFBCF,EFF$ND,<Illegal NS.EOM and NS.WAI>
X $EFADE,EFF$ND,<NSP. UUO address check>
X $EFRJU,EFF$NM,<Rejected by user>
X $EFIXN,EFF$NM,<No more files>
X $EFIXE,EFF$NM,<No more files (redundantly)>
X $EFNAD,EFF$DV,<Device not a disk>
X $EFIFO,EFF$NM,<Illegal file operation>
X $EFIFM,EFF$NM,<Illegal file mode>
X $EFILI,EFF$DV,<Illegal input, output device only>
X $EFILO,EFF$DV,<Illegal output, input device only>
X $EFISW,EFF$NM,<Illegal secondary wildcarding>
X $EFVBI,EFF$DV,<Variable blocksize illegal>
X $EFBTB,EFF$DV,<Blocksize too big>
X $EFBTS,EFF$DV,<Blocksize too small>
X $EFFUL,EFF$NM,<Device full - storage exhausted>
X $EFQTA,EFF$NM,<Device quota exhausted>
X $EFDIF,EFF$NM,<Directory full or can't create unique name>
0
;ERFTBU - UNUSUAL FILE ACCESS ERROR TABLE
DEFINE X(COD, FLG, TXT),<XWD [FLG![ASCIZ\TXT\]],COD>
EFF$FT==777777000000 ;FATAL ERROR
EFF$WR==000000000000 ;WARNING
EFF$IN==000001000000 ;INFORMATIONAL
ERFTBU: X $EERSP,EFF$IN,<Aborting network/DAP link due to remote screwy DAP protocol>
0
;COMMON ERROR EXIT
EREXIT: CAIN P1,1 ;IS THIS AN INFORMATIONAL MESSAGE?
PUSHJ P,.TRBRK## ;YES, ISSUE CLOSING "]"
PUSHJ P,.TCRLF## ;CAP OFF MESSAGE WITH A <CR><LF>
MOVE M0,.IOERR(IO) ;RESTORE EXCEPTION CODE
POPJ P, ;RETURN
SUBTTL Error messages - I/O errors
;ERISR -- ISSUE ERROR MESSAGE FOR .IOISR (INPUT) ERROR
;EROSR -- ISSUE ERROR MESSAGE FOR .IOOSR (OUTPUT) ERROR
;Call is:
;
; MOVX M0,<COD>
; MOVX T1,<CDB>
; PUSHJ P,ERxxx
; return always
;
;Where <COD> is the 18-bit status/exception/error code; and <CDB> is the
;associated I/O CDB (contains file name, etc).
;
;These routines issue a textual error message to the command terminal.
;
;Preserves all registers.
;ERISR - Issue .IOISR I/O error
ENTRY .ERISR
.ERISR: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\reading \] ;INPUT PARTICIPLE
PJRST ERIOE1 ;GO FINISH OFF
;EROSR - Issue .IOOSR I/O error
ENTRY .EROSR
.EROSR: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\Writing \] ;OUTPUT PARTICIPLE
PJRST ERIOE1 ;GO FINISH OFF
;COMMON CODE FOR I/O ERRORS
;
;AC usage is as follows:
;
; P1 -1=fatal; 0=warning; 1=informational
; P2 address of "participle" text string
; P3 flags and address of reason text string
ERIOE1: PUSHJ P,.SACIO## ;SWITCH TO I/O CONTEXT
PUSHJ P,.SAVE4## ;SAVE THE PEAS
PUSHJ P,TSAV14## ;PROTECT CALLER'S T REGS
MOVE P2,M0 ;POSITION PARTICIPLE TEXT STRING ADDRESS
SETZ P1, ;ASSUME MERELY A WARNING
PUSHJ P,ONERCK## ;SEE IF USER WANTS TO CONTINUE AFTERWARD
SETO P1, ;NO, FATAL ERROR
MOVE P4,.IOFSC(IO) ;ADDRESS OF FILE SPEC BLOCK
DMOVE T3,.FXMOD(P4) ;/OKPROT AND /OKNONE VALUES
MOVE T2,.IOERR(IO) ;FETCH ERROR CODE BACK
;FIRST CHECK FOR SPECIAL-CASE I/O ERROR MESSAGE
ERIOE2: JSP T4,.CDISP## ;DISPATCH ON SPECIAL-CASE ERROR MESSAGE
ERIX10,,$EINLA ;NETWORK LINK ABORTED
ERIX20,,$EERDE ;REMOTE-DETECTED DAP PROTOCOL ERROR
ERIX30,,$EIDAP ;BIZARRE DAP STATUS
0 ;NONE OTHERS
;NOT A SPECIAL-CASE ERROR TYPEOUT
;FIND THE GENERAL ERROR REASON TEXT AND FLAGS
ERIOE4: MOVEI T4,ERITBL ;I/O ERROR TABLE
PUSHJ P,.CFIND## ;FIND ENTRY FOR THIS ERROR
JRST ERIOE6 ;NOT A KNOWN/EXPECTED I/O ERROR
XMOVEI P4,(T1) ;ADDRESS REASON TEXT AND FLAGS
MOVE P3,(P4) ;REASON CODE ADDRESS AND FLAGS
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.IOE ;FIRE UP A NIPIOE ERROR MESSAGE
PUSHJ P,ERIOT ; FINISH OFF TEXT (FILE SPEC, ETC.)
PJRST EREXIT ;CAP OFF ERROR TEXT
;HERE FOR UNUSUAL ERROR/EXCEPTION CODE
ERIOE6: MOVEI T4,ERITBU ;"UNUSUAL" ERROR TEXT TABLE
; PUSHJ P,.CFIND## ;SEE IF KNOWN UNUSUAL ERROR
; JRST ERIOE8 ;NO, UNKNOWN ERROR/EXCEPTION CODE
; XMOVEI P4,(T1) ;ADDRESS OF FLG,,TEXT ADDRESS
; HLRE P1,(P4) ;SET SEVERITY LEVEL
; HRRZ T2,(P4) ;ADDRESS OF TEXT BODY
; PUSHJ P,M.IOE ;NIPIOE ERROR MESSAGE
; JFCL ;NOTHING MORE TO SAY HERE . . .
; PJRST EREXIT ;CAP OFF THE ERROR/EXCEPTION TEXT
;HERE FOR UNKNOWN I/O ERROR
ERIOE8: MOVEI T2,[ASCIZ\Unknown error/exception code = \]
PUSHJ P,M.IOE ;FIRE UP A NIPIOE ERROR MESSAGE
PUSHJ P,[MOVE T1,.IOERR(IO) ;FETCH THE UNKNOWN ERROR CODE
PJRST .TOCTW##] ;LIST IT (FOR WHAT IT'S WORTH)
PJRST EREXIT ;CAP OFF ERROR TEXT
;ERIX10 - SPECIAL CASE FOR "NETWORK LINK ABORTED"
ERIX10: MOVE P3,[EFF$NM![ASCIZ\Network link aborted (\]]
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.IOE ;FIRE UP A NIPIOE ERROR MESSAGE
CAIA ;FOLLOW-UP ON TEXT
JRST EREXIT ;JUST <CR><LF> THE PREFIX
ERIX14: PUSHJ P,ERIOT ;DO MOST OF THE TEXT/FILE SPEC/ETC.
MOVEI T4,ERITBL ;GENERAL I/O ERROR TABLE
SKIPE T2,.IOER2(IO) ;PICK UP NETWORK ERROR "SUB-STATE"
PUSHJ P,.CFIND## ;GET SUB-REASON TEXT
MOVEI T1,[[ASCIZ\Unknown/unspecified\]]
HRRZ T1,(T1) ;ADDRESS OF TEXT STRING
PUSHJ P,.TSTRG## ;ISSUE SUB-STATE ERROR TEXT
PUSHJ P,.TRPRN## ;TYPE THE CLOSING ")"
PJRST EREXIT ;CAP OFF ERROR MESSAGE
;ERIX20 - SPECIAL CASE FOR "DAP PROTOCOL ERROR"
ERIX20: MOVEI P3,[ASCIZ\Remote-detected DAP protocol error\]
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.IOE ;FIRE UP A NIPIOE ERROR MESSAGE
CAIA ;FOLLOW-UP ON TEXT
JRST EREXIT ;JUST <CR><LF> THE PREFIX
PUSHJ P,ERIOT ;DO MOST OF THE TEXT/FILE SPEC/ETC.
PUSHJ P,ERDE01 ;LIST DAP PROTOCOL ERROR STUFF
JRST EREXIT ;CAP OFF ERROR MESSAGE
;ERIX30 - SPECIAL CASE FOR "BIZARRE DAP STATUS"
ERIX30: MOVEI P3,[ASCIZ\Bizarre DAP error status\]
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.IOE ;FIRE UP A NIPIOE ERROR MESSAGE
CAIA ;FOLLOW-UP ON TEXT
JRST EREXIT ;JUST <CR><LF> THE PREFIX
PUSHJ P,ERIOT ;DO MOST OF THE TEXT/FILE SPEC/ETC.
PUSHJ P,EDAP01 ;PRINT THE OFFENDING STATUS
JRST EREXIT ;CAP OFF ERROR MESSAGE
;HERE FOR TYPING THE JUICY STUFF
ERIOT: MOVE T1,P2 ;THE PARTICIPLE STRING ADDRESS
PUSHJ P,.TSTRG## ;TYPE THAT OUT
;RDH MOVEI T1,[ASCIZ\file \] ;ASSUME STANDARD FILE
;RDH PUSHJ P,.TSTRG## ;ISSUE NEXT PART OF MESSAGE
MOVX T2,FX.UXX ;LIST EVERYTHING WE CAN
SKIPE T3,.I1NOD(IO) ;GET NODE NAME (SIXBIT)
; USE .I1NOD 'CUZ .ION6M ZEROED BY SOME ERRORS
CAMN T3,.MYNOD## ;IF LOCAL NODE
TXZ T2,FX.UND ;THEN DON'T TYPE OUT THE NODE NAME
PUSHJ P,TOCFS0## ;TYPE OUT FILE SPEC
JFCL ;DUH???
MOVEI T1,[ASCIZ\, \] ;SEPARATOR
PUSHJ P,.TSTRG## ;SEPARATE FILE SPEC FROM REASON TEXT
HRRZ T1,P3 ;ADDRESS OF REASON TEXT STRING
PJRST .TSTRG## ;CAP OFF ERROR MESSAGE
;HERE TO ISSUE NIPIOE ERROR MESSAGE
;Call is:
;
; MOVEI T2,<TXT>
; PUSHJ P,M.IOE
; FIRST return
; NOTEXT return
;
;Where <TXT> is the address of the text string to start up the error.
;
;M.IOE will print a NIPIOE error/warning/informational message. Register
;P1 is assumed to be the severity flag (-1 fatal; 0 warning; 1 informational)
;for the message. M.IOE only starts the message, the caller is responsible
;for terminating the message (i.e., the trailing ,<CR><LF>).
;
;On "FIRST" return, the user should append any subsidiary text desired to
;the basic text (such as typing the error code, file spec, etc.).
;
;On "NOTEXT" return, no further text should be typed, the message should
;immediately be finished (e.g., /MESSAGE:(PREFIX,NOFIRST)).
;
;Uses T1, T2, T3, T4
M.IOE: MOVE T1,['NIP',,'IOE'] ;MODULE AND MESSAGE CODES
HRL T2,[EXP "?", "%", "["]+1(P1) ;SEVERITY LEVEL
MOVE T3,.IOERR+1(IO) ;ADDRESS(+1) OF CALLER
PUSHJ P,.ERMSA## ;FIRE UP AN ERROR MESSAGE
TXNN T1,JWW.FL ;WANT "FIRST" LINE TEXT
AOS (P) ;NO, JUST .TCRLF IT
POPJ P, ;RETURN AS NEEDED.
;ERITBL - STANDARD I/O ERROR TABLE
DEFINE X(COD, FLG, TXT),<XWD [FLG![ASCIZ\TXT\]],COD>
ERITBL: X $EIEOF,0,<End of file>
X $EIDEV,0,<Hard device error>
X $EIDAT,0,<Data checksum or parity error>
X $EIBKT,0,<Data block too large for data buffer>
X $EIIMP,0,<Software-detected operational error>
X $EIFUL,0,<Device full - storage exhausted>
X $EIQTA,0,<User quota exceeded>
X $EIHWL,0,<Device is hardware write-locked>
X $EISWL,0,<Device is software write-locked>
X $EIEOV,0,<End-of-volume detected>
X $EIOFL,0,<Device is offline>
X $EILLE,0,<Lineprinter page limit exceeded>
X $EIVFE,0,<Lineprinter VFU format error>
X $EILUC,0,<Lineprinter undefined character interrupt>
X $EIVRP,0,<Lineprinter VFU RAM parity error>
X $EILBL,0,<Tape label error>
X $EICNO,0,<Channel not OPEN for file or I/O activity>
X $EIECF,0,<Error CLOSEing channel>
X $EINBI,0,<Non-blocking input>
X $EINBO,0,<Non-blocking output>
X $EILSN,0,<Line sequence number detected>
X $EILLN,0,<Ludicrous line sequence number detected>
X $EIEFL,0,<EOF while reading line sequence number>
X $EIMLN,0,<Multiple line sequence numbers detected>
X $EINOL,0,<File not OPENed for line sequence number generation>
X $EILTB,0,<Line sequence number too big>
X $EIINO,0,<File not OPENed for input>
X $EIONO,0,<File not OPENed for output>
X $EIILF,0,<Illegal I/O operation (.IOFUN call)>
X $EIBOR,0,<Begining of record encountered>
X $EIRSU,0,<Begining of record encountered, size unknown>
X $EIEOR,0,<Premature end of record (record size too large)>
X $EIDPR,0,<Data past end of record (record size too small)>
X $EIRFE,0,<Record format error>
X $EICCC,0,<Error in COBOL carriage control format>
X $EIFCC,0,<Error in FORTRAN carriage control format>
X $EIPRN,0,<Error in VAX "print file" control format>
X $EINRS,0,<Not a record-structured file>
X $EINIR,0,<Not in a record (record not initialized)>
X $EIRSO,0,<Record still outstanding (previous record not done)>
X $EIRTB,0,<Record size too big>
X $EIRAI,0,<Record address illegal>
X $EIDAP,0,<Bizarre (not-readily-translatable) DAP status code>
X $EIRIE,0,<Unspecified remote I/O error>
X $EICKE,0,<Network file data CRC ("checksum") error>
X $EINTI,0,<Non-blocking network input>
X $EINTO,0,<Non-blocking network output>
X $EIBAI,0,<Illegal ASCII record attributes for IMAGE/BINARY data>
X $EINLA,0,<Network link aborted>
X $EINMP,0,<Network message pending input>
X $EIABE,0,<Argument block format error>
X $EIALF,0,<Allocation failure>
X $EIBCN,0,<Bad channel number>
X $EIBFT,0,<Bad format type in process block>
X $EICFE,0,<Connect block format error>
X $EIIDL,0,<Interrupt data too long>
X $EIIFM,0,<Illegal flow control mode>
X $EIILF,0,<Illegal NSP. function>
X $EIJQX,0,<Job quota exceeded>
X $EILQX,0,<Link quota exceeded>
X $EINCD,0,<No connect data>
X $EIPIO,0,<NSP Percentage input out of bounds>
X $EIPRV,0,<Network privileges required>
X $EISTB,0,<NSP segment size too big>
X $EINSN,0,<No such node>
X $EIUXS,0,<Unexpected NSP state: unspecified>
X $EIWNA,0,<Wrong number of arguments>
X $EIWRS,0,<Network link in wrong state>
X $EICBL,0,<NSP connect block length error>
X $EIPBL,0,<NSP process block length error>
X $EISBL,0,<NSP string block length error>
X $EIUDS,0,<Unexpected NSP state: disconnect sent>
X $EIUDC,0,<Unexpected NSP state: disconnect confirmed>
X $EIUCF,0,<"No confidence">
X $EIULK,0,<"No link">
X $EIUCM,0,<"No communication">
X $EIUNR,0,<Unexpected NSP state: no resources>
X $EIRBO,0,<Aborted by object>
X $EIDBO,0,<Disconnected by object>
X $EIRES,0,<Connect rejected: no resources>
X $EIUXN,0,<Connect rejected: unknown object name>
X $EIRNS,0,<Connect rejected: node is shutting down>
X $EIURO,0,<Connect rejected: unknown object type>
X $EIIOF,0,<Connect rejected: illegal object format>
X $EIOTB,0,<Connect rejected: no free objects>
X $EIABM,0,<Connect rejected: aborted by management>
X $EIABO,0,<Aborted by object>
X $EIINF,0,<Connect rejected: invalid node name format>
X $EILNS,0,<Connect rejected: local net shutting down>
X $EIUID,0,<Connect rejected: invalid userid>
X $EINRO,0,<Connect rejected: no response from object>
X $EINUR,0,<Node unreachable>
X $EINLK,0,<No link>
X $EIDSC,0,<Disconnect complete>
X $EIIMG,0,<Image field too long>
X $EIUAC,0,<Invalid ACCOUNT>
X $EIBCF,0,<Illegal NS.EOM and NS.WAI>
X $EIADE,0,<NSP. UUO address check>
0
;ERITBU - UNUSUAL I/O ERROR TABLE
DEFINE X(COD, FLG, TXT),<XWD [FLG![ASCIZ\TXT\]],COD>
EFF$FT==777777000000 ;FATAL ERROR
EFF$WR==000000000000 ;WARNING
EFF$IN==000001000000 ;INFORMATIONAL
ERITBU: 0
0
SUBTTL Error messages - Special DAP routines
;ERDE - TYPE OUT A "REMOTE-DETECTED DAP PROTOCOL ERROR"
ERDE01: PUSHJ P,.TCRLF## ;CAP OFF FIRST LINE OF TEXT
MOVEI T1,[ASCIZ\ DAP status = \]
PUSHJ P,.TSTRG## ;START UP EXTENDED TEXT BLAB
MOVE T1,.IDSTC(IO) ;GET DAP STATUS VALUE
PUSHJ P,.TOCTW## ;LIST IT IN OCTAL
MOVEI T1,[ASCIZ\; Secondary status = \]
PUSHJ P,.TSTRG## ;IDENTIFY SECONDARY STATUS
DMOVE T1,.IDSTV(IO) ;FETCH SECONDARY STATUS VALUE (DOUBLE-WORD)
PUSHJ P,.TOCTD## ;LIST IT IN OCTAL
;Now list the MACCODE error class
ERDE10: PUSHJ P,.TCRLF## ;CAP OFF FIRST EXTENDED TEXT LINE
MOVEI T1,[ASCIZ\ DAP error class is "\]
PUSHJ P,.TSTRG## ;START UP A LINE OF TEXT
LDB T1,PDPEMA## ;GET DAP STATUS "MACCODE"
MOVE T1,ERDETB(T1) ;GET APPROPRIATE TEXT STRING
PUSHJ P,.TSTRG## ;AND LIST THE MAJOR ERROR CLASS
PUSHJ P,.TDQTE## ;CAP OFF QUOTED STRING
;Now try for the specific message type in error
ERDE20: PUSHJ P,.TCRLF## ;CAP OFF SECOND EXTENDED TEXT LINE
LDB P1,PDPEMT## ;GET DAP MESSAGE TYPE
LDB P2,PDPEMF## ;GET DAP FIELD CODE
JUMPN P1,ERDE23 ;GO IF NOT A "MISCELLANEOUS" ERROR
MOVE T2,P2 ;POSITION "FIELD" CODE
MOVEI T4,[[ASCIZ\ Unspecified DAP message error\],,00
[ASCIZ\ Unknown DAP message type\],,10
0] ;TEXT POSSIBILITIES
PUSHJ P,.CFIND## ;TRY FOR VIABLE TEXT
MOVEI T1,[ASCIZ\ Unknown "miscellaneous" DAP error code\]
PUSHJ P,.TSTRG## ;PUNT TEXT AND
JRST ERDE50 ;EXIT THIS VALE OF TEARS
ERDE23: MOVEI T1,[ASCIZ\ DAP message type is "\]
PUSHJ P,.TSTRG## ;START UP MESSAGE TYPE LINE
MOVEI T4,DAPIDX## ;DAP EXECUTION TABLE INDEXER
MOVE T2,P1 ;RETRIEVE DAP MESSAGE TYPE
CAIG T2,$DHACL ;CODE THAT SEEMS TO PARALLEL MESSAGE CODES?
PUSHJ P,.CFIND## ;YES, TRY TO FIND MATCHING MESSAGE TYPE
TDZA P3,P3 ;CAN'T IDENTIFY THE MESSAGE TYPE
SKIPA P3,T1 ;REMEMBER EXECUTION TABLE INDEX
SKIPA T1,[[ASCIZ\<<unknown>>\]] ;CAN'T IDENTIFY IT
MOVE T1,DAPXTX(T1) ;MATCHED, GET MESSAGE TEXTUAL DESCRIPTION
ERDE29: PUSHJ P,.TSTRG## ;IDENTIFY MESSAGE TYPE THAT DIED
PUSHJ P,.TDQTE## ;TYPE CLOSING DOUBLE-QUOTE
CAIGE P2,20 ;UNLESS ERROR IN DAP MESSAGE HEADER FIELD,
JUMPE P3,ERDE50 ;CAN GO NO FURTHER IF UNKNOWN MESSAGE TYPE
;Now identify message field within message type that died
ERDE30: PUSHJ P,.TCRLF## ;CAP OFF SECOND EXTENDED TEXT LINE
MOVEI T1,[ASCIZ\ DAP message field is "\]
PUSHJ P,.TSTRG## ;START UP MESSAGE FIELD LINE
JUMPN P2,ERDE33 ;TRACK DOWN OFFENDING FIELD IF PRESENT
ERDE32: MOVEI T1,[ASCIZ\<<unknown>>\] ;UNKNOWN FIELD
JRST ERDE39 ;TYPE THAT OUT
ERDE33: CAIGE P2,20 ;ERROR IN HEADER OR MESSAGE FIELD?
TDZA P3,P3 ;HEADER, FLAG PROTOTYPE TEMPLATE
SUBI P2,10 ;OFFSET MESSAGE FIELD TYPE
SUBI P2,07 ;OFFSET MESSAGE HEADER TYPE
ADD P3,P2 ;POINT P3 AT DAPXCT TABLE ENTRY FOR FIELD
LDB T2,[POINTR DAPXCT(P3),DX$COD] ;GET RELATIVE FIELD NUMBER
CAME T2,P2 ;THIS THE FIELD?
JRST ERDE32 ;NO, THEN WE DON'T KNOW THE FIELD
MOVE T1,DAPXTX(P3) ;YES, GET FIELD TEXT BLURB
ERDE39: PUSHJ P,.TSTRG## ;AND TYPE IT OUT
PUSHJ P,.TDQTE## ;CAP OFF THE QUOTED FIELD STRING
;List the status text field if the remote it
ERDE50: MOVE T1,.IODPV(IO) ;GET DAP PROTOCOL VERSION
CAIL T1,007000 ;VERSION 7.0 OR LATER?
SKIPN .IDSTX(IO) ;YES, GOT A STATUS TEXT FIELD TO TYPE?
JRST ERDE90 ;NO, ALL DONE
PUSHJ P,.TCRLF## ;FINISH OFF TEXT
MOVEI T1,[ASCIZ\ DAP status text is "\]
PUSHJ P,.TSTRG## ;FIRE UP YET ANOTHER LINE
MOVEI T1,.IDSTX(IO) ;ADDRESS OF ARBITRARY STATUS TEXT STRING
PUSHJ P,.TSTRG## ;TYPE IT OUT TOO
PUSHJ P,.TDQTE## ;CAP OFF QUOTED STRING
;All done here
ERDE90: POPJ P, ;JUST RETURN
;DAP ERROR CLASS TABLE
ERDETB: [ASCIZ\Operation in progress\]
[ASCIZ\Operation successful\]
[ASCIZ\Operation or value unsupported\]
[ASCIZ\<<reserved>>\]
[ASCIZ\File OPEN operation\]
[ASCIZ\I/O transfer\]
[ASCIZ\I/O transfer (warning)\]
[ASCIZ\File CLOSE operation\]
[ASCIZ\DAP message syntax error\]
[ASCIZ\DAP message field error\]
[ASCIZ\DAP message out of synchronization\]
[ASCIZ\<<reserved>>\]
[ASCIZ\<<reserved>>\]
[ASCIZ\<<reserved>>\]
[ASCIZ\<<User-defined MACCODE = 16>>\]
[ASCIZ\<<User-defined MACCODE = 17>>\]
;EDAP - TYPE OUT A "BIZARRE DAP STATUS"
EDAP01: PUSHJ P,.TCRLF## ;CAP OFF FIRST LINE OF TEXT
MOVEI T1,[ASCIZ\ DAP status = \]
PUSHJ P,.TSTRG## ;START UP EXTENDED TEXT BLAB
MOVE T1,.IDSTC(IO) ;GET DAP STATUS VALUE
PUSHJ P,.TOCTW## ;LIST IT IN OCTAL
MOVEI T1,[ASCIZ\; Secondary status = \]
PUSHJ P,.TSTRG## ;IDENTIFY SECONDARY STATUS
DMOVE T1,.IDSTV(IO) ;FETCH SECONDARY STATUS VALUE (DOUBLE-WORD)
PUSHJ P,.TOCTD## ;LIST IT IN OCTAL
;Now list the MACCODE error class
EDAP10: PUSHJ P,.TCRLF## ;CAP OFF FIRST EXTENDED TEXT LINE
MOVEI T1,[ASCIZ\ DAP error class is "\]
PUSHJ P,.TSTRG## ;START UP A LINE OF TEXT
LDB T1,PDPEMA ;GET DAP STATUS "MACCODE"
MOVE T1,ERDETB(T1) ;GET APPROPRIATE TEXT STRING
PUSHJ P,.TSTRG## ;AND LIST THE MAJOR ERROR CLASS
PUSHJ P,.TDQTE## ;FINISH QUOTED ERROR CLASS STRING
;Now list the MICCODE error reason
EDAP20: PUSHJ P,.TCRLF## ;FINISH OFF SECOND LINE TEXT
MOVEI T1,[ASCIZ\ DAP status meaning is "\]
PUSHJ P,.TSTRG## ;FIRE UP ANOTHER LINE
MOVEI T4,DAPSTS## ;THE DAP STATUS TABLE
LDB T2,PDPEMI## ;EXTRACT FULL MICCODE VALUE
PUSHJ P,.CFIND## ;MATCH STATUS CODE
MOVEI T1,[ASCIZ\<<unknown>>\] ;HOHUM
PUSHJ P,.TSTRG## ;LIST THE STATUS TEXT
PUSHJ P,.TDQTE## ;CAP OFF EXTENDED MESSAGE
;Now list the status text field, if any
EDAP30: MOVE T1,.IODPV(IO) ;GET DAP PROTOCOL VERSION
CAIL T1,007000 ;VERSION 7.0 OR LATER?
SKIPN .IDSTX(IO) ;YES, GOT A STATUS TEXT FIELD TO TYPE?
JRST EDAP90 ;NO, ALL DONE
PUSHJ P,.TCRLF## ;FINISH OFF THIRD LINE TEXT
MOVEI T1,[ASCIZ\ DAP status text is "\]
PUSHJ P,.TSTRG## ;FIRE UP YET ANOTHER LINE
MOVEI T1,.IDSTX(IO) ;ADDRESS OF STATUS TEXT STRING
PUSHJ P,.TSTRG## ;TYPE IT OUT TOO
PUSHJ P,.TDQTE## ;CAP OFF QUOTED STRING
;All done here
EDAP90: POPJ P, ;RETURN NOT <CR><LF>'ED
SUBTTL Error messages - QUEUE/GALAXY related
;ERQUE -- ISSUE ERROR MESSAGE FOR .QUEOP (QUEUE/GALAXY) ERROR
;Call is:
;
; MOVX M0,<COD>
; MOVX T1,<CDB>
; PUSHJ P,ERQUE
; return always
;
;Where <COD> is the 18-bit status/exception/error code; and <CDB> is the
;associated I/O CDB (contains file name, etc).
;
;This routine issues a textual error message to the command terminal.
;
;Preserves all registers.
ENTRY .ERQUE
.ERQUE: MOVEM M0,.IOERR(T1) ;PROTECT THE ERROR CODE
MOVE M0,0(P) ;CALLER'S PC (+1)
MOVEM M0,.IOERR+1(T1) ;SAVE ADDRESS TOO
XMOVEI M0,[ASCIZ\queueing \] ;QUEUEING PARTICIPLE
;AC usage is as follows:
;
; P1 -1=fatal; 0=warning; 1=informational
; P2 address of "participle" text string
; P3 flags and address of reason text string
ERQUE1: PUSHJ P,.SACIO## ;SWITCH TO I/O CONTEXT
PUSHJ P,.SAVE4## ;SAVE THE PEAS
PUSHJ P,TSAV14## ;PROTECT CALLER'S T REGS
MOVE P2,M0 ;POSITION PARTICIPLE TEXT STRING ADDRESS
SETZ P1, ;ASSUME MERELY A WARNING
PUSHJ P,ONERCK## ;SEE IF USER WANTS TO CONTINUE AFTERWARD
SETO P1, ;NO, FATAL ERROR
MOVE P4,.IOFSC(IO) ;ADDRESS OF FILE SPEC BLOCK
ERQUE2: MOVEI T4,ERQTBL ;QUEUE ERROR TABLE
PUSHJ P,.CFIND## ;FIND ENTRY FOR THIS ERROR
JRST ERQUE4 ;NOT A KNOWN/EXPECTED QUEUE ERROR
XMOVEI P4,(T1) ;ADDRESS REASON TEXT AND FLAGS
MOVE P3,(P4) ;REASON CODE ADDRESS AND FLAGS
MOVEI T2,[ASCIZ\Error \] ;BASIC TEXT
PUSHJ P,M.QUE ;FIRE UP A NIPQUE ERROR MESSAGE
PUSHJ P,ERFAT ; FINISH OFF TEXT (FILE SPEC, ETC.)
PJRST EREXIT ;CAP OFF ERROR TEXT
;HERE FOR UNUSUAL ERROR/EXCEPTION CODE
ERQUE4: MOVEI T4,ERQTBU ;"UNUSUAL" ERROR TEXT TABLE
PUSHJ P,.CFIND## ;SEE IF KNOWN UNUSUAL ERROR
JRST ERQUE6 ;NO, TRY FOR SPECIAL CASES
XMOVEI P4,(T1) ;ADDRESS OF FLG,,TEXT ADDRESS
HLRE P1,(P4) ;SET SEVERITY LEVEL
HRRZ T2,(P4) ;ADDRESS OF TEXT BODY
PUSHJ P,M.QUE ;NIPFAE ERROR MESSAGE
JFCL ;NOTHING MORE TO SAY HERE . . .
PJRST EREXIT ;CAP OFF THE ERROR/EXCEPTION TEXT
;HERE TO LOOK FOR SPECIAL CASES
ERQUE6: JSP T4,.CDISP## ;DISPATCH ON SPECIAL-CASE MESSAGES
0 ;NONE OTHERS
;FALL INTO ERQUE8
;HERE FOR UNKNOWN QUEUE ERROR
ERQUE8: MOVEI T2,[ASCIZ\Unknown error/exception code = \]
PUSHJ P,M.QUE ;FIRE UP A NIPQUE ERROR MESSAGE
PUSHJ P,[MOVE T1,.IOERR(IO) ;FETCH THE UNKNOWN ERROR CODE
PJRST .TOCTW##] ;LIST IT (FOR WHAT IT'S WORTH)
PJRST EREXIT ;CAP OFF ERROR TEXT
;HERE TO ISSUE NIPQUE ERROR MESSAGE
;Call is:
;
; MOVEI T2,<TXT>
; PUSHJ P,M.QUE
; FIRST return
; NOTEXT return
;
;Where <TXT> is the address of the text string to start up the error.
;
;M.QUE will print a NIPQUE error/warning/informational message. Register
;P1 is assumed to be the severity flag (-1 fatal; 0 warning; 1 informational)
;for the message. M.QUE only starts the message, the caller is responsible
;for terminating the message (i.e., the trailing ,<CR><LF>).
;
;On "FIRST" return, the user should append any subsidiary text desired to
;the basic text (such as typing the error code, file spec, etc.).
;
;On "NOTEXT" return, no further text should be typed, the message should
;immediately be finished (e.g., /MESSAGE:(PREFIX,NOFIRST)).
;
;Uses T1, T2, T3, T4
M.QUE: MOVE T1,['NIP',,'QUE'] ;MODULE AND MESSAGE CODES
HRL T2,[EXP "?", "%", "["]+1(P1) ;SEVERITY LEVEL
MOVE T3,.IOERR+1(IO) ;ADDRESS(+1) OF CALLER
PUSHJ P,.ERMSA## ;FIRE UP AN ERROR MESSAGE
TXNN T1,JWW.FL ;WANT "FIRST" LINE TEXT
AOS (P) ;NO, JUST .TCRLF IT
POPJ P, ;RETURN AS NEEDED.
;ERQTBL - STANDARD QUEOP ERROR TABLE
ERQTBL: X $EQIAL,EFF$NM,<QUEUE. Illegal argument list>
X $EQILF,EFF$NM,<QUEUE. Illegal function>
X $EQNFS,EFF$NM,<QUEUE. No monitor free core>
X $EQADC,EFF$NM,<QUEUE. Address check>
X $EQCNR,EFF$NM,<QUEUE. Componet not running (no PID)>
X $EQFER,EFF$NM,<QUEUE. Fatal error returned from ORION>
X $EQSOC,EFF$NM,<QUEUE. Invalid message from ORION>
X $EQNPV,EFF$NM,<QUEUE. Privilege violation>
X $EQPAC,EFF$NM,<SPPRM. Address check>
X $EQPIA,EFF$NM,<SPPRM. Illegal arg list length>
X $EQPID,EFF$NM,<SPPRM. Illegal device>
X $EQPNA,EFF$NM,<SPPRM. Device not OPENed>
X $EQPNS,EFF$NM,<SPPRM. Device is not spooled>
X $EQPNC,EFF$NM,<SPPRM. No monitor free core>
X $EQPIF,EFF$NM,<SPPRM. Illegal function>
0
;ERQTBU - UNUSUAL QUEOP ERROR TABLE
ERQTBU: 0
SUBTTL Error message processor
;ERMSX -- OUTPUT ERROR MESSAGE BASED ON ERROR/STATUS CODE
;CALL IS:
;
; MOVEI M0,<STS>
; MOVX T1,<CDB>
; PUSHJ P,ERMSX
; error return
; normal return
;
;Where <STS> is the generic program status code (as defined in the
;definitions module ND); and <CDB> is the address of the associated
;I/O CDB, if appropriate.
;
;On "error" return the "process" cannot be continued (e.g., network
;link died, program stopcode, etc.).
;
;On normal return a textual message has been generated and issued to
;the "command terminal".
;
;ERMSX does not attempt any type of error-correction activity, that is
;left to the caller's discretion - all ERMSX does is try to tell the
;"user" exactly what is "going on".
;
;Preserves all acs (even M0!)
ENTRY .ERMSX
INTERN ERMSX0, ERMSX1
.ERMSX: PUSHJ P,.SACIO## ;SET UP I/O CDB INDEX, JUST IN CASE
ERMSX0:
ERMSX1: PUSHJ P,.SAVE4## ;SAVE THE P'S
PUSHJ P,TSAV14## ;SAVE THE T'S ON G.P.S
PUSH P,M0 ;SAVE EVEN M0!
SETZ T1, ;NO "OUTPUT" SPEC HERE
MOVE T2,IO ;ALWAYS AN "INPUT" SPEC
PUSHJ P,IOQET1## ;MAKE SURE FILE SPEC HAS BEEN "TELL"'ED
JFCL ;DUH??
MOVE M0,0(P) ;RESTORE ORIGINAL ERROR CODE
PUSHJ P,EMSG ;GENERATE THE TEXT
SOS -1(P) ;NON-SKIP RETURN
POP P,M0 ;RESTORE M0
JRST .POPJ1## ;AND SKIP [MAYBE] RETURN
;DO THE REAL WORK OF ERMSX
EMSG: MOVE T2,M0 ;POSITION 18-BIT CODE
ANDX T2,$E$ERR ;AND REDUCE IT TO ITS FUNCTIONAL GROUPING
JSP T4,.CDISP## ;AND DISPATCH ON FUNCTIONAL GROUPING
ESTS,,$E$STS ;GENERAL STATUS
EFIL,,$E$FIL ;FILE ACCESS ERROR
EIOX,,$E$IOX ;I/O TRANSMISSION ERROR
EDAT,,$E$DAT ;DATA FORMAT
EENV,,$E$ENV ;ENVIRONMENTAL ERROR
EMEM,,$E$MEM ;MEMORY MANAGEMENT
EMSC,,$E$MSC ;MISCELLANEOUS
ECTL,,$E$CTL ;INTERNAL FLOW CONTROL
EDIE,,$E$DIE ;INTERNAL PROGRAM ERROR
0 ;END OF TABLE
;UNKNOWN STATUS CODE
EMSG10: MOVEI T1,[ASCIZ\? Unknown status/error code \]
;TEMP TYPER
EMSG20: PUSH P,M0 ;SAVE 18-BIT CODE
PUSHJ P,.TSTRG## ;TYPE TEXT
POP P,T1 ;POSITION 18-BIT CODE
PUSHJ P,.TOCTW## ;AND TYPE IT TOO
PJRST .TCRLF## ;CAP IT OFF AND ABORT
;GENERAL STATUS
ESTS: MOVEI T1,[ASCIZ\? General status code \]
JRST EMSG20 ;ISSUE SOMETHING
;FILE ACCESS ERROR
EFIL: MOVE T2,M0 ;ERROR CODE
JSP T4,.CDISP## ;DISPATCH ON ERROR TYPE
EFDAP,,$EFDAP ;DAP FILE ACCESS ERROR
0 ;THAT'S IT
MOVEI T1,[ASCIZ\? File access error \]
JRST EMSG20 ;ISSUE SOMETHING
;UNSPECIFIED DAP FILE ACCESS ERROR
EFDAP: MOVEI T1,[ASCIZ\? DAP-level file access error \]
PUSHJ P,.TSTRG## ;START UP MESSAGE
LDB T1,[POINT 12,.IDSTC(IO),35] ;DAP STATUS MICCODE FIELD
PUSHJ P,.TOCTW## ;LIST OCTAL REASON
MOVEI T1,[ASCIZ\; \]
PUSHJ P,.TSTRG## ;TYPE OUT SEPARATOR
LDB T2,[POINT 12,.IDSTC(IO),35] ;DAP MICCODE FIELD AGAIN
MOVEI T4,DAPSTS## ;DAP STATUS CODES TABLE
PUSHJ P,.CFIND## ;SEE IF IT IS KNOWN TO US
JRST [MOVEI T1,[ASCIZ\Unknown DAP status "MICCODE" value\]
CAIN T2,0 ;"UNSPECIFIED ERROR"
MOVEI T1,[ASCIZ\Unspecified error\]
JRST .+1] ;ISSUE SOMETHING
PUSHJ P,.TSTRG## ;TYPE OUT TEXT
PUSHJ P,.TCRLF## ;CAP OFF WITH A <CR><LF>
SKIPN .IDSTV+1(IO) ;SOMETHING FUNNY PASSED ALSO?
JRST .POPJ1## ;NO, ALL DONE
MOVEI T1,[ASCIZ\ Secondary status value = \]
PUSHJ P,.TSTRG## ;YES, TELL USER THAT TOO
MOVE T1,.IDSTV+1(IO) ;RETRIEVE LOW-ORDER WORD
PUSHJ P,.TOCTW## ;BLAST IT OUT IN OCTAL
PUSHJ P,.TCRLF## ;CAP OFF SECONDARY STATUS
JRST .POPJ1## ;AND RETURN
;I/O TRANSMISSION ERROR
EIOX: CAIN M0,$EICKE ;CRC ERROR
JRST EIOCKE ;YES
MOVEI T1,[ASCIZ\? I/O transmission error \]
JRST EMSG20 ;ISSUE SOMETHING
;CRC ("CHECKSUM") ERROR
EIOCKE: MOVEI T1,[ASCIZ\? Network file data CRC ("checksum") error \]
PUSHJ P,.TSTRG## ;TELL USER OF WOE
PJRST .TCRLF## ;CAP IT OFF
;DATA FORMAT ERROR
EDAT: MOVEI T1,[ASCIZ\? Data format error \]
JRST EMSG20 ;ISSUE SOMETHING
;ENVIRONMENTAL ERRORS
EENV: MOVE T2,M0 ;RETRIEVE ERROR
JSP T4,.CDISP## ;DISPATCH ON ERROR TYPE
EERDE,,$EERDE ;REMOTE-DETECTED DAP ERROR
0 ;END OF TABLE
MOVEI T1,[ASCIZ\? Environmental error \]
JRST EMSG20 ;ISSUE SOMETHING
;ENVIRONMENTAL ERROR - REMOTE DETECTED DAP ERROR
EERDE: MOVEI T1,[ASCIZ\? Remote-detected DAP-level error: \]
PUSHJ P,.TSTRG## ;START UP THE OUTPUT
LDB T2,[POINT 4,.IDSTC(IO),23] ;GET DAP MAJOR CLASS
MOVEI T4,[
[ASCIZ\unsupported function\],,2
[ASCIZ\bad message syntax\],,10
[ASCIZ\message field invalid\],,11
0] ;TEXT POSSIBILITIES
PUSHJ P,.CFIND## ;FIND MAJOR ERROR
MOVEI T1,[ASCIZ\ UNKNOWN\] ;DUH?
PUSHJ P,.TSTRG## ;LIST MAJOR ERROR
PUSHJ P,.TCRLF## ;START UP A NEW LINE
LDB P1,[POINT 6,.IDSTC(IO),29] ;GET DAP MESSAGE CODE
LDB P2,[POINT 6,.IDSTC(IO),35] ;GET DAP FIELD CODE
JUMPN P1,EERDE4 ;PROCESS NORMAL ERROR
MOVE T2,P2 ;SUB-MICCODE FIELD
MOVEI T4,[
[ASCIZ\ Unspecified DAP message error\],,00
[ASCIZ\ Unknown DAP message type\],,10
0] ;TEXT POSSIBILITIES
PUSHJ P,.CFIND## ;LOOK FOR VIABLE TEXT
MOVEI T1,[ASCIZ\ Unknown "miscellaneous" DAP error code\]
PUSHJ P,.TSTRG## ;TYPE OUT NEAR-USLESS MESSAGE
JRST EERDE9 ;AND EXIT THIS VALE OF TEARS
;ERROR IS IN THE DAP MESSAGE
EERDE4: MOVEI T1,[ASCIZ\ Error detected in DAP "\]
PUSHJ P,.TSTRG## ;PREFIX MESSAGE CODE
CAIG P1,20 ;ONE THAT SEEMS TO PARALLEL ACTUAL MSG CODE?
SKIPA T2,P1 ;YES
SETO T2, ;NO
MOVEI T4,DAPIDX## ;DAP EXECUTION TABLE INDEXER
PUSHJ P,.CFIND## ;TRY TO FIND A MATCHING MESSAGE TYPE
SETO T1, ;NONE? OH WELL, WE DID TRY!
MOVE P1,T1 ;HANG ON TO INDEX
CAIL T1,0 ;DID MESSAGE CODE GEL?
SKIPA T1,DAPXTX##(T1) ;YES, GET APPROPRIATE TEXT
MOVEI T1,[ASCIZ\UNKNOWN\] ;DUH?
PUSHJ P,.TSTRG## ;LIST ENGLISH MESSAGE CODE DESCRIPTION
MOVEI T1,[ASCIZ\" message; \]
PUSHJ P,.TSTRG## ;DELIMIT MESSAGE TYPE
JUMPL P1,EERDE9 ;CAN'T DO ANYMORE HERE
JUMPE P2,[MOVEI T1,[ASCIZ\Unknown field present\]
JRST EERDE7] ;GO BARF AT USER
CAIGE P2,20 ;ERROR IN DAP MESSAGE HEADER?
SETZ P1, ;YES, RESET TO USE HEADER TEMPLATE TEXT
MOVE T2,P2 ;SCRATCH COPY TO USE AS INDEX
CAIL P2,20 ;ERROR IN DAP MESSAGE FIELD?
SUBI T2,10 ;YES
SUBI T2,7 ;REDUCE TO FIELD ID
JUMPGE T2,EERDE6 ;GO LIST FIELD BY NAME
EERDE5: MOVEI T1,[ASCIZ\(Unknown DAP error field indicator "\]
PUSHJ P,.TSTRG## ;TYPE OUT
MOVE T1,P2 ;FIELD INDICATOR
PUSHJ P,.TSTRG## ;TYPE THAT TOO
MOVEI T1,[ASCIZ\")\]
PUSHJ P,.TSTRG## ;CAP OFF UNKNOWN WHATEVER
JRST EERDE9 ;GO BARF AT USER
EERDE6: MOVE T1,P1 ;DAP INDEX
ADD T1,T2 ;RELOCATE TO SPECIFIC FIELD COMPONET
LDB T3,[POINTR DAPXCT##(T1),DX$COD] ;FETCH FIELD NUMBER WITHIN MSG
CAME T2,T3 ;FIELDS MATCH?
JRST EERDE5 ;NO (????)
MOVE P1,DAPXTX##(T1) ;GET TEXTUAL NAME OF FIELD
MOVEI T1,"""" ;QUOTE THE FIELD NAME
PUSHJ P,.TCHAR## ; . . .
MOVE T1,P1 ;ADDRESS OF FIELD NAME STRING
EERDE7: PUSHJ P,.TSTRG## ;TYPE IT OUT
MOVEI T1,[ASCIZ\" field.\]
PUSHJ P,.TSTRG## ;CAP OFF FIELD NAME MESSAGE
EERDE9: PUSHJ P,.TCRLF## ;END LINE
JRST .POPJ1## ;RETURN
;MEMORY MANAGEMENT ERRORS
EMEM: MOVEI T1,[ASCIZ\? Memory management error \]
JRST EMSG20 ;ISSUE SOMETHING
;MISCELLANEOUS
EMSC: MOVEI T1,[ASCIZ\? Miscellaneous status/error \]
JRST EMSG20 ;ISSUE SOMETHING
;INTERNAL FLOW CONTROL
ECTL: MOVEI T1,[ASCIZ\? Internal flow control code \]
JRST EMSG20 ;ISSUE SOMETHING
;INTERNAL PROGRAM ERROR
EDIE: MOVEI T1,[ASCIZ\? Internal program error \]
JRST EMSG20 ;ISSUE SOMETHING
END