MNI TITLE 'DMKMNI (CP) VM/370 - RELEASE 6' 00001000
ISEQ 73,80 VALIDATE SEQUENCING OF INPUT @V2B2638 00002000
COPY OPTIONS @V2B2638 00003000
COPY LOCAL @V2B2638 00004000
SPACE 4 00005000
DMKMNI CSECT @V2B2638 00006000
MODID DC CL8'DMKMNI' IDENTIFICATION FOR DUMPS @V2B2638 00007000
USING SAVEAREA,R13 @V2B2638 00008000
USING PSA,R0 @V2B2638 00009000
USING MONCOM,R9 @V4075A4 00010000
EJECT 00011000
*. 00012000
* 00013000
* MODULE NAME - 00014000
* 00015000
* DMKMNI 00016000
* 00017000
* FUNCTION - 00018000
* 00019000
* PAGEABLE MONITOR FUNCTIONS 00020000
* 00021000
* ATTRIBUTES - 00022000
* 00023000
* REENTRANT, PAGABLE, 00024000
* 00025000
* CALLED VIA: 00026000
* SVC FROM DMKMCC 00027000
* SVC FROM DMKMON 00028000
* SVC FROM DMKCPS 00029000
* 00030000
* ENTRY POINTS - 00031000
* 00032000
* DMKMNISH - TO INITIATE MONITOR SHUTDOWN 00033000
* DMKMNITR - TO WRITE MONITOR TRAILER RECORD 00034000
* DMKMNIFI - TO COMPLETE MONITOR SHUTDOWN 00035000
* 00036000
* ENTRY CONDITIONS - 00037000
* 00038000
* REFER TO THE PROLOG ASSOCIATED WITH EACH ENTRY POINT 00039000
* 00040000
* EXIT CONDITIONS - 00041000
* 00042000
* REFER TO THE PROLOG ASSOCIATED WITH EACH ENTRY POINT 00043000
* 00044000
* EXTERNAL REFERENCES / CALLS TO OTHER ROUTINES - 00045000
* 00046000
* THE FOLLOWING ARE FUNCTIONAL EXTERNAL REFERENCES 00047000
* OR ROUTINES WHICH ARE CALLED BY THE MONITOR. 00048000
* REFER TO THE DATA COLLECTION TABLE FOR ALL DATA 00049000
* EXTERNAL REFERENCES PERTAINING TO COUNTERS, ETC. 00050000
* 00051000
EXTRN DMKIOSQR REQUEST CP I/O TO A DEVICE @V2B2638 00052000
EXTRN DMKMONPR ALLOC SPACE IN BUFF FOR RECORD @V4075A4 00053000
EXTRN DMKMON00 COLLECT CODE 0 CLASS 0 INFO @V4075A4 00054000
EXTRN DMKMON40 COLLECT CODE 4 CLASS 0 INFO @V4075A4 00055000
EXTRN DMKSCHRT UNCHAIN TRB @V4075A4 00056000
EXTRN DMKDSPCH FIND SOME OTHER WORK TO BE DONE @V2B2638 00057000
EXTRN DMKFREE OBTAIN A BLOCK OF FREE STORAGE @V2B2638 00058000
EXTRN DMKFRET RETURN A BLOCK OF FREE STORAGE @V2B2638 00059000
EXTRN DMKSTKCP STACK A CPEXBLOK @V2B2638 00060000
EXTRN DMKPRGC8 ENABLED CLASSES OF MONITOR EVENTS@V2B2638 00061000
EXTRN DMKPRGMI ADDRESS OF MONITOR INT HANDLER @V2B2638 00062000
EXTRN DMKPRGMC ADDRESS OF COMMUNICATIONS AREA @V2B2638 00063000
EXTRN DMKPRGTI TIMER INTERVAL @V4075A4 00064000
EXTRN DMKERMSG SEND AN ERROR MESSAGE @V2B2638 00065000
EXTRN DMKPTRUL UNLOCK A PAGE @V2B2638 00066000
EXTRN DMKPTRFT OBTAIN A PAGE OF FREE STORAGE @V2B2638 00067000
EXTRN DMKCVTDT OBTAIN DATE AND TIME IN EBCDIC @V2B2638 00068000
EXTRN DMKCPEID RELEASE/VERSION/LEVEL INFO @V4075A4 00069000
EXTRN DMKDSPNP COUNT OF SYSTEM PAGEABLE PAGES @VA07357 00070000
EXTRN DMKPGTVR,DMKMIACC,DMKUDRFU,DMKSCNFD,DMKSYSUR @V50A2B5 00071000
EXTRN DMKSYSTS,DMKSYSTE,DMKSYSCL,DMKSYSMX @V50A2B5 00072000
EXTRN DMKCVTBD,DMKSYSAT @V50A2B5 00073000
EXTRN DMKSLC NUC START AFTER V=R AREA @V60BEBC 00073100
EXTRN DMKFRELO LOW FREE STORAGE BASE @V60BEBC 00073200
EXTRN DMKFREHI HIGH FREE STORAGE BASE @V60BEBC 00073300
EXTRN DMKENTTI UTILIZATION (I/O) RTN @V60BEBC 00073400
EXTRN DMKCPEND RESIDENT NUCLEUS END @V60BEBC 00073500
EXTRN DMKSYSRM AVAILABLE MEMORY @V60BEBC 00073600
EXTRN DMKSYSRV SYSGEN MEMORY @V60BEBC 00073700
EXTRN DMKENTUT UTILIZATION INTERVAL @V60BEBC 00073800
* 00074000
* REGISTER USAGE IN THIS MODULE - 00075000
* 00076000
* R0 - WORK REG 00077000
* R1 - WORK REG 00078000
* R2 - WORK REG 00079000
* R3 - WORK REG 00080000
* R4 - WORK REG 00081000
* R6 - RCHBLOK / RETURN ADDRESS FOR TIMER COLLECTION ROUTINES 00082000
* R7 - RCUBLOK / WORKREG 00083000
* R8 - RDEVBLOK / WORKREG 00084000
* R9 - MONCOM ADDRESS 00085000
* R10 - IOB ADDRESS WITHIN I/O ROUTINES AND I/O DATA COLLECTION 00086000
* R11 - VMBLOK ADDRESS 00087000
* R12 - BASE ADDRESS 00088000
* R13 - FOR MI ENTRY, R13 OF ISSUER 00089000
* R14 - BALR LINKAGE 00090000
* R15 - BALR LINKAGE 00091000
* 00092000
*. 00093000
EJECT 00094000
*. 00095000
* 00096000
* 00097000
* ENTRY POINT - 00098000
* 00099000
* DMKMNITH - COLLECT TAPE HEADER INFORMATION 00100000
* 00101000
* ENTRY CONDITIONS - 00102000
* 00103000
* GPR9 - ADDRESS OF MONCOM 00104000
* GPR12 - ADDRESS OF ENTRY POINT 00105000
* GPR13 - ADDRESS OF STANDARD SAVE AREA 00106000
* 00107000
* EXIT CONDITIONS - 00108000
* 00109000
* NONE 00110000
* 00111000
* CALLS TO OTHER ROUTINES - 00112000
* 00113000
* DMKCVTDT - TO GET THE CURRENT DATE AND TIME 00114000
* 00115000
* OPERATION - 00116000
* 00117000
* MONITOR TAPE HEADER PROCESSING 00118000
* 00119000
* DMKMNITH: 00120000
* 00121000
* INITIALIZE THE IOBLOK WHICH IS HUNG FROM THE 00122000
* MONCOM. 00123000
* 00124000
* CALL DMKIOSQR TO ISSUE THE REWIND / SET-MODECCW 00125000
* SEQUENCE. 00126000
* 00127000
* EXIT BACK TO DMKMCC TO ISSUE THE COMMAND COMPLETE 00128000
* MESSAGE, THUS FREEING THE CONSOLE WHILE A POSSIBLE 00129000
* REWIND OPERATION IS IN PROGRESS. 00130000
* 00131000
* ON I/O COMPLETION, STOP THE MONITOR IF THERE WAS AN 00132000
* I/O ERROR OR A MONITOR STOP COMMAND HAS BEEN 00133000
* ISSUED. OTHERWISE, REINITIALIZE THE IOB FOR NORMAL 00134000
* PROCESSING. 00135000
* 00136000
* SET CONTROL REGISTER 8 TO THE VALUE STORED IN 00137000
* DMKPRGC8, THUS ENABLING THE DESIRED CLASSES OF 00138000
* MONITOR CALL INTERRUPTS. 00139000
* 00140000
* INDICATE A CLASS 0 CODE 97 MONITOR CALL IN PSA. 00141000
* 00142000
* OBTAIN BUFFER SPACE AND INITIALIZE THE BASIC HEADER 00143000
* RECORD. 00144000
* 00145000
* IF THE DASTAP CLASS IS ENABLED THEN COLLECT THE 00146000
* DASTAP HEADER AS DESCRIBED BELOW; OTHERWISE GO TO 00147000
* PERFORM. 00148000
* 00149000
* SCAN ALL DEVICES DEFINED IN DMKRIO AND COUNT THE 00150000
* NUMBER OF DEVICES THAT ARE EITHER TAPE OR DASD. 00151000
* 00152000
* OBTAIN ENOUGH STORAGE TO CONTAIN A POINTER TO EACH 00153000
* DASD AND TAPE DEVICE BLOCK. OBTAIN MONITOR BUFFER 00154000
* SPACE FOR THE DASTAP RECORD. 00155000
* 00156000
* MAKE ANOTHER SCAN OF THE DEVICES DEFINED IN DMKRIO. 00157000
* THIS TIME INITIALIZE THE DEVICE LIST AND CREATE THE 00158000
* DASTAP HEADER RECORD. 00159000
* 00160000
* PERFORM: 00161000
* 00162000
* IF THE PERFORM CLASS IS NOT ENABLED THEN GO TO 00163000
* USER. OTHERWISE INDICATE A CLASS 0 CODE 0 MONITOR 00164000
* CALL IN PSA AND COLLECT THE FIRST PERFORM DATA. 00165000
* 00166000
* USER: 00167000
* 00168000
* IF THE USER CLASS IS ENABLED THEN INDICATE A CLASS 00169000
* 4 CODE 0 MONITOR CALL IN PSA AND COLLECT THE FIRST 00170000
* USER RECORD. 00171000
* 00172000
* EXIT. 00173000
* 00174000
*. 00175000
DMKMNITH RELOC @V2B2638 00176000
USING VMBLOK,R11 @V2B2638 00177000
USING MONCOM,R9 @V2B2638 00178000
L R10,MONAIOB GET THE IOB ADDRESS @V2B2638 00179000
USING IOBLOK,R10 ADDRESS IT @V2B2638 00180000
L R8,MONARDB GET THE RDEVBLOK ADDRESS @V2B2638 00181000
LA R1,MODRETN ADDRESS OF THE RETURN POINT @V2B2638 00182000
ST R1,IOBIRA SAVE THAT IN THE IRA @V2B2638 00183000
CALL DMKIOSQR REQUEST THE REW + SET MODE @V2B2638 00184000
LR R2,R12 ADDR OF THIS MODULE FOR DMKPTRLK 00185000
CALL DMKPTRLK LOCK DMKMNI FOR IOB RETURN 00186000
EXIT => MCC FOR 'COMMAND COMPLETE' 00187000
SPACE 2 00188000
* 00189000
* ENTRY POINT - DMKMNIDK 00190000
* 00191000
ENTRY DMKMNIDK @V50A2B5 00192000
DROP R12 @V50A2B5 00193000
USING *,R15 @V50A2B5 00194000
DMKMNIDK DS 0H MONITOR OUTPUT TO SPOOL FILES @V50A2B5 00195000
LR R12,R15 COMPUTE ADDRESS @V50A2B5 00196000
SL R12,=A(DMKMNIDK-DMKMNI) OF MNI @V50A2B5 00197000
DROP R15 @V50A2B5 00198000
USING DMKMNI,R12 @V50A2B5 00199000
B NOTTAPE CONTINUE ON @V50A2B5 00200000
SPACE 3 @V50A2B5 00201000
USING *,R12 TEMPORARY ADDRESSABILITY @V2B2638 00202000
MODRETN SL R12,=A(MODRETN-DMKMNI) REGAIN ADDRESSABILITY @V2B2638 00203000
USING DMKMNI,R12 NORMAL ADDRESSABILITY @V2B2638 00204000
L R9,=A(DMKPRGMC) GET ADDR OF MONCOM @V2B2638 00205000
L R9,0(R9) ... @V2B2638 00206000
L R1,MONAIOB ADDRESS OF THE REAL IOB @V2B2638 00207000
CR R1,R10 IS THIS THE REAL ONE? @V2B2638 00208000
LA R5,GOTODSP IN CASE IT ISN'T @V2B2638 00209000
BNE FRETIOB NOPE, THROW AWAY & WAIT FOR FINAL@V2B2638 00210000
BAL R5,FRETIOER IN ANY CASE, THROW OUT ANY IOER @V2B2638 00211000
TM IOBSTAT,IOBFATAL DID THE REW/SET MODE WORK? @V2B2638 00212000
BO ERRONERR NOPE, SHUT THE MONITOR DOWN NOW. @V2B2638 00213000
TM MONFLAG1,CFSTOP DID SOMEBODY SAY STOP WHILE @V2B2638 00214000
* WE WERE DOING REW/SET MODE? 00215000
BO UNLOKMON YUP, THEN STOP THIS INSTANT. @V2B2638 00216000
SR R1,R1 CLEAR A REG @V4075A4 00217000
ST R1,MONIOBF INDICATE TAPE NO LONGER BUSY @V4075A4 00218000
MVI IOBSIZE*8+16(R10),X'1F' RESET REW TO WTM @V2B2638 00219000
MVI IOBSIZE*8+24(R10),X'0F' AND SET MODE TO RUN @V2B2638 00220000
NOTTAPE DS 0H @V50A2B5 00221000
LA R0,MNCOTH SET UP TAPE HEADER CLASS/CODE @VM01017 00222000
ST R0,MONCODE ... @V2B2638 00223000
LA R0,MNCLPERF @VM01017 00224000
STH R0,MONCLASS @VM01017 00225000
LA R0,MN097LEN LENGTH OF TAPE HEADER RECORD @V2B2638 00226000
CALL DMKMONPR GET SPACE FOR TAPE HEADER RECORD @V4075A4 00227000
LTR R1,R1 TEST BUFFER SPACE @VA10215 00227300
BZ NOMORE NO SPACE-LEAVE @VA10215 00227600
TM MONFLAG3,SPOOLED ARE WE SPOOLING @V50A2B5 00228000
BO NOSETX DO NOT SET IOBIRA @V50A2B5 00229000
ST R0,IOBIRA NO SPOOLING, SET IT @V50A2B5 00230000
NOSETX EQU * @V50A2B5 00231000
SWITCH @VA12214 00231100
USING MN097,R3 ADDRESS THE RECORD @V2B2638 00232000
LR R3,R1 MOVE DATA POINTER TO R3 @V2B2638 00233000
MVC MN097CPU,CPUID MOVE CPUID DATA INTO TAPE HEADER @V2B2638 00234000
L R2,=A(DMKCPEID) RELEASE/VERSION/LEVEL INFO. @V2B2638 00235000
MVC MN097LEV,0(R2) MOVE INTO DATA RECORD @V2B2638 00236000
LA R1,MN097DAT FIELD FOR DATE @V2B2638 00237000
LA R2,MN097TIM AND ONE FOR TIME @V2B2638 00238000
CALL DMKCVTDT SET DATE & TIME INTO TAPE HEADER @V2B2638 00239000
L R2,=A(DMKPRGC8) ADDR OF ALMOST CURRENT MASK @V2B2638 00240000
MVC MN097CR8,0(R2) MOVE MASK INTO RECORD @V2B2638 00241000
MVC MN097UID,MONUSER USERID STARTING THE TAPE @V2B2638 00242000
L R2,=A(DMKCPEND) GET NUCLEUS END @V60BEBC 00242020
ICM R1,B'1111',=A(DMKSLC) SUBTRACT OFF V=R @V60BEBC 00242040
BZ NOVR AREA (IF ANY), EXCEPT FOR @V60BEBC 00242060
USING PSA,R0 ABSOLUTE PAGE 0 @V60BEBC 00242080
S R1,F4095 .... @V60BEBC 00242100
SR R2,R1 .... @V60BEBC 00242120
NOVR ST R1,MN097VR SAVE V=R BYTES @V60BEBC 00242140
ST R2,MN097NUC SAVE NUCLEUS BYTES @V60BEBC 00242160
L R1,PREFIXA TRACE TABLE END @V60BEBC 00242180
L R2,16(R1) MINUS TRACE TABLE START @V60BEBC 00242200
S R2,12(R1) EQUALS TRACE TABLE SIZE @V60BEBC 00242220
ST R2,MN097TTS SAVE TRACE TABLE SIZE @V60BEBC 00242240
L R1,=A(DMKFREHI) DMKFREHI... @V60BEBC 00242260
L R1,0(R1) MINUS @V60BEBC 00242280
L R4,=A(DMKFRELO) DMKFRELO @V60BEBC 00242300
L R4,0(R4) MINUS @V60BEBC 00242320
SR R1,R4 TRACE TABLE SIZE @V60BEBC 00242340
SR R1,R2 EQUALS D.P.A. SIZE @V60BEBC 00242360
ST R1,MN097DPA SAVE DYNAMIC PAGING AREA SIZE @V60BEBC 00242380
L R2,=A(DMKCPEND) GET SIZE OF @V60BEBC 00242400
SR R4,R2 LOW FREE STORAGE @V60BEBC 00242420
L R1,=A(DMKSYSRV) GET SYSGEN SPECIFIED @V60BEBC 00242440
L R1,0(R1) MEMORY SIZE @V60BEBC 00242460
L R2,=A(DMKSYSRM) GET REAL MEMORY SIZE @V60BEBC 00242480
L R2,0(R2) ... @V60BEBC 00242500
CR R2,R1 REAL CORE GGREATER GEN CORE? @V60BEBC 00242520
BL CALCFREE NO, USE REAL CORE SIZE @V60BEBC 00242540
LR R2,R1 YES, USE GEN SIZE @V60BEBC 00242560
CALCFREE L R1,=A(DMKFREHI) DIFFERENCE OF USABLE CORE @V60BEBC 00242580
L R1,0(R1) AND DMKFREHI @V60BEBC 00242600
SR R2,R1 PLUS LOW FREE SIZE @V60BEBC 00242620
AR R2,R4 EQUALS FREE STORE SIZE @V60BEBC 00242640
TM APSTAT1,APUOPER ALSO DECREMENT FROM FREE @V60BEBC 00242660
BNO NOPREFIX 2 PREFIXED PAGEFRAMES @V60BEBC 00242680
S R2,=F'8192' IF APU IS RUNNING @V60BEBC 00242700
NOPREFIX ST R2,MN097FSS SAVE FREE STORAGE SIZE @V60BEBC 00242720
TM APSTAT1,PROCIO SAVE PROCESSOR LOGICAL ADDRS @V60BEBC 00242740
BNO NOTMAIN DEPENDENT UPON CURRENT EXECUTIO@V60BEBC 00242760
MVC MN097CPL,LPUADDR MAIN PROCESSOR ADDR @V60BEBC 00242780
MVC MN097APL,LPUADDRX AP ADDR @V60BEBC 00242800
B SKIPOUT FINISHED @V60BEBC 00242820
NOTMAIN MVC MN097CPL,LPUADDRX MAIN PROCESSOR ADDR @V60BEBC 00242840
MVC MN097APL,LPUADDR AP ADDRESS @V60BEBC 00242860
SKIPOUT EQU * @V60BEBC 00242880
L R2,=A(DMKPRGC8) V60BEBC 00242900
DROP R3 NO MORE USE OF HEADER RECORD @V2B2638 00243000
OI MONFLAG1,MONTIINT TIME COLLECT IN CASE SUSPEND @VM01095 00244000
TM 2(R2),DASDCL WAS DASTAP SPECIFIED? @V2B2638 00245000
BO MONCOD60 YES, GO GENERATE SECOND HEADER @V2B2638 00246000
TSTPERF SLR R2,R2 CLEAR THE MONSUSCT FIELD USED... @V2B2638 00247000
ST R2,MONSUSCT ... BY CLASS 6 HEADER. @V2B2638 00248000
TM MONFLAG2,SUSPEND HAVE WE SUSPENDED? @VM01095 00249000
BO NOMORE YES, BEATIT, QUICK. @VM01095 00250000
L R2,=A(DMKPRGC8) READDRESS MASK FIELD @V2B2638 00251000
TM 2(R2),PERFCL IS PERFORM CLASS ACTIVE @V2B2638 00252000
BZ TSTUSER NO, BUT MAYBE USER CLASS IS @V2B2638 00253000
LA R0,MNCLPERF YES, SIMULATE PERFORM CLASS @VM01017 00254000
STH R0,MONCLASS @VM01017 00255000
LA R0,MNCOSYS @VM01017 00256000
ST R0,MONCODE @VM01017 00257000
CALL DMKMON00 AND GO COLLECT THE FIRST SHOT @V4075A4 00258000
TM MONFLAG2,SUSPEND HAVE WE SUSPENDED? @VM01095 00259000
BO NOMORE YES, GET OUT NOW. @VM01095 00260000
TSTUSER L R2,=A(DMKPRGC8) READDRESS MASK FIELD @V2B2638 00261000
TM 2(R2),USERCL IS USER CLASS ACTIVE @V2B2638 00262000
BZ SETCR8 NO, DONE @V2B2638 00263000
LA R0,MNCLUSER YES, SIMULATE USER CLASS @VM01017 00264000
STH R0,MONCLASS @VM01017 00265000
LA R0,MNCOUSER @VM01017 00266000
ST R0,MONCODE @VM01017 00267000
CALL DMKMON40 GO COLLECT FIRST USER RECORDS 00268000
TM MONFLAG2,SUSPEND HAVE WE SUSPENDED? @VM01095 00269000
BO NOMORE YES, DON'T ENABLE NOW. @VM01095 00270000
SETCR8 L R2,=A(DMKPRGC8) READDRESS THE MASK @V2B2638 00271000
L R2,0(R2) PICK UP SAID MASK @V2B2638 00272000
ST R2,CPCREG8 PUT IT IN PSA @V2B2638 00273000
L R8,PREFIXB GET ADDRESS OF OTHER PSA @V4075A4 00274000
ST R2,CPCREG8(R8) PROPAGATE MC MASK TO OTHER PSA @V4075A4 00275000
LCTL C8,C8,CPCREG8 SET THE SYSTEM MASK TO THAT @V2B2638 00276000
NI MONFLAG3,X'FF'-CLSUS TURN OFF CLOSE SUSPEND @V50A2B5 00277000
NOMORE NI MONFLAG1,255-MONTIINT SIMUL TIMER PROCESS DONE @V4075A4 00278000
B GOTO EXIT TO DISPATCHER 00279000
SPACE 00280000
ERRONERR LA R2,220 MSG220, TAPE ERR, MON SHUTDOWN @V4075A4 00281000
O R2,=X'B0C90000' RETURN HERE + ALARM + @V4075A4 00282000
I SLR R1,R1 ZIP R1 = NO SUBSTITUTABLES @V4075A4 00283000
ICM R0,B'1110',MODID+3 ISSUEING MODULE ID @V4075A4 00284000
CALL DMKERMSG GO PUT OUT THE MESSAGE @V4075A4 00285000
B UNLOKMON DONE ALL WE CAN, SHUTDOWN MON @V4075A4 00286000
EJECT 00287000
******* 00288000
* 00289000
* CLASS 6 CODE 0, DASTAP, COLLECT DEVICE STATISTICS HEADER 00290000
* 00291000
* REGISTER USAGE IN THIS ROUTINE: 00292000
* 00293000
* R0 - DEVICE COUNT 00294000
* R1 - CHANNEL INDEX 00295000
* R2 - CONTROL UNIT INDEX 00296000
* R3 - DEVICE INDEX 00297000
* R4 - BXLE INCREMENT CONSTANT 00298000
* R5 - BXLE COMPARAND VALUE 00299000
* R6 - CHANNEL BLOCK ADDRESS / DEVICE TYPE BYTE 00300000
* R7 - CONTROL UNIT BLOCK ADDRESS 00301000
* R8 - DEVICE BLOCK ADDRESS 00302000
* R9 - MONCOM ADDRESS 00303000
* R10 - POINTER WITHIN DEVICE LIST FOR PASS 2 00304000
* R11 - VMBLOCK ADDRESS 00305000
* R12 - BASE REGISTER 00306000
* R13 - NOT USED 00307000
* R14 - DEVICE TYPE CHECK BYTE / BALR TO DMKFREE 00308000
* R15 - POINTER WITHIN MN600 RECORD FOR PASS 2 00309000
* 00310000
******* 00311000
USING RCHBLOK,R6 @V2B2638 00312000
USING RCUBLOK,R7 @V2B2638 00313000
USING RDEVBLOK,R8 @V2B2638 00314000
MONCOD60 TM MONFLAG3,CLSUS ARE WE CLOSE SUSPENDED? @V60BEBC 00315000
BNO INIT60 NO,NORMAL MONITOR STARTUP @V60BEBC 00315150
LH R0,MONDVNUM YES,RESET DEVICE LIST @V60BEBC 00315300
L R1,MONDVLST TO NULL @V60BEBC 00315450
CALL DMKFRET FREE DEVICE LIST @V60BEBC 00315600
INIT60 MVI MONSUSCT,X'01' REMEMBER AS PASS 1 @V60BEBC 00315750
MVI MONSUSCT+1,CLASDASD+CLASTAPE SET FOR DAS + TAPE @V2B2638 00316000
RESCAN SLR R0,R0 DEVICE COUNT @V2B2638 00317000
SECPASS LA R4,2 LOAD INCREMENT FOR BXLE LOOP @V2B2638 00318000
SLR R1,R1 ZERO CHANNEL INDEX @V2B2638 00319000
LA R5,30 GPR5 POINTS TO END OF INDEX TABLE@V2B2638 00320000
EXAMNCH L R6,ARIOCT ADDRESS OF CHANNEL INDICES @V2B2638 00321000
LH R6,0(R1,R6) LOAD INDEX OF NEXT CHANNEL @V2B2638 00322000
LTR R6,R6 IS CHANNEL ALIVE ? @V2B2638 00323000
BM EXAMCHI NO, TRY NEXT CHANNEL @V2B2638 00324000
A R6,ARIOCH ADDRESS OF RCHBLOK IN GPR6 @V2B2638 00325000
USING RCHBLOK,R6 @V2B2638 00326000
SLR R2,R2 ZERO CONTROL UNIT INDEX COUNT @V2B2638 00327000
LA R5,62 END OF CONTROL UNIT INDEX TABLE @V2B2638 00328000
EXAMNCU LH R7,RCHCUTBL(R2) PICK UP INDEX @V2B2638 00329000
LTR R7,R7 IS CONTROL UNIT THERE ? @V2B2638 00330000
BM EXAMCUI NO TRY NEXT CU @V2B2638 00331000
A R7,ARIOCU ADDRESS OF RCUBLOK TO GPR7 @V2B2638 00332000
USING RCUBLOK,R7 @V2B2638 00333000
SLR R3,R3 ZERO INDEX FOR DEV INDEX @V2B2638 00334000
LA R5,30 R5 = END OF DEVICE INDEX TABLE @V2B2638 00335000
EXAMNDEV LH R8,RCUDVTBL(R3) PICK UP INDEX @V2B2638 00336000
LTR R8,R8 IS DEVICE THERE ? @V2B2638 00337000
BM EXAMDVI NO TRY NEXT DEVICE @V2B2638 00338000
SLL R8,3(0) CONVERT TO BYTE INDEX @V2B2638 00339000
A R8,ARIODV ADDRESS OF RDEVBLOK TO GPR8 @V2B2638 00340000
USING RDEVBLOK,R8 @V2B2638 00341000
IC R14,MONSUSCT+1 GET DEVICE TYPE TO LOOK FOR @V2B2638 00342000
EX R14,TESTTYPE IS THIS DEVICE OF THE RIGHT TYPE?@V2B2638 00343000
BZ EXAMDVI NOPE, SKIP TO NEXT DEVICE @V2B2638 00344000
TM RDEVSTAT,RDEVDISA YES, IS THE DEVICE ONLINE? @V2B2638 00345000
BO EXAMDVI NOPE, THEN SKIP IT. @V2B2638 00346000
LR R14,R7 PUT CU ADDRESS IN R14 @VA08777 00346100
TM RCUTYPE,RCUSUB IS THIS SUBORDINATE CU ? @VA08398 00346200
BNO HAVPRIM NO, R5 CONTAINS PRIME CU @VA08398 00346300
L R14,RCUPRIME PUT PRIME CU ADDR IN R14 @VA08777 00346400
HAVPRIM EQU * @VA08398 00346500
C R6,16(R14) PRIMARY CHANNEL INTERFACE ? @VA08777 00346600
BNE EXAMDVI NO, AVOID DUPLICATE ENTRY @VA08102 00346700
CL R7,RDEVCUA PRIMARY CONTROL UNIT INTERFACE ??@VA08102 00346800
BNE EXAMDVI NO, SKIP TO NEXT DEVICE @VA08102 00346900
CLI MONSUSCT,X'01' IS THIS PASS 1 OR 2 @VM01054 00347000
BNE PASS2 PASS 2 @V2B2638 00348000
A R0,F1 PASS1, INCR DEVICE COUNT @V2B2638 00349000
B EXAMDVI AND GO TO NEXT DEVICE @V2B2638 00350000
SPACE 3 00351000
PASS2 ST R8,0(R10) SAVE THIS DEVICE ADDR IN TABLE @V2B2638 00352000
LA R10,MNDEVLEN(,R10) INCREMENT TO NEXT POSITION @V60BEBC 00353000
LTR R15,R15 DO WE HAVE A BUFFER? @VA13063 00353400
BZ GOLOOP NO-DON'T TRY TO LOAD IT @VA13063 00353800
USING MN600DEV,R15 ADDRESS THE BLOCK @V2B2638 00354000
MVC MN600ADD,RDEVADD GET THE RDEVICE ADDR @V2B2638 00355000
OC MN600ADD+1(1),RCUADD+1 ADD CONTROL UNIT ADDR @V2B2638 00356000
OC MN600ADD(1),RCHADD AND THE CHANNEL ADDRESS @V2B2638 00357000
MVC MN600TY,RDEVTYPC GET THE DEV CLAS AND TYPE @V2B2638 00358000
MVC MN600SER,RDEVSER GET THE SERIAL NUMBER @V2B2638 00359000
MVC MN600CNT,RDEVIOCT AND THE CURRENT IO COUNT @V2B2638 00360000
LA R15,MN600DLN(,R15) BUMP TO NEXT ENTRY @V2B2638 00361000
GOLOOP BCT R0,EXAMDVI BEWARE OF MAX NO. OF DEVICES @VA13063 00362000
DROP R15 @V60BEBC 00362030
L R5,=A(DMKENTUT) GET I/O UTILIZATION INTERVAL @V60BEBC 00362060
LH R5,0(R5) .... @V60BEBC 00362090
LTR R5,R5 HAS IT BEEN SPECIFIED? @V60BEBC 00362120
BZ TSTPERF NO, DON'T COLLECT DATA @V60BEBC 00362150
TM MONFLAG3,CLSUS CLOSE SUSPENSION? @V60BEBC 00362180
BO TSTPERF YES, ALREADY HAVE TRB, CHANNEL @V60BEBC 00362210
LA R0,MNCHSIZE OBTAIN STORAGE FOR @V60BEBC 00362240
CALL DMKFREE CHANNEL SAMPLE FIELDS @V60BEBC 00362270
ST R1,MONCHPTR SAVE PTR IN MONCOMM AREA @V60BEBC 00362300
XC 0(MNCHSIZE*8,R1),0(R1) INITIALIZE TO 0 @V60BEBC 00362330
LA R0,TRQBSIZE DOUBLE WORDS FOR TRB @V60BEBC 00362360
CALL DMKFREE GET SPACE FOR TRB @V60BEBC 00362390
USING TRQBLOK,R1 ADDR VIA R1 @V60BEBC 00362420
ST R1,MONUTRB SAVE ADDRESS IN MONCOM @V60BEBC 00362450
L R2,ASYSVM CHARGE HANDLING TO @V60BEBC 00362480
ST R2,TRQBUSER THE SYSTEM @V60BEBC 00362510
STCK TRQBTOD TIME OF DAY FOR REQUEST @V60BEBC 00362540
BC 12,CLOCKOK CLOCK FUNCTIONING?? @V60BEBC 00362570
GOTO DMKCVTAB NO, ABEND CVT001 @V60BEBC 00362600
CLOCKOK SLR R4,R4 CLEAR FOR MULTIPLY @V60BEBC 00362630
M R4,=F'1000000' CHANGE TO MICROSECS. @V60BEBC 00362660
SLDL R4,12 ALIGN WITH TOD FORMAT @V60BEBC 00362690
AL R5,TRQBTOD+4 ADD IN LOW ORDER TOD @V60BEBC 00362720
BC 12,NOVFLW SKIP ADD IF NO OVERFLOW @V60BEBC 00362750
AL R4,F1 ADD 1 SEC TO HIGH ORDER TOD @V60BEBC 00362780
NOVFLW AL R4,TRQBTOD ADD IN HIGH ORDER TOD @V60BEBC 00362810
STM R4,R5,TRQBVAL FIRST INTERRUPT DUE AT THIS TIM@V60BEBC 00362840
L R4,=A(DMKENTTI) GET ADDR TIMER INTERRUPT RTN @V60BEBC 00362870
ST R4,TRQBIRA SAVE IT IN INTERRUPT ROUTINE AD@V60BEBC 00362900
CALL DMKSCHST INSERT TRB IN CHAIN @V60BEBC 00362930
DROP R1 @V60BEBC 00362960
B TSTPERF GOT THE MAX, NOW BEATIT. @V2B2638 00363000
SPACE 00364000
EXAMDVI BXLE R3,R4,EXAMNDEV AND CONT. W/ NEXT DEV ON THIS CU @V2B2638 00366000
LA R5,62 LOAD END OF CU TABLE @V2B2638 00367000
EXAMCUI BXLE R2,R4,EXAMNCU AND CONT. W/ NEXT CU ON THIS CH @V2B2638 00368000
LA R5,30 LOAD END OF CH INDEX TABLE @V2B2638 00369000
EXAMCHI BXLE R1,R4,EXAMNCH AND CONT. W/ NEXT CH ON THIS MACH@V2B2638 00370000
CLI MONSUSCT,X'01' FINISH WITH PASS 1? @V2B2638 00371000
BNE TSTPERF NO, PASS 2 DONE. @V2B2638 00372000
LA R1,MN600MAX GET THE MAX POSSIBLE NO. OF DEV. @V2B2638 00373000
TM MONFLAG3,SPOOLED ARE WE SPOOLING @VA09588 00373100
BZ NOTSPOOL NO, USING MAX 291 DEVICES @VA09588 00373200
LA R1,MN600MXS GET SPOOLED MAX DEVICES 289 @VA09588 00373300
NOTSPOOL EQU * @VA09588 00373400
CR R0,R1 HAVE WE EXCEEDED IT? @V2B2638 00374000
BNH CONTAIN NOPE, WHEW. @V2B2638 00375000
TM MONSUSCT+1,CLASTAPE WERE WE CHECKING FOR TAPE? @V2B2638 00376000
BZ NOTAPE NOPE, BEEN HERE BEFORE @V2B2638 00377000
NI MONSUSCT+1,255-CLASTAPE YES, THEN TRY WITHOUT @V2B2638 00378000
B RESCAN ... @V2B2638 00379000
SPACE 00380000
NOTAPE LR R0,R1 GIVE UP AND TAPE MAX DASD+ONLINE @VM01054 00381000
CONTAIN MVI MONSUSCT,X'02' INDICATE PASS 2 IN PROGRESS @V2B2638 00382000
STH R0,MONDVNUM SAVE THE NUMBER OF DEVICES @V2B2638 00383000
CALL DMKFREE GO GET THE STORAGE @V2B2638 00386000
ST R1,MONDVLST SAVE FOR LATER @V2B2638 00387000
LR R10,R1 SET FOR PASS 2 @V2B2638 00388000
LR R4,R1 ADDR OF DEV LIST IN EVEN REG @V60BEBC 00388150
LR R5,R0 LENGTH TIMES 8 FOR CLEAR @V60BEBC 00388300
SLL R5,3 NUMBER OF BYTES FOR MVCL @V60BEBC 00388450
SLR R1,R1 PAD AND COUNT IS 0 @V60BEBC 00388600
MVCL R4,R0 CLEAR DEVICE LIST @V60BEBC 00388750
LA R0,MNCLDAST SIMULATE DASTAPE CLASS @VM01017 00389000
STH R0,MONCLASS @VM01017 00390000
LA R0,MNCODASH @VM01017 00391000
ST R0,MONCODE @VM01017 00392000
LH R1,MONDVNUM GET THE NUMBER OF DEVICES @V2B2638 00393000
MH R1,=AL2(MN600DLN) TIMES NO OF BYTES FOR EACH @V2B2638 00394000
LA R0,MN600HLN(R1) PLUS CNT FLD LENGTH, -> R0 @V2B2638 00395000
CALL DMKMONPR GO GET THE BUFFER SPACE @V4075A4 00396000
LR R15,R1 GIVE R15 THE CURRENT POINTER @VA13063 00396300
LH R0,MONDVNUM GET THE NUMBER OF DEVICES @VA13063 00396600
LTR R1,R1 DO WE HAVE A BUFFER? @VA13063 00396900
BZ SECPASS NO - GO WITHOUT IT @VA13063 00397200
USING MN600HDR,R1 @VA13063 00397500
STH R0,MN600NUM INTO 6.00 REC AND KEEP FOR SCAN @V2B2638 00399000
LA R15,MN600HLN(R1) ADJUST CURRENT POINTER @V2B2638 00400000
B SECPASS AND GO DO PASS 2 STUFF @V2B2638 00401000
DROP R6,R7 @V2B2638 00402000
SPACE 5 00403000
TESTTYPE TM RDEVTYPC,X'00' CHK FOR DASD + TAPE OR DASD ONLY @V2B2638 00404000
EJECT 00405000
*. 00436000
* 00437000
* ENTRY POINT - 00438000
* 00439000
* DMKMNISH - SHUTDOWN THE MONITOR 00440000
* 00441000
* ENTRY CONDITIONS - 00442000
* 00443000
* THE MONITOR TAPE MUST NOT BE BUSY. 00444000
* 00445000
* GPR1 - ADDRESS OF A CPEXBLOK WHOSE ADDRESS IS IN MONCOM 00446000
* GPR9 - ADDRESS OF COMMUNICATIONS AREA 00447000
* GPR12 - ADDRESS OF ENTRY POINT 00448000
* GPR13 - ADDRESS OF STANDARD SAVE AREA 00449000
* 00450000
* EXIT CONDITIONS - 00451000
* 00452000
* NONE 00453000
* 00454000
* OPERATION - 00455000
* 00456000
* MONITOR SHUTDOWN (STOP) PROCESSING 00457000
* 00458000
* DMKMNISH: 00459000
* 00460000
* OBTAIN A CPEXBLOK AND SAVE ALL REGS IN IT. 00461000
* 00462000
* SET THE CPEXADD VALUE IN THE CPEXBLOK TO THE RETURN 00463000
* ADDRESS IN THIS ROUTINE. THEN EXIT BACK TO DMKMCC 00464000
* FOR THE 'COMMAND COMPLETE' MESSAGE. 00465000
* 00466000
* WHEN CONTROL IS RETURNED VIA THE STACKED CPEXBLOK, 00467000
* IF THE TAPE IS STILL NOT IN ERROR RECOVERY OR BUSY, 00468000
* THEN GO TO THE TRAILER RECORD ROUTINE DMKMNISH. 00469000
* (OTHERWISE, RETURN TO THE DISPATCHER.) 00470000
* 00471000
* FROM THERE THE TRAILER RECORDS WILL BE CREATED AND 00472000
* WRITTEN TO TAPE, THE TAPE WILL BE REWOUND UNLOADED 00473000
* AND RELEASED, AND FINAL CLEANUP OF THE MONITOR WILL 00474000
* BE PERFORMED. 00475000
* 00476000
*. 00477000
DMKMNISH RELOC THE USUAL STARTER @V2B2638 00478000
USING CPEXBLOK,R1 CPEXBLOK PASSED IN R1 @V2B2638 00479000
LA R0,CPEXSIZE SIZE OF CPEXBLOK @VM01004 00480000
CALL DMKFREE GO GET ONE... @VM01004 00481000
LA R2,SHRETN RETURN VIA CPEXBLOK IN A MOMENT @VM01004 00482000
ST R2,CPEXADD SET UP ACCORDINGLY @V2B2638 00483000
L R10,MONAIOB IOB ADDR -> R10 FOR TRAILER RTN. @V2B2638 00484000
USING IOBLOK,R10 ESTABLISH ADDRESSABILITY @V4075A4 00485000
STM R0,R15,CPEXR0 SAVE REGS FOR LATER RETURN @VM01004 00486000
CALL DMKSTKCP GO STACK THIS CPEXBLOK @VM01004 00487000
LR R2,R12 ADDR OF DMKMNI IN R2 FOR LOCK 00488000
CALL DMKPTRLK LOCK THIS MODULE FOR CPEX RETURN 00489000
EXIT AND RETURN TO MCC FOR CMD COMP. @V4075A4 00490000
SPACE 2 00491000
SHRETN TM MONFLAG1,ERROR+TRUN OK TO CONTINUE? 00492000
BNZ GOTO NOPE, SYSTEM WILL DO THE REST @VM01004 00493000
L R0,MONIOBF IS TAPE BUSY? @V4075A4 00494000
LTR R0,R0 NON-ZERO VALUE MEANS IT IS @V4075A4 00495000
BNZ GOTO BUSY, SYSTEM WILL DO THE REST @V4075A4 00496000
BAL R7,TRAILER WRITE MONITOR TRAILER RECORD 00497000
B GOTO EXIT TO DISPATCHER 00498000
DROP R1 @V2B2638 00499000
EJECT 00500000
*. 00501000
* 00502000
* 00503000
* ENTRY POINT - 00504000
* 00505000
* DMKMNITR - WRITE MONITOR TRAILER RECORD 00506000
* 00507000
* ENTRY CONDITIONS - 00508000
* 00509000
* GPR9 - ADDRESS OF MONCOM 00510000
* GPR12 - ADDRESS OF ENTRY POINT 00511000
* GPR13 - ADDRESS OF STANDARD SAVE AREA 00512000
* 00513000
* EXIT CONDITIONS - 00514000
* 00515000
* NONE 00516000
* 00517000
* OPERATION - 00518000
* 00519000
* MONITOR TAPE TRAILER PROCESSING 00520000
* TRAILER: 00521000
* INDICATE A CLASS 0 CODE 98 MONITOR CALL (TRAILER 00522000
* RECORD) IN PSA. OBTAIN AND INITIALIZE STORAGE FOR 00523000
* THE RECORD; INITIALIZE THE IOB FOR REUSE. SET UP 00524000
* THE CCW'S FOR A WRITE, WTM AND RUN SEQUENCE; SET 00525000
* THE 'TRUN' FLAG. CALCULATE THE LAST BUFFER SIZE 00526000
* AND LINK TO THE TAPE I/O MANAGER TO INITIATE THE 00527000
* FINAL TAPE I/O SEQUENCE. RETURN TO THE CALLER. 00528000
* ON RECEIVING THE FINAL I/O INTERRUPT FROM THE TAPE, 00529000
* DMKMNI WILL BE RE-ENTERED AT DMKMNIFI TO CLEAN UP THE 00530000
* MONITOR'S RESOURCES. 00531000
* 00532000
* FRETIOB: 00533000
* IF THERE IS AN IOERBLOK, THEN FRET IT. FRET THE 00534000
* IOB. (IF THE IOB IS THE ONE USED FOR THE MONITOR 00535000
* THEN ADJUST THE SIZE ACCORDINGLY). RETURN TO THE 00536000
* CALLER. 00537000
* 00538000
*. 00539000
DMKMNITR RELOC @V4075A4 00540000
LA R7,EXITT SET RETURN ADDRESS 00541000
SPACE 00542000
TRAILER LA R0,MNCLPERF DUMMY UP A TRAILER CALL, CL 0 @VM01017 00543000
STH R0,MONCLASS ... @VM01017 00544000
LA R0,MNCOTT TRAILER CODE @VM01017 00545000
ST R0,MONCODE ... @V2B2638 00546000
LA R0,MN098LEN LENGTH OF TRAILER RECORD @V2B2638 00547000
TM MONFLAG3,SPOOLED ARE WE SPOOLED @V50A2B5 00548000
BNO CONTIN1 NO @V50A2B5 00549000
TM MONFLAG3,CLSUS AND CLOSE SUSPENDED? @V50A2B5 00550000
BO RETN YES, GET OUT @V50A2B5 00551000
CONTIN1 EQU * @V50A2B5 00552000
CALL DMKMONPR CALL PREPREC ROUT IN DMKMON V2B2638 00553000
LTR R1,R1 @VA10215 00553300
BZR R7 @VA10215 00553600
L R15,MONIOBF MONITOR I/O BUFFER NONZERO WHEN @V4M0238 00554000
* I/O IS IN PROGRESS. @V4M0238 00555000
LTR R15,R15 WAS CURRENT BUFFER FULL ? @V4M0238 00556000
BNZR R7 YES - DMKMONIO WILL FORCE RENTRY @V4M0238 00557000
* TO DMKMNITR AFTER I/O COMPLETES. @V4M0238 00558000
USING MN098,R1 ADDRESS THE TRAILER RECORD @V2B2638 00559000
MVC MN098UID,MONUSER TRACK WHO SAID IT @V2B2638 00560000
TM MONFLAG3,SPOOLED ARE WE SPOOLED @V50A2B5 00561000
BNO RESMTR NO, RESUME TRAILER @V50A2B5 00562000
CALL DMKMIACC CLOSE UP THE SPOOL FILE @V50A2B5 00563000
* MNIFI WILL BE CALLED FROM MIACC @V50A2B5 00564000
RETN BR R7 @V50A2B5 00565000
RESMTR EQU * @V50A2B5 00566000
LA R1,IOBSIZE*8(R10) GET THE WRITE CCW @V2B2638 00567000
OI 4(R1),CC COMMAND CHAIN IT TO WTM, RUN @V2B2638 00568000
ST R1,IOBCAW MAKE SURE WE HAVE THE RIGHT CCW @V2B2638 00569000
L R4,MONCURBF GET THE SIZE OF THE CURRENT PAGE @V2B2638 00570000
* IN BYTES. 00571000
L R8,PREFIXA SETUP FOR ABSOLUTE 0 REFERENCE @V4M0163 00572000
L R2,MONNEXT(R8) NXT SLOT IN BUFFER. @V4M0163 00573000
SR R2,R4 ... @V2B2638 00574000
SLL R2,16 PUT IN UPPER HALF @V2B2638 00575000
ST R2,0(R4) PUT IN PAGE HEADER (V FORMAT) @V2B2638 00576000
SRL R2,16 SHUFFLE BACK DOWN FOR STH @V2B2638 00577000
STH R2,IOBSIZE*8+6(R10) PUT BYTE COUNT INTO CCW @V2B2638 00578000
ST R4,IOBSIZE*8(R10) SET UP THE CCW DATA ADDRESS @V2B2638 00579000
MVI IOBSIZE*8(R10),X'01' REPLACE THE OP CODE @V2B2638 00580000
OI MONFLAG1,TRUN WTM-RUN DONE+ TAPE NOW BUSY @V2B2638 00581000
ST R4,MONIOBF INDICATE TAPE NOW BUSY @V4075A4 00582000
CALLIOS XC IOBFLAG(2),IOBFLAG CLEAR THE IOB FOR REUSE @V4075A4 00583000
L R8,MONARDB ADDRESS OF THE RDEVBLOK @V4075A4 00584000
CALL DMKIOSQR QUEUE THE I/O REQUEST @V4075A4 00585000
BR R7 RETURN TO CALLER 00586000
SPACE 00587000
EXITT EXIT RETURN TO EXTERNAL CALLER 00588000
SPACE 5 00589000
FRETIOB ST R5,IOBMISC2 SAVE THE RETURN ADDRESS @V2B2638 00590000
BAL R5,FRETIOER DROP THE IOERBLOK IF ONE EXISTS @V2B2638 00591000
L R5,IOBMISC2 RELOAD THE RETURN ADDRESS @V2B2638 00592000
LA R1,0(R10) CLEAR HI BYTE AND MOVE TO R1 @V2B2638 00593000
LA R0,IOBSIZE GET SIZE OF STANDARD IOB @V2B2638 00594000
C R1,MONAIOB IS THIS THE MONITOR BASE IOB? @V2B2638 00595000
BNE STDIOB NO, STANDARD IOB SIZE @V2B2638 00596000
LA R0,IOBSIZE+4 SET FOR IOB + CCW'S @V2B2638 00597000
STDIOB CALL DMKFRET RETURN THE STORAGE @V2B2638 00598000
BR R5 RETURN TO CALLER @V2B2638 00599000
SPACE 3 00600000
FRETIOER L R1,IOBIOER GET THE IOER ADDRESS @V2B2638 00601000
LTR R1,R1 IS THERE ONE? @V2B2638 00602000
BZR R5 NOPE, RETURN @V2B2638 00603000
LA R0,IOERSIZE GET THE CORRECT SIZE @V2B2638 00604000
CALL DMKFRET FRET THE IOERBLOK @V2B2638 00605000
SLR R1,R1 CLEAR THE IOB POINTER @V2B2638 00606000
ST R1,IOBIOER ... @V2B2638 00607000
BR R5 RETURN TO CALLER @V2B2638 00608000
EJECT 00609000
*. 00610000
* 00611000
* ENTRY POINT - 00612000
* 00613000
* DMKMNIFI - CLEAN UP MONITOR RESOURCES 00614000
* 00615000
* ENTRY CONDITIONS - 00616000
* 00617000
* GPR9 - ADDRESS OF MONCOM 00618000
* GPR12 - ADDRESS OF ENTRY POINT 00619000
* GPR13 - ADDRESS OF STANDARD SAVE AREA 00620000
* 00621000
* EXIT CONDITIONS - 00622000
* 00623000
* NONE 00624000
* 00625000
* OPERATION - 00626000
* 00627000
* MONITOR CLEANUP PROCESSING 00628000
* 00629000
* FINISHUP: 00630000
* 00631000
* FRET THE BACK POCKET CPEXBLOK. 00632000
* 00633000
* FRET THE IOB VIA A LINK TO STEP FRETIOB. 00634000
* 00635000
* RELEASE THE TAPE DRIVE. 00636000
* 00637000
* IF THERE IS AN ACTIVE TRB, DEQUEUE AND FRET IT. 00638000
* 00639000
* IF THERE IS A DEVICE LIST, THEN FRET IT. 00640000
* 00641000
* CALL DMKPTRFT TO RETURN THE BUFFER PAGES. 00642000
* 00643000
* SET THE MONITOR BUFFER POINTERS IN PSA TO ZERO. 00644000
* 00645000
* FRET THE MONCOM BLOCK. 00646000
* 00647000
* SET THE MONITOR VALUES AND POINTERS IN DMKPRG TO ZERO. 00648000
* 00649000
* CALL DMKPTRUL TO UNLOCK THIS PAGE. 00650000
* 00651000
* IF THERE WAS A STACKED CPEXBLOK ON MONCOM, THE 00652000
* STACK IT ON THE DISPATCHERS CPEXBLOK QUEUE. GO 00653000
* TO THE DISPATCHER. 00654000
* 00655000
*. 00656000
DMKMNIFI RELOC @V4075A4 00657000
TM MONFLAG3,SPOOLED ARE WE SPOOLED @V50A2B5 00658000
BO UNLOKMON YES, THEN UNLOCK MONITOR @V50A2B5 00659000
SVC 16 RETURN CALLER'S SAVE AREA AND @V4075A4 00660000
* UNLOCK DMKMON 00661000
B FINISHUP SKIP EXPLICIT DMKMON UNLOCK 00662000
SPACE 00663000
UNLOKMON L R2,=A(DMKPRGMI) GET POINTER TO ADDR OF DMKMON 00664000
L R2,0(R2) GET ADDR OF DMKMON 00665000
CALL DMKPTRUL UNLOCK IT @V4075A4 00666000
FINISHUP EQU * @VA07357 00667000
L R14,=A(DMKDSPNP) ADDR OF SYSTEM PAGEABLE PGE CNT@VA07357 00668000
L R15,0(R14) TOTAL PAGEABLE PAGES @VA07357 00669000
LA R15,1(R15) PLUS 1 FOR UNLOCK OF DMKMON @VA07357 00670000
ST R15,0(R14) SAVE NEW TOTAL @VA07357 00671000
SPACE 00672000
SLR R3,R3 ZILCH R3 FOR QUICK STORES @VA07357 00673000
TM MONFLAG3,SPOOLED ARE WE SPOOLED @V50A2B5 00674000
BO CONFRET CONTINUE WITH THE FRET @V50A2B5 00675000
LTR R10,R10 MAKE SURE R10 IS OK @V50A2B5 00676000
BZ CONTFI @V50A2B5 00677000
CONFRET EQU * @V50A2B5 00678000
L R1,IOBMISC ADDR OF THE BACK POCKET CPEXBLOK @V2B2638 00679000
LA R0,CPEXSIZE SIZE TO RELEASE @V2B2638 00680000
CALL DMKFRET AND RETURN IT. @V2B2638 00681000
L R6,IOBMISC2 GET DEFERRED RETN ADDR FOR SHUT @VM01004 00682000
BAL R5,FRETIOB RETURN THE IOB @V2B2638 00683000
CONTFI EQU * @V50A2B5 00684000
ST R3,MONAIOB NO MORE IOB @V2B2638 00685000
TM MONFLAG3,SPOOLED ARE WE SPOOLED @V50A2B5 00686000
BNO DODEV NO, WORK WITH DEVICE @V50A2B5 00687000
L R6,FFS SET R6 SPECIAL @V50A2B5 00688000
B NODEV @V50A2B5 00689000
DODEV EQU * @V50A2B5 00690000
L R8,MONARDB ADDRESS OF THE TAPE RDEVBLOK @V2B2638 00691000
USING RDEVBLOK,R8 @V2B2638 00692000
NI RDEVFLAG,255-RDEVSYS NOMORE IN USE BY SYS @V2B2638 00693000
DROP R8 @V2B2638 00694000
NODEV EQU * @V50A2B5 00695000
L R1,MONATRB GET THE TRB ADDRESS @V2B2638 00696000
LTR R1,R1 IS THERE ONE? @V2B2638 00697000
BZ CKDAS NOPE, GO CHECK DASTAP @V2B2638 00698000
CALL DMKSCHRT REMOVE IT FROM THE CHAIN @V2B2638 00699000
LA R0,TRQBSIZE AND THROW IT AWAY @V2B2638 00700000
CALL DMKFRET ... @V2B2638 00701000
ST R3,MONATRB ZILCH THE OLD POINTER @V2B2638 00702000
CKDAS L R1,MONUTRB GET ADDR OF UTILIZATION TRB @V60BEBC 00703000
LTR R1,R1 IS THERE ONE? @V60BEBC 00703080
BZ FREEDLST NO UTILIZATION, CHECK DEV LIST @V60BEBC 00703160
CALL DMKSCHRT REMOVE TRB FROM CHAIN @V60BEBC 00703240
LA R0,TRQBSIZE ..... @V60BEBC 00703320
CALL DMKFRET AND THROW IT AWAY @V60BEBC 00703400
ST R3,MONUTRB ZILCH THE POINTER TO UTILIZATIO@V60BEBC 00703480
L R1,MONCHPTR POINT TO CHANNEL SAMPLE FIELDS @V60BEBC 00703560
LA R0,MNCHSIZE SIZE IN DOUBLE WORDS @V60BEBC 00703640
CALL DMKFRET FREE SAMPLE FIELDS @V60BEBC 00703720
ST R3,MONCHPTR ZILCH THE POINTER TO SAMPLE FIE@V60BEBC 00703800
FREEDLST L R1,MONDVLST IS THERE A DEVICE LIST? @V60BEBC 00703880
LTR R1,R1 ... @V2B2638 00704000
BZ FRETBUFS NOPE, GO DUMP CORE BUFFERS @V2B2638 00705000
LH R0,MONDVNUM NUMBER OF DEVICES @V2B2638 00706000
CALL DMKFRET THROW IT AWAY @V2B2638 00709000
ST R3,MONDVLST NO MORE DEVICE LIST @V2B2638 00710000
FRETBUFS EQU * @VA07357 00711000
L R15,ASYSVM GET SYSTEM VMBLOK @V50A2B5 00712000
LCTL C1,C1,VMSEG-VMBLOK(R15) FOR CORRECT SEG TABLE @V50A2B5 00713000
SR R4,R4 CLEAR INDEX REGISTER @VA07357 00714000
L R5,ACORETBL ADDRESS OF SYSTEM CORE TABLE @VA07357 00715000
FREPAGE EQU * @VA07357 00716000
L R7,MONBUF1(R4) ADDRESS OF BUFFER TO RELEASE @VA07357 00717000
LTR R7,R7 LAST ENTRY ? @VA07357 00718000
BM PSACLEAN YES - CLEAR PSA MONITOR DATA @VA07357 00719000
SRL R7,8 INDEX TO CORETABLE ENTRY @VA07357 00720000
AR R7,R5 LOCATE ENTRY TO BE FREED @VA07357 00721000
USING CORTABLE,R7 @V2B2638 00722000
NI CORFLAG,255-CORCP NOT A CP PAGE ANYMORE @V2B2638 00723000
L R2,MONBUF1(R4) LOAD IN REAL BUFFER ADDRESS @V50A2B5 00724000
L R1,MONBUF1V(R4) LOAD IN VIRTUAL BUFFER ADDRESS @V50A2B5 00725000
CALL DMKPTRUL UNLOCK THE PAGE @V50A2B5 00726000
CALL DMKPGTVR RELEASE THE PAGE @V50A2B5 00727000
LA R4,8(R4) BUMP TO NEXT SLOT @V50A2B5 00728000
L R14,=A(DMKDSPNP) GET PAGEABLE SLOT @V50A2B5 00729000
L R15,0(R14) LOAD IT IN @V50A2B5 00730000
LA R15,1(R15) BUMP IT UP @V50A2B5 00731000
ST R15,0(R14) AND STORE IT @V50A2B5 00732000
B FREPAGE GO DO IT AGAIN @V2B2638 00733000
PSACLEAN EQU * @V4M0163 00734000
L R1,PREFIXA CURRENT PREFIX TO REFERENCE ABS 0@V4M0163 00735000
ST R3,PAGEND(R1) CLEAR PAGEND IN ABSOLUTE 0 @V4M0163 00736000
ST R3,PAGECUR(R1) CLEAR PAGECUR IN ABSOLUTE 0 @V4M0163 00737000
ST R3,PAGENXT(R1) CLEAR PAGENXT IN ABSOLUTE 0 @V4M0163 00738000
ST R3,MONNEXT(R1) CLEAR MONNEXT IN ABSOLUTE 0 @V4M0163 00739000
LR R1,R9 ADDR OF THE MONCOM @V2B2638 00740000
LA R0,MONSIZE SIZE OF THE COMMUNICTION AREA @V2B2638 00741000
LA R4,7(R4) ENSURE DOUBLEWORD IS RELEASED @VA07357 00742000
AR R0,R4 MONSIZE + MONBUF1 AREA @VA07357 00743000
SRL R0,3 CONVERT TO NO. DOUBLEWORDS @VA07357 00744000
CALL DMKFRET DUMP THAT TOO. @V2B2638 00745000
DROP R7,R10 @VA08888 00746500
L R1,=A(DMKPRGMC) ADDR OF MONCOM @V2B2638 00747000
ST R3,0(,R1) NO MORE @V2B2638 00748000
L R1,=A(DMKPRGTI) ADDR OF INTERVAL @V2B2638 00749000
STH R3,0(,R1) NO MORE @V2B2638 00750000
ST R3,CPCREG8 ZERO PSA VALUE @VA11128 00750200
L R2,PREFIXB GET OTHER PSA @VA11128 00750400
ST R3,CPCREG8(R2) ZERO IT AS WELL @VA11128 00750600
L R1,=A(DMKPRGC8) ENABLED VALUE @V2B2638 00751000
STCTL C8,C8,0(R1) STORE CR8 @VA09647 00752000
CLC 0(4,R1),ZEROES IS CR8 ZERO? @VA09647 00752100
BE FINCLEAN YES - CONTINUE @VA09647 00752200
LCTL C8,C8,ZEROES ZERO CR8 @VA09647 00752300
ST R3,0(,R1) NO MORE @VA09647 00752400
LA R0,NOENABLN SET MSG LENGTH @VA09647 00752500
LA R1,NOENAB POINT TO MSG @VA09647 00752600
CALL DMKQCNWT,PARM=NORET @VA09647 00752700
FINCLEAN EQU * @VA09647 00752800
L R1,=A(DMKPRGMI) ADDR OF THIS ROUTINE @V2B2638 00753000
ST R3,0(R1) NO MORE @V2B2638 00754000
LA R3,DEFINTVL N SECOND DEFAULT FOR I/O UTILIZ@V60BEBC 00754250
L R1,=A(DMKENTUT) ADDR OF DEV UTILIZATION INTERVA@V60BEBC 00754500
STH R3,0(R1) SAVE DEFAULT @V60BEBC 00754750
LTR R6,R6 ARE WE HERE FROM SHUTDOWN CMD? @VM01004 00755000
BZ GOTO NOPE, NORMAL MONITOR STOP @VM01066 00756000
C R6,FFS CHECK IF THIS IS MONITOR @V50A2B5 00757000
BE STDEXIT YES, EXIT @V50A2B5 00758000
USING CPEXBLOK,R6 ADDRESS THE BLOCK @VM01066 00759000
LM R0,R15,CPEXR0 LOAD UP FOR RETURN TO SHUTDOWN @VM01066 00760000
BR R14 AND RETURN THERE NOW. @VM01066 00761000
DROP R6 DEADDRESS THE BLOCK @VM01066 00762000
SPACE 1 00763000
STDEXIT EXIT @V50A2B5 00764000
SPACE 00765000
GOTO LR R2,R12 ADDR OF DMKMNI IN R2 FOR UNLOCK 00766000
CALL DMKPTRUL UNLOCK THIS MODULE 00767000
TM MONEX,CLCMD SHUTDOWN OR MONITOR STOP? @VA08888 00767100
BO GOTODSP YES, LEAVE PAGE COUNT ALONE @VA08888 00767150
TM MONFLAG3,SPOOLED ARE WE SPOOLED? @VA08888 00767200
BNO GOTODSP I SAID LEAVE IT ALONE @VA08888 00767250
N R2,XPAGNUM GET PAGE NUMBER @VA08888 00767300
SRL R2,8 DIVIDED BY 256 @VA08888 00767350
A R2,ACORETBL POINT TO CORETABLE ENTRY @VA08888 00767400
USING CORTABLE,R2 @VA08888 00767450
L R0,CORLCNT IF LOCKCOUNT NONZERO LEAVE AND.. @VA08888 00767500
LTR R0,R0 DONT INCREMENT AVAILABLE.. @VA08888 00767550
BP GOTODSP PAGE COUNT THIS TIME @VA08888 00767600
L R14,=A(DMKDSPNP) GET AVAILABLE PAGE COUNT @VA08888 00767650
L R15,0(R14) LOAD IT IN @VA08888 00767700
LA R15,1(R15) BUMP IT UP @VA08888 00767750
ST R15,0(R14) AND STORE IT @VA08888 00767800
DROP R2,R9 @VA08888 00767850
GOTODSP GOTO DMKDSPCH LET DISPATCHER FIND SOMTIN' TODO @V2B2638 00768000
EJECT 00769000
*. 00770000
* 00771000
* ENTRY POINT - 00772000
* 00773000
* DMKMNISP 00774000
* 00775000
* ENTRY CONDITIONS - 00776000
* 00777000
* NONE 00778000
* 00779000
* EXIT CONDITIONS - 00780000
* 00781000
* REGISTER 2 CONTAINS RETURN CODE 00782000
* 0 - NORMAL RETURN 00783000
* 5 - BUFFS PARSED OUT OF COMMAND BUFFER 00784000
* OTHER - ERROR 00785000
* 00786000
* EXTERNAL REFERENCES - 00787000
* 00788000
* DMKSYSUR - SPOOL MONITOR DEFAULT USER 00789000
* 00790000
* DMKUDRFU - VM ID IDENTIFIER 00791000
* 00792000
* REGISTER USAGE 00793000
* 00794000
* R9 - ADDRESS OF COMMAND BUFFER AREA 00795000
* R11 - ADDRESS OF VMBLOK OF USER 00796000
* R12 - ADDRESSABILITY 00797000
* R13 - SAVEAREA 00798000
* 00799000
* FUNCTION - 00800000
* TO VERIFY THAT THE USER IN THE DMKSYS AREA IS VALID FOR 00801000
* USAGE OF SPOOL MONITOR 00802000
* 00803000
*. 00804000
SPACE 1 00805000
USING VMBLOK,R11 00806000
USING SAVEAREA,R13 00807000
* @V50A2B5 00808000
DMKMNISP RELOC @V50A2B5 00809000
SR R2,R2 FIRST SET @V50A2B5 00810000
ST R2,SAVER2 SAVER2 TO NO ERROR @V50A2B5 00811000
CALL DMKSCNFD GET THE NEXT FIELD @V50A2B5 00812000
BNZ USEDFLT USE DEFAULT USER @V50A2B5 00813000
CL R0,F2 LEGAL LENGTH @V50A2B5 00814000
BNE CHKBFS NOT AT ALL @V50A2B5 00815000
CLC 0(2,R1),=C'TO' SHOULD BE TO @V50A2B5 00816000
BNE MSG002 NOT AT ALL @V50A2B5 00817000
CALL DMKSCNFD GET THE SUPPOSED USERID @V50A2B5 00818000
BNZ MSG002 MUST BE THERE @V50A2B5 00819000
CHKUSR EQU * @V50A2B5 00820000
LR R5,R1 REGISTER 5 USED IN MOVE @V50A2B5 00821000
CL R0,F1 SEE IF * SPECIFIED @V50A2B5 00822000
BNE SYNCHK NO CONTINUE @V50A2B5 00823000
CLI 0(R1),C'*' IS IT * @V50A2B5 00824000
BNE SYNCHK NO CONTINUE @V50A2B5 00825000
LA R5,VMUSER USER THIS USER @V50A2B5 00826000
LA R0,8(R0) INIT COUNTER @V50A2B5 00827000
B STORUSR WORK WITH USER @V50A2B5 00828000
SYNCHK EQU * @V50A2B5 00829000
CL R0,F8 LEGAL LENGTH @V50A2B5 00830000
BH MSG002 NO, SEND MESSAGE @V50A2B5 00831000
SR R2,R2 PREPARE TO VERIFY USER @V50A2B5 00832000
CALL DMKUDRFU VERIFY THE USER @V50A2B5 00833000
BNZ MSG225 NO SUCH PERSON EXISTS @V50A2B5 00834000
STORUSR L R2,=A(DMKSYSUR) STORE FOR THE USERID @V50A2B5 00835000
LR R3,R0 GET LENGTH @V50A2B5 00836000
BCTR R3,R0 DOWN FOR EXECUTE @V50A2B5 00837000
MVC 0(8,R2),BLANKS FILL IN BLANKS @V50A2B5 00838000
EX R3,STORUID STORE IN USERID @V50A2B5 00839000
SR R8,R8 BLANK OUT VDEV FIELD @V50A2B5 00840000
SAFEXIT EQU * @V50A2B5 00841000
B EXITS EXIT @V50A2B5 00842000
USEDFLT EQU * @V50A2B5 00843000
L R1,=A(DMKSYSUR) GET LENGTH OF USER AREA @V50A2B5 00844000
LR R2,R1 KEEP IN REGISTER 2 @V50A2B5 00845000
LA R3,8 SET COUNTER AT 8 @V50A2B5 00846000
LP CLI 0(R2),C' ' CHECK FOR BLANK @V50A2B5 00847000
BE ENDLP YES, CONTINUE @V50A2B5 00848000
LA R2,1(R2) BUMP UP ADDRESS @V50A2B5 00849000
BCT R3,LP KEEP LOOPING IF NECESSARY @V50A2B5 00850000
ENDLP SR R2,R1 COMPUTE LENGTH @V50A2B5 00851000
LR R0,R2 GET READY TO @V50A2B5 00852000
SR R2,R2 VERIFY @V50A2B5 00853000
CALL DMKUDRFU THE USER @V50A2B5 00854000
BNZ MSG225 HE DOES NOT EXIST @V50A2B5 00855000
B SAFEXIT EXIT @V50A2B5 00856000
STORUID MVC 0(0,R2),0(R5) MOVE OF INFORMATION @V50A2B5 00857000
SPACE 1 00858000
MSG002 LA R2,2 ILLEGAL OPERAND @V50A2B5 00859000
B CALLERM CALL ERROR MESSAGE @V50A2B5 00860000
SPACE 1 00861000
MSG225 LA R2,225 ILLEGAL MONITOR USERID @V50A2B5 00862000
SR R1,R1 ZIP OUT REGISTER ONE @V50A2B5 00863000
B CALLERM CALL ERROR MESSAGE ROUTINE @V50A2B5 00864000
SPACE 1 00865000
CALLERM ICM R0,B'1110',MODID+3 MONITOR ID FOR MESSAGE @V50A2B5 00866000
ST R2,WORK2 SET UP REGISTER 2 @V50A2B5 00867000
ST R2,SAVER2 DO SO MONITOR DOES NOT START@V50A2B5 00868000
MVI WORK2,X'80' INDICATE RETURN HERE @VA08679 00869000
L R2,WORK2 REG 2 COMPLETE @V50A2B5 00870000
CALL DMKERMSG CALL MESSAGE ROUTINE @VA08679 00871000
EXITS EXIT EXIT @V50A2B5 00872000
SPACE 1 00873000
CHKBFS CL R0,F5 MIGHT BE BUFFS @V50A2B5 00874000
BNE MSG002 NOPE @V50A2B5 00875000
CLC 0(5,R1),=C'BUFFS' IS IT BUFFS @V50A2B5 00876000
BNE MSG002 NO @V50A2B5 00877000
MVC SAVER2(4),F5 IT IS, SET PROPER RETURN @V50A2B5 00878000
B USEDFLT CONTINUE @V50A2B5 00879000
EJECT 00880000
*. 00881000
* 00882000
* ENTRY POINT - 00883000
* 00884000
* DMKMNIDS 00885000
* 00886000
* ENTRY CONDITIONS - 00887000
* 00888000
* NONE 00889000
* 00890000
* EXIT CONDITIONS - 00891000
* 00892000
* NONE 00893000
* 00894000
* EXTERNAL REFERENCES - 00895000
* 00896000
* DMKQCNWT - MESSAGE ROUTINE 00897000
* DMKSYSAT - SPOOL MONITOR ENVIRONMENT DEFAULTS 00898000
* DMKSYSUR - SPOOL MONITOR DEFAULT USER 00899000
* DMKSYSMX - SPOOL MONITOR SPOOL FILE MAXIMUM 00900000
* DMKSYSTS - SPOOL MONITOR AUTO START TIME 00901000
* DMKSYSTE - SPOOL MONITOR AUTO STOP TIME 00902000
* DMKCVTBD - CONVERT TO BINARY ROUTINE 00903000
* DMKPRGMC - MONITOR COMMUNICATIONS AREA 00904000
* 00905000
* REGISTER USAGE - 00906000
* 00907000
* R10 - MONITOR COMMUNICATIONS AREA 00908000
* R11 - ADDRESS OF VMBLOK OF USER 00909000
* R12 - ADDRESSABILITY 00910000
* R13 - SAVE AREA 00911000
* 00912000
* FUNCTION - 00913000
* 00914000
* TO DISPLAY SPOOL MONITOR INFORMATION 00915000
* 00916000
*. 00917000
SPACE 1 00918000
DMKMNIDS RELOC @V50A2B5 00919000
LA R1,SPLMSG PUT OUT THE SPOOL MESSAGE @V50A2B5 00920000
LA R0,SPLMSGLN GET THE LENGTH @V50A2B5 00921000
CALL DMKQCNWT,PARM=NORET PUT OUT MESSAGE @V50A2B5 00922000
L R5,=A(DMKSYSAT) READ THE BITS HERE @V50A2B5 00923000
MVC AUTDMSG+11(8),ENAB SET TO ENABLE @V50A2B5 00924000
TM 0(R5),AUTGO BUT IF AUTODISK @V50A2B5 00925000
BO *+10 IS NOT ON, @V50A2B5 00926000
MVC AUTDMSG+11(8),DISAB SAY SO @V50A2B5 00927000
MVC AUTXMSG+13(6),NOSTOP SET TO NOSTOP @V50A2B5 00928000
TM 0(R5),AUTOSPL BUT IF AUTOSPOOL @V50A2B5 00929000
BO *+10 IS NOT ON, @V50A2B5 00930000
MVC AUTXMSG+13(6),STOP SAY NO @V50A2B5 00931000
L R5,=A(DMKSYSUR) GET THE USERID MESSAGE @V50A2B5 00932000
MVC AUTUMSG+11(8),0(R5) PUT IN THE USERID @V50A2B5 00933000
L R5,=A(DMKSYSCL) GET INFORMATION FOR THE CLASS @V50A2B5 00934000
MVC AUTCMSG+11(1),0(R5) PUT THIS IN THE MESSAGE @V50A2B5 00935000
L R5,=A(DMKSYSMX) OBTAIN THE SPOOL MAX @V50A2B5 00936000
L R1,0(R5) INTO REGISTER ONE @V50A2B5 00937000
CALL DMKCVTBD CONVERT TO DECIMAL CHARACTERS @V50A2B5 00938000
STM R0,R1,TIMVAL NEED GOOD BOUNDARY FOR INSERT @V50A2B5 00939000
MVC AUTXMSG+6(6),TIMVAL+2 FILL IN THE MESSAGE @V50A2B5 00940000
L R5,=A(DMKSYSTS) GET THE START TIME @V50A2B5 00941000
LM R6,R7,0(R5) @V50A2B5 00942000
LA R5,AUTT1MSG FILL IN THE START TIME @V50A2B5 00943000
BAL R8,SETTIME CALL THE ROUTINE TO DO IT @V50A2B5 00944000
L R5,=A(DMKSYSTE) GET THE END TIME @V50A2B5 00945000
LM R6,R7,0(R5) @V50A2B5 00946000
LA R5,AUTT2MSG FILL IN THE END TIME @V50A2B5 00947000
BAL R8,SETTIME CALL THE ROUTINE TO DO IT @V50A2B5 00948000
LA R8,NOSPLMSG NOW PUT OUT THE MESSAGES @V50A2B5 00949000
LA R0,19 EACH IS 19 BYTES LONG @V50A2B5 00950000
LA R1,MSGSPL GET TO THE BEGINNING @V50A2B5 00951000
OUTMSG CALL DMKQCNWT,PARM=NORET PUT OUT THE MESSAGE @V50A2B5 00952000
LA R1,19(R1) POINT TO NEXT MESSAGE @V50A2B5 00953000
BCT R8,OUTMSG KEEP PUTTING OUT MESSAGES @V50A2B5 00954000
L R10,=A(DMKPRGMC) SEE IF MONITOR IS ON @V50A2B5 00955000
ICM R10,B'1111',0(R10) LOAD IN THE ADDRESS @V50A2B5 00956000
BZ NOBUFMSG NO BUFFER MESSAGE REQUIRED @V50A2B5 00957000
USING MONCOM,R10 @V50A2B5 00958000
L R1,MONSFB SEE IF A SPOOL FILE AROUND @V50A2B5 00959000
LTR R1,R1 TEST IF THERE IS ONE @V50A2B5 00960000
BZ NOBUFMSG NO, NO NEED FOR MESSAGE @V50A2B5 00961000
USING SFBLOK,R1 @V50A2B5 00962000
LH R1,SFBFILID GET THE FILE ID @V50A2B5 00963000
CALL DMKCVTBD CONVERT TO DECIMAL @V50A2B5 00964000
STCM R1,B'1111',FILID KEEP THE FILID @V50A2B5 00965000
DROP R1 @V50A2B5 00966000
L R1,MONSPLCT GET THE NUMBER OF BUFFERS @V50A2B5 00967000
CALL DMKCVTBD CONVERT TO DECIMAL @V50A2B5 00969000
STCM R0,B'1111',BUFFLD @V50A2B5 00970000
STCM R1,B'1111',BUFFLD+4 @V50A2B5 00971000
LA R1,BUFMSG WRITE OUT THE MESSAGE @V50A2B5 00972000
LA R0,BUFMSGSZ @V50A2B5 00973000
CALL DMKQCNWT,PARM=NORET DO THE WRITE @V50A2B5 00974000
LA R2,MONBUF1 COUNT BUFFERS @V50A2B5 00975000
LA R1,1(R0) BUMP BY ONE @V50A2B5 00976000
COMPCONT CLI 8(R2),X'FF' ANY MORE @V50A2B5 00977000
BE NICHTO NO @V50A2B5 00978000
LA R2,8(R2) KEEP COUNTING @V50A2B5 00979000
LA R1,1(R1) BUMP BY ONE @V50A2B5 00980000
B COMPCONT @V50A2B5 00981000
NICHTO CALL DMKCVTBD CONVERT TO BINARY @V50A2B5 00982000
STCM R1,B'0011',AUTBMSG+11 STORE THIS @V50A2B5 00983000
LA R0,L'AUTBMSG GET LENGTH OF MESSAGE @V50A2B5 00984000
LA R1,AUTBMSG GET ADDRESS OF MESSAGE @V50A2B5 00985000
CALL DMKQCNWT,PARM=NORET WRITE OUT THE MESSAGE @V50A2B5 00986000
DROP R10 @V50A2B5 00987000
NOBUFMSG EQU * @V50A2B5 00988000
EXIT @V50A2B5 00989000
SPACE 2 00990000
SETTIME EQU * @V50A2B5 00991000
SRDL R6,12 CONVERT TO SECONDS @V50A2B5 00992000
D R6,=F'1000000' DIVIDE FROM MICRO TO SECS. @V50A2B5 00993000
SR R6,R6 DIVIDE NO OF SECONDS TO HOURS @V50A2B5 00994000
D R6,=F'3600' @V50A2B5 00995000
LR R1,R7 WORK WITH THE HOURS RESULT @V50A2B5 00996000
CALL DMKCVTBD CONVERT TO DECIMAL CHARACTERS @V50A2B5 00997000
STM R0,R1,TIMVAL USE THE GOOD BOUNDARY @V50A2B5 00998000
MVC 11(2,R5),TIMVAL+6 PUT THIS IN THE MESSAGE @V50A2B5 00999000
LR R7,R6 NOW WORK WITH THE REMAINDER @V50A2B5 01000000
SR R6,R6 FIND NUMBER OF MINUTES @V50A2B5 01001000
D R6,=F'60' BY DIVIDING BY 60 @V50A2B5 01002000
LR R1,R7 DO THE CONVERSION AGAIN @V50A2B5 01003000
MVI 13(R5),C':' PUT IN A COLON @V50A2B5 01004000
CALL DMKCVTBD CONVERT TO DECIMAL CHARACTERS @V50A2B5 01005000
STM R0,R1,TIMVAL USE THE GOOD BOUNDARY @V50A2B5 01006000
MVC 14(2,R5),TIMVAL+6 LOAD IN THE MESSAGE @V50A2B5 01007000
BR R8 @V50A2B5 01008000
EJECT 01009000
*. 01010000
* 01011000
* ENTRY POINT - 01012000
* 01013000
* DMKMNIST 01014000
* 01015000
* ENTRY CONDITIONS - 01016000
* 01017000
* GPR11 - ADDRESS OF VMBLOK OF USER 01018000
* GPR13 - SAVE AREA 01019000
* 01020000
* EXIT CONDITIONS - 01021000
* 01022000
* NONE 01023000
* 01024000
* EXTERNAL REFERENCES - 01025000
* 01026000
* DMKCVTAB - DAMAGED CLOCK ROUTINE 01027000
* DMKENTBS - AUTO START TRQ STATUS 01028000
* DMKENTEC - TRQ ENTRY POINT TO END 01029000
* DMKENTES - AUTO END TRQ STATUS 01030000
* DMKENTSC - TRQ ENTRY POINT TO START 01031000
* DMKENTTB - ADDRESS OF TRQ TO AUTO START 01032000
* DMKENTTE - ADDRESS OF TRQ TO AUTO END 01033000
* DMKPRGMC - ADDRESS OF MONCOM AREA 01034000
* DMKSCHRT - ROUTINE TO UNSTACK TRQ 01035000
* DMKSCHST - ROUTINE TO STACK TRQ 01036000
* DMKSTKCP - ROUTINE TO STACK CPEXBLOK 01037000
* DMKSYSAT - MONITOR ENVIRONMENT FLAG 01038000
* DMKSYSTE - MONITOR AUTO END TIME 01039000
* DMKSYSTS - MONITOR AUTO START TIME 01040000
* 01041000
* REGISTER USAGE - 01042000
* 01043000
* GPR6 - ROUTINE LINKAGE 01044000
* GPR10 - ADDRESS OF MONITOR COMMUNICATIONS AREA 01045000
* GPR11 - ADDRESS OF VMBLOK OF USER 01046000
* GPR12 - ADDRESSABILITY 01047000
* GPR13 - SAVE AREA 01048000
* 01049000
* OPERATION - 01050000
* 01051000
* FIRST ALL TRQ FOR MONITOR ARE UNSTACKED IF MONITOR AUTODISK IS 01052000
* NOT ON. BY COMPARING THE MONITOR START TO MONITOR STOP AUTO 01053000
* TIMES, IT IS DETERMINED WHICH TRQS ARE TO UNSTACKED AND STACKE 01054000
* 01055000
*. 01056000
EXTRN DMKCVTAB @VMD0138 01057000
EXTRN DMKENTTB @VMD0138 01058000
EXTRN DMKENTBS @VMD0138 01059000
EXTRN DMKENTTE @VMD0138 01060000
EXTRN DMKENTES @VMD0138 01061000
EXTRN DMKENTST @VMD0138 01062000
EXTRN DMKENTET @VMD0138 01063000
EXTRN DMKSCHST @VMD0138 01064000
EXTRN DMKENTSC @VMD0138 01065000
EXTRN DMKENTEC @VMD0138 01066000
DMKMNIST RELOC @V50A2B5 01067000
L R10,=A(DMKPRGMC) GET THE ADDRESS OF THE @V50A2B5 01068000
L R10,0(R10) MONCOM AREA @V50A2B5 01069000
USING MONCOM,R10 @V50A2B5 01070000
L R3,=A(DMKSYSAT) GET THE AUTO FLAGS @V50A2B5 01071000
TM 0(R3),AUTGO SEE IF AUTO IS ON @V50A2B5 01072000
BO STKBLKS CONTINUE TRQ STACKING LOGIC @V50A2B5 01073000
BAL R6,USTKST UNSTACK ANY START TRQ @V50A2B5 01074000
BAL R6,USTKEN UNSTACK ANY END TRQ @V50A2B5 01075000
B EXITS LEAVE THIS CODE NOW @V50A2B5 01076000
STKBLKS EQU * @V50A2B5 01077000
STCK TIMVL GET CURRENT TIME OF DAY @V50A2B5 01078000
BC 12,CLOCKRT BE SURE CLOCK IS OK @V50A2B5 01079000
GOTO DMKCVTAB CLOCK DAMAGED ABEND CVT001 @V50A2B5 01080000
CLOCKRT EQU * HERE IF CLOCK IS OK @V50A2B5 01081000
L R4,=A(DMKSYSTS) ADDRESS OF TIME START @V50A2B5 01082000
L R5,=A(DMKSYSTE) ADDRESS OF TIME END @V50A2B5 01083000
CLC 0(8,R4),0(R5) SEE IF NONE SPECIFIED @V50A2B5 01084000
BE USTKALL1 YES UNSTACK EVERYTHING @V50A2B5 01085000
CLC 0(8,R4),ZEROES SEE IF FULL DAY ALSO @V50A2B5 01086000
BNE NOTFULL NO, NOT TIME 0 @V50A2B5 01087000
CLC 0(8,R5),SET24 SEE IF END MATCHES @V50A2B5 01088000
BZ USTKALL2 YES, ALSO UNSTACK ALL @V50A2B5 01089000
NOTFULL EQU * @V50A2B5 01090000
LM R2,R3,0(R4) MUST ADD TOD @V50A2B5 01091000
AL R3,TODATE+4 TO START TIME @V50A2B5 01092000
BC 12,*+8 SEE IF A CARRY @V50A2B5 01093000
AL R2,F1 THIS IS A CARRY VALUE @V50A2B5 01094000
AL R2,TODATE FINISH ADDITION @V50A2B5 01095000
STM R2,R3,TIMESTRT STORE THE TIME START @V50A2B5 01096000
LM R2,R3,0(R5) GET THE END TIME @V50A2B5 01097000
AL R3,TODATE+4 ALSO ADD TOD @V50A2B5 01098000
BC 12,*+8 SEE IF A CARRY @V50A2B5 01099000
AL R2,F1 THIS IS A CARRY VALUE @V50A2B5 01100000
AL R2,TODATE FINISH ADDITION @V50A2B5 01101000
STM R2,R3,TIMEEND STORE THE END TIME @V50A2B5 01102000
CLC TIMVL(8),TIMESTRT C.T. > S.T. @V50A2B5 01103000
BH CHECKEND YES @V50A2B5 01104000
BAL R6,USTKST UNSTACK ANY START CONTASK @V50A2B5 01105000
BAL R6,STACKSTR STACK A START @V50A2B5 01106000
B STKEND STACK AN END @V50A2B5 01107000
CHECKEND EQU * CHECK ON THE END TIME @V50A2B5 01108000
CLC TIMVL(8),TIMEEND C.T. < E.T. @V50A2B5 01109000
BL DOSTRT YES @V50A2B5 01110000
LTR R9,R10 DO A SHUTDOWN @V50A2B5 01111000
BZ EXITS ONLY IF ON @V50A2B5 01112000
BAL R6,CPEXEND END MONITOR VIA CPEX @V50A2B5 01113000
B EXITS LEAVE THE CODE @V50A2B5 01114000
DOSTRT EQU * @V50A2B5 01115000
BAL R6,USTKST UNSTACK ANY START TRQ @V50A2B5 01116000
BAL R6,CPEXSTRT DO A CPEXSTART @V50A2B5 01117000
STKEND EQU * @V50A2B5 01118000
BAL R6,USTKEN UNSTACK THE END TRQ @V50A2B5 01119000
BAL R6,STACKEND STACK THE END TRQ @V50A2B5 01120000
B EXITS GO TO EXIT @V50A2B5 01121000
SPACE 1 01122000
USTKST EQU * @V50A2B5 01123000
L R1,=A(DMKENTTB) ADDRESS OF BEGIN BLOCK @V50A2B5 01124000
L R2,=A(DMKENTBS) ADDRESS OF BEGIN STATUS @V50A2B5 01125000
B FLOWRTN BRANCH TO ROUTINE FLOW @V50A2B5 01126000
USTKEN EQU * @V50A2B5 01127000
L R1,=A(DMKENTTE) ADDRESS OF END TRQ @V50A2B5 01128000
L R2,=A(DMKENTES) ADDRESS OF END STATUS @V50A2B5 01129000
FLOWRTN CLI 0(R2),C'S' SEE IF STACKED @V50A2B5 01130000
BNE NOUSTK NO @V50A2B5 01131000
CALL DMKSCHRT UNSTACK IT @V50A2B5 01132000
MVI 0(R2),C'U' SET IN UNSET CONDITION @V50A2B5 01133000
NOUSTK EQU * HERE IS NOT UNSTACKED @V50A2B5 01134000
BR R6 RETURN @V50A2B5 01135000
SPACE 1 01136000
STACKSTR L R1,=A(DMKENTTB) GET A BEGIN TRQ @V50A2B5 01137000
L R2,=A(DMKENTBS) GET THE STATUS BYTE @V50A2B5 01138000
L R7,=A(DMKENTST) THE ENTRY POINT @V50A2B5 01139000
LA R8,TIMESTRT ADDRESS OF TIME START @V50A2B5 01140000
B NOSTACK BRANCH TO THE REAL LOGIC @V50A2B5 01141000
STACKEND L R1,=A(DMKENTTE) GET AN END TRQ @V50A2B5 01142000
L R2,=A(DMKENTES) GET THE END STATUS @V50A2B5 01143000
L R7,=A(DMKENTET) THE ENTRY POINT @V50A2B5 01144000
LA R8,TIMEEND ADDRESS OF THE END TIME @V50A2B5 01145000
NOSTACK EQU * @V50A2B5 01146000
MVI 0(R2),C'S' SAY IT WILL BE STACKED @V50A2B5 01147000
USING TRQBLOK,R1 @V50A2B5 01148000
L R2,ASYSVM OPERATOR DOES OPERATION @V50A2B5 01149000
ST R2,TRQBUSER PUT IN THE USER @V50A2B5 01150000
MVC TRQBVAL(8),0(R8) LOAD IN THE TIME @V50A2B5 01151000
ST R7,TRQBIRA STORE THE ENTRY POINT @V50A2B5 01152000
CALL DMKSCHST SCHEDULE THE TASK @V50A2B5 01153000
DROP R1 @V50A2B5 01154000
BR R6 RETURN @V50A2B5 01155000
SPACE 1 01156000
CPEXSTRT EQU * STACK A CPEX BLOCK TO START @V50A2B5 01157000
L R5,=A(DMKENTSC) GET THE ENTRY POINT @V50A2B5 01158000
B *+8 GET INTO THE REAL LOGIC @V50A2B5 01159000
CPEXEND EQU * @V50A2B5 01160000
L R5,=A(DMKENTEC) END VIA CPEX BLOCK @V50A2B5 01161000
LA R0,CPEXSIZE LOAD SIZE OF CPEXBLOK @V50A2B5 01162000
CALL DMKFREE GET THE STORAGE FOR IT @V50A2B5 01163000
USING CPEXBLOK,R1 @V50A2B5 01164000
STM R0,R15,CPEXR0 STORE THE REGISTERS @V50A2B5 01165000
ST R5,CPEXADD ADDRESS AT WHICH TO START @V50A2B5 01166000
ST R5,CPEXR12 TAKE IN ALSO REGISTER 12 @V50A2B5 01167000
CALL DMKSTKCP STACK THE CPEXBLOCK @V50A2B5 01168000
DROP R1 @V50A2B5 01169000
BR R6 RETURN @V50A2B5 01170000
SPACE 1 01171000
USTKALL1 EQU * @V50A2B5 01172000
BAL R6,USTKST UNSTACK START TRQ @V50A2B5 01173000
BAL R6,USTKEN UNSTACK END TRQ @V50A2B5 01174000
B EXITS AND EXIT @V50A2B5 01175000
SPACE 1 01176000
USTKALL2 EQU * @V50A2B5 01177000
BAL R6,USTKST UNSTACK START TRQ @V50A2B5 01178000
BAL R6,USTKEN UNSTACK END TRQ @V50A2B5 01179000
L R6,=A(DMKPRGMC) SEE IF ALREADY ON @V50A2B5 01180000
ICM R6,B'1111',0(R6) THROUGH THIS LOAD @V50A2B5 01181000
BNZ EXITS YES, SO EXIT @V50A2B5 01182000
BAL R6,CPEXSTRT START IT VIA CPEXBLOK @V50A2B5 01183000
B EXITS AND EXIT @V50A2B5 01184000
DROP R10 @V50A2B5 01185000
EJECT 01186000
TIMVL DS 0D @VMD0138 01187000
DC CL8' ' @VMD0138 01188000
TIMESTRT DC CL8' ' @VMD0138 01189000
TIMEEND DC CL8' ' @VMD0138 01190000
SET24 DC X'000141DD76000000' @VMD0138 01191000
*********************************************************************** 01192000
* 01193000
* CONSTANTS AND WORK AREAS 01194000
* 01195000
*********************************************************************** 01196000
DS 0F @V2B2638 01197000
SPACE 1 01198000
Q1DROP EQU X'40' QUEUE DROP INDICATOR @V2B2638 01199000
WORK2 DS F @V50A2B5 01200000
MSGSPL EQU * @V50A2B5 01201000
AUTDMSG DC CL19'AUTODISK ' @V50A2B5 01202000
AUTT1MSG DC CL19'START TIME ' @V50A2B5 01203000
AUTT2MSG DC CL19'STOP TIME ' @V50A2B5 01204000
AUTXMSG DC CL19'LIMIT ' @V50A2B5 01205000
AUTUMSG DC CL19'USERID ' @V50A2B5 01206000
AUTCMSG DC CL19'FILE CLASS ' @V50A2B5 01207000
NOSPLMSG EQU (*-MSGSPL)/19 @V50A2B5 01208000
AUTBMSG DC CL19'BUFFERS ' @V50A2B5 01209000
SPLMSG DC C'AUTOMATIC MONITORING INFORMATION FOLLOWS' @V50A2B5 01210000
SPLMSGLN EQU *-SPLMSG @V50A2B5 01211000
ENAB DC CL8'ENABLED ' @V50A2B5 01212000
DISAB DC CL8'DISABLED' @V50A2B5 01213000
TIMVAL DS 0D @V50A2B5 01214000
DC CL8' ' @V50A2B5 01215000
BUFMSG EQU * @V50A2B5 01216000
BUFFLD DS XL8 BUFFERS @V50A2B5 01217000
DC C' RECORDS WRITTEN TO SPOOL FILE ' @V50A2B5 01218000
FILID DS XL4 @V50A2B5 01219000
BUFMSGSZ EQU *-BUFMSG @V50A2B5 01220000
STOP DC C'STOP ' @V50A2B5 01221000
NOSTOP DC C'NOSTOP' @V50A2B5 01222000
NOENAB DC C'CANNOT ENABLE - MONITOR IN SHUTDOWN - REENTER ENABLE' 01222300
NOENABLN EQU *-NOENAB @VA09647 01222600
LTORG @V2B2638 01223000
EJECT 01224000
COPY EQU @V2B2638 01225000
COPY ALLOC @V2B2638 01226000
PSA @V2B2638 01227000
COPY MONBLOKS @V2B2638 01228000
COPY VMBLOK @V2B2638 01229000
COPY SAVE @V2B2638 01230000
COPY IOBLOKS @V2B2638 01231000
COPY IOER @V2B2638 01232000
COPY CORE @V2B2638 01233000
COPY DEVTYPES @V2B2638 01234000
COPY RBLOKS @V2B2638 01235000
COPY TIMER @V2B2638 01236000
COPY SPOOL @V50A2B5 01237000
END 01238000