CPV TITLE 'DMKCPV (CP) VM/370 - RELEASE 6' 00001000
*. 00002000
* MODULE NAME - 00003000
* 00004000
* DMKCPV 00005000
* 00006000
* FUNCTION - 00007000
* 00008000
* TO HANDLE A, B, AND C PRIVILEGE CLASS COMMANDS THAT ARE NOT 00009000
* SUBSETS OF NON-PRIVILEGED COMMANDS 00010000
* 00011000
* ATTRIBUTES - 00012000
* 00013000
* REENTRANT, PAGEABLE, CALLED VIA SVC 00014000
* 00015000
* ENTRY POINTS 00016000
* 00017000
* DMKCPVEN - ENABLE SYSTEM LOW SPEED LINES 00018000
* DMKCPVAE - ENABLE SYSTEM LOW SPEED LINES DURING SYSTEM RESTART 00019000
* DMKCPVDS - DISABLE SYSTEM LOW SPEED LINES 00020000
* DMKCPVLK - LOCK USER PAGES INTO MAIN STORAGE 00021000
* DMKCPVUL - UNLOCK USER PAGES PREVIOUSLY LOCKED 00022000
* DMKCPVAC - CREATE AN ACCOUNTING RECORD FOR THE SPECIFIED 00023000
* USER OR FOR ALL USERS ON THE SYSTEM 00024000
* DMKCPVAA - TO PUNCH ACCOUNTING CARDS 00025000
* 00026000
* ENTRY CONDITIONS - 00027000
* 00028000
* GPR9 = ADDRESS OF COMMAND LINE BUFFER 00029000
* GPR11 = ADDRESS OF CALLER'S VMBLOK 00030000
* GPR12 = ADDRESS OF ENTRY POINT 00031000
* GPR13 = ADDRESS OF SAVEAREA 00032000
* 00033000
* EXIT CONDITIONS - 00034000
* 00035000
* NORMAL - 00036000
* GPR2 = 0 00037000
* 00038000
* ERROR - 00039000
* GPR2 = ERROR MESSAGE CODE NUMBER 00040000
* 00041000
* CALLS TO OTHER ROUTINES - 00042000
* 00043000
* DMKGRFIN - TO ENABLE GRAPHIC DEVICES 00044000
* DMKQCNWT - TO WRITE MESSAGE TO CONSOLE 00045000
* DMKFREE - TO OBTAIN STORAGE 00046000
* DMKSCNAU - TO FIND VMBLOK 00047000
* DMKPTRUL - TO UNLOCK A PAGE 00048000
* DMKFRET - TO RETURN A BLOCK OF STORAGE 00049000
* DMKCVTBH - TO CONVERT BINARY TO HEX 00050000
* DMKSCNRN - GET THE REAL DEVICE TYPE 00051000
* DMKSCNFD - LOCATE THE NEXT ARGUMENT ON THE COMMAND LINE 00052000
* DMKCVTHB - CONVERT HEXADECIMAL ADDRESSES TO BINARY 00053000
* DMKSCNRU -LOCATE THE RDEVBLOK FOR THE SPECIFIED REAL DEVICE 00054000
* DMKPTRAN - LOCATE AND FETCH A PAGE OF VIRTUAL STORAGE 00055000
* DMKACOTM - PRINT USER ACCOUNTING MESSAGE GIVING CONNECT AND 00056000
* CPU TIMES 00057000
* DMKACOFF - CREATE AN ACCOUNTING RECORD FOR A USER 00058000
* DMKACODV - CREATE AN ACCOUNTING RECORD FOR A DEDICATED DEVICE 00059000
* DMKERMSG - TO SEND ERROR MESSAGES TO TERMINAL 00060000
* DMKSCNRD - GET THE REAL DEVICE ADDRESS (CCU) 00061000
* DMKLOKSW - SWITCH TO ANOTHER VMBLOK IF SYSTEM IS AP-MODE 00061100
* 00062000
* EXTERNAL REFERENCES - 00063000
* 00064000
* DMKDSPNP - NUMBER OF PAGES AVAILABLE IN DYNAMIC PAGING 00065000
* AREA. 00066000
* DMKSCHPU - PAGE USAGE COUNT (TOTAL WORKING SET SIZE 00066200
* OF IN-QUEUE USERS). 00066400
* 00067000
* TABLES / WORKAREAS - 00068000
* 00069000
* CORTABLE 00070000
* 00071000
* REGISTER USAGE - 00072000
* 00073000
* GPR0 = LENGTH OF ARGUMENT (RETURNED BY DMKSCNFD) 00074000
* GPR1 = ADDRESS OF ARGUMENT (RETURNED BY DMKSCNFD) 00075000
* GPR2 = PARMS PASSED TO CALLED ROUTINES 00076000
* GPR3 = LENGTH FOR EXECUTED MOVES AND COMPARES 00077000
* GPR4 = INTERNAL LINKAGE (2ND LEVEL) 00078000
* GPR5 = INTERNAL LINKAGE (2ND LEVEL) 00079000
* GPR6-8 NOT USED 00080000
* GPR9 = ADDRESS OF COMMAND LINE BUFFER 00081000
* GPR10 = IOBLOK BASE 00082000
* GPR11 = VMBLOK BASE 00083000
* GPR12 = MODULE BASE 00084000
* GPR13 = SAVEAREA BASE 00085000
* GPR14 = EXTERNAL LINKAGE 00086000
* GPR15 = EXTERNAL LINKAGE 00087000
* 00088000
* OPERATION - 00089000
* 00090000
* THE COMMAND HANDLING ROUTINES IN DMKCPV ARE CALLED FROM DMKCFM 00091000
* AFTER THEIR PRIVILEGE CLASS HAS BEEN VERIFIED 00092000
* THE FORMAT AND OPERATION OF EACH COMMAND IS DESCRIBED IN S 00093000
* SEPARATE COMMAND PROLOGUES BELOW 00094000
*. 00095000
EJECT 00096000
COPY OPTIONS @VA03757 00097000
COPY LOCAL @VA03757 00098000
SPACE 3 00099000
PUNCH 'SPB' @VA03757 00100000
DMKCPV CSECT @VA03757 00101000
MODID DC CL8'DMKCPV' @VA03757 00102000
SPACE 3 00103000
USING PSA,R0 @VA03757 00104000
USING VMBLOK,R11 @VA03757 00105000
USING SAVEAREA,R13 @VA03757 00106000
SPACE 2 00107000
EXTRN DMKSCNFD @VA03757 00108000
EXTRN DMKSCNAU @VA03757 00109000
EXTRN DMKCVTHB @VA03757 00110000
EXTRN DMKSCNRD @VA03757 00111000
EXTRN DMKSCNRU @VA03757 00112000
EXTRN DMKPTRUL @VA03757 00113000
EXTRN DMKACOTM @VA03757 00114000
EXTRN DMKACOFF @VA03757 00115000
EXTRN DMKACODV @VA03757 00116000
EXTRN DMKDSPNP @VA03757 00117000
EXTRN DMKSCHPU @VA04709 00117500
EXTRN DMKCVTBH @VA03757 00118000
EXTRN DMKSCNRN @VA03757 00119000
EXTRN DMKERMSG @VA03757 00120000
EXTRN DMKRNH @VA05061 00120500
EXTRN DMKPTRAN @VA03757 00121000
* DMKPGSPR - RELEASE PAGES IN VIRT=REAL REGION 00122000
EXTRN DMKSTKCP,DMKCNSEN,DMKGRFEN @VA03757 00123000
EXTRN DMKPTRCP,DMKPTRSN @VA08341 00123100
AIF (NOT &VIRREAL).VIRT0 @VA03757 00124000
EXTRN DMKSLC @VA03757 00125000
EXTRN DMKPGSPR @V408246 00126000
.VIRT0 ANOP 00127000
EJECT 00128000
*. 00129000
* SUBROUTINE NAME - 00130000
* 00131000
* DMKCPVEN 00132000
* 00133000
* FUNCTION - 00134000
* 00135000
* TO ENABLE SYSTEM LOW SPEED LINES FOR USER LOGON 00136000
* 00137000
* COMMAND LINE FORMAT - 00138000
* 00139000
* +----------+---------------------------+ 00140000
* | ENABLE | LINE1 LINE2 ... LINEN | 00141000
* | EN | ALL | 00142000
* +----------+---------------------------+ 00143000
* 00144000
* OPERATION - 00145000
* 00146000
* 1. CALL DMKSCNFD TO GET THE NEXT ARGUMENT. IF NONE FOUND, 00147000
* CHECK TO SEE IF ANY ARGUMENTS HAVE BEEN PROCESSED. IF NOT, 00148000
* CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV026E. IF 00149000
* PROCESSING HAS BEEN DONE, EXIT. 00150000
* 2. IF ARGUMENT = 'ALL', GO TO STEP 6. IF NOT, CALL DMKCVTHB 00151000
* TO CONVERT THE ADDRESS TO BINARY. IF CONVERT FAILS, CALL 00152000
* DMKERMSG TO SEND ERROR MESSAGE DMKCPV021E. 00153000
* 3. ISSUE SWITCH TO INSURE PROCESSING CONTINUES ON THE MAIN 00154100
* PROCESSOR IF THE SYSTEM IS IN AP-MODE. CALL DMKSCNRU 00154200
* TO GET THE DEVICE BLOKS. IF THE BLOKS ARE NOT 00154300
* FOUND, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV040E. 00155000
* 4. IF DEVICE IS NOT A TERMINAL, GO TO STEP 8. IF IT IS A 00156000
* DEDICATED LINE, GO TO STEP 10. IF DEVICE IS OFFLINE, GO TO 00157000
* STEP 9. ELSE - CONTINUE. 00158000
* 5. IF THIS IS A DISABLE COMMAND, GO TO THE DISABLE ROUTINE 00159000
* AT LABEL DISASUB VIA A BAL R14. THIS ROUTINE IS DESCRIBED 00160000
* IN THE PROLOG FOR DISABLE. IF AN ENABLE COMMAND, RESET THE 00161000
* RDEVDISB FLAG IN THE RDEVBLOK. IF LINE IS ALREADY ENABLED, 00162000
* GO TO STEP 1. IF NOT,BAL TO THE SUBROUTINE LABELED ENABTERM 00163000
* IN STEP 12. UPON RETURN FROM THIS, GO TO STEP 1. 00164000
* 6. CALL DMKSCNFD TO CHECK FOR ANY EXTRANEOUS ARGUMENT. IF 00165000
* ONE FOUND, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV003E. 00166000
* PICK UP THE DEVICE BLOKS FOR THE NEXT TERMINAL DEVICE. IF 00167000
* THIS IS A DISABLE COMMAND, BAL TO THE DISABLE ROUTINE AT 00168000
* LABEL DISASUB WHICH IS DESCRIBED IN THE PROLOG FOR THE 00169000
* DISABLE COMMAND. WHEN RETURN, GO TO STEP 7. IF THIS IS AN 00170000
* ENABLE COMMAND, RESET THE RDEVDISB FLAG IN THE RDEVBLOK. 00171000
* THEN BAL TO THE ENABLE ROUTINE IN STEP 12. 00172000
* 7. IF THIS IS 'ALL' PROCESS AND THERE ARE MORE DEVICES TO 00173000
* SCAN, GO BACK TO STEP 6. IF COMMAND IS COMPLETLY 00174000
* PROCESSED, CALL DMKQCNWT TO SEND THE 'COMMAND COMPLETE' 00175000
* MESSAGE AND THEN EXIT. 00176000
* 8. SET UP THE INVALID TYPE MESSAGE(DMKCPV006E) AND GO TO 00177000
* STEP 11. 00178000
* 9. SET UP THE OFFLINE MESSAGE(DMKCPV046E) AND GO TO STEP 11. 00179000
* 10. SET UP THE DEDICATED DEVICE(DMKCPV140E) ERROR MESSAGE. 00180000
* 11. CALL DMKERMSG TO SEND THE ERROR MESSAGE. THEN GO BACK 00181000
* TO STEP 1. 00182000
* 12. CALL DMKFREE TO OBTAIN STORAGE FOR A CPEXBLOK. 00183000
* STACK CPEXBLOK FOR DMKCNSEN OR DMKGRFEN TO ENABLE THE 00184000
* SPECIFIED DEVICE. RETURN ON GR9. 00185000
* 00186000
* RESPONSES - 00187000
* COMMAND COMPLETE 00188000
* 00189000
* ERROR MESSAGES - 00190000
* DMKCPV003E INVALID OPTION - (OPTION) 00191000
* DMKCPV006E INVALID DEVICE TYPE - (ADDR) 00192000
* DMKCPV021E RADDR MISSING OR INVALID 00193000
* DMKCPV026E OPERAND MISSING OR INVALID 00194000
* DMKCPV040E DEV (ADDR) DOES NOT EXIST 00195000
* DMKCPV046E (TYPE RADDR) OFFLINE 00196000
* DMKCPV140E (TYPE RADDR) ATTACHED TO (USERID) 00197000
* 00198000
*. 00199000
EJECT 00200000
DMKCPVEN RELOC @VA03757 00201000
MVC SAVEWRK1(4),ZEROES ZERO FLAG FIELD @VA03757 00202000
SPACE 2 00203000
ENABSCAN EQU * SCAN FOR ENABLE / DISABLE CMD @VA03757 00204000
CALL DMKSCNFD FIND ANOTHER ARGUMENT @VA03757 00205000
BNZ NOARG NO MORE ARGUMENTS @VA03757 00206000
MVI SAVEWRK1,X'FF' INDICATE AT LEAST ONE ARG. @VA03757 00207000
* RECEIVED 00208000
CLC 0(3,R1),=C'ALL' WAS ALL SPECIFIED @VA03757 00209000
BE DOALL YES @VA03757 00210000
CL R0,F3 CAN ONLY HAVE UP TO THREE @VA03757 00211000
* CHARACTERS 00212000
BH CPV021 ERROR IF HAVE MORE @VA03757 00213000
CALL DMKCVTHB CONVERT THE ADDRESS @VA03757 00214000
BNZ CPV021 CONVERT FAILED @VA03757 00215000
CALL DMKSCNRU LOCATE REAL BLOKS FOR DEVICE @VA03757 00216000
BNZ CPV040 NOT FOUND @VA03757 00217000
SWITCH CONTINUE PROCESSING ON MAIN PROC @V407508 00217100
USING RDEVBLOK,R8 @VA03757 00218000
CLI RDEVTYPC,CLASTERM TEST FOR TERMINAL CLASS @VA03757 00219000
BE TSTTYP YES, TEST ADAPTER TYPE @VA03757 00220000
CLI RDEVTYPC,CLASGRAF IS IT GRAPHIC TYPE ?? @VA03757 00221000
BNE NOTERM NO, INVALID @VA03757 00222000
TM RDEVTYPE,TYP3066+TYP3277+TYP3284+TYP3278 @V60A6B6 00223000
BNZ TSTDED YES - ENABLE IT @VA03757 00224000
B NOTERM INVALID @VA03757 00225000
TSTTYP CLI RDEVTYPE,TYPTTY SUPPORTED DEVICE TYPE ? @VA03757 00226000
BH NOTERM NO -- ERROR @VA03757 00227000
CLI RDEVTYPE,TYPSDLC SDLC ADAPTER? @VA11139 00227100
BE NOTERM YES, IGNORE IT. @VA11139 00227200
TSTDED TM RDEVFLAG,RDEVENAB IS IT ENABLED? @VA03757 00228000
BO ENADISA YES--GO PROCESS @VA03757 00229000
TM RDEVSTAT,RDEVDED DEDICATE DEVICE? @VA03757 00230000
BO DEDDEV YES INFORM OPERATOR @VA03757 00231000
TM RDEVSTAT,RDEVDISA IS DEVICE NOT AVAILABLE? @VA03757 00232000
BO NOTONLNE YES @VA03757 00233000
ENADISA EQU * @VA03757 00234000
BAL R14,ENABSUB GO ENABLE OR DISABLE THE LINE @VA03757 00235000
B ENABSCAN GO GET NEXT ARGUMENT @VA03757 00236000
EJECT 00237000
DOALL EQU * @VA03757 00238000
CL R0,F3 MUST HAVE THREE AND ONLY THREE @VA03757 00239000
* CHARACTERS 00240000
BNE CPV003 ERROR IF IT ISN'T @VA03757 00241000
SPACE 00242000
CPVCPI EQU * ENTER HERE FOR AUTO RE-ENABLE @VA03757 00243000
LA R4,2 LOAD INCREMENT FOR BXLE LOOP @VA03757 00244000
SR R1,R1 ZERO CHANNEL INDEX @VA03757 00245000
LA R5,30 GPR5 POINTS TO END OF INDEX TABLE@VA03757 00246000
ENABNCH L R10,ARIOCT ADDRESS OF CHANNEL INDICES @VA03757 00247000
LH R6,0(R1,R10) LOAD INDEX OF NEXT CHANNEL @VA03757 00248000
LTR R6,R6 IS CHANNEL ALIVE ? @VA03757 00249000
BM ENABCHI NO, TRY NEXT CHANNEL @VA03757 00250000
A R6,ARIOCH ADDRESS OF RCHBLOK IN GPR6 @VA03757 00251000
USING RCHBLOK,R6 @VA03757 00252000
SR R2,R2 ZERO CONTROL UNIT INDEX COUNT @VA03757 00253000
LA R5,62 END OF CONTROL UNIT INDEX TABLE @VA03757 00254000
ENABNCU LH R7,RCHCUTBL(R2) PICK UP INDEX @VA03757 00255000
LTR R7,R7 IS CONTROL UNIT THERE ? @VA03757 00256000
BM ENABCUI NO TRY NEXT CU @VA03757 00257000
A R7,ARIOCU ADDRESS OF RCUBLOK TO GPR7 @VA03757 00258000
USING RCUBLOK,R7 @VA03757 00259000
SR R3,R3 ZERO INDEX FOR DEV INDEX @VA03757 00260000
LA R5,30 SET R5 TO END OF DEVICE INDEX @VA03757 00261000
* TABLE 00262000
ENABNDEV LH R8,RCUDVTBL(R3) PICK UP INDEX @VA03757 00263000
LTR R8,R8 IS DEVICE THERE ? @VA03757 00264000
BM ENABDVI NO TRY NEXT DEVICE @VA03757 00265000
SLL R8,3(0) CONVERT TO BYTE INDEX @VA03757 00266000
A R8,ARIODV ADDRESS OF RDEVBLOK TO GPR8 @VA03757 00267000
USING RDEVBLOK,R8 @VA03757 00268000
TM RDEVSTAT,RDEVDISA AVAILABLE? @VA03757 00269000
BO ENABDVI NO--SKIP IT @VA03757 00270000
SPACE 00271000
CLI RDEVTYPC,CLASTERM SLOW-SPEED TERMINAL ? @VA03757 00272000
BNE TSTGRAF NO -- CHECK FOR GRAPHIC @VA03757 00273000
CLI RDEVTYPE,TYPTTY CHECK FOR SUPPORTED TYPE @VA03757 00274000
BH ENABDVI NO -- SKIP OVER IT @VA03757 00275000
CLI RDEVTYPE,TYPSDLC SDLC ADAPTER @VA11139 00275100
BE ENABDVI YES, IGNORE IT. @VA11139 00275200
BAL R14,ENABSUB ENABLE OR DISABLE THE LINE @VA03757 00276000
B ENABDVI CONTINUE @VA03757 00277000
SPACE 00278000
TSTGRAF EQU * CHECK FOR SUPPORTED GRAPHIC TERMS@VA03757 00279000
CLI RDEVTYPC,CLASGRAF LOCAL GRAPHIC TERMINAL ? @VA03757 00280000
BNE ENABDVI NO -- SKIP OVER IT @VA03757 00281000
TM RDEVTYPE,TYP3066+TYP3277+TYP3284+TYP3278 @V60A6B6 00282000
BZ ENABDVI NO -- SKIP IT @VA03757 00283000
BAL R14,ENABSUB ENABLE OR DISABLE THIS DEVICE @VA03757 00284000
ENABDVI BXLE R3,R4,ENABNDEV @VA03757 00285000
LA R5,62 LOAD END OF CU TABLE @VA03757 00286000
ENABCUI BXLE R2,R4,ENABNCU @VA03757 00287000
LA R5,30 LOAD END OF CH INDEX TABLE @VA03757 00288000
ENABCHI BXLE R1,R4,ENABNCH @VA03757 00289000
TM SAVEWRK1+2,CPICALL+RNHCALL NEED A MSG? @VA05061 00290100
BNZ ENABEXIT NOT THIS TIME @VA05061 00291100
EJECT 00292000
* 00293000
* WHEN FALL THRU - HAVE CHECKED ALL DEVICES 00294000
* 00295000
ALLDONE EQU * HAVE PROCESSED ALL OF COMMAND @VA03757 00296000
MSG 'COMMAND COMPLETE' REASSURANCE MESSAGE @VA03757 00297000
SENDMSG EQU * @VA03757 00298000
CALL DMKQCNWT,PARM=NORET SEND THE MESSAGE @VA03757 00299000
ENABEXIT EQU * RETURN TO DMKCFM @VA03757 00300000
EXIT , @VA03757 00301000
SPACE 2 00302000
NOARG TM SAVEWRK1,X'FF' ANY ARGUMENTS AT ALL ? @VA03757 00303000
BO ALLDONE YES @VA03757 00304000
B CPV026 NO ARGUMENTS @VA03757 00305000
SPACE 00306000
SERRMSG LA R1,SAVEWRK2 ADDRESS OF FIELDS @VA03757 00307000
ICM R0,14,MODID+3 LOAD MODULE IDENTIFIER @VA03757 00308000
CALL DMKERMSG SEND THE MESSAGE @VA03757 00309000
* DMKERM WILL RETURN DIRECTLY TO DMKCFM INSTEAD OF HERE. 00310000
SPACE 00311000
NOTERM EQU * HAVE NON-TERMINAL DEVICE @VA03757 00312000
CALL DMKCVTBH CONVERT THE ADDRESS BACK TO HEX @VA03757 00313000
STCM R1,7,SAVEWRK2 STICK IT IN WIRK AREA @VA03757 00314000
LA R0,3 FIELD LENGTH @VA03757 00315000
LA R2,6 ERROR CODE @VA03757 00316000
B SERRMSG SEND MESSAGE @VA03757 00317000
SPACE 00318000
NOTONLNE BAL R10,GETYPE GO SET UP TYPE FIELD @VA03757 00319000
LA R0,8 FIELD LENGTH @VA03757 00320000
LA R2,46 ERROR CODE @VA03757 00321000
B SERRMSG @VA03757 00322000
SPACE 00323000
DEDDEV EQU * @VA03757 00324000
BAL R10,GETYPE SET UP TYPE FIELD @VA03757 00325000
L R2,RDEVUSER VMBLOK ADDRESS OF USER @VA03757 00326000
MVC SAVEWRK4+1(8),VMUSER-VMBLOK(R2) MOVE IN USERI @VA03757 00327000
MVI SAVEWRK4,X'00' SEP. FIELDS @VA03757 00328000
LA R0,17 FIELD LENGTH @VA03757 00329000
LA R2,140 ERROR CODE @VA03757 00330000
B SERRMSG ... @VA03757 00331000
SPACE 00332000
GETYPE EQU * DEVELOP TYPE AND RADDR FOR @VA03757 00333000
* ERROR MESSAGE 00334000
CALL DMKCVTBH FIRST GET ADDR @VA03757 00335000
ST R1,SAVEWRK3 AND PUT IN THE MESSAGE @VA03757 00336000
MVI SAVEWRK3,X'00' SEPARATER @VA03757 00337000
CALL DMKSCNRN GET THE REAL NAME @VA03757 00338000
ST R1,SAVEWRK2 SAVE NAME IN WORK AREA @VA03757 00339000
BR R10 RETURN TO CALLER @VA03757 00340000
SPACE 3 00341000
ENABSUB EQU * ENABLE OR DISABLE A DEVICE @VA03757 00342000
CLI RDEVTYPE,TYPSDLC SDLC ADAPTER? @VA11139 00342100
BE NOTERM YES, IGNORE IT. @VA11139 00342200
TM SAVEWRK1+2,DISABLE DISABLE COMMAND ? @VA03757 00343000
BZ ENABLIN NO -- MUST BE ENABLE @VA03757 00344000
TM RDEVFLAG,RDEVENAB IS THIS LINE ENABLED ? @VA03757 00345000
BCR 8,R14 (BZ) NO -- NOTHING NEED BE DONE @VA03757 00346000
OI RDEVFLAG,RDEVDISB SET THE DISABLE FLAG @VA03757 00347000
CLI RDEVTYPC,CLASGRAF IS THIS A GRAPHIC CLASS @VA03757 00348000
BNE ENABCPX NO, ALERT INTERRUPT HANDLER @VA03757 00349000
CLI RDEVTYPE,TYP3284 IS THIS A 3270 PRINTER @VA03757 00350000
BNE ENABCPX NO, ALERT THE INTERRUPT HANDLER @VA03757 00351000
NI RDEVFLAG,X'FF'-RDEVENAB CLEAR ENABLE FLAG @VA03757 00352000
BR R14 RETURN TO IN LINE CODE @VA03757 00353000
ENABLIN EQU * @VA03757 00354000
NI RDEVFLAG,255-RDEVDISB TURN OFF DISABLE FLAG @VA05107 00354500
TM RDEVSTAT,RDEVDED DEDICATED DEVICE? @VA03757 00355000
BOR R14 YES--RETURN @VA03757 00356000
TM SAVEWRK1+2,CPICALL+RNHCALL AUTO RE-ENABLE @VA05061 00357100
BZ ENABDEV NO -- CHECK ALREADY ENABLED @VA03757 00358000
TM RDEVFLAG,RDEVENAB SHOULD WE ENABLE THIS LINE ? @VA03757 00359000
BCR 8,R14 NO -- NOTHING TO BE DONE @VA03757 00360000
TM SAVEWRK1+2,RNHCALL WHO CALLED? @VA05061 00360100
BZ ENCPI MUST HAVE BEEN DMKCPI @VA05061 00360200
CLI RDEVTYPC,CLASGRAF NEED WE GO FURTHER? @VA05061 00360300
BER R14 NO - IT'S A GRAPHICS DEVICE @VA05061 00360400
CH R9,RDEVBASE ON THE PROPER 370X? @VA05061 00360500
BE ENABCPX YES - GO TO IT @VA05061 00360600
BR R14 NO - TRY ANOTHER @VA05061 00360700
ENCPI EQU * @VA05061 00360800
CLI RDEVTYPC,CLASGRAF IS THIS A GRAPHIC CLASS @VA03757 00361000
BNE ENABCPX NO, ALERT INTERRUPT HANDLER @VA03757 00362000
CLI RDEVTYPE,TYP3284 IS THIS A 3270 PRINTER @VA03757 00363000
BNE ENABCPX NO, ALERT INTERRUPT HANDLER @VA03757 00364000
BR R14 RETURN TO IN LINE CODE @VA03757 00365000
ENABDEV EQU * @VA03757 00366000
NI RDEVFLAG,255-RDEVDISB TURN OFF DISABLE FLAG @VA03757 00367000
TM RDEVFLAG,RDEVENAB IS THE LINE ALREADY ENABLED @VA03757 00368000
BCR 1,R14 (BO) YES - NOTHING TO BE DONE @VA03757 00369000
OI RDEVFLAG,RDEVENAB DEVICE IS NOW ENABLED @VA03757 00370000
CLI RDEVTYPC,CLASGRAF IS THIS A GRAPHIC CLASS @VA03757 00371000
BNE ENABCPX NO, ALERT INTERRUPT HANDLER @VA03757 00372000
CLI RDEVTYPE,TYP3284 IS THIS A 3270 PRINTER @VA03757 00373000
BNE ENABCPX NO, ALERT INTERRUPT HANDLER @VA03757 00374000
BR R14 RETURN TO IN LINE CODE @VA03757 00375000
ENABCPX EQU * ALERT THE INTERRUPT HANDLER @VA03757 00376000
CLC RDEVUSER(4),ASYSVM IS THERE AN ACTIVE USER ? @VA03757 00377000
BCR 7,R14 (BNE) YES - NOTHING TO BE DONE @VA03757 00378000
TM RDEVTFLG,RDEVLOG LOGON ALREADY STARTED ? @VA03757 00379000
BCR 1,R14 YES - JUST RETURN @VA03757 00380000
STM R14,R5,BALRSAVE SAVE REGISTERS TEMPORARILY @VA03757 00381000
LA R0,CPEXSIZE @VA03757 00382000
CALL DMKFREE GET FREE STORAGE FOR A CPEXBLOK @VA03757 00383000
USING CPEXBLOK,R1 ... @VA03757 00384000
XC CPEXBLOK(16),CPEXBLOK CLEAR HEADER SECTION @VA03757 00385000
STM R0,R15,CPEXREGS SET REGISTERS FOR DMKCNS, DM @VA03757 00386000
L R2,=A(DMKCNSEN) ENABLE START/STOP TERM @VA03757 00387000
CLI RDEVTYPC,CLASTERM IS THAT THE CORRECT ENTRY ? @VA03757 00388000
BE *+8 YES - @VA03757 00389000
L R2,=A(DMKGRFEN) ENABLE GRAPHICS TERM @VA03757 00390000
ST R2,CPEXADD SET AS EXECUTION ADDRESS... @VA03757 00391000
ST R2,CPEXR12 ...AND AS MODULE BASE ADDRESS @VA03757 00392000
CALL DMKSTKCP STACK BLOCK FOR LATER EXECUTION @VA03757 00393000
LM R14,R5,BALRSAVE DMKSTKCP DOES'NT USE BALRSAVE @VA03757 00394000
BR R14 RETURN TO SCAN ROUTINE @VA03757 00395000
EJECT 00396000
*. 00397000
* 00398000
* SUBROUTINE NAME - 00399000
* 00400000
* DMKCPVAE - ENABLE SYSTEM LOW SPEED LINES FOR SYSTEM RESTART 00401000
* OR 370X FAILURE. 00402100
* 00403000
* OPERATION - 00404000
* 00405000
* 1. SET FLAG (CPICALL OR RNHCALL) IN SAVEWRK1+2 TO 00406100
* INDICATE WHERE CALL ORIGINATED. ISSUE SWITCH TO INSURE 00407150
* PROCESSING CONTINUES ON THE MAIN PROCESSOR IF THE SYSTEM 00407250
* IS IN AP-MODE. THEN ENTER ENABLE 00407350
* ROUTINE AT LABEL CPVCPI. 00408000
* 00409000
* 2. THE ENABLE ROUTINE WILL SCAN ALL TERMINAL AND GRAPHIC 00410000
* RDEVBLOKS. ONLY THE RDEVBLOKS HAVING THE ENABLE 00411000
* FLAG ON WILL BE ENABLED. (THE ENABLE FLAG 00412000
* SET ON BY DMKWRM DURING SYSTEM RESTART) 00413000
* 00414000
* 2A. IF THE CALL CAME FROM DMKRNH, ONLY THOSE EMULATOR 00414100
* LINES ON THE AFFECTED 370X WILL BE ENABLED. 00414200
* RESPONSES - 00415000
* 00416000
* N/A 00417000
* 00418000
* ERROR MESSAGES - 00419000
* 00420000
* N/A 00421000
* 00422000
*. 00423000
SPACE 2 00424000
DMKCPVAE RELOC @VA03757 00425000
MVC SAVEWRK1(4),ZEROES ZERO FLAG FIELD @VA03757 00426000
MVI SAVEWRK1+2,CPICALL CALLED FROM DMKCPI @VA03757 00427000
SWITCH CONTINUE PROCESSING ON MAIN PROC @V407508 00427100
CLC SAVER12(4),=A(DMKRNH) WHO CALLED? @VA05061 00428100
BNE CPVCPI TWAS DMKCPI @VA05061 00428200
SPACE 00428300
* REG 8 CONTAINS A (RDEVBLOK) FOR 370X WHICH HAD PROBLEM 00428400
CALL DMKSCNRD GO GET 'CUU' TYPE ADDRESS @VA05061 00428500
LR R9,R1 PUT IN REG 9 FOR LATER @VA05061 00428600
MVI SAVEWRK1+2,RNHCALL SHOW PROPER CALLER @VA05061 00428700
B CPVCPI JOIN REST OF ENABLE @VA05061 00428800
SPACE 00429000
CPICALL EQU X'80' CALL FROM DMKCPI FLAG @VA03757 00430000
RNHCALL EQU X'40' CALL FROM DMKRNH FLAG @VA05061 00430100
EJECT 00431000
*. 00432000
* SUBROUTINE NAME - 00433000
* 00434000
* DMKCPVDS 00435000
* 00436000
* FUNCTION - 00437000
* 00438000
* TO CAUSE AN ACTIVE LINE TO BE DISABLED AFTER THE CURRENT USER 00439000
* (IF ANY) IS FINISHED WITH IT 00440000
* 00441000
* COMMAND LINE FORMAT - 00442000
* 00443000
* +-----------+-------------------------+ 00444000
* | DISABLE | LINE1 LINE2 ...LINEN | 00445000
* | DISA | ALL | 00446000
* +-----------+-------------------------+ 00447000
* 00448000
* OPERATION - 00449000
* 1. SET FLAG IN SAVEWRK1+2 TO INDICATE A DISABLE OPERATION. 00450000
* ISSUE SWITCH TO INSURE PROCESSING CONTINUES ON THE MAIN 00450100
* PROCESSOR IF THE SYSTEM IS IN AP-MODE. 00450200
* THEN BRANCH TO THE COMMON ROUTINES DESCRIBED IN THE 00451000
* ENABLE PROLOG. 00452000
* 00453000
* RESPONSES - 00454000
* COMMAND COMPLETE 00455000
* 00456000
* ERROR MESSAGE - 00457000
* DMKCPV003E INVALID OPTION - (OPTION) 00458000
* DMKCPV006E INVALID DEVICE TYPE - (ADDR) 00459000
* DMKCPV021E RADDR MISSING OR INVALID 00460000
* DMKCPV026E OPERAND MISSING OR INVALID 00461000
* DMKCPV040E DEV (ADDR) DOES NOT EXIST 00462000
* DMKCPV046E (TYPE RADDR) OFFLINE 00463000
* DMKCPV140E (TYPE RADDR) ATTACHED TO (USERID) 00464000
* 00465000
*. 00466000
SPACE 2 00467000
DMKCPVDS RELOC DISABLE LINE(S) @VA03757 00468000
MVC SAVEWRK1(4),ZEROES ZERO FLAG AREA @VA03757 00469000
MVI SAVEWRK1+2,DISABLE INDICATE DISABLE OPERATION @VA03757 00470000
SWITCH CONTINUE PROCESSING ON MAIN PROC @V407508 00470100
B ENABSCAN DO SAME AS ENABLE EXCEPT WILL @VA03757 00471000
* DISA LINE 00472000
SPACE 00473000
DISABLE EQU X'01' SAVEWRK1+2 FLAG FOR DISABLE CMD @VA07385 00474500
EJECT 00475000
*. 00476000
* 00477000
* SUBROUTINE NAME - 00478000
* 00479000
* DMKCPVLK 00480000
* 00481000
* FUNCTION - 00482000
* 00483000
* TO LOCK INTO REAL MAIN STORAGE SPECIFIED PAGES OF A USER'S 00484000
* VIRTUAL STORAGE SPACE 00485000
* 00486000
* COMMAND LINE FORMAT - 00487000
* 00488000
* +------+--------------------------------------------+ 00489000
* | LOCK | USERID FIRSTPAGE LASTPAGE (MAP) | 00490000
* | | SYSTEM | 00491000
* +------+--------------------------------------------+ 00492000
* 00493000
* OPERATION - 00494000
* 00495000
* 1. CALL DMKSCNFD TO LOCATE THE USERID. IF NONE FOUND, CALL 00496000
* DMKERMSG TO SEND ERROR MESSAGE DMKCPV020E. 00497000
* 2. CALL DMKSCNAU TO GET THE USERID VMBLOK. IF NOT FOUND, CALL 00498000
* DMKERMSG TO SEND ERROR MESSAGE DMKCPV045E. 00499000
* 3. CALL DMKSCNFD TO GET THE FPAGE ARGUMENT. IF NONE IS 00500000
* FOUND, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV033E. IF 00501000
* ONE IS FOUND, CALL DMKCVTHB TO CONVERT THE PAGE NUMBER TO 00502000
* BINARY. IF THE CONVERT FAILS, CALL DMKERMSG TO SEND ERROR 00503000
* MESSAGE DMKCPV004E.IF OK, SAVE THE FPAGE NUMBER. 00504000
* 4. LOCATE AND CONVERT THE LPAGE ARGUMENT IN THE SAME MANNER. 00505000
* 5. VERIFY THAT THE PAGES ARE WITHIN THE USERS STORAGE LIMITS. 00506000
* IF NOT, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV160E. 00507000
* ALSO CHECK THAT THE FIRST PAGE IS EQUAL TO OR LESS THAN 00508000
* THE LAST PAGE. IF NOT, CALL DMKERMSG TO SEND ERROR MESSAGE 00509000
* DMKCPV009E. 00510000
* 6. IF THIS IS AN UNLOCK COMMAND, GO TO THE LABEL 'UNLOCK' 00511000
* TO PROCESS. THIS IS DESCRIBED IN THE PROLOG FOR UNLOCK. 00512000
* IF 'LOCK' CONTINUE WITH NEXT STEP. 00513000
* 7. IF THE PAGE IS NOT IN STORAGE GO TO STEP 8. IF IT IS, 00514000
* FIND THE CORTABLE ENTRY FOR THIS PAGE. IF THE PAGE IS 00515000
* ALREADY LOCKED IN GO TO STEP 9. IF NOT CONTINUE WITH 00516000
* NEXT STEP. 00517000
* 8. TRANS IN THE PAGE AND LOCK. IF THE SYSTEM IS IN AP-MODE 00518100
* AND THE PAGE IS A SHARED PAGE; UNLOCK THE PAGE, CALL 00518200
* DMKERMSG TO ISSUE MESSAGE DMKCPV165I, AND CONTINUE AT 00518300
* STEP 9. OTHERWISE, DECREMENT THE COUNT OF 00518400
* PAGES AVAILABLE, THE USER'S PROJECTED WORKING SET SIZE 00519200
* AND, IF IN QUEUE, THE PAGE USAGE COUNT. 00519400
* 9. IF THE LAST PAGE HAS BEEN PROCESSED, CALL DMKQCNWT TO 00520000
* SEND THE COMMAND COMPLETE MESSAGE AND EXIT. IF MORE PAGES 00521000
* GET THE NEXT PAGE ADDRESS AND GO TO STEP 6. 00522000
* 00523000
* RESPONSES - 00524000
* COMMAND COMPLETE 00525000
* 00526000
* ERROR MESSAGES - 00527000
* DMKCPV004E INVALID HEXLOC - (HEXLOC) 00528000
* DMKCPV009E INVALID RANGE - (RANGE) 00529000
* DMKCPV020E USERID MISSING OR INVALID 00530000
* DMKCPV045E (USERID) NOT LOGGED ON 00531000
* DMKCPV160E HEXLOC (HEXLOC) EXCEEDS STORAGE 00532000
* DMKCPV165I PAGE (HEXLOC) NOT LOCKED; SHARED PAGE 00532100
* 00533000
*. 00534000
SPACE 2 00535000
DMKCPVLK RELOC LOCK USER PAGE INTO CORE @VA03757 00536000
MVI SAVEWRK1,X'00' INDICATE LOCK FUNCTION @VA03757 00537000
LOCKSCAN CALL DMKSCNFD GET USER ID @VA03757 00538000
BNZ CPV020 MISSING ARGUMENT @VA03757 00539000
STM R0,R1,SAVEWRK2 SAVE ARG LENGTH AND ADDRESS @VA03757 00540000
AIF (NOT &VIRREAL).VIRT1 @VA03757 00541000
TM SAVEWRK1,X'01' UNLOCK? @VA05291 00541300
BZ SCANUSER NO.GO SCAN FOR USERID @VA05291 00541700
CLC 0(9,R1),=C'VIRT=REAL' UNLOCKING VIRT=REAL AREA ?@VA03757 00542000
BNE ABBREV SEE IF ABBREVIATION V=R IS USED @VA03757 00543000
CL R0,F9 GREATER THAN NINE CHARACTERS @VA03757 00544000
BH CPV003 YES,INVALID OPTION @VA03757 00545000
B GETBLOK CONTINUE FOR VIRT=REAL @VA03757 00546000
ABBREV CLC 0(3,R1),=C'V=R' V=R SPECIFIED @VA03757 00547000
BNE SCANUSER NO, MUST BE FOR A USERID @VA03757 00548000
CL R0,F3 THREE CHARACTERS INPUTTED @VA03757 00549000
BH SCANUSER NO. CAN'T BE V=R THEN, CAN IT? @VA04681 00550500
GETBLOK L R4,AVMREAL GET VMBLOK OF OWNER OF V=R AREA @VA03757 00551000
LTR R4,R4 IS THE AREA IN USE ? @VA03757 00552000
BP CPV176 IF YES - CAN'T RELEASE IT. @VA03757 00553000
L R2,=A(DMKSLC-4096) WAS IT GENERATED AT LOAD TIME@VA03757 00554000
LTR R2,R2 TEST FOR OPTION @VA03757 00555000
BM CPV202 IF NOT; ITS IMPOSSIBLE TO @VA03757 00556000
* UNLOCK IT. 00557000
L R1,ASYSVM USE THE SYSTEM VMBLOK @V407508 00559100
SWTCHVM OPT=UNLOCK UNLOCK VM & SWITCH TO ASYSVM @V407508 00559200
L R1,F4096 R1 = 1'ST PAGE; R2 = LAST PAGE @VA07236 00560100
CALL DMKPGSPR RELEASE SYSTEM PAGES @V408246 00562000
MVC AVMREAL,F1 IN-USE BY NOBODY @V408246 00564500
L R15,PREFIXB GET PREFIX ADDR OF OTHER PROC @V4M0132 00564600
MVC AVMREAL-PSA(,R15),F1 SET AVMREAL IN BOTH PSA'S @VA07236 00564700
* SET UP SO THAT DMKPTR PAGE SELECTION ROUTINE WILL INCLUDE 00564720
* THESE UNLOCKED V=R PAGES IN ITS SCAN. 00564740
L R1,=A(DMKPTRSN) ADDRESS OF PAGE SELECTION PTRS. @VA08341 00564760
OI 6(R1),VEQRUNLK INDICATE V=R AREA UNLOCKED AND @VA08341 00564780
* TO BE INCLUDED IN PAGE SELECTION SCAN 00564800
L R1,=A(DMKPTRCP) ADDRESS OF FRAME BLOCKS @VA08341 00564820
LA R1,40(R1) POINT TO V=R FULLSCAN BLOCK @VA08341 00564840
L R0,ACORETBL START OF CORE TABLE @VA08341 00564860
A R0,F16 FIRST V=R CORE TABLE ENTRY @VA08341 00564880
BCTR R0,R0 SUBTRACT ONE FOR COMPARE @VA08341 00564900
ST R0,12(R1) STORE IN V=R FULLSCAN BLOCK @VA08341 00564920
L R0,=A(DMKSLC-4096) ADDR. OF LAST V=R PAGE @VA08341 00564940
ST R0,0(R1) SAVE IN V=R FULLSCAN BLOCK @VA08341 00564960
SRL R0,12 GET PAGE NUMBER @VA08341 00564980
SLL R0,4 MULTIPLY BY CORETBL ENTRY LENGTH @VA08341 00565000
A R0,ACORETBL ADD CORE TABLE START ADDRESS @VA08341 00565020
ST R0,4(R1) SAVE CORETBL ENTRY ADDRESS OF @VA08341 00565040
* TOP V=R PAGE IN FULLSCAN1 BLOCK 00565060
L R1,SAVER11 RETURN TO ORIGINAL CALLER @V407508 00565100
SWTCHVM LOCK THIS VMBLOK @V407508 00565200
B ALLDONE SEND RESPONSE MESSAGE. @VA03757 00567000
.VIRT1 ANOP 00568000
SCANUSER CALL DMKSCNAU FIND VMBLOK @VA03757 00569000
BNZ USERNON USER NOT ON @VA03757 00570000
LR R8,R1 SAVE USERS VMBLOK @VA03757 00571000
AIF (NOT &VIRREAL).VIRT1A @VA05290 00571200
CL R8,AVMREAL IS THIS THE V=R USERID ? @VA05290 00571400
BE CPV020 IF YES,CAN'T BE CORRECT @VA05290 00571600
.VIRT1A ANOP 00571800
LOCKSYS DS 0H @VA03757 00572000
CALL DMKSCNFD GET FPAGE ARGUMENT @VA03757 00573000
BNZ CPV033 MISSING ARGUMENT @VA03757 00574000
CL R0,F3 THREE DIGIT MAX @VA03757 00575000
BH CPV033 CAN'T HAVE PAGE THAT SIZE @VA03757 00576000
STM R0,R1,SAVEWRK2 SAVE ARG LENGTH AND ADDRESS @VA03757 00577000
CALL DMKCVTHB CONVERT TO BINARY @VA03757 00578000
BNZ BADPAGE INVALID PAGE NUMBER @VA03757 00579000
LR R4,R1 GPR4 CONTAINS FIRST PAGE @VA03757 00580000
CALL DMKSCNFD GET LPAGE @VA03757 00581000
BNZ CPV033 MISSING ARGUMENT @VA03757 00582000
CL R0,F3 MAX NUM OF DIGITS ALLOWED @VA03757 00583000
BH CPV033 ....... @VA03757 00584000
STM R0,R1,SAVEWRK4 SAVE ARG LEN AND ADDR @VA03757 00585000
CALL DMKCVTHB CONVERT TO BINARY @VA03757 00586000
BNZ BADPAGE1 INVALID PAGE NUMBER @VA03757 00587000
CR R1,R4 IS LAST PAGE LESS THAN FIRST ? @VA03757 00588000
BL BADRANGE INVALID PAGE SEQUENCE @VA03757 00589000
TM SAVEWRK1,X'01' UNLOCK COMMAND? @VA05729 00589050
BO NOCHK YES, BYPASS NO OF DYNAMIC PGS @VA05729 00589150
LR R5,R1 SAVE LAST PAGE NO. @VA05729 00589250
SR R1,R4 GET NO. OF PAGES TO LOCK @VA05729 00589350
A R1,F1 BUMP 1 TO CORRECT NO. PGS @VA05729 00589450
L R3,=A(DMKDSPNP) NO. OF DYNAMIC PGS IN SYSTEM @VA05729 00589550
C R1,0(R3) IS THERE ENOUGH ROOM? @VA05729 00589650
BNL BADRANGE NO, GIVE HIM THE BAD NEWS @V4M0158 00589750
LR R1,R5 PUT BACK AS WE FOUND IT @VA05729 00589850
NOCHK SLL R1,12 FORM ADDRESS @VA05729 00590000
DROP R11 @VA03757 00591000
USING VMBLOK,R8 @VA03757 00592000
L R0,VMSTOR GET VIRTUAL MACHINE SIZE @VA03757 00593000
CL R8,ASYSVM ARE WE LOCKING A SYSTEM PAGE @VA03757 00594000
BNE *+8 NO - R0 ALL SET @VA03757 00595000
L R0,VMSIZE GET SYSTEMS VIRTUAL STORAGE SIZE @VA03757 00596000
CLR R1,R0 IS PAGE WITHIN MACHINE SIZE @VA03757 00597000
BNL CPV160 NO - TAKE BRANCH @VA03757 00598000
DROP R8 @VA03757 00599000
USING VMBLOK,R11 @VA03757 00600000
LR R10,R11 SAVE OPERATORS VMBLOK @VA03757 00601000
LR R5,R1 GPR5 CONTAINS LAST PAGE @VA03757 00605000
SLL R4,12 FORM ADDRESS OF FIRST PAGE @VA03757 00606000
LOCKCHEK TM SAVEWRK1,X'01' IS THIS UNLOCK REQUEST ?? @VA03757 00607000
BO UNLOCK YES. @VA03757 00608000
CALL DMKSCNFD GET MAP OPTION @VA03757 00609000
BNZ LOCKPAGE NOT THERE @VA03757 00610000
LR R2,R0 SET COUNT REGISTER @VA03757 00614000
BCTR R2,R0 DECREMENT FOR EXECUTE @VA03757 00615000
CH R2,F2+2 IS IT 3 CHARS ?? @VA03757 00616000
BNE CPV003 NO, NO GOOD @VA03757 00617000
EX R2,CMAP TEST FOR MAP OPTION @VA03757 00618000
BNE CPV003 INVALID OPTION @VA03757 00619000
OI SAVEWRK1,X'80' INDICTAE MAP @VA03757 00620000
LA R1,LMAPHDR HEADER @VA03757 00621000
LA R0,LMAPHDRL .. @VA03757 00622000
CALL DMKQCNWT,PARM=NORET @VA03757 00623000
LOCKPAGE DS 0H ATTEMPT TO LOCK USER PAGE @V407508 00624100
LR R1,R8 GET ADDRES OF USERS VMBLOK @V407508 00624200
SWTCHVM LOCK THIS VMBLOK @V407508 00624300
LR R1,R4 GET THE VIRTUAL ADDR OF THE PAGE @V407508 00624400
LCTL R1,R1,VMSEG LOAD CONTROL REG 1 @VA03757 00628000
LRA R2,0(,R4) LOAD REAL ADDRESS (IF ANY) @VA03757 00629000
BNZ LOCKTRAN BRANCH IF NOT IN CORE @VA03757 00630000
SRL R2,8 FORM INDEX TO CORETABLE @VA03757 00631000
A R2,ACORETBL CORE TABLE ENTRY @VA03757 00632000
USING CORTABLE,R2 @VA03757 00633000
TM CORFLAG,CORCFLCK IS PAGE ALREADY LOCKED IN ??? @VA03757 00634000
BO MAPCHEK CHECK FOR LOCK MAP @VA03757 00635000
TM SAVEWRK1,X'40' FOOLING WITH THE SYSTEM? @VA03757 00636000
BZ LOCKTRAN NOPE, OK TO CONTINUE @VA03757 00637000
CL R4,APAGCP IS HE IN PAGEABLE CP? @VA10861 00637100
BL MAPCHEK NOPE, RESIDENT PGES ARE ALL SET @VA10861 00637200
CLC CORVM,ASYSVM IS THIS A CP OWNED PAGE? @VA07284 00638100
BNE NOTSYSPG NOPE, NOT A SYSTEM PAGE @VA08031 00639100
B LOCKTRAN HE IS PAGEABLE, LOCK HIM @VA08031 00639700
NOTSYSPG EQU * @VA08031 00639900
CLI CORFPNT,C'F' IS IT A CP FREE PAGE? @VA03757 00640000
BE MAPCHEK YUP, JUST FINE AS IS. @VA03757 00641000
LOCKTRAN LA R2,BRING+DEFER+LOCK USE THESE OPTIONS FOR PAGE @VA03757 00642000
TM SAVEWRK1,X'40' CALL FOR SYSTEM PAGE(S) ? @VA03757 00643000
BZ *+8 NO - OPTIONS OK. @VA03757 00644000
LA R2,SYSTEM(,R2) YES, ADD SYSTEM OPTION @V408246 00645500
CALL DMKPTRAN NOW - LOCK THIS PAGE @VA03757 00646000
LR R6,R2 SAVE REAL ADDRESS @V407508 00646100
SRL R2,8 FORM INDEX INTO CORETABLE @VA03757 00647000
A R2,ACORETBL CORE TABLE TO R2 @VA03757 00648000
USING CORTABLE,R2 @VA03757 00649000
TM CORFLAG,CORCFLCK IS PAGE ALREADY LOCKED IN @VA03757 00650000
BO MAPCHEK CHECK FOR LOCK MAP @VA03757 00651000
TM APSTAT1,APUOPER IS THIS AN AP SYSTEM? @V407508 00651050
BNO LOCKOK NO, CONTINUE NORMALLY @V407508 00651100
TM CORFLAG,CORSHARE IS PAGE A SHARED PAGE? @V407508 00651150
BNO LOCKOK NO, CONTINUE NORMALLY @V407508 00651200
LR R2,R6 RESTORE REAL ADDRESS FOR UNLOCK @V407508 00651250
CALL DMKPTRUL UNLOCK THE SHARED PAGE @V407508 00651300
LR R1,R4 GET VIRTUAL ADDRESS OF PAGE @V407508 00651350
CALL DMKCVTBH CONVERT TO HEX FOR PRINTING @V407508 00651400
STM R0,R1,SAVEWRK2 SAVE CONVERTED VALUE @V407508 00651450
MVC SAVEWRK2(2),=CL2' ' PAD FIELD WITH BLANKS @V407508 00651500
LR R1,R10 GET ADDR OF OPERATORS VMBLOK @V407508 00651550
SWTCHVM SWITCH TO THIS VMBLOK @V407508 00651600
LA R0,8 SET UP LENGTH OF DATA @V407508 00651650
ICM R0,B'1110',MODID+3 INSERT MODULE IDENTIFIER @V407508 00651700
LA R1,SAVEWRK2 GET THE ADDRESS OF DATA @V407508 00651750
L R2,ERMR2 SET UP R2 WITH ERM PARMS @V407508 00651800
CALL DMKERMSG WRITE OUT MESSAGE @V407508 00651850
B ENDCHEK GO CHECK FOR MORE PAGES @V407508 00651900
LOCKOK DS 0H PAGE O.K. TO LOCK @V407508 00651950
OI CORFLAG,CORCFLCK TURN ON CF LOCK BIT @VA03757 00652000
L R1,CORFPNT GET POINTER TO PAGE'S OWNER @V408246 00652100
LH R0,VMPAGES-VMBLOK(,R1) DECREMENT @V408246 00652200
BCTR R0,0 IN-CORE PAGE COUNT @V408246 00652300
LTR R0,R0 VMPAGES TO GO NEGATIVE ? @VA07224 00652320
BM CPV1 YES - ABEND CP @VA07224 00652340
STH R0,VMPAGES-VMBLOK(,R1) @V408246 00652400
TM CORFLAG,CORRSV LOCKING RESERVED PAGE? @V408246 00652500
BO MAPCHEK YES, COUNT ALREADY DECREMENTED @V408246 00652600
DROP R2 @VA03757 00653000
L R3,=A(DMKDSPNP) ADDRESS OF PAGE COUNT @VA03757 00654000
L R1,0(,R3) LOAD COUNT @VA03757 00655000
BCTR R1,0 DECREMENT COUNT @VA03757 00656000
ST R1,0(,R3) STORE BACK @VA03757 00657000
TM VMDSTAT,VMINQ USER IN QUEUE ? @VA04709 00661100
BZ MAPCHEK NO -- LEAVE PAGE USAGE ALONE @VA04709 00661200
L R3,=A(DMKSCHPU) GET PAGE USAGE COUNT @VA04709 00661300
L R1,0(,R3) ... @VA04709 00661400
LTR R1,R1 WILL PAGE USAGE GO NEGATIVE @VA08454 00661420
BNP MAPCHEK YES, ZERO IS MINIMUM COUNT @VA08454 00661440
BCTR R1,0 DECREMENT IT @VA04709 00661500
ST R1,0(,R3) ... AND STORE IT BACK @VA04709 00661600
MAPCHEK TM SAVEWRK1,X'80' MAP WANTED ?? @VA03757 00662000
BZ ENDCHEK NO, CONT @VA03757 00663000
S R2,ACORETBL MINUS BASE @VA03757 00664000
SLL R2,8 FORM REAL ADDRESS @VA03757 00665000
LR R1,R2 FOR CONVERT @VA03757 00666000
CALL DMKCVTBH TO HEX @VA03757 00667000
STM R0,R1,SAVEWRK4 SAVE @VA03757 00668000
LR R1,R4 VIRTUAL ADDRESS @VA03757 00669000
CALL DMKCVTBH HEX @VA03757 00670000
STM R0,R1,SAVEWRK2 SAVE @VA03757 00671000
MVC SAVEWRK2(2),=CL2' ' @VA03757 00672000
MVC SAVEWRK4(2),=CL2' ' @VA03757 00673000
LR R1,R10 GET ADDR OF OPERATORS VMBLOK @V407508 00673100
SWTCHVM SWITCH TO THIS VMBLOK @V407508 00673200
LA R0,16 SIZE @VA03757 00674000
LA R1,SAVEWRK2 TEXT @VA03757 00675000
CALL DMKQCNWT,PARM=NORET @VA03757 00679000
ENDCHEK CR R4,R5 REACHED END YET ? @VA03757 00683000
BL LOCKBUMP NO, GET NEXT PAGE @VA03757 00684000
LR R1,R10 GET ADDR OF OPERATORS VMBLOK @V407508 00685100
SWTCHVM SWITCH TO THIS VMBLOK @V407508 00685200
B ALLDONE . . @VA03757 00688000
LOCKBUMP A R4,F4096 ADD ONE PAGE TO GPR4 @VA03757 00689000
TM SAVEWRK1,X'01' IS IT UNLOCK ?? @VA03757 00690000
BO UNLOCK2 YES, GO UNLOCK THIS PAGE @V407508 00691100
B LOCKPAGE DO LOCK @VA03757 00692000
SPACE 00693000
USERNON LM R0,R1,SAVEWRK2 LEN AND ADDR OF BAD ARG @VA03757 00694000
BC 2,CPV020 USERID LARGER THAN 8 CHAR @VA03757 00695000
AIF (NOT &VIRREAL).VIRT1B @VA05291 00695200
CLC 0(4,R1),=C'V=R ' IS IT LOCK V=R? @VA05702 00695400
BE CPV020 @VA05291 00695600
.VIRT1B ANOP 00695800
CLC 0(7,R1),=CL7'SYSTEM ' IS IT SYSTEM ?? @VA03757 00696000
BNE CPV045 NO, USER NOT ON @VA03757 00697000
L R8,ASYSVM SET SYSTEM VMBLOK @VA03757 00698000
OI SAVEWRK1,X'40' IND WE'RE MESN WITH SYSTEM @VA03757 00699000
B LOCKSYS LOCK @VA03757 00700000
SPACE 2 00701000
CMAP CLC 0(0,R1),=CL3'MAP' EXECUTED COMP @VA03757 00702000
LMAPHDR DC CL16' VIRTPG REALPG' @VA03757 00703000
LMAPHDRL EQU *-LMAPHDR @VA03757 00704000
SPACE 00705000
BADPAGE LM R0,R1,SAVEWRK2 LEN AND ADDR @VA03757 00706000
B CPV004 .... @VA03757 00707000
SPACE 00708000
BADPAGE1 LM R0,R1,SAVEWRK4 LEN AND ADDR @VA03757 00709000
B CPV004 .... @VA03757 00710000
SPACE 00711000
BADRANGE EQU * @VA03757 00712000
LM R2,R3,SAVEWRK2 LEN AND ADDR OF FPAGE @VA03757 00713000
EX R2,MOVEFPG MOVE IN FIRST PAGE NUMBER @VA03757 00714000
LA R1,SAVEWRK2(R2) LOAD ADDRESS OF SEPARATER @VA03757 00715000
MVI 0(R1),X'40' INSERT BLANK @VA03757 00716000
LM R4,R5,SAVEWRK4 LEN AND ADDR OF LPAGE @VA03757 00717000
EX R4,MOVELPG MOVE IN LAST PAGE @VA03757 00718000
LA R0,1(R2,R4) FIELD LENGTH @VA03757 00719000
LA R1,SAVEWRK2 FIELD ADDRESS @VA03757 00720000
B CPV009 ... @VA03757 00721000
SPACE 1 00721100
ABEND 1 VMPAGES NEGATIVE - TERMINATE CP @VA07224 00721200
SPACE 1 00721300
SPACE 00722000
MOVEFPG MVC SAVEWRK2(0),0(R3) EXECUTED MOVE @VA03757 00723000
MOVELPG MVC 1(0,R1),0(R5) EXECUTED MOVE @VA03757 00724000
SPACE 00724100
ERMR2 DC A(X'80C900A5') REG 2 FOR CALL TO DMKERMSG @V407508 00724200
EJECT 00725000
*. 00726000
* 00727000
* SUBROUTINE NAME - 00728000
* 00729000
* DMKCPVUL 00730000
* 00731000
* FUNCTION - 00732000
* 00733000
* TO UNLOCK PAGES LOCKED BY OPERATOR COMMAND 00734000
* 00735000
* COMMAND LINE FORMAT - 00736000
* 00737000
* +--------+------------------------------------------+ 00738000
* | UNLOCK | USERID FIRSTPAGE LASTPAGE | 00738500
* | | SYSTEM | 00739000
* | | VIRT=REAL | 00739500
* | | V=R | 00740000
* +--------+------------------------------------------+ 00740500
* 00742000
* OPERATION - 00743000
* 00744000
* 1. SET A FLAG TO INDICATE AN UNLOCK COMMAND AND GO TO STEP 1 00745000
* OF THE PROLOG FOR THE LOCK COMMAND. 00746000
* 2. UNLOCK - CONTROL IS GIVEN HERE FOR UNLOCKING A PAGE. IF 00747000
* THIS PAGE HAS NOT BEEN LOCKED VIA THE 'LOCK' COMMAND, GO 00748000
* TO STEP 9 OF THE 'LOCK' PROLOG. ELSE RESET THE CFLOCK 00749000
* FLAG IN THE CORTABLE AND INCREMENT THE PAGE COUNT. CALL 00750000
* DMKPTRUL TO UNLOCK THE PAGE. THEN GO TO STEP 9 OF THE 00751000
* 'LOCK' PROLOG. 00752000
* 3. UNLOCK VIRT=REAL : THE AREA IS CHECKED TO SEE IF IT IS 00753000
* ACTIVE AND ALSO THAT IT IN FACT WAS GENERATED. IF IT 00754000
* IS FREE THE ENTIRE AREA IS GIVEN BACK TO THE CONTROL 00755000
* PROGRAM TO BE USED FOR PAGING. THE COUNT OF FREE 00756000
* PAGES IS UPDATED IN DMKDSP TO REFLECT THE NUMBER OF 00757000
* PAGES NOW AVAILABLE. THE CORE TABLE ENTRIES ARE CHANGED 00758000
* FROM *VR* TO *CP* AND THE LOCK COUNT DECREMENTED TO 0. 00759000
* 00760000
* 00761000
* RESPONSES - 00762000
* COMMAND COMPLETE 00763000
* 00764000
* ERROR MESSAGES - 00765000
* DMKCPV003E INVALID OPTION - (OPTION) 00766000
* DMKCPV004E INVALID HEXLOC - (HEXLOC) 00767000
* DMKCPV009E INVALID RANGE - (RANGE) 00768000
* DMKCPV020E USERID MISSING OR INVALID 00769000
* DMKCPV045E (USERID) NOT LOGGED ON 00770000
* DMKCPV160E HEXLOC (HEXLOC) EXCEEDS STORAGE 00771000
* DMKCPV176E VIRT=REAL AREA IN USE BY <USERID | SYSTEM> 00772000
* DMKCPV202E VIRT=REAL AREA NOT AVAILABLE; INSUFFICIENT STORAGE 00773000
* 00774000
* 00775000
*. 00776000
EJECT 00777000
DMKCPVUL RELOC UNLOCK USER PAGE @VA03757 00778000
MVI SAVEWRK1,X'01' INITIALIZE UNLOCK REQUEST @VA03757 00779000
B LOCKSCAN GO SCAN ARGUMENTS @VA03757 00780000
UNLOCK DS 0H SET UP TO PROCESS UNLOCK COMMAND @V407508 00781100
LR R1,R8 GET ADDR OF USERS VMBLOK @V407508 00781200
SWTCHVM SWITCH TO THIS VMBLOK @V407508 00781300
UNLOCK2 DS 0H USERS VMBLOK ALREADY LOCKED @V407508 00781400
LCTL R1,R1,VMSEG SET UP CR1 @V407508 00781500
TRANS 2,4,OPT=(DEFER) GET REAL PAGE ADDRESS @V408246 00782000
LR R7,R2 SAVE REAL CORE ADDRESS @VA03757 00783000
BNZ ENDCHEK THIS PAGE NOT IN CORE @VA03757 00784000
AIF (NOT &VIRREAL).VIRT2 @VA05486 00784050
L R3,=A(DMKSLC) GET V=R END ADDRESS @VA04959 00784100
LTR R3,R3 CHECK IF V=R SYSGENED @VA04959 00784200
BZ NOTVR V=R NOT DEFINED @VA04959 00784300
CLC AVMREAL(4),F1 WAS V=R AREA UNLOCKED? @V408246 00784400
BE NOTVR YES, CONTINUE @VA04959 00784500
CR R2,R3 FIRST PAGE IN V=R AREA? @VA04959 00784600
BNH CPV204 YES, CANT DO UNLOCK - SEND MSG @VA04959 00784700
NOTVR EQU * @VA04959 00784800
.VIRT2 ANOP 00784900
SRL R2,8 SET UP INDEX INTO CORETBL @VA03757 00785000
A R2,ACORETBL GPR2 NOW POINTS TO CORETABLE @VA03757 00786000
* ENTRY 00787000
USING CORTABLE,R2 @VA03757 00788000
TM CORFLAG,CORCFLCK CONSOLE FUNCTION LOCK BIT ON @VA03757 00789000
* ???? 00790000
BZ ENDCHEK BRANCH IF NO @VA03757 00791000
NI CORFLAG,255-CORCFLCK TURN OFF CF LOCK BIT @VA03757 00792000
L R1,CORFPNT GET POINTER TO PAGE'S OWNER @V408246 00792100
LA R0,1 INCREMENT @V408246 00792150
AH R0,VMPAGES-VMBLOK(,R1) IN-CORE PAGE COUNT @V408246 00792200
STH R0,VMPAGES-VMBLOK(,R1) @V408246 00792250
TM CORFLAG,CORRSV UNLOCKING RESERVED PAGE @V408246 00792300
BO UNLCKX YES, HANDLE VIA RESERVED COUNT @V408246 00792350
L R3,=A(DMKDSPNP) @V408246 00792400
LA R1,1 INCREMENT @V408246 00792450
A R1,0(,R3) COUNT OF PAGEABLE PAGES @V408246 00792500
ST R1,0(,R3) @V408246 00792550
UNLCKX DS 0H @V408246 00792600
DROP R2 @VA03757 00793000
LR R2,R7 RESTORE REAL ADDRESS @VA03757 00794000
CALL DMKPTRUL UNLOCK PAGE @VA03757 00795000
B ENDCHEK GET NEXT PAGE TO UNLOCK @VA03757 00800000
EJECT 00801000
*. 00802000
* 00803000
* SUBROUTINE NAME - 00804000
* 00805000
* DMKCPVAC 00806000
* 00807000
* FUNCTION - 00808000
* 00809000
* TO CREATE ACCOUNTING RECORDS FOR LOGGED ON USERS, AND TO RESET 00810000
* ACCUMULATED ACCOUNTING INFORMATION 00811000
* 00812000
* COMMAND LINE FORMAT - 00813000
* 00814000
* +-----------+-------------------------+ 00815000
* | ACNT | USERID1 ... USERIDN | 00816000
* | ACNT | ALL | 00817000
* +-----------+-------------------------+ 00818000
* 00819000
* OPERATION - 00820000
* 00821000
* 1. CALL DMKSCNFD TO GET ARGUMENT. IF NO ARGUMENTS AT ALL ARE 00822000
* FOUND IN THE COMMAND, CALL DMKERMSG TO SEND ERROR MESSAGE 00823000
* DMKCPV020E. IF ARGUMENT IS OVER 8 CHARACTERS, CALL 00824000
* DMKERMSG TO SEND ERROR MESSAGE DMKCPV007E. IF IT IS AN 00825000
* 'ALL' REQUEST, GO TO STEP 5 - ELSE CONTINUE. 00826000
* 2. CALL DMKSCNAU TO GET USERID VMBLOK. IF NOT FOUND, GO TO 00827000
* STEP 7. IF USER IS NOT RECEIVING ACCOUNTING MESSAGES, 00828000
* GO TO STEP 3. IF RECEIVING ACCOUNTING MESSAGES, CALL 00829000
* DMKACOTM TO SEND MESSAGE. 00830000
* 3. CALL DMKACOFF TO CREATE AN ACCOUNTING RECORD FOR THIS 00831000
* USERID. THEN BAL TO STEP 8 TO CHECK FOR DEDICATED DEVICES. 00832000
* 4. IF THIS IS AN 'ALL' REQUEST, GO TO STEP 6. IF NOT, GO TO 00833000
* STEP 1. 00834000
* 5. CHECK FOR ANY OTHER ARGUMENTS IN THE COMMAND LINE. IF ANY 00835000
* ARE FOUND, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV003E. 00836000
* ELSE - SET FLAG TO INDICATE ALL REQUEST AND CONTINUE. 00837000
* 6. PICK UP THE NEXT VMBLOK IN THE CHAIN. IF MORE TO BE 00838000
* PROCESSED, GO TO STEP 2. ELSE - CALL DMKQCNWT TO SEND THE 00839000
* 'COMMAND COMPLETE' MESSAGE AND EXIT. 00840000
* 7. CALL DMKERMSG TO SEND ERROR MESSAGE DMKCPV045E. THEN GO TO 00841000
* STEP 1. 00842000
* 8. THIS IS A SUBROUTINE WHICH SCANS THROUGH ALL THE VIRTUAL 00843000
* DEVICES. FOR EACH ONE THAT IS DEDICATED OR A 'T' DISK, 00844000
* CALL DMKACODV TO BUILD AN ACCOUNTING RECORD FOR THE 00845000
* DEDICATED DEVICE. WHEN ALL DEVICES FOR THIS USER HAVE 00846000
* BEEN SCANNED, RETURN TO THE CALLER. 00847000
* 00848000
* RESPONSES - 00849000
* COMMAND COMPLETE 00850000
* 00851000
* ERROR MESSAGES - 00852000
* DMKCPV003E INVALID OPTION - (OPTION) 00853000
* DMKCPV007E INVALID USERID - (USERID) 00854000
* DMKCPV020E USERID MISSING OR INVALID 00855000
* DMKCPV045E (USERID) NOT LOGGED ON 00856000
* 00857000
*. 00858000
EJECT 00859000
DMKCPVAC RELOC CREATE ACCOUNTING RECORDS @VA03757 00860000
MVC SAVEWRK1(4),ZEROES ZERO FLAG AREA @VA03757 00861000
LR R10,R11 SAVE OPERATORS VMBLOK ADDRESS @VA03757 00862000
ACNTSCAN CALL DMKSCNFD GET NEXT ARGUMENT @VA03757 00863000
BNZ ACNTNARG NO MORE - GO CLEAN UP @VA03757 00864000
CL R0,F8 CHECK ON THE ARGUMENT @VA03757 00865000
BH CPV007A TAKE ERROR BRANCH IF MORE THAN 8 @VA03757 00866000
CL R0,F3 IS ARG LENGTH 3? @VA03757 00867000
BNE NOTAL NOPE, CANT BE 'ALL' THEN @VA03757 00868000
CLC 0(3,R1),=C'ALL' IS IT 'ALL' @VA03757 00869000
BE ACNTALL GO DO ALL @VA03757 00870000
NOTAL OI SAVEWRK1,X'80' FLAG AS 'USERID . . .' SEQ. @VA03757 00871000
NOTALL EQU * @VA03757 00872000
STM R0,R1,SAVEWRK8 SAVE ARGUMENT LENGTH AND ADDRESS @VA03757 00873000
CALL DMKSCNAU FIND USERS VMBLOK @VA03757 00874000
BNZ ACNTNUSE USER NOT IN SYSTEM @VA03757 00875000
SWTCHVM SWITCH TO USERS VMBLOK @V407508 00876100
ACNTLOFF TM VMRSTAT,VMLOGOFF+VMLOGON IS THE USER LOGING @VA03757 00879000
BNZ ACNTNUSE YES- GO TELL THE OPERATOR @VA03757 00880000
TM VMMLEVEL,VMMACCON IS USER RECEIVING ACCOUNT @VA03757 00881000
* MESSAGES 00882000
BZ ACNTRECB NO, JUST BUILD ACCOUNT RECORDS @VA03757 00883000
CALL DMKACOTM GO TELL USER @VA03757 00884000
ACNTRECB CALL DMKACOFF CREATE AN ACCOUNTING RECORD @VA03757 00885000
BAL R9,ACNTDED GO CHEK FOR DEDICATED DEVICES @VA03757 00886000
L R9,SAVEREGS+36 RESTORE REG 9 TO ADR. OF @VA03757 00887000
* COMMAND LINE 00888000
TM SAVEWRK1,X'40' IS THIS AN 'ALL' REQUEST? @VA03757 00889000
BO ACNTBUMP YES GO GET NEXT USER @VA03757 00890000
B ACNTSCAN NO GO GET NEXT ARGUMENT @VA03757 00891000
SPACE 2 00892000
ACNTALL EQU * @VA03757 00893000
TM SAVEWRK1,X'80' IS NON-ALL CASE ACTIVE? @VA03757 00894000
BO NOTALL YES, PROCESS 'ALL' AS A USER @VA03757 00895000
OI SAVEWRK1,X'40' FLAG 'ALL' ACTIVE @VA03757 00896000
LR R10,R11 SAVE THE OPERATORS VMBLOK ADDRESS@VA03757 00897000
B ACNTLOFF DO ACCOUNTING FOR THE OPERATOR @VA03757 00898000
SPACE 00899000
ACNTBUMP DS 0H GO TO NEXT VMBLOK @V407508 00900100
L R1,VMPNT GET ADDRESS OF NEXT VMBLOK @V407508 00900200
SWTCHVM SWITCH TO NEXT VMBLOK @V407508 00900300
CR R10,R11 HAVE WE COMPLETED THE CYCLE ? @VA03757 00903000
BNE ACNTLOFF NO - GO PROCESS THIS USER @VA03757 00904000
SPACE 3 00905000
ACNTNARG EQU * @VA03757 00906000
LR R1,R10 GET CALLERS VMBLOK ADDRESS @V407508 00907100
SWTCHVM SWITCH BACK TO THIS VMBLOK @V407508 00907200
TM SAVEWRK1,X'C0' IS ANYTHING ACTIVE? @VA03757 00910000
BZ CPV020 NOPE, ERROR @VA03757 00911000
B ALLDONE SOMETHING WAS, OK @VA03757 00912000
SPACE 2 00913000
CPV007A LR R11,R10 RESTORE VMBLOK POINTER @VA03757 00914000
B CPV007 AND GO SEND ERROR MESSAGE @VA03757 00915000
SPACE 00916000
ACNTNUSE EQU * @VA03757 00917000
TM SAVEWRK1,X'40' IS 'ALL' ACTIVE? @VA03757 00918000
BO ACNTBUMP YES - BYPASS MESSAGE @VA03757 00919000
LR R1,R10 GET CALLERS VMBLOK ADDRESS @V407508 00920100
SWTCHVM SWITCH BACK TO THIS VMBLOK @V407508 00920200
LA R2,045 ERROR CODE @VA03757 00923000
LM R0,R1,SAVEWRK8 LOAD ARGUMENT LENGTH AND ADDRESS @VA03757 00924000
ICM R0,14,MODID+3 INSERT MODULE ID @VA03757 00925000
CALL DMKERMSG SEND MESSAGE @VA03757 00926000
* 00927000
* ERMSG WILL RETURN TO DMKCFM, NOT HERE. 00928000
* 00929000
SPACE 2 00930000
ACNTDED SR R1,R1 ZERO INDEX FOR CHANNEL @VA03757 00931000
LA R4,2 LOAD INCREMENT REG @VA03757 00932000
LA R5,30 LOAD END OF TABLES @VA03757 00933000
ACNTNCH LH R6,VMCHTBL(R1) NEXT CHANNEL INDEX @VA03757 00934000
LTR R6,R6 DOES THIS CHAN. EXIST ? @VA03757 00935000
BM ACNTCHI NO - TRY NEXT CHAN. @VA03757 00936000
A R6,VMCHSTRT ADDRESS OF VCHBLOK TO R6 @VA03757 00937000
USING VCHBLOK,R6 @VA03757 00938000
SR R2,R2 ZERO INDEX FOR CONTROL UNITS @VA03757 00939000
ACNTNCU LH R7,VCHCUTBL(R2) LOAD NEXT CONTROL UNIT @VA03757 00940000
LTR R7,R7 DOES IT EXIST ? @VA03757 00941000
BM ACNTCUI NO - GO TRY NEXT @VA03757 00942000
A R7,VMCUSTRT ADDRESS OF VMCUBLOK @VA03757 00943000
USING VCUBLOK,R7 @VA03757 00944000
SR R3,R3 ZERO INDEX FOR DEVICES @VA03757 00945000
ACNTNDEV LH R8,VCUDVTBL(R3) GET NEXT DEVICE @VA03757 00946000
LTR R8,R8 DOES IT EXIST ? @VA03757 00947000
BM ACNTDEVI NO - GO TRY NEXT @VA03757 00948000
A R8,VMDVSTRT ADDRESS OF VMDEVBLOK @VA03757 00949000
USING VDEVBLOK,R8 @VA03757 00950000
TM VDEVSTAT,VDEVDED IS THIS A DEDICATED DEVICE ? @VA03757 00951000
BO ACNTCALL BRANCH IF IT IS @VA03757 00952000
CLI VDEVTYPC,CLASDASD IS THIS A DASD DEVICE ?? @VA03757 00953000
BNE ACNTDEVI NO -- GO GET NEXT DEVICE @VA03757 00954000
TM VDEVFLAG,VDEVTDSK 'T' DISK ???? @VA03757 00955000
BZ ACNTDEVI NO - GO GET NEXT DEVICE @VA03757 00956000
SPACE 00957000
ACNTCALL EQU * @VA03757 00958000
CALL DMKACODV BUILD AN ACCOUNTING CARD FOR @VA03757 00959000
* THE DEVICE 00960000
ACNTDEVI BXLE R3,R4,ACNTNDEV @VA03757 00961000
ACNTCUI BXLE R2,R4,ACNTNCU @VA03757 00962000
ACNTCHI BXLE R1,R4,ACNTNCH @VA03757 00963000
SPACE 00964000
* WHEN FALL THRU - HAVE SCANNAD ALL DEVICES FOR THIS USER 00965000
BR R9 RETURN TO CALLER @VA03757 00966000
********************************************************************** 00967000
EJECT 00968000
********************************************************************* 00969000
* 00970000
* SUBROUTINE NAME - 00971000
* DMKCPVAA 00972000
* 00973000
* FUNCTION - 00974000
* 00975000
*. 00976000
* USERID. 00977000
* 00978000
* OPERATION - 00979000
* 00980000
* DMKCPVAA DOES THE FOLLOWING TO GENERATE ACCOUNT RECORDS 00981000
* FOR THE USER: 00982000
* 00983000
* 1. DMKCPVAA GIVES CONTROL TO DMKACO TO MOVE THE USERID, 00984000
* ACCOUNT NUMBER AND DISTRIBUTION NUMBER INTO THE RECORD 00985000
* PROVIDING A POINTER EXIST FOR THE USER ACCOUNTING BLOCK. 00986000
* IF THE USER ACCOUNTING BLOCK POINTER (VMACOUNT) IS ZERO, 00987000
* THAN THE USERID, ACCOUNT NUMBER AND DISTRIBUTION NUMBER 00988000
* ARE MOVE INTO THE RECORD FROM THE VMBLOK AND THE RECORDS 00989000
* ARE PUNCH FOR THE USER THAT GAVE CONTROL TO DMKHVC. 00990000
* 00991000
* 2. ONCE DMKACO RETURNS CONTROL TO DMKCPVAA, THE DEVICE 00992000
* ACCOUNTING CARDS ARE PUNCH. AFTERWARD, CONTROL IS RETURN 00993000
* TO DMKHVC TO RELEASE THE STORAGE FOR THE USER ACCOUNTING 00994000
* BLOCK IF ONE EXIST. 00995000
* 00996000
* 00997000
* RESPONSES - 00998000
* N/A 00999000
* 01000000
* ERROR MESSAGES - 01001000
* N/A 01002000
*. 01003000
********************************************************************** 01004000
SPACE 2 01005000
DMKCPVAA RELOC @VA03757 01006000
CALL DMKACOFF GO CREATE AN ACCOUNTING CARD @VA03757 01007000
BAL R9,ACNTDED GO CHECK FOR DEDICATED DEVICES @VA03757 01008000
EXIT @VA03757 01009000
EJECT 01010000
CPV003 LA R2,3 ERROR CODE @VA03757 01011000
B CALLERM .... @VA03757 01012000
SPACE 01013000
CPV004 LA R2,4 ERROR CODE @VA03757 01014000
B CALLERM .... @VA03757 01015000
SPACE 01016000
CPV007 LA R2,7 ERROR CODE @VA03757 01017000
B CALLERM @VA03757 01018000
SPACE 01019000
CPV009 LA R2,9 ERROR CODE @VA03757 01020000
B CALLERM .... @VA03757 01021000
SPACE 01022000
CPV020 LA R2,20 ERROR CODE @VA03757 01023000
B NOVAR ... @VA03757 01024000
SPACE 01025000
CPV021 LA R2,21 ERROR CODE @VA03757 01026000
B NOVAR .... @VA03757 01027000
SPACE 01028000
CPV026 LA R2,26 ERROR CODE @VA03757 01029000
B NOVAR ..... @VA03757 01030000
SPACE 01031000
CPV033 LA R2,33 ERROR CODE @VA03757 01032000
B NOVAR .... @VA03757 01033000
SPACE 01034000
CPV040 EQU * @VA03757 01035000
CALL DMKCVTBH CONVERT ADDR BACK TO HEX @VA03757 01036000
N R1,X40FFS BLANK HIGH BYTE @VA03757 01037000
SLR R0,R0 ZERO GPR0 @VA03757 01038000
LA R2,40 ERROR CODE @VA03757 01039000
B CALLERM .... @VA03757 01040000
SPACE 01041000
CPV045 LA R2,45 ERROR CODE @VA03757 01042000
B CALLERM .... @VA03757 01043000
SPACE 01044000
CPV160 LM R0,R1,SAVEWRK4 LEN AND ADDRESS OF BAD ARG. @VA03757 01045000
LA R2,160 ERROR CODE @VA03757 01046000
B CALLERM .... @VA03757 01047000
SPACE 01048000
AIF (NOT &VIRREAL).VIRT3 @VA03757 01049000
CPV176 LA R2,176 ERROR CODE @VA03757 01050000
DROP R11 @VA03757 01051000
C R4,F1 AREA UNLOCKED? @V408246 01051100
BNE *+8 NO @V408246 01051200
L R4,ASYSVM YES, GET SYSTEM USERID @V408246 01051300
USING VMBLOK,R4 @VA03757 01052000
MVC SAVEWRK2(8),VMUSER USERID WHO OWNS VIRT=REAL @VA03757 01053000
* AREA 01054000
DROP R4 @VA03757 01055000
USING VMBLOK,R11 @VA03757 01056000
LA R0,8 LENGHT OF DATA PASSED @VA03757 01057000
LA R1,SAVEWRK2 AND ITS LOCATION. @VA03757 01058000
B CALLERM SEND MSG DMKCPV176E @VA03757 01059000
.VIRT3 ANOP 01060000
SPACE 01061000
AIF (NOT &VIRREAL).VIRT4 @VA03757 01062000
CPV202 LA R2,202 ERROR CODE @VA03757 01063000
B NOVAR ... @VA03757 01064000
.VIRT4 ANOP 01065000
SPACE 1 01065100
AIF (NOT &VIRREAL).VIRT5 @VA05486 01065150
CPV204 DS 0H @V4M0205 01065210
CHARGE SWITCH,10 SWITCH TO OPERATOR @V4M0205 01065220
.VIRT5 ANOP 01065700
SPACE 3 01066000
SPACE 01067000
NOVAR SLR R1,R1 ZIP THE PARM REG @VA03757 01068000
CALLERM ICM R0,14,MODID+3 INSERT THE MODULE INDENT. @VA03757 01069000
CALL DMKERMSG SEND THE MESSAGE @VA03757 01070000
* 01071000
* ERMSG WILL RETURN DIRECTLY TO DMKCFM -- NOT HERE -- 01072000
* 01073000
SPACE 2 01073100
VEQRUNLK EQU X'40' V=R AREA HAS BEEN UNLOCKED BY @VA08341 01073200
* THE OPERATOR AND IS AVAILABLE TO THE 01073300
* PAGE SELECTION SCAN PROCESS 01073400
EJECT 01074000
LTORG @VA03757 01075000
EJECT 01076000
PSA @VA03757 01077000
COPY CORE @VA03757 01078000
COPY DEVTYPES @VA03757 01079000
COPY EQU @VA03757 01080000
COPY IOBLOKS @VA03757 01081000
COPY IOER @VA03757 01082000
COPY MONBLOKS @VA03757 01083000
COPY NETWORK @VA03757 01084000
COPY RBLOKS @VA03757 01085000
COPY SAVE @VA03757 01086000
COPY SAVTABLE @VA03757 01087000
COPY SYSTBL @VA03757 01088000
COPY VBLOKS @VA03757 01089000
COPY VMBLOK @VA03757 01090000
END 01091000