LOH TITLE 'DMKLOH (CP) VM/370 - RELEASE 6' 00001000
ISEQ 73,80 VALIDATE SEQUENCING OF SOURCE 00002000
*. 00003000
* MODULE NAME - 00004000
* 00005000
* DMKLOH - ISSUE MESSAGES TO A USER (OR THE OPERATOR). 00006000
* 00007000
* FUNCTION - 00008000
* 00009000
* TO CONSTRUCT AND SEND LOGON RELATED MESSAGES TO A USER 00010000
* (OR THE OPERATOR). 00011000
* 00012000
* ATTRIBUTES - 00013000
* 00014000
* REENTRANT, PAGEABLE, CALLED VIA SVC 00015000
* 00016000
* ENTRY POINTS - 00017000
* 00018000
* DMKLOHON - ISSUE LOGON RELATED MESSAGES. 00019000
* 00020000
* DMKLOHRC - TO UPDATE VMBLOKS TO RECONNECT A DISCONNECTED USER 00020100
* (SEE COMMENT BLOCK IN DMKLOHRC FOR VITAL INFO). 00020200
* 00020300
* 00020400
* DMKLOHSS - MSS DISK ALLOCATION AFTER A MOUNT @VA09593 00020500
* 00020600
* ENTRY CONDITIONS - 00021000
* 00022000
* GPR 2 = CONTENTS OF DMKLOG'S SAVEWRK1 00023000
* GPR 9 = ADDRESS OF FREE STORAGE 00024000
* GPR 11 = ADDRESS OF USER'S VMBLOK 00025000
* GPR 12 = ADDRESS OF DMKLOGON OR DMKLOGOP 00026000
* GPR 13 = ADDRESS OF STANDARD SAVE AREA 00027000
* 00028000
* EXIT CONDITIONS - 00029000
* 00030000
* APPROPRIATE LOGON MESSAGES SENT TO USER AND SYSTEM OPERATOR. 00031000
EJECT 00032000
* CALLS TO OTHER ROUTINES - 00033000
* 00034000
* DMKCQRFI - SEND MESSAGE TO USER FOR SPOOL FILES IF ANY 00035000
* DMKCVTBD - CONVERT FROM BINARY TO PRINTABLE DECIMAL 00036000
* DMKCVTBH - CONVERT FROM BINARY TO PRINTABLE HEX 00037000
* DMKCVTDT - OBTAIN DATE-TIME 00038000
* DMKFRET - RETURN UNUSED VMBLOK TO FREE STORAGE 00039000
* DMKSCNRD - TO CONVERT TERMINAL DEVICE ADDRESS TO CCU FORM 00040000
* DMKQCNWT - SEND MESSAGE TO USER TERMINAL 00041000
* DMKERMSG - SEND ERROR MESSAGE TO USER @VA09593 00041050
* DMKSCNRU - FIND RDEVBLOK FOR A DEDICATED DEVICE @VA09593 00041100
* DMKSCNVU - FIND VIRTUAL DEVICE BLOCKS @VA09593 00041150
* DMKSTKCP - STACK A CPEXBLOK FOR DMKDSP @VA09593 00041200
* DMKVDSAT - ATTACH A VIRTUAL DEVICE @VA09593 00041250
* DMKSCHRT - TO PREVENT WAKE UP TO A DEV (REMOVE TRQBLOK 00041450
* FROM QUEUE). 00041650
* EXTERNAL REFERENCES - 00042000
* 00043000
* DMKSYSTI - TIME ZONE IDENTIFIER 00044000
* 00045000
* TABLES / WORK AREAS - 00046000
* 00047000
* NONE 00048000
EJECT 00049000
* REGISTER USAGE - 00050000
* 00051000
* GPR 8 = ADDRESS OF TERMINAL RDEVBLOK, AND OTHER USE 00052000
* GPR 9 = ADDRESS OF FREE STORAGE ADDRESS 00053000
* GPR 11 = ADDRESS OF USER'S VMBLOK 00054000
* GPR 12 = BASE REGISTER 00055000
* GPR 13 = ADDRESS OF STANDARD SAVE AREA 00056000
* 00057000
* GPRS 0-1, 3-7, 10, AND 14-15 ARE WORK REGISTERS 00058000
* 00059000
* NOTES - 00060000
* 00061000
* NONE. 00062000
* 00063000
* OPERATION - 00064000
* 00065000
* IF THE USER WAS RUNNING DISCONNECTED, A MESSAGE IS SENT TO 00066000
* THE USER THAT HE HAS BEEN RECONNECTED AND TO THE 00067000
* OPERATOR THAT THE GIVEN USER HAS BEEN RECONNECTED. 00068000
* 00069000
* THE DATE/TIME AT WHICH THE SYSTEM LOG MESSAGE (LOGMSG) 00070000
* WAS GENERATED OR MOST RECENTLY REVISED IS THEN TYPED AT 00071000
* THE USER'S TERMINAL, EXCEPT FOR AUTOLOG USERS WITH NO REAL 00072000
* TERMINAL. 00073000
* 00074000
* IF ANY LINES OF THE SYSTEM LOG MESSAGE START WITH AN '*' 00075000
* (INDICATING THEY ARE OF A HIGH PRIORITY), THEY ARE TYPED 00076000
* AT THE USER'S TERMINAL AT THIS POINT. (OTHERWISE, MERELY 00077000
* DATE/TIME OF THE LOG MESSAGE IS GIVEN.) 00078000
* 00079000
* THEN, IF ANY FILES EXIST IN HIS READER, PRINTER, 00080000
* OR PUNCH, THIS INFORMATION IS TYPED AT HIS TERMINAL. 00081000
* 00082000
* NEXT, THE 'READY AT ... TIME ... DATE' MESSAGE IS SENT 00083000
* TO THE USER, AND A MESSAGE IS SENT TO THE SYSTEM OPERATOR 00084000
* INDICATING THAT THE USER HAS BEEN LOGGED ON. 00085000
* 00085100
* 00085200
* CHANGE ACTIVITY - 00085300
* 00085400
* 1. APAR 13723: SPLIT OF DMKLOG AT LABEL LOG07A. CODE PLACED 00085500
* INTO DMKLOHRC. 07-24-81 00085600
* 00085700
* 00085800
* 00086000
EJECT 00087000
* MESSAGES - 00088000
* 00089000
* NORMAL RESPONSES: 00090000
* 00091000
* 'LOGMSG - HH:MM:SS TID WEEKDAY MM/DD/YY' 00092000
* 00093000
* 'LOGON AT HH:MM:SS TID WEEKDAY MM/DD/YY' 00094000
* OR 00095000
* 'RECONNECTED AT HH:MM:SS TID WEEKDAY MM/DD/YY' 00096000
* 00097000
* MESSAGES SENT TO SYSTEM OPERATOR: 00098000
* 00099000
* 'TYPE RADDR LOGON AS USERID USERS = NNN' 00100000
* OR 00101000
* 'TYPE RADDR RECONNECT USERID USERS = NNN' 00102000
*. 00103000
EJECT 00104000
COPY OPTIONS 00105000
COPY LOCAL 00106000
SPACE 3 00107000
DMKLOH CSECT 00108000
SPACE 00109000
DC CL8'DMKLOH' PAGEABLE MODULE IDENTIFIER @V200820 00110000
SPACE 00111000
EXTRN DMKSYSTI,DMKCVTBD,DMKCVTDT,DMKCQRFI,DMKCVTAB 00112000
EXTRN DMKSCNRD,DMKCVTBH 00113000
EXTRN DMKERMSG,DMKSCNRU,DMKSCNVU @VA09593 00113050
EXTRN DMKSTKCP,DMKVDSAT @VA09593 00113100
EXTRN DMKSCHRT @VA13723 00113500
SPACE 00114000
USING PSA,R0 FOR ALL ENTRIES 00115000
USING VMBLOK,R11 " 00116000
USING DMKLOH,R12 00117000
USING SAVEAREA,R13 " 00118000
EJECT 00119000
DMKLOHON RELOC LOGON A USER 00120000
ST R2,SAVEWRK1 SAVE FLAGS SET BY DMKLOG 00121000
ST R3,SAVEWRK8 SAVE AUTOLOG CMD ISSUER'S VMBLOK @VMD0139 00121200
* ADDRESS 00121400
ST R4,SAVEWRK9 SAVE VMBLOK ADDR OF DMKLOG'S @VMD0139 00121600
* CALLER 00121800
LOH01 DS 0H 00122000
* HANDLE SYSTEM LOG MESSAGE: 00123000
L R4,ASYSLC REFERENCE SYSLOC INFO @VM03066 00124000
USING SYSLOCS,R4 ... 00125000
SR R7,R7 CLEAR R7 (FOR EX-MVC USE) @VA04247 00126000
L R3,DMKSYSLG GET POINTER TO 1ST LOG MESSAGE BLOCK 00127000
LTR R3,R3 ANYTHING THERE AT ALL ? 00128000
BZ LOH05 IF NOT, FORGET THE WHOLE THING. 00129000
LR R10,R9 SET R10 FROM R9 TO CONSTRUCT MESSAGE 00130000
MVC 0(L'NR1,R10),NR1 SET: LOGMSG - 00131000
MVC L'NR1(8,R10),DMKSYSTM TIME 00132000
LA R10,L'NR1+8(,R10) (BUMP R10 FOR 'LOGMSG - ' & TIME) 00133000
MVC 0(5,R10),BLANKS BLANK-FILL WHERE TIME-ZONE WILL GO 00134000
L R15,=A(DMKSYSTI) GET ADDR OF TIME ZONE IDENTIFIER 00135000
MVC 1(3,R10),0(R15) MOVE TO MSG 00136000
LA R10,5(,R10) AND ADVANCE TO WHERE TO PUT WEEKDAY 00137000
IC R7,DMKSYSLW+1 GET NUMBER OF BYTES (LESS 1) IN WEEKDAY 00138000
LA R6,DMKSYSLW+2 POINT AT THE WEEKDAY FOR THE LOG MSG, 00139000
EX R7,MVCMSG MOVE IN THE WEEKDAY 00140000
LA R10,1(R10,R7) BUMP R10 TO NEXT FIELD 00141000
MVI 0(R10),C' ' PUT IN A BLANK 00142000
MVC 1(8,R10),DMKSYSDT NOW PUT IN THE DATE 00143000
LA R0,9(,R10) COMPUTE END OF FILLED-IN MESSAGE 00144000
LR R1,R9 R1 = BEGINNING 00145000
SR R0,R1 NOW WE HAVE THE BYTE-COUNT 00146000
CALL DMKQCNWT,PARM=NORET TYPE LOGMSG DATE + TIME @V200820 00147000
* 00148000
LOH03 LA R1,8(,R3) GET ADDRESS OF ACTUAL MESSAGE 00149000
CLI 0(R1),C'*' IS 1ST CHAR = '*' (= "IMPORTANT") ? 00150000
BNE LOH04 IF NOT, DON'T BOTHER WITH IT. 00151000
LH R0,4(,R3) GET LENGTH OF LOG MSG LINE 00152000
CALL DMKQCNWT,PARM=NORET TYPE "IMPORTANT" LOGMSG LINE@V200820 00153000
LOH04 L R3,0(,R3) POINT TO NEXT LOG MESSAGE BLOCK (IF ANY) 00154000
LTR R3,R3 IS THERE ANOTHER ? 00155000
BNZ LOH03 TRF IF YES - KEEP CHECKING THEM. 00156000
LOH05 DS 0H LOG MESSAGE FINISHED; CONTINUE: 00157000
SPACE 00158000
* HANDLE MESSAGE RE SPOOLED FILES: 00159000
LA R2,1(0) GR2 NONZERO = NO MSG IF NO FILES @V200820 00160000
CALL DMKCQRFI SUB TO FORMAT FILES MESSAGE @V200930 00161000
SPACE 00162000
* CONSTRUCT AND SEND READY OR RECONNECT MESSAGE TO USER: 00163000
TM SAVEWRK1,AUTOLOG AUTOLOG COMMAND? @V305535 00164000
BZ LOH09 @V305535 00165000
STCK DMKSYSCK GET TOD CLOCK VALUE @V305535 00166000
BC 3,DOWNWEGO CLOCK NOT FUNCTIONING @VA04301 00167000
MVC VMTIMEON,DMKSYSCK SAVE WORD ZERO @V305535 00168000
MVC 0(LAMOP,R9),AMOP BASE MESSAGE WITHOUT USER IDS @V305535 00169000
MVC AMOP2-AMOP(8,R9),VMUSER NEW USER ID @V305535 00170000
L R1,DMKSYSNM NO. OF USERS @V305535 00171000
AL R1,F1 BUMP COUNT OF LOGGED-ON USERS @VA04247 00172000
ST R1,DMKSYSNM ... AND STORE ... @VA04247 00173000
C R1,DMKSYSMU @V305535 00174000
BNH *+8 LESS THAN HIGH WATER MARK @V305535 00175000
ST R1,DMKSYSMU SAVE HIGH WATER MARK @V305535 00176000
CALL DMKCVTBD CONVERT NO. USERS TO DECIMAL @V305535 00177000
STCM R1,7,AMOP3-AMOP(R9) NO. OF USERS NOW LOGGED ON @V305535 00178000
LA R0,LAMOP AUTO LOGON MESSAGE LENGTH @V305535 00179000
TM SAVEWRK1,PSWRDCK ALOGON COMMAND? @V305535 00180000
BO LOH08 YES @V305535 00181000
MVC AMOP4-AMOP(8,R9),=CL8'SYSTEM' AUTO LOGON BY @V305535 00182000
* SYSTEM 00183000
B LOH14 @V305535 00184000
LOH08 DS 0H @V305535 00185000
L R10,SAVEWRK8 GET CMD ISSUERS VMBLOK @VM03066 00186000
MVC AMOP4-AMOP(8,R9),VMUSER-VMBLOK(R10) AUTO LOGON @V305535 00187000
* BY USER 00188000
B LOH14 @V305535 00189000
SPACE 3 00190000
LOH09 DS 0H @V305535 00191000
LR R10,R9 SET R10 FROM R9 TO CONSTRUCT MESSAGE 00192000
TM SAVEWRK1,RECON RECONNECTED OR READY ? 00193000
BZ LOH10 TRF IF READY. 00194000
MVC 0(L'NR3,R10),NR3 SET RECONNECTED MESSAGE 00195000
LA R10,L'NR3(,R10) BUMP R10 FOR NEXT ADDRESS 00196000
B LOH11 00197000
LOH10 MVC 0(L'NR2,R10),NR2 READY AT MSG 00198000
LA R10,L'NR2(,R10) ... 00199000
LOH11 LR R2,R10 REMEMBER IN R2 WHERE TIME WILL GO 00200000
MVI 8(R2),C' ' BLANK AFTER TIME 00201000
L R15,=A(DMKSYSTI) GET ADDR OF TIME ZONE IDENTIFIER 00202000
MVC 9(3,R2),0(R15) MOVE TO MSG 00203000
MVI 12(R2),C' ' BLANK AFTER TIME ZONE IDENTIFIER 00204000
LA R10,13(,R10) SKIP OVER THE TIME 00205000
IC R7,DMKSYSDW+1 GET NUMBER OF BYTES (LESS 1) IN WEEKDAY 00206000
LA R6,DMKSYSDW+2 POINT AT THE WEEKDAY 00207000
EX R7,MVCMSG MOVE IN THE WEEKDAY 00208000
LA R10,1(R10,R7) BUMP TO NEXT FIELD 00209000
MVI 0(R10),C' ' PUT IN A BLANK 00210000
LA R1,1(,R10) POINT AT WHERE TO PUT THE DATE 00211000
CALL DMKCVTDT MOVE DATE AND TIME INTO THE RIGHT PLACES 00212000
TM SAVEWRK1,RECON RECONNECT ? 00213000
BO LOH12 YES (LEAVE VMTIMEON AS IS). 00214000
STCK DMKSYSCK GET CURRENT TOD VALUE @VM08883 00215000
BC 12,CLOCKOK IS CLOCK FUNCTIONING? @VA04301 00216000
DOWNWEGO GOTO DMKCVTAB CLOCK DAMAGED...ABEND CVT001 @VA04301 00217000
CLOCKOK EQU * @VA04301 00218000
MVC VMTIMEON,DMKSYSCK SAVE WORD ZERO @VM08883 00219000
LOH12 LA R0,9(,R10) COMPUTE END OF FILLED-IN MESSAGE 00220000
LR R1,R9 R1 = BEGINNING 00221000
SR R0,R1 NOW WE HAVE THE BYTE-COUNT 00222000
CALL DMKQCNWT,PARM=0 SEND READY/RECON MSG, WAIT @V200820 00223000
CH R2,=H'12' LINE FAILURE DURING WRITE ? @V200820 00224000
BE LOHEXIT YES - JUST EXIT RAPIDLY @V200820 00225000
SPACE 00226000
* CONSTRUCT AND SEND READY OR RECONNECT MESSAGE TO SYSTEM OPERATOR: 00227000
MVC 0(LMOP,R9),MOP2 MOVE CANNED MESSAGE TO FREE STORAGE 00228000
MVC LMOP3(8,R9),VMUSER INSERT THE USERID @VA04247 00229000
L R1,DMKSYSNM GET COUNT OF LOGGED ON USERS @VA04247 00230000
TM SAVEWRK1,RECON USER RECONNECTING? @VA04247 00231000
BO LOH13 YES....CONTINUE @VA04247 00232000
MVC 0(L'MOP1,R9),MOP1 'LOGON' INSTEAD OF 'RECONN' @VA04247 00233000
AL R1,F1 BUMP COUNT OF LOGGED-ON USERS @VA04247 00234000
ST R1,DMKSYSNM ...AND STORE @VA04247 00235000
C R1,DMKSYSMU IS THIS A NEW MAX. OF USERS EVER ON ? 00236000
BNH LOH13 NOPE. 00237000
ST R1,DMKSYSMU YES, STORE NEW MAX. USERS EVER ON. 00238000
DROP R4 (THRU WITH SYSLOCS NOW) 00239000
LOH13 CALL DMKCVTBD CONVERT NO. OF USERS TO DECIMAL 00240000
STCM R1,7,LMOP5(R9) STORE IN PRINTOUT 00241000
L R8,VMTERM TERMINAL RDEVBLOK ADDRESS @V200820 00242000
LR R1,R11 (VMBLOK ADDRESS IN GR1, ALSO) @V200820 00243000
BAL R4,TERMADD GET 'TYPE RADDR' IN GR0-1 @V200820 00244000
STM R0,R1,0(R9) SET AT HEAD OF OPERATOR MESSAGE @V200820 00245000
LA R0,LMOP LENGTH OF MESSAGE, 00246000
LOH14 DS 0H @V305535 00247000
LR R1,R9 ADDRESS 00248000
CALL DMKQCNWT,PARM=NORET+OPERATOR SEND MSG TO OPERATOR 00249000
TM SAVEWRK1,AUTOLOG+PSWRDCK AUTOLOG COMMAND? @VM03066 00250000
BNO EXITR NOPE, RETURN TO DMKLOG @VMD0139 00251500
TM VMOSTAT-VMBLOK(R10),VMSYSOP IS THIS SYS OPER? @VM03066 00252000
BO EXITR YES, RETURN TO DMKLOG @VMD0139 00253500
LR R1,R10 R1 GETS ISSUERS VMBLOK, THEN @V407593 00254000
* THEN SWITCH TIMERS AND LOCKS FROM R11 TO R1 00255000
BAL R5,SWVM GO TO SWITCH VMBLOKS @V4M0193 00256000
LR R1,R9 ADDRESS OF MSG FROM ABOVE @V4075A0 00257000
LA R0,LAMOPU LENGTH OF USER MESSAGE @VM03066 00258000
CALL DMKQCNWT,PARM=NORET TELL HIM ABOUT IT @VM03066 00259000
L R1,SAVEWRK9 SWITCH ACTIVE VMBLOK (TMRS.. @VMD0139 00260500
* LOCKS) TO SAVER11 00261000
BAL R5,SWVM GO TO SWITCH VMBLOKS @V4M0193 00262000
EXITR DS 0H @VMD0139 00262100
SR R2,R2 WHEN R2=0, DMKLOG WILL CONTINUE @VMD0139 00262200
ST R2,SAVER2 SAVE R2 IN DMKLOG'S R2 @VMD0139 00262300
B LOHEXITR RETURN TO DMKLOG 00263000
SPACE 00264000
LOHEXIT DS 0H 00265200
TM SAVEWRK1,R9FRE FREE STORAGE TO BE RETURNED? @VMD0139 00265300
LA R2,4 WHEN R2=4, DMKLOG WILL EXIT @VMD0139 00265400
ST R2,SAVER2 SAVE R2 IN DMKLOG'S R2 @VMD0139 00265500
BZ LOHEXTA @V408246 00266000
LA R0,UDBFSIZE*2+2 THE SIZE WE'VE BEEN USING INTO R0, 00267000
LR R1,R9 ADDRESS INTO R1 FROM R9, 00268000
CALL DMKFRET AND GIVE IT BACK (WITH THANKS, OF COURSE) 00269000
LOHEXTA DS 0H @V408246 00270000
C R11,SAVEWRK9 SAME VMBLOK? @VMD0139 00271100
BE LOHEXITR YES @V408246 00272000
L R1,SAVEWRK9 NO, SWITCH VMBLOKS @VMD0139 00273100
* TO CALLERS VMBLOK 00274000
BAL R5,SWVM GO TO SWITCH VMBLOKS @V4M0193 00275000
LOHEXITR EXIT REALLY EXIT. 00276000
SPACE 1 @V4M0148 00277000
SWVM DS 0H @V4M0148 00278000
SWTCHVM SWITCH VMBLOKS @V4M0193 00279000
BR R5 RETURN TO CALLER @V4M0193 00280000
EJECT 00281000
* EXECUTED INSTRUCTIONS: 00282000
MVCMSG MVC 0(*-*,R10),0(R6) MSG (R6) TO FREE STRG (R10); R7 = CNT 00283000
* 00284000
SPACE 2 00285000
TERMADD EQU * ROUTINE TO BUILD 'TYPE RADDR' INFO @V200820 00286000
LTR R8,R8 IS THERE A TERMINAL RDEVBLOK ? @V200820 00287000
BNP TERMNOD NO -- SETUP DEFAULT TYPE, RADDR @V200820 00288000
USING RDEVBLOK,R8 @V200820 00289000
CLI RDEVTYPC,CLASSPEC IS THIS A 370X NCP TERMINAL @V200820 00290000
BE TERMRID YES - GO FIND 'VMTRMID' @V200820 00291000
CLI RDEVTYPC,CLASTERM IS THIS A TERMINAL CLASS @V2D3931 00292000
BNE *+12 NO, BYPASS TEST FOR BISYNC LINE @V2D3931 00293000
TM RDEVTYPE,TYPBSC IS THIS A BISYNC LINE ? @V2D3931 00294000
BO TERMRID YES, ... @V2D3931 00295000
TM RDEVADD,RDEVLDEV Is this an LDEV? HRC065DK 00295100
BO TERMLDEV Yes, special handling HRC065DK 00295200
CALL DMKSCNRD GET 'CCU' ADDRESS FROM RDEVBLOK @V200820 00296000
CALL DMKCVTBH CONVERT TO PRINTABLE EBCDIC @V200820 00297000
ICM R1,B'1000',BLANKS GET A HIGH-ORDER BLANK IN R1@V200820 00298000
L R0,=C'LINE DSC' PUT 'LINE' IN GR0 @V200820 00299000
CLI RDEVTYPC,CLASTERM IS IT REALLY A LINE ? @V200820 00300000
BCR 8,R4 YES - RETURN AS IS @V200820 00301000
L R0,=C'GRAF' MUST BE A LOCAL GRAPHICS TERMINAL@V200820 00302000
BR R4 @V200820 00303000
TERMLDEV EQU * HRC065DK 00303100
LH R1,RDEVADD Get the LDEV address HRC065DK 00303200
N R1,F4095 Keep only the dev num HRC065DK 00303300
CALL DMKCVTBH Make it displayable HRC065DK 00303400
ICM R1,8,=C'L' Insert LDEV identifier HRC065DK 00303500
L R0,=C'GRF ' Use short GRAF name HRC065DK 00303600
BR R4 Return with R0/R1 filledHRC065DK 00303700
TERMRID EQU * SETUP 'DEV XXXX' FOR 370X TERMS @V200820 00304000
LH R1,VMTRMID-VMBLOK(,R1) RESOURCE FIELD @V200820 00305000
CALL DMKCVTBH CONVERT TO PRINTABLE EBCDIC @V200820 00306000
L R0,=C'DEV ' PUT CORRECT TYPE IN GR0 @VM03066 00307000
BR R4 RETURN @VM03066 00308000
TERMNOD LM R0,R1,=C'LINE DSC' DEFAULT FOR DISC MACHINE @VM03066 00309000
BR R4 RETURN @VM03066 00310000
DROP R8 NO MORE RDEVBLOK @VM03066 00311000
EJECT 00311100
SPACE 2 00311150
*********************************************************************** 00311200
* * 00311250
* DMKLOHRC - TO UPDATE VMBLOKS TO RECONNECT A DISCONNECTED USER * 00311300
* * 00311350
*---------------------------------------------------------------------* 00311400
* * 00311450
* * 00311500
* ENTRY CONDITIONS: * 00311550
* * 00311600
* R1 - VMBLOK ADDRESS TO RECONNECT USER * 00311650
* R2 - LOGON COMMAND ARGUMENTS * 00311700
* * 00311750
* R6 - CONTAINS A BRANCH ADDRESS REQUIRED BY DMKLOG. THIS * 00311800
* ADDRESS MUST BE SAVED IF R6 IS TO BE USED AND RESTORED * 00311850
* AT EXIT TIME FROM THIS ROUTINE. * 00311900
* * 00311950
* * 00312000
* EXIT CONDITIONS: * 00312050
* * 00312100
* R1 - CONTAINS A RETURN CODE OF 0, 4, OR 8. THIS RETURN * 00312150
* IS REQUIRED BY DMKLOG FOR BRANCHING PURPOSES. * 00312200
* * 00312250
* R6 - CONTAINS THE RESTORED VALUE IT ORIGINALLY HAD UPON * 00312300
* ENTRY INTO THIS MODULE. * 00312350
* * 00312400
* * 00312450
* * 00312500
* * 00312550
* OPERATION - DMKLOHRC * 00312600
* * 00312650
* THE VMBLOK BELONGING TO THE DISCONNECTED USER IS REVISED TO USE * 00312700
* THE TERMINAL REAL DEVICE BLOCK POINTED TO BY THE 'CURRENT' GPR 11, * 00312750
* AND OTHER REVISIONS MADE AS NEEDED. THEN THE VMBLOK POINTED TO BY * 00312800
* GPR 11 IS RELEASED FROM THE SYSTEM, AND THE OTHER VMBLOK IS USED * 00312850
* THEREAFTER. * 00312900
*---------------------------------------------------------------------* 00312950
SPACE 2 00313000
DMKLOHRC RELOC @VA13723 00313050
LR R10,R1 PARM TO PERM REG @VA13723 00313100
ST R2,SAVEWRK1 STORE SAVEWRK1 INDICATORS @VA13723 00313150
TM SAVEWRK1,AUTOLOG+PSWRDCK AUTOLOG CMD? @VA05283 00313200
BNZ LOG07AB YES--BYPASS THE FOLLOWING CHECKS @VA05283 00313250
L R8,VMTERM TERMINAL RDEVBLOK ADDRESS @V200820 00313300
LTR R8,R8 IS TERMINAL STILL THERE? @VA04453 00313350
BZ LOHEXIT4 NO--ABORT RECONNECT @VA13723 00313400
USING RDEVBLOK,R8 @V200820 00313450
ST R8,VMTERM-VMBLOK(,R10) SET IN "OLD" USER VMBLOK @V200820 00313500
CLI RDEVTYPC,CLASSPEC LOGON VIA 370X NCP ? @V200820 00313550
BE LOG07AA YES - DIFFERENT @V200820 00313600
OI RDEVSTA3,RDEVATSW PREVENT ATTN DURING SWITCH @VA10462 00313650
SWITCH MAKE SURE WE'RE ON THE IO PROC @V4075A0 00313700
NI RDEVSTA3,X'FF'-RDEVATSW ALLOW ATTN AFTER SWITCH @VA10462 00313750
CLI RDEVTYPC,CLASTERM IS THIS A TERMINAL CLASS @V2D3931 00313800
BNE *+12 NO, CONTINUE @V2D3931 00313850
TM RDEVTYPE,TYPBSC IS THIS A BISYNC LINE @V2D3931 00313900
BO LOG07AA YES, ... @V2D3931 00313950
TM RDEVTFLG,RDEVTRQ 'NOT ACCEPTED', ETC. TIMER? @VA13200 00313955
BZ SETUSER NONE, CONTINUE @VA13200 00313960
NI RDEVTFLG,X'FF'-RDEVTRQ RESET FLAG BIT @VA13200 00313965
L R1,RDEVAIRA GET ADDRESS OF TRQBLOK @VA13200 00313970
LTR R1,R1 IS ADDRESS VALID? @VA13200 00313975
BZ SETUSER NO; ALREADY TAKEN CARE OF @VA13200 00313980
CALL DMKSCHRT RESET ACTIVE TIMER REQUEST @VA13200 00313985
SETUSER DS 0H @VA13200 00313990
ST R10,RDEVUSER RESET RDEVBLOK POINTER TO VMBLOK @V200820 00314000
L R15,RDEVAIOB CHECK FOR AN ACTIVE IOBLOK @V200820 00314050
LTR R15,R15 IS THERE ONE RIGHT NOW ? @V200820 00314100
BNP LOG07AB NO -- GO GET RID OR R11 VMBLOK @V200820 00314150
ST R10,IOBUSER-IOBLOK(,R15) IOBLOK PTR TO VMBLOK @V200820 00314200
B LOG07AB @V200820 00314250
LOG07AA EQU * RECONNECT VIA 3705 TERMINAL @V200820 00314300
LH R7,VMTRMID RESOURCE I.D. FROM LOGON VMBLOK @V200820 00314350
STH R7,VMTRMID-VMBLOK(,R10) SET INTO GR10 VMBLOK @V200820 00314400
N R7,F4095 EXTRACT THE ACTUAL RESOURCE I.D. @V200820 00314450
MH R7,=AL2(NICSIZE*8) COMPUTE INDEX FOR NICBLOK @V200820 00314500
AL R7,RDEVNICL GR7 = ADDRESS OF TERMINAL NICBLOK@V200820 00314550
USING NICBLOK,R7 @V200820 00314600
ST R10,NICUSER RESET NICBLOK POINTER TO VMBLOK @V200820 00314650
TM NICSTAT,NICTRQ 'NOT ACCEPTED' TIMER, ETC. SET? @VA13200 00314655
BZ LOG07AB NO, CHECK IF IN 'SLEEP' @VA13200 00314660
NI NICSTAT,X'FF'-NICTRQ NO TIMER SET ANYMORE! @VA13200 00314665
L R1,NICATRB ADDRESS OF SCHEDULED TRQBLOK @VA13200 00314670
LTR R1,R1 IS TRQBLOK STILL AROUND? @VA13200 00314675
BZ LOG07AB NO; BEEN FRET'D; SKIP DEQUEUE @VA13200 00314680
CALL DMKSCHRT DEQUEUE: VMBLOK GOING AWAY. @VA13200 00314685
DROP R7 @VA12982 00314700
LOG07AB EQU * RELEASE GR11 VMBLOK @V200820 00314750
TM VMOSTAT,VMSLEEP LOGONXXX ASLEEP ??? @VA07417 00314800
BNO LOG07AC NO, REAL FAST SKIP @VA07417 00314850
L R1,VMDELAY GET POSSIBLE TRQBLOK POINTER @VA07417 00314900
LTR R1,R1 WAS SLEEP WITH TIME INTERVAL ?? @VA07417 00314950
BNP LOG07AC NO, STILL EASY @VA07417 00315000
CALL DMKSCHRT PREVENT WAKEUP TO LOGONXXX @VA07417 00315050
LA R0,TRQBSIZE AND FRET TRQBLOK @VA07417 00315100
CALL DMKFRET @VA07417 00315150
LOG07AC EQU * LOGONXXX TRQBLOKS CLEANED UP @VA07417 00315200
L R5,ASYSVM LET R5 START FROM THE SYSTEM VMBLOK 00315250
L R3,VMPNT-VMBLOK(,R5) AND R3 STARTS WITH THE FIRST USER 00315300
L R7,VMPNT GET POINTER TO NEXT VMBLOK 00315350
LOG07B C R11,RUNUSER DOES RUNUSER BY ANY CHANCE POINT TO US ? 00315400
BNE LOG08 NO (WE DIDN'T THINK IT WOULD). 00315450
ST R5,RUNUSER YES, USE SYSTEM VMBLOK (NOT FRET'D BLOCK) 00315500
LOG08 LR R4,R3 REMEMBER PREVIOUS BLOCK 00315550
L R3,VMPNT-VMBLOK(,R3) GET PNTR TO NEXT BLOCK 00315600
CLR R3,R11 IS IT US ? 00315650
BNE LOG08 IF NOT, KEEP LOOKING. 00315700
ST R7,VMPNT-VMBLOK(,R4) PATCH CHAIN TO LEAVE US OUT 00315750
ST R4,VMPNT-VMBLOK(,R5) STORE NEW ANCHOR FOR CHAIN IN SYSVM 00315800
L R1,VMDFTPNT GET ADDRESS OF DEFERRED TASK @V4M0148 00315850
LTR R1,R1 IS THERE ONE? @V4M0148 00315900
BZ NODFT NO, SKIP FRET OF DEFERRED TASK @V4M0148 00315950
LA R0,CPEXSIZE GET SIZE OF DEFERRED TASK @V4M0148 00316000
CALL DMKFRET FRET DEFERRED TASK @V4M0148 00316050
NODFT DS 0H @V4M0148 00316100
LR R1,R11 'NEW' VMBLOK INTO R1 00316150
LR R11,R5 SWITCH TO ASYSVM @V407593 00316200
CHARGE START @V407593 00316250
DROP R11 @V407593 00316300
USING VMBLOK,R10 @V407593 00316350
C R1,STACKVM STACKVM = THIS VMBLOK? @VA09087 00316400
BNE LOGSVM NO - LET IT BE. @VA09087 00316450
MVC STACKVM,ZEROES YES - ZERO THE FIELD @VA09087 00316500
LOGSVM EQU * @VA09087 00316550
TM RDEVTFLG,RDEVTRQ IS THERE A TRQ ? @VA12982 00316600
BZ LOGSVM1 NO...CONTINUE @VA12982 00316650
L R6,RDEVAIRA GET TRQBLOK POINTER @VA12982 00316700
USING TRQBLOK,R6 SET UP TEMP BASE FOR TRQBLOK @VA12082 00316750
C R1,TRQBUSER IS IT FOR PSEUDO VMBLOK ? @VA13723 00316800
BNE LOGSVM1 NO...BRANCH @VA12982 00316850
LR R5,R1 SAVE VMBLOK FOR LATER USE @VA12982 00316900
LR R1,R15 GET READY TO FRET THE TRQBLOK @VA13723 00316950
CALL DMKSCHRT TAKE OFF THE CHAIN @VA12982 00317000
LR R1,R5 RESTORE VMBLOK @VA12982 00317050
ST R10,TRQBUSER UPDATE TRQBLOK USER @VA12982 00317100
NI RDEVTFLG,X'FF'-RDEVTRQ RESET TRQ INDICATOR @VA12982 00317150
DROP R6,R8 @VA12982 00317200
LOGSVM1 DS 0H @VA12982 00317250
LA R0,VMBSIZE NOW RETURN THE ONE WE WON'T BE USING 00317300
CALL DMKFRET TO FREE STORAGE 00317350
ST R10,SAVER11 RETURN RECONNECTED VMBLOK TO @VA15234 00317400
* CALLER 00317500
EJECT 00317600
TM SAVEWRK1,RECON WAS THIS A RECONNECT ? 00317650
BZ LOG8A IF NO, INITIALIZE TIMERS 00317700
DROP R10 @VA15234 00317710
LR R1,R10 SWITCH TO RECONNECTED VMBLOK @VA15234 00317740
USING VMBLOK,R11 @VA15234 00317770
BAL R5,SWVM @VA15234 00317800
NI VMOSTAT,255-VMDISC RESET DISCONNECTED BIT @VA15234 00317830
OI VMRSTAT,VMCFWAIT PUR HIM IN CF WAIT @VA15234 00317860
OI VMOSTAT,VMCF AND FLAG CONS FUNC RUNNING @VA15234 00317890
L R1,VMDELAY CHECK FOR DISCONNECT TRQBLOK @V200820 00317950
LTR R1,R1 IS THERE A PENDING INTERRUPT ? @V200820 00318000
BNP LOHEXIT0 NO -- CONTINUE RECONNECT PROCESS @VA13723 00318050
CALL DMKSCHRT REMOVE TRQBLOK FROM REQUEST QUEUE@V200820 00318100
LA R0,TRQBSIZE SIZE OF BLOCK IN DOUBLE-WORDS @V200820 00318150
CALL DMKFRET RETURN TRQBLOK TO FREE STORAGE @V200820 00318200
SLR R1,R1 @V200820 00318250
ST R1,VMDELAY CLEAR VMBLOK POINTER TO BLOCK @V200820 00318300
NI VMOSTAT,255-VMSLEEP REMOVE USER FROM SLEEP MODE @V200820 00318350
B LOHEXIT0 GO COMPLETE RECONNECT PROCESS @VA13723 00318400
DROP R11 @VA15234 00318450
USING VMBLOK,R10 @VA15234 00318500
LOG8A MVC VMTIMER,=X'FFFFFF00' ... 00318550
* SET VARIOUS FLAGS, ETC. SAME AS DMKBLDVM WOULD HAVE DONE 00318600
OI VMOSTAT,VMCF FLAG AS EXEC. CONS. FUNC.... @VA02059 00318650
OI VMRSTAT,VMCFWAIT PUT IN CF WAIT @VA15234 00318675
OI VMRSTAT,VMLOGON ...LOGGING ON AND... @VA02059 00318700
OI VMMLEVEL,VMMSGON+VMWNGON+VMMCODE+VMMTEXT @VA02059 00318750
OI VMMLVL2,VMMIMSG AND THIS @V2A3663 00318800
MVI VMPSW+1,WAIT ... 00318850
MVC VMVTIME,ZEROES ZERO OUT TOTAL PROBLEM TIME. FOR START 00318900
MVC VMTMOUTQ,=X'7FFFFFFFFFFFF000' INITIALIZE VMTMOUTQ 00318950
MVC VMTTIME(16),VMTMOUTQ VMTTIME AND VMTMINQ 00319000
TM APSTAT1,APUOPER IS THIS AN AP SYSTEM? @V4M0203 00319050
BZ LOG8B NO, SKIP INIT OF CPTIME & APTIME @V4M0203 00319100
MVC VMCPTIME,HALFTIME INITIALIZE VMCPTIME @V4M0203 00319150
MVC VMAPTIME,HALFTIME INITIALIZE VMAPTIME @V4M0203 00319200
LOG8B DS 0H @V4M0203 00319250
DROP R10 @VA15234 00319300
LR R1,R10 SWITCH TO NEW VMBLOK @VA15234 00319350
USING VMBLOK,R11 @VA15234 00319400
BAL R5,SWVM GO SWITCH VMBLOK @VA15234 00319450
SPACE 2 00319500
*---------------------------------------------------------------------* 00319550
* * 00319600
* THE FOLLOWING CODE SETS UP RETURN CODES FOR A BRANCH TABLE * 00319650
* WHEN RETURN IS MADE TO DMKLOG. * 00319700
*---------------------------------------------------------------------* 00319750
SPACE 1 00319800
LA R14,8 OP IS LOGGING ON, R11 UPDATED @VA13723 00319850
B LOHSAVE GO STORE IT FOR RETURN @VA13723 00319900
LOHEXIT4 LA R14,4 TERMINAL NO LONGER THERE, ABORT @VA13723 00319950
B LOHSAVE GO STORE IT FOR RETURN @VA13723 00320000
LOHEXIT0 SR R14,R14 OK, CONTINUE THE RECONNECT @VA13723 00320050
LOHSAVE ST R14,SAVER1 STORE BACK IN SAVE AREA @VA13723 00320100
EXIT 00320150
EJECT 00320200
DMKLOHSS RELOC ENTRY FROM THE DISPATCHER @VA09593 00320250
* 00320300
* DMKLOHSS IS ENTERED FROM DMKDSP AFTER A REQUESTED 00320350
* MSS VOLUME HAS BEEN MOUNTED. THE ADDRESS OF 00320400
* LABEL 'DMKLOHSS' IS PLACED IN THE CPEXADD 00320450
* FIELD OF A CPEXBLOK BY DMKSSS WHEN AN MSS 00320500
* MOUNT IS REQUIRED TO SATISFY A DED REQUEST. 00320550
* WHEN THE VOLUME HAS BEEN MOUNTED, MODULE 00320600
* DMKDSB FINDS THE CPEXBLOK CHAINED FROM AN 00320650
* MSSCOM BLOCK AND GOES TO DMKDSP. 00320700
* 00320750
* THIS ROUTINE WILL RESET THE ENVIRONMENT AS IF 00320800
* THERE HAD BEEN NO ASYNCHRONOUS MSS MOUNT AND 00320850
* THEN PROCEED TO COMPLETE THE DISK ALLOCATION. 00320900
* 00320950
LH R1,MSSVUA-OSVSCOM(R3) RDEV ADDR @VMI2009 00321000
CALL DMKSCNRU GET THE RDEVBLOK @V60B6B8 00321050
LR R1,R8 ADDR TO GPR 1 @V60B6B8 00321100
LR R2,R5 UDEVBLOK ADDR FOR DMKVDSAT @V60B6B8 00321150
CALL DMKVDSAT ATTACH THE DEVICE @V60B6B8 00321200
BZ TSTV333V GOOD RETURN FROM VDS @V60B6B8 00321250
LA R2,CON95 ERROR MSG ID @V60B6B8 00321300
LH R1,UDEVADD-UDEVBLOK(R5) VIRTUAL ADDRESS @V60B6B8 00321350
CALL DMKCVTBH CONVERT TO PRINTABLE HEX @V60B6B8 00321400
ICM R1,8,BLANKS BLANK FIRST CHAR @V60B6B8 00321450
ICM R0,14,DMKLOH+3 MODULE ID @VA09593 00321500
ICM R2,8,=X'80' INDICATE RETURN TO DMKLOH @V60B6B8 00321550
CALL DMKERMSG WRITE ERROR MSG @V60B6B8 00321600
B FREEUDEV @V60B6B8 00321650
TSTV333V EQU * SEE IF USER WANTS VIRTUAL 3330V @V60B6B8 00321700
TM UDEVFTR-UDEVBLOK(R5),VIRTUAL VIRT 3330V @V60B6B8 00321750
BZ FREEUDEV NO, ALL DONE @V60B6B8 00321800
LH R1,UDEVADD-UDEVBLOK(R5) VIRTUAL DEVICE ADDR @V60B6B8 00321850
CALL DMKSCNVU GET THE VDEVBLOK @V60B6B8 00321900
OI VDEVFLG2-VDEVBLOK(R8),VDEVVIRT SET FLAG @VA09758 00321950
L R1,VDEVREAL-VDEVBLOK(R8) REAL DEV BLOK ADDR @V60B6B8 00322000
OI RDEVFLAG-RDEVBLOK(R1),RDEV333V DED AS 3330V @VA11587 00322050
FREEUDEV EQU * @V60B6B8 00322100
LA R0,UDEVSIZE UDEVBLOK SIZE @V60B6B8 00322150
LR R1,R5 ADDR OF SAVED BLOCK @V60B6B8 00322200
CALL DMKFRET RETURN THE MEMORY @V60B6B8 00322250
* 00322300
* NOW CHECK TO SEE IF THERE IS ANY PENDING I/O FOR 00322350
* THE VIRTUAL DEVICE JUST ATTACHED. IF THERE 00322400
* IS, THEN A CPEXBLOK REPRESENTING THE I/O 00322450
* WILL HAVE BEEN CHAINED FROM THE MSSCOM BLOCK 00322500
* WHEN THE USER SIO WAS RECEIVED. 00322550
* 00322600
* NOTE: WHEN DMKDSB QUEUES THE MSSCOM BLOCK 00322650
* FROM FIELD DMKSSSMQ, AND CREATES THE CPEXBLOK 00322700
* FOR DMKLOHSS, IT PLACES THE ADDRESS OF 00322750
* THE MSSCOM BLOCK IN THE GPR 3 FIELD OF THE 00322800
* CPEXBLOK. 00322850
* 00322900
USING OSVSCOM,R3 R3 SET BY DMKSSS @VMI2009 00322950
L R1,MSSTASK3 CPEXBLOK IF SIO FROM USER @V60B6B8 00323000
LTR R1,R1 IS THERE A SIO PENDING @V60B6B8 00323050
BZ FREECOM NO @V60B6B8 00323100
CALL DMKSTKCP STACK THE CPEXBLOK FOR DMKDSP @V60B6B8 00323150
FREECOM EQU * RETURN STORAGE FOR THE MSSCOM @V60B6B8 00323200
LR R1,R3 MSSCOM ADDRESS @VMI2009 00323250
LA R0,MSSSIZE NO. OF D-WORDS IN BLOCK @V60B6B8 00323300
CALL DMKFRET AND RETURN THE STORAGE @V60B6B8 00323350
DROP R3 @VMI2009 00323400
GOTO DMKDSPCH AND EXIT @V60B6B8 00323450
EJECT 00323500
LTORG 00323550
EJECT 00323600
HALFTIME DC X'3FFFFFFFFFFFF000' TIME CONSTANT USED BY LOH @VA13723 00323650
* VARIOUS MESSAGES, RESPONSES, AND SKELETONS FOR SAME: 00323700
* 00323750
* NORMAL RESPONSES: 00323800
NR1 DC C'LOGMSG - ' FOR LOG MESSAGE TIME 00323850
NR2 DC C'LOGON AT ' FOR LOGON MESSAGE 00323900
NR3 DC C'RECONNECTED AT ' FOR RECONNECT MESSAGE 00323950
*NR4 DC C'HH:MM:SS TID' TIME 00324000
*NR5 DC C'WEEKDAY ' WEEKDAY 00324050
*NR6 DC C'MM/DD/YY' DATE 00324100
SPACE 00325000
* MESSAGES SENT TO SYSTEM OPERATOR: 00326000
MOP1 DC C'LINE XXX LOGON AS ' @VA04247 00327000
MOP2 DC C'LINE XXX RECONNECT ' @VA04247 00328000
MOP3 DC C'USERID ' 00329000
MOP4 DC C'USERS = ' 00330000
MOP5 DC C'NNN' 00331000
LMOP EQU *-MOP2 LENGTH OF MESSAGE 00332000
LMOP3 EQU MOP3-MOP2 DISP. OF USERID FROM THE BEGINNING 00333000
LMOP5 EQU MOP5-MOP2 DISP. OF NNN FROM THE BEGINNING 00334000
AMOP DC C'AUTO LOGON *** ' @V305535 00335000
AMOP2 DS CL8 @V305535 00336000
DC C' USERS = ' @VM03066 00337000
AMOP3 DS CL3 @V305535 00338000
LAMOPU EQU *-AMOP LENG OF MSG SENT TO CMD ISSUER @VM03066 00339000
DC C' BY ' @V408246 00340000
AMOP4 DS CL8 @V305535 00341000
LAMOP EQU *-AMOP @V305535 00342000
EJECT 00343000
PSA 00344000
COPY SAVE 00345000
* FLAG-BITS USED IN SAVEWRK1: 00346000
* 00347000
AUTOLOG EQU X'80' AUTOLOG CMD OR CPI SYS OP LOGON @VM03066 00348000
PSWRDOK EQU X'40' PASSWORD OK - DON'T CALL DMKEPSWD 00349000
NOIPL EQU X'20' NO AUTOMATIC IPL WANTED 00350000
NONFATAL EQU X'10' ERROR(S) NONFATAL - GO READ NEXT UDEVBLOK 00351000
RECON EQU X'08' RECONNECT PERFORMED 00352000
R9FRE EQU X'04' R9 IN USE AS FREE-STORAGE BUFFER 00353000
EXECF EQU X'02' RECONNECTED W/ VMCF STILL ON @VM03066 00354000
PSWRDCK EQU X'01' AUTOLOG CMD - PASSWORD REQUIRED @VM03066 00355000
SPACE 00356000
EJECT 00357000
COPY EQU 00358000
COPY VMBLOK 00359000
COPY UDIRECT 00360000
SYSLOCS 00361000
COPY RBLOKS 00362000
COPY DEVTYPES 00363000
OSVSCOM MSSCOM @V60B6B8 00363100
CON95 EQU 95 DMKLOH095E MESSAGE @VA09593 00363200
COPY VBLOKS @VA09593 00363300
COPY IOBLOKS IOBLOKS COPY FILE @VA13723 00363400
COPY TIMER TRQBLOK COPY FILE @VA13723 00363500
COPY NETWORK NICBLOK COPY FILE @VA13723 00363600
END DMKLOH 00364000