STA TITLE 'DMMSTA (IPCS) VM/370 - RELEASE 6' 00001000
* 00002000
* MODULE NAME: STAT 00003000
* 00004000
* 00005000
* FUNCTION: DISPLAYS STATUS OF A GIVEN PROBLEM, GROUP OF 00006000
* PROBLEMS, OR ALL PROBLEMS. 00007000
* 00008000
* 00009000
* ATTRIBUTES: NON-REENTRANT 00010000
* NON-REUSABLE 00011000
* 00012000
* 00013000
* ENTRY POINTS: DMMSTA 00014000
* 00015000
* 00016000
* ENTRY CONDITIONS: R1 POINTS TO PASSED PARMS 00017000
* MODULE NAME LENGTH 8 00018000
* PARM1 (ALL OR PNUM) LENGTH 8 00019000
* PARM2 (SRCH ARG1) LENGTH 8 00020000
* PARM3 (SRCH ARG2) LENGTH 8 00021000
* 00022000
* 00023000
* EXIT CONDITIONS: RETURN CODE IN R15 00024000
* 0 NORMAL RETURN, FUNCTION PERFORMED 00025000
* 4 PROBLEM NUMBER NOT FOUND IN SYMPTOM SUMMARY 00026000
* 8 UNCORRECTABLE ERROR OCCURRED 00027000
* 00028000
* 00029000
* CALLS TO OTHER ROUTINES: NONE 00030000
* 00031000
* 00032000
* EXTERNAL REFERENCES: NONE 00033000
* 00034000
* 00035000
* TABLES/WORKAREAS: NONE 00036000
* 00037000
* 00038000
* REGISTER USAGE: R13 SAVEAREA 00039000
* R12 BASE 00040000
* R11 SYMSECT DSECT (SYMPTOM SUMMARY CONTROL RECORD) 00041000
* R10 WORK 00042000
* R9 CURRENT RECORD NUMBER WITHIN SYMPTOM SUMMARY 00043000
* R8 INTERNAL LINK REGISTER 00044000
* R7 POINTER TO TERMINAL OUTPUT RECORD 00045000
* R6 LENGTH OF TERMINAL OUTPUT RECORD 00046000
* R2,R3,R4,R5 WORK 00047000
* R1 POINTER TO PARMS 00048000
* 00049000
* 00050000
* NOTES: 00051000
* 00052000
* 00053000
* OPERATION: 00054000
* 00055000
* I. STAT ALL LOCAL 00056000
* 11. STAT ALL AAAAAA BBBBBB 00057000
* 111. STAT NNNNN 00058000
* 1V. USER PROMPT INTERNAL SUBROUTINE 00059000
* 00060000
* UPON ENTRY IT IS DETERMINED IF ANY PARMS HAVE BEEN SUPPLIED. 00061000
* IF NOT THE USER PROMPT SUBROUTINE IS ENTERED. 00062000
* IF PARMS WERE PASSED THEY ARE EXAMINED FOR VALIDITY AND THE 00063000
* APPROPRIATE ROUTINE IS ENTERED. 00064000
* 00065000
* I. STAT ALL 00066000
* 00067000
* A. LALLSW SWITCH IS SET INDICATING STAT ALL. 00068000
* B. THE OLD 'STATALL LOCAL A1' FILE IS ERASED. 00069000
* C. THE HDR IS PUT OUT IN THE NEW 'STATALL LOCAL A1' FILE. 00070000
* D. THE SYMPTOM SUMMARY FILE IS READ AND THE FIRST CTL RCD 00071000
* IS PUT OUT IN THE 'STATALL LOCAL A1' FILE. 00072000
* E. THE POSITION OF THE NEXT SYMPTOM SUMMARY CONTROL RCD IS 00073000
* CALCULATED AND READ. THE RCD IS ADDED TO 'STATALL LOCAL A1' 00074000
* F. WHEN END OF FILE IS REACHED ON THE SYMPTOM SUMMARY FILE 00075000
* THE 'STATALL LOCAL A1' FILE IS CLOSED AND THE USER IS 00076000
* INFORMED THAT THE FILE HAS BEEN CREATED. 00077000
* G. NORMAL EXIT IS TAKEN. 00078000
* 00079000
* II. STAT ALL AAAAA BBBBB 00080000
* 00081000
* A. AAAAA IS EXAMINED FOR VALIDITY AND R2 (STATUS OR LAST 00082000
* FUNCTION) OR R4 (FAILURE TYPE) IS LOADED WITH THE ADDR OF 00083000
* THE USER SUPPLIED SEARCH ARGUMENT. 00084000
* B. IF THERE IS A BBBBB IT IS ALSO EXAMINED FOR A VALID SRCH 00085000
* ARGUMENT AND THE APPROPRIATE REGISTER LOADED TO POINT IT. 00086000
* (THE BBBBB ARGUMENT WILL SUPERCEDE THE AAAAA ARG IF THEY 00087000
* ARE OF THE SAME TYPE I.E. BOTH STATUS OR BOTH FAILURE). 00088000
* C. THE SYMPTOM SUMMARY FILE CTL RCDS ARE NOW SEARCHED FOR 00089000
* MATCHES AND ANY MATCHES ARE DISPLAYED ON THE TERMINAL. 00090000
* (BEFORE THE FIRST MATCH IS DISPLAYED A CP DIAGNOSE TO ERASE 00091000
* THE SCREEN IS EXECUTED IN CASE THE TERMINAL IS A DISPLAY 00092000
* DEVICE). 00093000
* 00094000
* III. STAT NNNNN (STATUS OF A SINGLE PROBLEM NNNNN) 00095000
* 00096000
* A. THE PASSED PARM IS EXAMINED FOR VALIDITY (NUMERICS) AND 00097000
* IF IN ERROR (SEE IV.). 00098000
* B. THE SYMPTOM SUMMARY FILE IS SEARCHED FOR THE PROB NUMBR 00099000
* C. THE CTL RECORD IS DISPLAYED ON THE TERMINAL WHEN FOUND. 00100000
* 00101000
* IV. USER PROMPTING FOR A PROBLEM NUMBER. 00102000
* 00103000
* A. THE USER IS PROMPTED TO ENTER THE PROBLEM NUMBER OR 00104000
* 00000 FOR A STATUS ALL REQUEST. 00105000
* B. THE INPUT IS EXAMINED FOR VALIDITY AND NORMALIZED TO A 5 00106000
* DIGIT NUMBER. 00107000
* C. GO TO III. 00108000
* 00109000
* 00110000
* ERROR MESSAGES: 00111000
* 00112000
* DMMSTA100S ERROR 'NNN' READING FILE 'FILENAME FILETYPE FM' 00113000
* DMMSTA200S ERROR 'NNN' WRITING FILE 'FILENAME FILETYPE FM' 00114000
* DMMSTA601S OPERAND NOT RECOGNIZED, STATALL ASSUMED 00115000
* 00116000
* 00117000
EJECT 00118000
DMMSTA CSECT @VA04250 00119000
USING DMMSTA,R15 TEMPORARY ADDRESSABILITY @VA04250 00120000
B START GO AROUND EYECATCHER @VA04250 00121000
DS 0D @VA04250 00122000
MODNAME DC C'DMMSTA ' MODULE NAME @VA04250 00123000
RELLEV DC C'REL4LEV0' RELEASE AND LEVEL @V4075A1 00124000
START STM R14,R12,12(R13) SAVE CALLER'S REGISTERS @VA04250 00125000
LR R12,R15 ESTABLISH OUR BASE REGISTER @VA04250 00126000
DROP R15 @VA04250 00127000
USING DMMSTA,R12 START USING OUR BASE REGISTER @VA04250 00128000
ST R13,SAVEAREA+8 SAVE ADDRESS OF CALLER'S SAVEAREA@VA04250 00129000
LA R13,SAVEAREA ESTABLISH OUR SAVEAREA @VA04250 00130000
LA R11,INPUT INPUT FOR SYMPTOM SUMMARY RCDS @VA04250 00131000
USING SYMSECT,R11 SYMPTOM SUMMARY CTL RCD FORMAT @VA04250 00132000
USING PARMSECT,R1 PASSED PARMS DSECT @VA04250 00133000
* CHECK FOR TYPE OF STATUS REQUEST 00134000
CLC PARM1,=C'ALL ' STATUS ALL COMMAND? @VA04250 00135000
BE STATSRCH YES @VA04250 00136000
CLI PARM1,FENCE ANYTHING AT ALL ENTERED? @VA04250 00137000
BE SPNUM NO, GO PROMPT @VA04250 00138000
TM PARM1,NUMERIC DID USER JUST SUPPLY PRB NMBR? @VA04250 00139000
BO STATRDY YES @VA04250 00140000
MVC M601PARM,PARM1 MOVE PAD PARM TO MESSAGE @VA04250 00141000
B DOMSG601 GO TELL USER @VA04250 00142000
STATRDY LA R0,EIGHT INDICATE WE HAVE READ 8 BYTES @VA04250 00143000
LA R1,EIGHT(R1) POINT DIRECTLY TO DATA @VA04250 00144000
B SPNUM2 GO CHECK FOR VALID NUMERIC DATA @VA04250 00145000
*************************************************************** 00146000
* STATUS ALL HAS BEEN REQUESTED. THE POSSIBILITES ARE: 00147000
* STAT ALL OR A SEARCH FOR PROBLEMS IN CATEGORIES 00148000
* SPECIFIED BY THE USER. 00149000
* WE WILL CHECK FIRST FOR STAT ALL 00150000
*************************************************************** 00151000
STATSRCH CLI PARM2,BLANK IF NOTHING THEN @VA04250 00152000
BE STALLOC ASSUME STATUS ALL @VA04250 00153000
CLI PARM2,FENCE NOTHING? @VA04250 00154000
BE STALLOC ASSUME STAT ALL LOC @VA04250 00155000
*************************************************************** 00156000
* THE USER WANTS SOME KIND OF SEARCH OF THE SYMPTOM SUMMARY 00157000
* DONE. WE'LL ALLOW THE SEARCH OF SYMSTAT, SYMFAIL, AND SYMLFCT 00158000
* FIELDS AGAINST THE VALUES SUPPLIED BY THE USER. 00159000
*************************************************************** 00160000
SR R2,R2 INDICATE NO STATUS VALUE AT START@VA04250 00161000
LA R3,SYMSTAT THIS WILL BE USED AS A SEARCH PTR@VA04250 00162000
SR R4,R4 INDICATE NO FAILURE VALUE FIRST @VA04250 00163000
LA R5,SYMFAIL SUBSEQUENT COMPARES @VA04250 00164000
CLC =C'AB ',PARM2 IS IT PSR CODE FOR ABEND? @VA04250 00165000
BE CKMVAB YES @VA04250 00166000
CLC =C'ABEND ',PARM2 LOOKING AT ABENDS? @VA04250 00167000
BNE CKOPENU NO @VA04250 00168000
CKMVAB LA R4,=C'ABEND ' USER WANTS TO FIND ALL ABENDS @VA04250 00169000
CKOPENU CLC =C'OPENUSER',PARM2 ALL OPEN USER PROBLEMS? @VA04250 00170000
BNE CKOPENI NO @VA04250 00171000
LA R2,=C'OPENUSER' SAVE FOR LATER COMPARE @VA04250 00172000
CKOPENI CLC =C'OPENIBM ',PARM2 ALL OPENIBM PROBLEMS? @VA04250 00173000
BNE CKOPEN NO @VA04250 00174000
LA R2,=C'OPENIBM ' SAVE FOR LATER COMPARE @VA04250 00175000
CKOPEN CLC =C'OPEN ',PARM2 ALL OPEN PROBLEMS? @VA04250 00176000
BNE CKAPAR NO @VA04250 00177000
LA R2,=C'OPEN ' SAVE PARM FOR LATER COMPARE @VA04250 00178000
CKAPAR CLC =C'APARED ',PARM2 ALL PROBLEMS APARED? @VA04250 00179000
BNE CKMSG NO @VA04250 00180000
LA R2,=C'APARED ' SAVE PARM FOR LATER COMPARE @VA04250 00181000
CKMSG CLC =C'MS ',PARM2 ALL MESSAGES? @VA04250 00182000
BE CKMVMSG YES @VA04250 00183000
CLC =C'MSG ',PARM2 ALL MESSAGES? @VA04250 00184000
BNE CKINCO NO @VA04250 00185000
CKMVMSG LA R4,=C'MS ' SAVE PARM FOR LATER COMPARE @VA04250 00186000
CKINCO CLC =C'IN ',PARM2 ALL INCORRECT OUTS? @VA04250 00187000
BE CKMVIN YES @VA04250 00188000
CLC =C'INCORR ',PARM2 ALL INCORRECT OUTS? @VA04250 00189000
BNE CKINF NO @VA04250 00190000
CKMVIN LA R4,=C'INCORR ' SAVE PARM FOR LATER COMPARE @VA04250 00191000
CKINF CLC =C'INF ',PARM2 ALL INFORMATION PROBLEMS? @VA04250 00192000
BNE CKWAIT NO @VA04250 00193000
LA R4,=C'INF ' POINT TO INF FOR LATER COMPARE @VA04250 00194000
CKWAIT CLC =C'WAIT',PARM2 ALL WAIT TYPE? @VA04250 00195000
BE CKMVWS YES @VA04250 00196000
CLC =C'WS ',PARM2 PSR CODE FOR WAIT STATE? @VA04250 00197000
BNE CKLOOP NO @VA04250 00198000
CKMVWS LA R4,=C'WAIT ' SAVE PARM FOR LATER COMPARE @VA04250 00199000
CKLOOP CLC =C'LOO',PARM2 ALL LOOPS? @VA04250 00200000
BE CKMVLP YES @VA04250 00201000
CLC =C'LP ',PARM2 PSR CODE FOR LOOP? @VA04250 00202000
BNE CKPERF NO @VA04250 00203000
CKMVLP LA R4,=C'LOOP ' SAVE PARM FOR LATER COMPARE @VA04250 00204000
CKPERF CLC =C'PERFORM ',PARM2 PERFORMANCE PROBLEMS? @VA04250 00205000
BE CKMVPR YES @VA04250 00206000
CLC =C'PR ',PARM2 PSR CODE FOR PERFORMANCE? @VA04250 00207000
BNE CKDOC NO @VA04250 00208000
CKMVPR LA R4,=C'PERFORM ' SAVE PARM FOR LATER COMPARE @VA04250 00209000
CKDOC CLC =C'DOC ',PARM2 DOCUMENTATION PROBLEMS? @VA04250 00210000
BE CKMVDD YES @VA04250 00211000
CLC =C'DD ',PARM2 PSR CODE FOR DOCUMENTATION? @VA04250 00212000
BNE CKCLOSE NO @VA04250 00213000
CKMVDD LA R4,=C'DOC ' SAVE PARM FOR LATER COMPARE @VA04250 00214000
CKCLOSE CLC =C'CLOSED ',PARM2 ALL CLOSED PROBLEMS? @VA04250 00215000
BNE CKNEED NO @VA04250 00216000
LA R2,=C'CLOSED ' SAVE PARM FOR LATER COMPARE @VA04250 00217000
CKNEED CLC =C'NEEDINFO',PARM2 ALL PROBLEMS AWAITING INFO? @VA04250 00218000
BNE CKPTF1 NO @VA04250 00219000
LA R2,=C'NEEDINFO' SAVE PARM FOR LATER COMPARE @VA04250 00220000
CKPTF1 CLC =C'PTFON ',PARM2 ALL PROBLEMS IN PTF APPLIED @VA04250 00221000
BNE CKPTF2 NO @VA04250 00222000
LA R2,=C'PTFON ' SAVE PARM FOR LATER COMPARE @VA04250 00223000
CKPTF2 CLC =C'PTFRCVD ',PARM2 ALL PROBLEMS WITH AVAILABLE P@VA04250 00224000
BNE CK1ABEND NO @VA04250 00225000
LA R2,=C'PTFRCVD ' SAVE PARM FOR COMPARES @VA04250 00226000
CK1ABEND CLC =C'ABEND ',PARM3 LOOKING AT ABENDS? @VA04250 00227000
BE CK1MVABE YES @VA04250 00228000
CLC =C'AB ',PARM3 LOOKING AT ABENDS? @VA04250 00229000
BNE CK1OPENU NO @VA04250 00230000
CK1MVABE LA R4,=C'ABEND ' SAVE PARM FOR LATER COMPARE @VA04250 00231000
CK1OPENU CLC =C'OPENUSER',PARM3 ALL OPEN USER PROBLEMS? @VA04250 00232000
BNE CK1OPENI NO @VA04250 00233000
LA R2,=C'OPENUSER' SAVE FOR LATER COMPARE @VA04250 00234000
CK1OPENI CLC =C'OPENIBM ',PARM3 ALL OPENIBM PROBLEMS? @VA04250 00235000
BNE CK1OPEN NO @VA04250 00236000
LA R2,=C'OPENIBM ' SAVE FOR LATER COMPARE @VA04250 00237000
CK1OPEN CLC =C'OPEN ',PARM3 ALL OPEN PROBLEMS? @VA04250 00238000
BNE CK1APAR NO @VA04250 00239000
LA R2,=C'OPEN ' SAVE FOR LATER COMPARE @VA04250 00240000
CK1APAR CLC =C'APARED ',PARM3 ALL APARED PROBLEMS? @VA04250 00241000
BNE CK1MSG NO @VA04250 00242000
LA R2,=C'APARED ' SAVE PARM FOR LATER COMPARE @VA04250 00243000
CK1MSG CLC =C'MS ',PARM3 ALL MESSAGES? @VA04250 00244000
BE CK1MVMSG YES @VA04250 00245000
CLC =C'MSG ',PARM3 ALL MESSAGES? @VA04250 00246000
BNE CK1INCO NO @VA04250 00247000
CK1MVMSG LA R4,=C'MS ' SAVE PARM FOR LATER COMPARE @VA04250 00248000
CK1INCO CLC =C'IN ',PARM3 INCORRECT OUTS? @VA04250 00249000
BE CK1MVINC YES @VA04250 00250000
CLC =C'INCORR ',PARM3 INCORRECT OUTS? @VA04250 00251000
BNE CK1INF NO @VA04250 00252000
CK1MVINC LA R4,=C'INCORR ' SAVE PARM FOR LATER COMPARE @VA04250 00253000
CK1INF CLC =C'INF ',PARM3 INFORMATION TYPE PROBLEMS? @VA04250 00254000
BNE CK1WAIT NO @VA04250 00255000
LA R4,=C'INF ' SAVE DATA FOR LATER COMPARE @VA04250 00256000
CK1WAIT CLC =C'WAIT ',PARM3 ALL WAIT TYPE? @VA04250 00257000
BE CK1MVWS YES @VA04250 00258000
CLC =C'WS ',PARM3 PSR CODE FOR WAIT STATE? @VA04250 00259000
BNE CK1LOOP NO @VA04250 00260000
CK1MVWS LA R4,=C'WAIT ' SAVE PARM FOR LATER COMPARE @VA04250 00261000
CK1LOOP CLC =C'LOOP ',PARM3 ALL LOOPS? @VA04250 00262000
BE CK1MVLP YES @VA04250 00263000
CLC =C'LP ',PARM3 PSR CODE FOR LOOP? @VA04250 00264000
BNE CK1PERF NO @VA04250 00265000
CK1MVLP LA R4,=C'LOOP ' SAVE PARM FOR LATER COMPARE @VA04250 00266000
CK1PERF CLC =C'PERFORM ',PARM3 PERFORMANCE PROBLEMS? @VA04250 00267000
BE CK1MVPR YES @VA04250 00268000
CLC =C'PR ',PARM3 PSR CODE FOR PERFORMANCE? @VA04250 00269000
BNE CK1DOC NO @VA04250 00270000
CK1MVPR LA R4,=C'PERFORM ' SAVE PARM FOR LATER COMPARE @VA04250 00271000
CK1DOC CLC =C'DOC ',PARM3 DOCUMENTATION PROBLEMS? @VA04250 00272000
BE CK1MVDD YES @VA04250 00273000
CLC =C'DD ',PARM3 PSR CODE FOR DOCUMENTATION? @VA04250 00274000
BNE CK1CLOSE NO @VA04250 00275000
CK1MVDD LA R4,=C'DOC ' SAVE PARM FOR LATER COMPARE @VA04250 00276000
CK1CLOSE CLC =C'CLOSED ',PARM3 ALL CLOSED PROBLEMS? @VA04250 00277000
BNE CK1NEED NO @VA04250 00278000
LA R2,=C'CLOSED ' SAVE PARM FOR LATER COMPARE @VA04250 00279000
CK1NEED CLC =C'NEEDINFO',PARM3 ALL PROBLEMS WAITING ON INFO?@VA04250 00280000
BNE CK1PTF1 NO @VA04250 00281000
LA R2,=C'NEEDINFO' SAVE PARM FOR LATER COMPARES @VA04250 00282000
CK1PTF1 CLC =C'PTFON ',PARM3 ALL PROBS IN PTF APPLIED STAT@VA04250 00283000
BNE CK1PTF2 NO @VA04250 00284000
LA R2,=C'PTFON ' SAVE PARM FOR LATER COMPARE @VA04250 00285000
CK1PTF2 CLC =C'PTFRCVD ',PARM3 ALL PROBLEMS WITH PTFS AVAILA@VA04250 00286000
BNE CK2CONT NO @VA04250 00287000
LA R2,=C'PTFRCVD ' SAVE PARM FOR COMPARES @VA04250 00288000
CK2CONT LTR R2,R2 ANY VALID STAT SEARCH? @VA04250 00289000
BNZ CK2CONT2 YES @VA04250 00290000
LTR R4,R4 ANY VALID SYMPTOM NAME? @VA04250 00291000
BNZ CK2CONT2 YES @VA04250 00292000
MVC M601PARM,PARM2 MOVE PAD PARM TO MESSAGE @VA04250 00293000
DOMSG601 WRTERM MSG601,MSG601L @VA04250 00294000
B RETCOD4 TAKE ERROR EXIT @VA04250 00295000
CK2CONT2 LA R9,ONE START WITH THE FIRST RECORD @VA04250 00296000
CKREAD FSREAD 'SYMPTOM SUMMARY A1',BUFFER=INPUT,RECNO=(R9),BSIZE=80 00297000
C R15,EOF EOF? @VA04250 00298000
BNE CKRDER NO @VA04250 00299000
CLI CKSW,ON ANYTHING BEEN PUT OUT? @VA04250 00300000
BE CKFSCLS YES, GO CLOSE FILE @VA04250 00301000
ST R15,WK SAVE RETURN CODE @VA04250 00302000
WRTERM 'NO MATCHES FOUND' @VA04250 00303000
CKFSCLS FSCLOSE 'SYMPTOM SUMMARY A1' @VA04250 00304000
B NORMEXIT GO TAKE NORMAL EXIT @VA04250 00305000
CKRDER LTR R15,R15 ERROR? @VA04250 00306000
BNZ RDERR REALLY WAS AN ERROR @VA04250 00307000
LTR R2,R2 ANY STAT COMPARE? @VA04250 00308000
BZ CKFAILCK NO GO DO FAILURE COMPARE @VA04250 00309000
CLC 0(FIRST4,R2),SYMSTAT THIS PROBLEM MATCH REQUEST?@VA04250 00310000
BE CKSTATCK THIS IS A CANDIDATE @VA04250 00311000
CLC 0(FIRST4,R2),SYMLFCT CHECK LAST FUNCTION FIELD @VA04250 00312000
BE CKSTATCK THIS IS A CANDIDATE, CHECK MORE @VA04250 00313000
CKINCR SR R1,R1 SET FOR IC INSTRUCTION @VA04250 00314000
IC R1,SYMCCNT GET NUMBER OF CARDS IN THIS ONE @VA04250 00315000
LA R9,ONE(R9,R1) GET NEXT RECORD NUMBER TO READ @VA04250 00316000
B CKREAD GO READ NEXT CONTROL RECORD @VA04250 00317000
CKSTATCK CLC =C'OPEN',0(R2) LOOKING AT OPEN PROBLEMS? @VA04250 00318000
BNE CKFAILCK NO @VA04250 00319000
CLC TYPEDISP(LAST4,R2),BLANKS ALL OPEN PROBLEMS? @VA04250 00320000
BE CKFAILCK YES @VA04250 00321000
CLC SYMSTAT,0(R2) CHECK PRECISELY FOR USER OR IBM @VA04250 00322000
BNE CKINCR NOT WHAT WE ARE LOOKING FOR @VA04250 00323000
CKFAILCK LTR R4,R4 ANY FAILURE COMPARE? @VA04250 00324000
BNZ CKFAIL2 YES, DO IT @VA04250 00325000
LTR R2,R2 DID WE ALREADY GET A HIT? @VA04250 00326000
BZ CKINCR NO @VA04250 00327000
BAL R8,CKWRT GO WRITE IT @VA04250 00328000
B CKINCR NOW GO GET NEXT RECORD @VA04250 00329000
CKFAIL2 CLC 0(FIRST3,R4),SYMFAIL THIS PROBLEM MATCH REQ? @VA04250 00330000
BE CKFAIL3 YES @VA04250 00331000
CLC =C'MS',SYMFAIL MESSAGE TYPE FAILURE? @VA04250 00332000
BNE CKINCR NO @VA04250 00333000
CKFAIL2A CLC 0(FIRST2,R4),SYMFAIL ARE WE LOOKING FOR MSGS? @VA04250 00334000
BNE CKINCR NO @VA04250 00335000
CKFAIL3 BAL R8,CKWRT GO PUT THIS STATUS RECORD OUT @VA04250 00336000
B CKINCR CONTINUE @VA04250 00337000
EJECT 00338000
*************************************************************** 00339000
* THIS CCW WILL ERASE THE SCREEN IF A 3270 TYPE TERMINAL 00340000
* THE FUNCTION WILL BE IGNORED IF THE TERMINAL IS NOT A 3270 00341000
*************************************************************** 00342000
DS 0D @VA04250 00343000
ERASECCW DC X'19',X'000000',X'20',X'FF',H'1' @VA04250 00344000
CKWRT CLI CKSW,ON HAVE WE ALREADY WRITTEN THE HDR? @VA04250 00345000
BE CKNOHEAD YES @VA04250 00346000
MVI CKSW,ON DON'T DO THIS AGAIN @VA04250 00347000
LA R6,ERASECCW THIS WILL HAVE NO EFFECT IF WE @VA04250 00348000
LA R7,CONSADDR ARE NOT ON A 3270 @VA04250 00349000
*************************************************************** 00350000
* CP DIAGNOSE INSTRUCTION FOR CONSOLE SCREEN ERASE 00351000
*************************************************************** 00352000
DC X'83670058' 3270 CONSOLE FUNCTION @VA04250 00353000
SPACE 1 00354000
LA R6,HEAD1 HEADER FOR OUTPUT @VA04250 00355000
LA R7,L'HEAD1 LENGTH OF HEADER FOR OUTPUT @VA04250 00356000
WRTERM (R6),(R7) DISPLAY ON TERMINAL @VA04250 00357000
CKNOHEAD LA R6,INPUT INPUT CONTAINS A SUMMARY HEADER @VA04250 00358000
LA R7,OUTLEN1 LENGTH OF OUTPUT @VA04250 00359000
WRTERM (R6),(R7) DISPLAY ON TERMINAL @VA04250 00360000
BR R8 RETURN @VA04250 00361000
EJECT 00362000
*************************************************************** 00363000
* THIS ROUTINE CREATES A STATALL LOCAL FILE FOR THE USER 00364000
*************************************************************** 00365000
STALLOC MVI LALLSW,ALL SET SWITCH FOR STATUS ALL @VA04250 00366000
FSERASE 'STATALL LOCAL A1' @VA04250 00367000
LA R2,HEAD1 POINT TO HEADER RECORD FOR OUTPUT@VA04250 00368000
BAL R8,FSWRITE GO PUT HEADER IN FILE @VA04250 00369000
B DORD GO READ FILE @VA04250 00370000
FSWRITE FSWRITE 'STATALL LOCAL A1',BUFFER=(R2),BSIZE=80 @VA04250 00371000
LTR R15,R15 GOOD WRITE? @VA04250 00372000
BNZ WRTERR NO @VA04250 00373000
BR R8 RETURN TO CALLER @VA04250 00374000
WRTERR CVD R15,WK CONVERT RETURN CODE TO DECIMAL @VA04250 00375000
UNPK WRCODE,WK+SIX(RCSIZE) UNPACK INTO MESSAGE @VA04250 00376000
OI WCODEEND,NUMERIC MAKE IT READABLE @VA04250 00377000
LA R7,MSGWRTER 'DMMSTA200S ERROR 'NNN' WRITING..@VA04250 00378000
LA R6,WRLNTH LENGTH OF ERROR MESSAGE @VA04250 00379000
BAL R8,WRTERM GO DISPLAY MESSAGE ON TERMINAL @VA04250 00380000
B RETCOD8 TAKE ERROR EXIT @VA04250 00381000
EJECT 00382000
*************************************************************** 00383000
* PROMPT FOR PROBLEM NUMBER OR ALL 00384000
*************************************************************** 00385000
SPNUM LA R7,MSGPNUM 'ENTER PROBLEM NUMBER' @VA04250 00386000
LA R6,L'MSGPNUM LENGTH OF PROMPT MESSAGE @VA04250 00387000
BAL R8,WRTERM GO DISPLAY PROMPT ON TERMINAL @VA04250 00388000
BAL R8,RDTERM GO READ USER RESPONSE @VA04250 00389000
SPNUM2 LTR R0,R0 DID USER ENTER ANYTHING? @VA04250 00390000
BZ SPNUM NO, GO REPROMPT @VA04250 00391000
LA R2,L'XXXXX PROBLEM NUMBERS ARE 5 DIGITS @VA04250 00392000
LR R3,R0 GET LENGTH @VA04250 00393000
CR R3,R2 MORE THAN 5 ENTERED? @VA04250 00394000
BNH SPNUM4 NO @VA04250 00395000
LA R4,0(R3,R1) POINT PAST END OF INPUT @VA04250 00396000
BCTR R4,0 POINT TO LAST BYTE @VA04250 00397000
SPNUMLP CLI 0(R4),BLANK BLANK AT END? @VA04250 00398000
BNE SPNXT NO, FOUND END OF VALID DATA @VA04250 00399000
BCTR R4,0 POINT TO PREVIOUS BYTE OF INPUT @VA04250 00400000
BCT R3,SPNUMLP CONTINUE CHECKING @VA04250 00401000
B SPNUM USER ENTERED ALL BLANKS @VA04250 00402000
SPNXT CR R3,R2 5 OR LESS NOW? @VA04250 00403000
BNH SPNUM4 NO, WE'RE OK SO FAR @VA04250 00404000
LA R7,MSGMAX 'MAX NUMBER MAY BE 5 DIGITS' @VA04250 00405000
LA R6,L'MSGMAX LENGTH OF MESSAGE @VA04250 00406000
BAL R8,WRTERM GO TELL USER @VA04250 00407000
B SPNUM GO REPROMPT FOR NUMBER @VA04250 00408000
SPNUM4 SR R4,R4 WE'LL KEEP COUNT HERE @VA04250 00409000
LR R5,R1 GET DATA POINTER @VA04250 00410000
CLI 0(R5),BLANK USER MAY HAVE ENTERED BLANKS @VA04250 00411000
BE SPNUM WHAT'S THIS? @VA04250 00412000
CHKLOOP TM 0(R5),NUMERIC CHECK FOR NUMERIC INPUT @VA04250 00413000
BNO STEND NOT NUMERIC @VA04250 00414000
LA R5,ONE(R5) POINT TO NEXT INPUT BYTE @VA04250 00415000
LA R4,ONE(R4) COUNT THE NUMBER OF INPUT BYTES @VA04250 00416000
BCT R3,CHKLOOP DO THIS FOR LENGTH OF INPUT @VA04250 00417000
STEND CLI 0(R5),BLANK TRAILING BLANK? @VA04250 00418000
BNE SPNUM NO, INVALID INPUT @VA04250 00419000
LTR R4,R4 ANYTHING GOOD HERE? @VA04250 00420000
BZ SPNUM NO, GO PROMPT AGAIN @VA04250 00421000
LA R3,XXXXX POINT TO WHERE PNUM WILL GO @VA04250 00422000
LA R2,L'XXXXX MAX OF 5 BYTE PROBLEM NUMBER @VA04250 00423000
SR R2,R4 GET NUMBER OF BYTES WE'LL SUPPLY @VA04250 00424000
LA R3,0(R3,R2) CALCULATE NEW OUTPUT POINTER @VA04250 00425000
BCTR R4,0 FOR EXECUTE @VA04250 00426000
EX R4,PNMVC MOVE IN USER ENTERED NUMBER @VA04250 00427000
CLC XXXXX,=C'00000' ALL ASKED FOR? @VA04250 00428000
BNE DORD GO FIND THE REQSTD STATUS HEADER @VA04250 00429000
SALL B STALLOC GO PROCESS STAT ALL @VA04250 00430000
DORD LA R9,ONE START WITH RECORD 1 @VA04250 00431000
SR R10,R10 @VA04250 00432000
*************************************************************** 00433000
* GET NEXT SYMPTOM SUMMARY CONTROL RECORD 00434000
*************************************************************** 00435000
FSREAD FSREAD 'SYMPTOM SUMMARY A1',RECNO=(R9),BUFFER=INPUT,BSIZE=80 00436000
LTR R15,R15 ERROR ON READ? @VA04250 00437000
BNZ RDERR YES @VA04250 00438000
CLI LALLSW,ALL ALL ASKED FOR? @VA04250 00439000
BNE DOCMPR NO WE MUST EXAMINE IT CLOSELY @VA04250 00440000
LA R2,INPUT POINT TO STATUS HEADER WE GOT @VA04250 00441000
IC R10,SYMCCNT GET THE NO. OF KEYWORK CARDS @VA08802 00442200
MVI SYMCCNT,X'40' BLANK THE COUNT FIELD FOR PRINT @VA08802 00442400
BAL R8,FSWRITE ADD TO 'STATALL LOCAL A1' @VA08802 00442600
LA R9,ONE(R9,R10) RECORD NUMBER OF NEXT CTL RCD @VA04250 00444000
B FSREAD GO READ IN THE CONTROL RECORD @VA04250 00445000
DOCMPR CLC XXXXX,INPUT HAVE WE FOUND THE PROBLEM NUMBER?@VA04250 00446000
BE SFOUND YES @VA04250 00447000
IC R10,SYMCCNT GET NUMBER OF KEYWORD CARDS. @VA04250 00448000
LA R9,ONE(R9,R10) GET NEXT STATUS RCD NUMBER @VA04250 00449000
B FSREAD CONTINUE @VA04250 00450000
PNMVC MVC 0(0,R3),0(R1) EXECUTED MOVE INSTRUCTION @VA04250 00451000
SFOUND LA R7,HEAD1 PUT OUT HEADER ON TERMINAL. @VA04250 00452000
LA R6,CARDLEN LENGTH OF HEADER @VA04250 00453000
BAL R8,WRTERM GO DISPLAY HEADER ON TERMINAL @VA04250 00454000
LA R7,INPUT POINT TO PROBLEM CONTROL RECORD @VA04250 00455000
LA R6,CARDLEN LENGTH OF RECORD @VA04250 00456000
BAL R8,WRTERM PUT OUT STATUS OF PROBLEM. @VA04250 00457000
B NORMEXIT ALL DONE @VA04250 00458000
EJECT 00459000
*************************************************************** 00460000
* CLEANUP AND ERROR ROUTINES. 00461000
*************************************************************** 00462000
RDERR ST R15,WK SAVE RETURN CODE @VA04250 00463000
CLI LALLSW,ALL STAT ALL? @VA04250 00464000
BNE RDERR2 NO @VA04250 00465000
FSCLOSE 'STATALL LOCAL A1' @VA04250 00466000
RDERR2 FSCLOSE 'SYMPTOM SUMMARY A1' @VA04250 00467000
CLC EOF,WK EOF FROM FSREAD? @VA04250 00468000
BNE RDERR4 NO @VA04250 00469000
CLI LALLSW,ALL STAT ALL? @VA04250 00470000
BE RDERR3 YES,THIS IS NORMAL @VA04250 00471000
LA R7,MSGNTFND 'PROBLEM NOT FOUND IN SUMMARY' @VA04250 00472000
LA R6,L'MSGNTFND LENGTH OF ERROR MESSAGE @VA04250 00473000
BAL R8,WRTERM PUT ERROR MESSAGE ON TERMINAL @VA04250 00474000
B RETCOD4 TAKE RETURN CODE 4 EXIT @VA04250 00475000
RDERR3 LA R7,MSGGSTAT 'STATALL LOCAL A1 FILE CREATED' @VA04250 00476000
LA R6,L'MSGGSTAT LENGTH OF INFORMATION MESSAGE @VA04250 00477000
BAL R8,WRTERM GO DISPLAY MESSAGE ON TERMINAL @VA04250 00478000
B NORMEXIT TAKE NORMAL EXIT @VA04250 00479000
RDERR4 L R2,WK GET RETURN CODE @VA04250 00480000
CVD R2,WK CONVERT IT TO DECIMAL @VA04250 00481000
UNPK RDCODE,WK+SIX(RCSIZE) UNPACK IT INTO MESSAGE @VA04250 00482000
OI RCODEEND,NUMERIC MAKE IT PRINTABLE @VA04250 00483000
LA R7,MSGRDERR 'DMMSTA100S ERROR 'NNN' READING..@VA04250 00484000
LA R6,RDLNTH LENGTH OF MESSAGE @VA04250 00485000
BAL R8,WRTERM DISPLAY MESSAGE ON TERMINAL @VA04250 00486000
B RETCOD8 TAKE ERROR EXIT @VA04250 00487000
*************************************************************** 00488000
* TERMINAL WRITE 00489000
*************************************************************** 00490000
WRTERM WRTERM (R7),(R6) WRITE ON TERMINAL @VA04250 00491000
BR R8 RETURN TO CALLER @VA04250 00492000
*************************************************************** 00493000
* TERMINAL READ ROUTINE 00494000
*************************************************************** 00495000
RDTERM RDTERM INPUT READ USER RESPONSE @VA04250 00496000
LA R1,INPUT POINT TO DATA @VA04250 00497000
LTR R0,R0 ANYTHING ENTERED? @VA04250 00498000
BZ RDEXIT NO @VA04250 00499000
LA R2,SIXTEEN CHECK SOME OF THE INPUT @VA04250 00500000
RDLOOP CLI 0(R1),BLANK LEADING BLANK? @VA04250 00501000
BNE RDEXIT NO @VA04250 00502000
LA R1,ONE(R1) POINT TO NEXT BYTE @VA04250 00503000
BCTR R0,0 DECREMENT COUNT @VA04250 00504000
LTR R0,R0 ANY MORE INPUT? @VA04250 00505000
BZ RDEXIT NO @VA04250 00506000
BCT R2,RDLOOP CHECK SOME MORE @VA04250 00507000
RDEXIT CLC HX,0(R1) USER TRYING TO QUIT? @VA04250 00508000
BE RETCOD4 YES @VA04250 00509000
BR R8 RETURN TO CALLER @VA04250 00510000
EJECT 00511000
*************************************************************** 00512000
* EXIT ROUTINES 00513000
*************************************************************** 00514000
NORMEXIT L R13,8(R13) RESTORE CALLER'S SAVEAREA POINTER@VA04250 00515000
LM R14,R12,12(R13) RESTORE CALLER'S REGISTERS @VA04250 00516000
SR R15,R15 RETURN CODE ZERO @VA04250 00517000
BR R14 RETURN TO CALLER @VA04250 00518000
RETCOD8 L R13,8(R13) RESTORE CALLER'S SAVEAREA POINTER@VA04250 00519000
LM R14,R12,12(R13) RESTORE CALLER'S REGISTERS @VA04250 00520000
LA R15,8 RETURN CODE 8 (ERROR) @VA04250 00521000
BR R14 RETURN TO CALLER @VA04250 00522000
RETCOD4 L R13,8(R13) RESTORE CALLER'S SAVEAREA POINTER@VA04250 00523000
LM R14,R12,12(R13) RESTORE CALLER'S REGISTERS @VA04250 00524000
LA R15,4 RETURN CODE 4 (PROBLEM NOT FOUND)@VA04250 00525000
BR R14 RETURN TO CALLER @VA04250 00526000
EJECT 00527000
*************************************************************** 00528000
* SAVEAREAS, CONSTANTS, AND EQUATES 00529000
*************************************************************** 00530000
SAVEAREA DS 18F OUR SAVEAREA @VA04250 00531000
HX DC C'HX' HALT EXECUTION TEST @VA04250 00532000
BLANKS DC C' ' BLANKS AS ADVERTIZED @VA04250 00533000
NUMERIC EQU X'F0' USED TO TEST DATA FOR NUMERICS @VA04250 00534000
FIRST2 EQU 2 PARTIAL COMPARE LENGTH OF 2 @VA04250 00535000
FIRST3 EQU 3 PARTIAL COMPARE LENGTH OF 3 @VA04250 00536000
FIRST4 EQU 4 PARTIAL COMPARE LENGTH OF 4 @VA04250 00537000
LAST4 EQU 4 PARTIAL COMPARE LENGTH OF 4 @VA04250 00538000
EOF DC F'12' EOF RETURN CODE @VA04250 00539000
CONSADDR EQU 9 CONSOLE ADDRESS FOR SCREEN ERASE @VA04250 00540000
CARDLEN EQU 80 LENGTH OF DATA UNIT @VA04250 00541000
OUTLEN1 EQU 79 LENGTH OF OUTPUT @VA04250 00542000
ONE EQU 1 FOR INCREMENT AND DECREMENT OF 1 @VA04250 00543000
RCSIZE EQU 2 SIZE OF USABLE RETURN CODE @VA04250 00544000
TYPEDISP EQU 4 DISPLACEMENT TO FIND OPEN TYPE @VA04250 00545000
SIX EQU 6 FOR MVC LENGTH OR DISP ETC. @VA04250 00546000
EIGHT EQU 8 LENGTH OF EACH PASSED PARM @VA04250 00547000
SIXTEEN EQU 16 LENGTH OF INPUT TO BE CHECKED @VA04250 00548000
SPACE 1 00549000
*************************************************************** 00550000
PRBXXXXX DS 0CL8 PROBLEM NUMBER IN FORM 'PRBXXXXX'@VA04250 00551000
PRB DC C'PRB' PRB (PROBLEM) @VA04250 00552000
XXXXX DC C'00000' DEFAULT PROBLEM NUMBER OF 00000 @VA04250 00553000
*************************************************************** 00554000
SPACE 1 00555000
WK DS D DOUBLE WORD WORK AREA @VA04250 00556000
INPUT DS CL132 INPUT AREA @VA04250 00557000
SPACE 1 00558000
*************************************************************** 00559000
CKSW DC X'00' STATALL OUTPUT INDICATOR @VA04250 00560000
ON EQU X'01' SWITCH IS ON (DATA HAS GONE OUT) @VA04250 00561000
*************************************************************** 00562000
SPACE 1 00563000
*************************************************************** 00564000
MSGPNUM DC C'ENTER PROBLEM NUMBER. (OR 00000 FOR ALL)' @VA04250 00565000
MSGMAX DC C'MAXIMUM PROBLEM NUMBER IS 5 DIGITS. --REENTER--' 00566000
MSGGSTAT DC C'STATALL LOCAL A1 FILE CREATED' @VA04250 00567000
MSGNTFND DC C'PROBLEM NOT FOUND IN SYMPTOM SUMMARY FILE' @VA04250 00568000
MSGRDERR DC C'DMMSTA100S ERROR ''' @VA04250 00569000
RDCODE DS CL3 RETURN CODE FROM FSREAD @VA04250 00570000
RCODEEND EQU RDCODE+2 LAST BYTE OF UNPACKED RETURN CODE@VA04250 00571000
DC C''' READING FILE ''SYMPTOM SUMMARY A1''' @VA04250 00572000
RDLNTH EQU *-MSGRDERR LENGTH OF ERROR MESSAGE @VA04250 00573000
MSGWRTER DC C'DMMSTA200S ERROR ''' @VA04250 00574000
WRCODE DS CL3 FSWRITE RETURN CODE @VA04250 00575000
WCODEEND EQU WRCODE+2 LAST BYTE OF UNPACKED RETURN CODE@VA04250 00576000
DC C''' WRITING FILE ''STATALL LOCAL A1''' @VA04250 00577000
WRLNTH EQU *-MSGWRTER LENGTH OF ERROR MESSAGE @VA04250 00578000
MSG601 DC C'DMMSTA601S OPERAND ''' @VA04250 00579000
M601PARM DS CL8 BAD PARM @VA04250 00580000
DC C''' NOT RECOGNIZED' @VA04250 00581000
MSG601L EQU *-MSG601 LENGTH OF MESSAGE @VA04250 00582000
*************************************************************** 00583000
SPACE 1 00584000
*************************************************************** 00585000
LALLSW DC X'00' ALL STATUS IS NOT SPECIFIED @VA04250 00586000
ALL EQU X'01' INDICATES STAT ALL SPECIFIED @VA04250 00587000
*************************************************************** 00588000
SPACE 1 00589000
HEAD1 DC C'PROB CREATED LAST LASTFNCT STATUS PTF/DUP/APAR X00590000
PLC SEV FAILURE ENVIR' 00591000
PATCH DC 50F'0' PATCH AREA @VA04250 00592000
SPACE 1 00593000
*************************************************************** 00594000
* DSECT OF PASSED PARMS 00595000
*************************************************************** 00596000
PARMSECT DSECT @VA04250 00597000
PARMPROG DS CL8 NAME OF PROGRAM INVOKED @VA04250 00598000
PARM1 DS CL8 'ALL' OR PROBLEM NUMBER @VA04250 00599000
PARM2 DS CL8 FIRST SEARCH ARGUMENT @VA04250 00600000
PARM3 DS CL8 SECOND SEARCH ARGUMENT @VA04250 00601000
FENCE EQU X'FF' INDICATES END OF PARMS @VA04250 00602000
BLANK EQU X'40' BLANK @VA04250 00603000
*************************************************************** 00604000
SPACE 1 00605000
COPY SYMSECT @VA04250 00606000
COPY INTSECT @VA04250 00607000
REGEQU @VA04250 00608000
END 00609000