User Tools

Site Tools


ibm:vm370-lib:cp:dmkuso.assemble_src

DMKUSO Source

References

Source Listing

DMKUSO.ASSEMBLE.txt
  1. USO TITLE 'DMKUSO (CP) VM/370 - RELEASE 6' 00001000
  2. ISEQ 73,80 VALIDATE SEQUENCING OF SYSIN 00002000
  3. *. 00003000
  4. * MODULE NAME - 00004000
  5. * 00005000
  6. * DMKUSO 00006000
  7. * 00007000
  8. * CONTENTS - 00008000
  9. * 00009000
  10. * DMKUSOLG - 'LOGOFF' COMMAND 00010000
  11. * DMKUSOFL - 'FORCE' COMMAND 00011000
  12. * DMKUSOFF - ROUTINE TO LOGOFF A USER 00012000
  13. * DMKUSODS - 'DISCONNECT' COMMAND 00013000
  14. *. 00014000
  15. EJECT 00015000
  16. COPY OPTIONS 00016000
  17. COPY LOCAL 00017000
  18. SPACE 3 00018000
  19. DMKUSO CSECT 00019000
  20. SPACE 00020000
  21. DC CL8'DMKUSO' PAGEABLE MODULE IDENTIFIER @V200820 00021000
  22. SPACE 00022000
  23. EXTRN DMKACOTM,DMKACOFF,DMKVATBC,DMKBLDRL @V200820 00023000
  24. EXTRN DMKCFPRR,DMKPGSPO,DMKPTRRU,DMKPTRRL @V200820 00024000
  25. EXTRN DMKCVTBD,DMKCVTBH,DMKCVTDT,DMKERMSG @V200820 00025000
  26. EXTRN DMKSSSUS,DMKSSSVM @V60B6B8 00025010
  27. EXTRN DMKSCNFD,DMKSCNAU,DMKSCNRD,DMKSCNRN @V200820 00026000
  28. EXTRN DMKSCNVD @VA07859 00026500
  29. EXTRN DMKSCHDL,DMKSCHRT,DMKSYSTI,DMKPTRPW @VA08037 00027200
  30. EXTRN DMKSCHAU @V408246 00027300
  31. EXTRN DMKSTKCP,DMKTRCND,DMKPERT @VM08908 00028000
  32. EXTRN DMKPAGSK @V408246 00028100
  33. EXTRN DMKSCNVU,DMKVDREL @VA03351 00029000
  34. EXTRN DMKVMASH @V60BC11 00030000
  35. EXTRN DMKPTRUL @VA05738 00030100
  36. EXTRN DMKCPE,DMKCKP @V408246 00030200
  37. EXTRN DMKPGSPP @V408246 00030400
  38. SPACE 00031000
  39. USING PSA,R0 FOR ALL ENTRIES 00032000
  40. USING VMBLOK,R11 ... 00033000
  41. USING SAVEAREA,R13 ... 00034000
  42. * 00035000
  43. EJECT 00036000
  44. *. 00037000
  45. * SUBROUTINE NAME - 00038000
  46. * 00039000
  47. * DMKUSOLG - 'LOGOFF' COMMAND 00040000
  48. * 00041000
  49. * FUNCTION - 00042000
  50. * 00043000
  51. * FOR A USER, TO LOGOFF FROM CP370 WHEN HIS 00044000
  52. * TERMINAL SESSION IS COMPLETED 00045000
  53. * 00046000
  54. * COMMAND LINE FORMAT - 00047000
  55. * 00048000
  56. * +--------+---------------------------------------------+ 00049000
  57. * | LOGOUT | | 00050000
  58. * | LOGOFF | <HOLD> | 00051000
  59. * | LOG | | 00052000
  60. * +--------+---------------------------------------------+ 00053000
  61. * 00054000
  62. * SEE "NOTES" BELOW. 00055000
  63. * 00056000
  64. * ATTRIBUTES - 00057000
  65. * 00058000
  66. * REENTRANT, PAGEABLE, CALLED VIA SVC 00059000
  67. * 00060000
  68. * ENTRY POINT - 00061000
  69. * 00062000
  70. * DMKUSOLG 00063000
  71. * 00064000
  72. * ENTRY CONDITIONS - 00065000
  73. * 00066000
  74. * GPR 2 = 0 00067000
  75. * GPR 9 = ADDRESS OF 'LOGOFF' COMMAND 00068000
  76. * GPR 11 = ADDRESS OF CALLER'S VMBLOK 00069000
  77. * GPR 12 = ADDRESS OF DMKUSOLG 00070000
  78. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00071000
  79. * 00072000
  80. * EXIT CONDITIONS - 00073000
  81. * 00074000
  82. * RETURNS TO THE CALLER IF AN ERROR IN THE COMMAND LINE 00075000
  83. * 00076000
  84. * WHEN A USER HAS LOGGED HIMSELF OFF, RETURNS TO CP370 00077000
  85. * WITH THE USER DELETED FROM THE RUNNING SYSTEM. 00078000
  86. * 00079000
  87. * CALLS TO OTHER ROUTINES - 00080000
  88. * 00081000
  89. * DMKSCNFD - TO SCAN COMMAND LINE 00082000
  90. * DMKERMSG - TO SEND ERROR MESSAGE TO CALLER IF NECESSARY 00083000
  91. * DMKUSOFF - INVOKED TO DO ACTUAL 'LOGOFF' PROCESS 00084000
  92. EJECT 00085000
  93. * EXTERNAL REFERENCES - 00086000
  94. * 00087000
  95. * NONE 00088000
  96. * 00089000
  97. * TABLES / WORK AREAS - 00090000
  98. * 00091000
  99. * NONE 00092000
  100. * 00093000
  101. * REGISTER USAGE - 00094000
  102. * 00095000
  103. * GPR 9 = ADDRESS OF 'LOGOFF' COMMAND BUFFER 00096000
  104. * GPR 10 = ADDRESS OF VMBLOK OF USER TO BE LOGGED OFF 00097000
  105. * GPR 11 = ADDRESS OF CALLER'S / USER'S VMBLOK 00098000
  106. * GPR 12 = BASE REGISTER 00099000
  107. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00100000
  108. * 00101000
  109. * OTHER REGISTERS ARE USED FOR WORK REGISTERS 00102000
  110. * 00103000
  111. * NOTES - 00104000
  112. * 00105000
  113. * 1. 'LOGOUT' MAY ALSO BE USED AS WELL AS 'LOGOFF' 00106000
  114. * FOR THIS COMMAND, BUT IN ANY EVENT AT LEAST 00107000
  115. * THREE CHARACTERS ('LOG') MUST BE GIVEN. 00108000
  116. * 00109000
  117. * 2. THE 'HOLD' OPTION IS USED TO KEEP A 2701/2702/2703 00110000
  118. * LINE ENABLED AFTER THE LOGOFF IS COMPLETE. 00111000
  119. * 00112000
  120. * OPERATION - 00113000
  121. * 00114000
  122. * 1. CALLS DMKSCNFD TO DETERMINE IF AN OPTION IS PRESENT ON THE 00115000
  123. * COMMAND LINE. IF YES, IT MUST BE 'HOLD' (ERROR IF NOT). 00116000
  124. * 00117000
  125. * 2. THEN SETS REGISTERS AND FLAGBITS AS NEEDED, AND 00118000
  126. * BRANCHES TO THE DMKUSOFF ROUTINE AT STEP 2 TO 00119000
  127. * ACCOMPLISH THE ACTUAL LOGOFF FROM THE SYSTEM. 00120000
  128. * 00121000
  129. * MESSAGES - 00122000
  130. * 00123000
  131. * RESPONSES - 00124000
  132. * 00125000
  133. * SEE DMKUSOFF ROUTINE FOR THE RESPONSES SENT TO THE USER 00126000
  134. * AND THE SYSTEM OPERATOR IN THE LOGOFF PROCESS. 00127000
  135. * 00128000
  136. * ERROR MESSAGES FOR 'LOGOFF' COMMAND: 00129000
  137. * 00130000
  138. * DMKUSO003E INVALID OPTION - XXXX 00131000
  139. *. 00132000
  140. EJECT 00133000
  141. *********************************************************************** 00134000
  142. * 00135000
  143. * DMKUSOLG - 'LOGOFF' COMMAND 00136000
  144. * 00137000
  145. *********************************************************************** 00138000
  146. SPACE 00139000
  147. DMKUSOLG RELOC ENTER 'LOGOFF' COMMAND. 00140000
  148. TM VMRSTAT,VMLOGOFF IS USER ALREADY IN LOGOFF? @VA01827 00141000
  149. BO USO99X YES--EXIT @VA04404 00142000
  150. TM VMRSTAT,VMEXWAIT IS USER IN EXECUTION WAIT ? @VA13025 00142100
  151. BZ USO06 NO, CONTINUE LOGOFF PROCESS @VA13025 00142200
  152. BAL R8,USOSUB CHECK CMD LINE @VA13025 00142300
  153. LR R10,R11 SET UP R10 FOR DELAYED LOGOFF @VA13025 00142400
  154. OI VMOSTAT,VMKILL DELAY THE LOGOFF UNTIL COMPLETE @VA13025 00142500
  155. B DELAYOFF GO SET UP TO DELAY THE LOGOFF @VA13025 00142600
  156. USO06 MVI SAVEWRK1,ELOGOFF SIGNAL: LOGOFF ENTERED. 00143000
  157. BAL R8,USOSUB AND CALL SUBROUTINE TO CHECK COMMAND LINE 00144000
  158. * COMMAND LINE WAS OK, PROCEED: 00145000
  159. USO08 OI VMRSTAT,VMLOGOFF SYNCHRONIZE LOGOFF @VA05705 00145650
  160. LA R15,8 SAVERETN+8 = DONT READ, DONT RUN @VA04404 00146200
  161. AL R15,SAVERETN MODIFY RETURN 00147000
  162. ST R15,SAVERETN AND STORE IT BACK. 00148000
  163. MC 5,1 TELL MONITOR USER LOGGING OFF @V4M0129 00148110
  164. LA R0,CPEXSIZE GET STORAGE FOR CPEXBLOK @VA02805 00149000
  165. CALL DMKFREE @VA02805 00150000
  166. USING CPEXBLOK,R1 @VA02805 00151000
  167. STM R0,R15,CPEXR0 SAVE ALL REGS @VA02805 00152000
  168. LA R3,USOJOIN RETURN TO USOJOIN IN DMKUSOFF... @VA02805 00153000
  169. ST R3,CPEXADD ...WHEN CPEXBLOK IS UNSTACKED @VA02805 00154000
  170. CALL DMKSTKCP STACK CPEXBLOK @VA02805 00155000
  171. GOTO DMKDSPCH CAUSE SYNCRONIZATION OF CPEXBLOKS@VA02805 00156000
  172. DROP R1 @VA02805 00157000
  173. EJECT 00158000
  174. *. 00159000
  175. * SUBROUTINE NAME - 00160000
  176. * 00161000
  177. * DMKUSOFL - 'FORCE' COMMAND 00162000
  178. * 00163000
  179. * FUNCTION - 00164000
  180. * 00165000
  181. * TO FORCE THE LOGOFF OF A SPECIFIC USER FROM THE SYSTEM 00166000
  182. * 00167000
  183. * COMMAND LINE FORMAT - 00168000
  184. * 00169000
  185. * +---------+---------------------------------------+ 00170000
  186. * | | | 00171000
  187. * | FORCE | USERID | 00172000
  188. * | | | 00173000
  189. * +---------+---------------------------------------+ 00174000
  190. * 00175000
  191. * SEE "NOTES" BELOW. 00176000
  192. * 00177000
  193. * ATTRIBUTES - 00178000
  194. * 00179000
  195. * REENTRANT, PAGEABLE, CALLED VIA SVC 00180000
  196. * 00181000
  197. * ENTRY POINT - 00182000
  198. * 00183000
  199. * DMKUSOFL 00184000
  200. * 00185000
  201. * ENTRY CONDITIONS - 00186000
  202. * 00187000
  203. * GPR 2 = 0 00188000
  204. * GPR 9 = ADDRESS OF 'FORCE' COMMAND 00189000
  205. * GPR 11 = ADDRESS OF CALLER'S VMBLOK 00190000
  206. * GPR 12 = ADDRESS OF DMKUSOFL 00191000
  207. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00192000
  208. * 00193000
  209. * EXIT CONDITIONS - 00194000
  210. * 00195000
  211. * RETURNS TO THE CALLER IF AN ERROR IN THE COMMAND LINE 00196000
  212. * 00197000
  213. * RETURNS TO THE CALLER WHEN THE SPECIFIED USER HAS BEEN 00198000
  214. * LOGGED OFF THE SYSTEM (UNLESS THE CALLER WAS THE USER) 00199000
  215. * 00200000
  216. * IF THE CALLER FORCED HIMSELF OFF, RETURNS TO CP370 00201000
  217. * WITH THE CALLER DELETED FROM THE RUNNING SYSTEM. 00202000
  218. * 00203000
  219. * CALLS TO OTHER ROUTINES - 00204000
  220. * 00205000
  221. * DMKSCNFD - TO SCAN COMMAND LINE 00206000
  222. * DMKSCNAU - TO CHECK FOR ACTIVE USER 00207000
  223. * DMKERMSG - TO SEND ERROR MESSAGE TO CALLER IF NECESSARY 00208000
  224. EJECT 00209000
  225. * EXTERNAL REFERENCES - 00210000
  226. * 00211000
  227. * DMKSYSOP - SYSTEM OPERATOR'S VMBLOK 00212000
  228. * 00213000
  229. * TABLES / WORK AREAS - 00214000
  230. * 00215000
  231. * NONE 00216000
  232. * 00217000
  233. * REGISTER USAGE - 00218000
  234. * 00219000
  235. * GPR 9 = ADDRESS OF 'FORCE' COMMAND BUFFER 00220000
  236. * GPR 10 = ADDRESS OF VMBLOK OF USER TO BE LOGGED OFF 00221000
  237. * GPR 11 = ADDRESS OF CALLER'S / USER'S VMBLOK 00222000
  238. * GPR 12 = BASE REGISTER 00223000
  239. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00224000
  240. * 00225000
  241. * OTHER REGISTERS ARE USED FOR WORK REGISTERS 00226000
  242. * 00227000
  243. * NOTES - 00228000
  244. * 00229000
  245. * 1. 'FORCE USERID' IS A PRIVILEGED COMMAND VALID ONLY 00230000
  246. * FOR A USER WITH PRIVILEGE CLASS A (SYSTEM OPERATOR). 00231000
  247. * 00232000
  248. * OPERATION - 00233000
  249. * 00234000
  250. * 1. CALLS DMKSCNFD TO OBTAIN THE USERID FROM THE COMMAND LINE. 00235000
  251. * (ERROR IF MISSING OR > 8 BYTES IN LENGTH.) IF OK, CALLS 00236000
  252. * DMKSCNAU TO DETERMINE IF THE GIVEN USERID IS CURRENTLY 00237000
  253. * LOGGED ON THE SYSTEM (ERROR IF NOT). 00238000
  254. * 00239000
  255. * 2. CHECKS TO SEE IF THE USERID TO BE LOGGED OFF IS THE 00240000
  256. * CALLER OF THE FORCE COMMAND (POSSIBLE IF PERHAPS UNLIKELY); 00241000
  257. * IF YES, HANDLES LIKE A NORMAL 'LOGOFF'. 00242000
  258. * 00243000
  259. * 3. SET THE 'VMKILL' FLAG IN VMOSTAT FOR THE FORCED USER. 00244000
  260. * BUILD A CPEXBLOK TO ENTER DMKDSPCH POINTING TO THE VMBLOK 00245000
  261. * OF THE FORCED USER, SO THAT DMKDSPCH WILL CALL DMKUSOFF. 00246000
  262. * 00247000
  263. * ERROR MESSAGES - 00248000
  264. * 00249000
  265. * DMKUSO020E USERID MISSING OR INVALID 00250000
  266. * DMKUSO045E USERID NOT LOGGED ON 00251000
  267. * DMKUSO003E INVALID OPTION - XXXX 00252000
  268. *. 00253000
  269. EJECT 00254000
  270. *********************************************************************** 00255000
  271. * 00256000
  272. * DMKUSOFL - 'FORCE' COMMAND - FORCE LOGOFF OF A USER 00257000
  273. * 00258000
  274. *********************************************************************** 00259000
  275. SPACE 00260000
  276. DMKUSOFL RELOC ENTER 'FORCE' COMMAND. 00261000
  277. MVI SAVEWRK1,EFORCE FLAG 'FORCE' COMMAND ENTERED@V200820 00262000
  278. CALL DMKSCNFD PICK UP USERID FROM COMMAND LINE @V200820 00263000
  279. BNZ ERROR20 ERROR IF MISSING. 00264000
  280. CL R0,F8 CHECK BYTE COUNT 00265000
  281. BH ERROR20 ERROR IF INVALID (> 8 CHARS) 00266000
  282. STM R0,R1,SAVEWRK2 REMEMBER R0/R1 (FROM DMKSCNFD) 00267000
  283. CALL DMKSCNAU SEE IF USERID IS ON THE SYSTEM 00268000
  284. BC 4+2,ERROR45 CALLING ERROR OR NOT ON. 00269000
  285. LR R10,R1 REMEMBER VMBLOK ADDR OF FORCEE @VA03806 00270000
  286. TM VMRSTAT-VMBLOK(R10),VMLOGOFF IN LOGOFF NOW? @VA03806 00271000
  287. BO ERROR45 YES, BR 00272000
  288. TM VMOSTAT-VMBLOK(R10),VMKILL MAKE DOUBLE SURE... @VA04404 00272300
  289. BO ERROR45 DONT DOIT TWICE. @VA04404 00272600
  290. CLR R10,R11 IS THE CALLER = THE USER (NOT ILLEGAL) 00273000
  291. BNE FRCUSER NO, THEN GO FORCE THE USER @VA13025 00274000
  292. TM VMRSTAT,VMEXWAIT IS USER IN EXECUTION WAIT @VA13025 00274100
  293. BZ USO08 NO, JUST TREAT LIKE NORMAL LOGOFF@VA13025 00274200
  294. OI VMOSTAT,VMKILL TURN ON KILL BIT @VA13025 00274300
  295. B DELAYOFF AND GO TO DELAY THE LOGOFF @VA13025 00274400
  296. FRCUSER DS 0H HERE TO FORCE A USER @VA13025 00274500
  297. SPACE 00275000
  298. OI VMOSTAT-VMBLOK(R10),VMKILL LOGOFF THIS USER A@V200820 00276000
  299. OI VMSVSTAT-VMBLOK(R10),VMLGFORC FORCE @VA13026 00276500
  300. SPACE 00277000
  301. DELAYOFF DS 0H DELAY THE FORCE/LOGOFF @VA13025 00277500
  302. LA R0,CPEXSIZE @V200820 00278000
  303. CALL DMKFREE GET FREE STORAGE FOR A CPEXBLOK @V200820 00279000
  304. USING CPEXBLOK,R1 @V200820 00280000
  305. XC CPEXBLOK(16),CPEXBLOK CLEAR HEADER PORTION @V200820 00281000
  306. ST R10,CPEXR11 SET GR11 = FORCED USER VMBLOK @V200820 00282000
  307. L R2,ADSPCH ENTRY TO DMKDSP @VA13026 00283100
  308. ST R2,CPEXR12 ...SET FOR 'GOTO DMKDSPCH' @V200820 00284000
  309. ST R2,CPEXADD ... @V200820 00285000
  310. CALL DMKSTKCP STACK THE CPEXBLOK @V200820 00286000
  311. SPACE 00287000
  312. EXIT , RETURN TO DMKCFM @V200820 00288000
  313. DROP R1 @V200820 00289000
  314. EJECT 00290000
  315. *. 00291000
  316. * SUBROUTINE NAME - 00292000
  317. * 00293000
  318. * DMKUSOFF - ROUTINE TO LOGOFF A USER 00294000
  319. * 00295000
  320. * FUNCTION - 00296000
  321. * 00297000
  322. * TO PERFORM THE APPROPRIATE INTERNAL FUNCTIONS 00298000
  323. * NECESSARY TO DELETE A USER FROM THE RUNNING SYSTEM. 00299000
  324. * 00300000
  325. * ATTRIBUTES - 00301000
  326. * 00302000
  327. * REENTRANT, PAGEABLE, CALLED VIA SVC 00303000
  328. * 00304000
  329. * ENTRY POINT - 00305000
  330. * 00306000
  331. * DMKUSOFF 00307000
  332. * 00308000
  333. * ENTRY CONDITIONS - 00309000
  334. * 00310000
  335. * GPR 11 = ADDRESS OF USER'S VMBLOK 00316000
  336. * GPR 12 = ADDRESS OF DMKUSOFF 00317000
  337. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00318000
  338. * 00319000
  339. * EXIT CONDITIONS - 00320000
  340. * 00321000
  341. * NONE 00322000
  342. * 00323000
  343. * CALLS TO OTHER ROUTINES - 00324000
  344. * 00325000
  345. * DMKCVTDT - COMPUTE DATE-TIME 00326000
  346. * DMKACOTM - GET ACCOUNTING TIME 00327000
  347. * DMKQCNWT - WRITE MESSAGE TO USER & OPERATOR 00328000
  348. * DMKSCHDL - SCHEDULE RUNNING USER 00329000
  349. * DMKSCHRT - RESET AN OUTSTANDING CLOCK COMPARATOR REQUEST 00330000
  350. * DMKPGSPO - RESET PAGES 00331000
  351. * DMKACOFF - DO FINAL ACCOUNTING 00332000
  352. * DMKCFPRR - RESET VIRTUAL MACHINE & RELEASE ALL VIRTUAL DEVICES 00333000
  353. * DMKSCNRN - TO GET DEVICE NAME 00334000
  354. * DMKFRET - RETURN VMBLOK TO FREE STORAGE 00335000
  355. * DMKFREE - OBTAIN STORAGE FOR MESSAGES. 00336000
  356. * DMKVATBC - RELEASE SHADOW TABLES. 00337000
  357. * DMKBLDRL - RELEASE SEGMENT, PAGE, AND SWAP TABLES. 00338000
  358. * DMKSCNRD - TO GET TERMINAL DEVICE ADDRESS. 00339000
  359. * DMKCVTBH - TO CONVERT A BINARY ADDRESS TO HEX. 00340000
  360. * DMKCVTBD - TO CONVERT A BINARY NUMBER TO DECIMAL. 00341000
  361. * DMKPERT - TO TERMINATE "PER" TRACING 00342000
  362. * DMKTRCND - TO TERMINATE "TRACE" TRACING 00343000
  363. * DMKPGSPP RELEASE PAGES 00343100
  364. * 00344000
  365. * EXTERNAL REFERENCES - 00345000
  366. * 00346000
  367. * DMKSYSOP - SYSTEM OPERATOR'S VMBLOK 00347000
  368. * DMKSYSVM - SYSTEM VMBLOK 00348000
  369. * 00349000
  370. * TABLES / WORK AREAS - 00350000
  371. * 00351000
  372. * VMBLOK 00352000
  373. * TERMINAL REAL DEVICE BLOCK 00353000
  374. * 00354000
  375. * REGISTER USAGE - 00355000
  376. * 00356000
  377. * GPR 9 = 0 00358000
  378. * GPR 11 = ADDRESS OF USER'S VMBLOK 00359000
  379. * GPR 12 = BASE REGISTER 00360000
  380. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00361000
  381. * 00362000
  382. * GPRS 0-1, 3-8, 10, AND 14-15 ARE WORK REGISTERS. 00363000
  383. * 00364000
  384. * NOTES - 00365000
  385. * 00366000
  386. * DMKUSOFF CALLED DIRECTLY BY DMKDSPCH IF 00367500
  387. * NECESSARY TO LOGOFF A USER BECAUSE OF A DROPPED LINE OR 00368000
  388. * BECAUSE HIS VIRTUAL MACHINE STOPPED RUNNING WHEN IN THE 00369000
  389. * DISCONNECTED MODE. 00370000
  390. * 00371000
  391. * OPERATION - 00372000
  392. * 00373000
  393. * 1. SETS R9 = 0 (TO INDICATE NOT INVOKED FROM DMKUSOLG) 00374000
  394. * 00376000
  395. * 2. BY CALLING APPROPRIATE SUBROUTINES, COMPUTES NEEDED 00377000
  396. * INFORMATION FOR MESSAGES SENT TO USER AND SYSTEM OPERATOR, 00378000
  397. * ACCOUNTING DATA, ETC. WHEN ALL I/O ACTIVITY FOR THE USER 00379000
  398. * HAS QUIESCED, CALLS ROUTINES TO RELEASE SHADOW SEGMENT AND 00380000
  399. * PAGE TABLES (IF IN USE), RELEASE ALL PAGES ASSIGNED TO THE 00381000
  400. * USER, RELEASE VIRTUAL CHANNEL, CONTROL UNIT, AND 00382000
  401. * DEVICE BLOCKS, AND ASSOCIATED OTHER BLOCKS. FINALLY, 00383000
  402. * THE USER'S VMBLOK IS DETACHED FROM THE CHAIN AND GIVEN 00384000
  403. * BACK TO FREE STORAGE, AND EXIT IS MADE TO CP370 WITH THE 00385000
  404. * USER DELETED FROM THE CHAIN OF USERS ON THE SYSTEM. 00386000
  405. * IF THE USER WAS OCCUPYING THE VIRTUAL = REAL REGION, THE 00387000
  406. * MEMORY RELEASE SUBROUTINE (DMKBLDRL) IS CALLED WITH A PARM 00388000
  407. * OF 1 IN GPR2 TO INDICATE THAT THE REGION IS NOW FREE, AND TO 00389000
  408. * INDICATE THAT THERE ARE NO SWAPTABLES TO BE RELEASED. 00390000
  409. EJECT 00391000
  410. * MESSAGES - 00392000
  411. * 00393000
  412. * NORMAL RESPONSES TO USER: 00394000
  413. * 00395000
  414. * 'CONNECT= HH:MM:SS VIRTCPU= MMM:SS.00 TOTCPU= MMM:SS.00' 00396000
  415. * 'LOGOFF AT HH:MM:SS TID WEEKDAY MM/DD/YY' 00397000
  416. * OQ 00398000
  417. * 'LOGOFF AT HH:MM:SS TID WEEKDAY MM/DD/YY BY SYSTEM' 00399000
  418. * 00400000
  419. * MESSAGES SENT TO SYSTEM OPERATOR: 00401000
  420. * 00402000
  421. * 'TYPE RADDR LOGOFF AS USERID USERS = NNN <FORCED>' 00403000
  422. * OR 00404000
  423. * 'LINE DSC LOGOFF AS USERID USERS = NNN <FORCED>' 00405000
  424. * 00406000
  425. * ERROR MESSAGES - NONE 00407000
  426. *. 00408000
  427. EJECT 00409000
  428. *********************************************************************** 00410000
  429. * 00411000
  430. * DMKUSOFF - ROUTINE TO LOGOFF A USER 00412000
  431. * 00413000
  432. *********************************************************************** 00414000
  433. SPACE 00415000
  434. DMKUSOFF RELOC 00416000
  435. SR R2,R2 CLEAR REG FOR INSERT OF PARMS @VA13026 00416200
  436. TM VMSVSTAT,VMLGFORC FORCE? @VA13026 00416280
  437. BZ NOFORCE @VA13026 00416360
  438. O R2,=A(FORCE) INDICATE FORCE @VA13026 00416440
  439. NOFORCE DS 0H @VA13026 00416520
  440. TM VMSVSTAT,VMLGNMSG NO OPERATOR MESSAGE PARM SET @VA13026 00416600
  441. BZ NONMSG PARM NOT SET, DON'T SUPPRESS @VA13026 00416680
  442. O R2,=A(NOOPMSG) SUPPRESS OPERATOR MESSAGE @VA13026 00416760
  443. NONMSG DS 0H @VA13026 00416840
  444. STC R2,SAVEWRK1 AND STORE PARM FROM CALLER IN R2 @VA13026 00416920
  445. N R2,F15 ENSURE USE OF ONLY THE LOW 4 BITS OF R2 00417000
  446. STC R2,SAVEWRK1 AND STORE PARM FROM CALLER IN R2 00418000
  447. USOJOIN SR R9,R9 R9=0 MEANS NO FREE STORAGE IN USE FOR MSG 00419000
  448. ST R9,SAVEWRK4 CLEAR WORK AREA @VA04579 00419500
  449. LA R0,8 LENGTH OF USERID @VA13441 00420000
  450. LA R1,VMUSER POINT TO USERID @VA13441 00420100
  451. CALL DMKSCNAU SEE IF VMBLOK STILL VALID @VA13441 00420200
  452. BZ LOGOFF STILL THERE - LOG HIM OFF @VA13441 00420300
  453. BM USO96 ALREADY GONE - EXIT @VA13441 00420400
  454. LOGOFF DS 0H @VA13441 00420700
  455. OI VMRSTAT,VMLOGOFF SIGNAL: IN LOGOFF PROCESS @VA13441 00420800
  456. NI VMOSTAT,VMSYSOP+VMDISC+VMSHR SAVE ONLY THESE FL@V200820 00421000
  457. LA R0,CPEXSIZE @V408246 00421010
  458. CALL DMKFREE @V408246 00421060
  459. USING CPEXBLOK,R1 @V408246 00421110
  460. STM R0,R15,CPEXR0 @V408246 00421160
  461. LA R0,USOSCH SCHEDULAR RETURN @V408246 00421210
  462. ST R0,CPEXADD @V408246 00421260
  463. CALL DMKSTKCP STACK CPEXBLOK @V408246 00421310
  464. GOTO DMKDSPCH MAKE SURE LAST IN THE QUEUE @V408246 00421360
  465. * 00421410
  466. USOSCH DS 0H @V408246 00421460
  467. CALL DMKSCHDL REMOVE FROM QUEUE @V408246 00421510
  468. LA R4,VMDELAY POINT TO TRQBLOK HOLD FIELD @V200820 00422000
  469. BAL R7,FRETRQB DEQUEUE AND FRET TRQBLOK @V200820 00423000
  470. TM VMPERFLG,VMPERUSE "PER" TRACING ACTIVE? PER001 00424000
  471. BZ USO04 NO -- @V200820 00425000
  472. CALL DMKPERT RESET PER TRACING @V200820 00426000
  473. USO04 EQU * CHECK FOR VIRTUAL TRACE @V200820 00428000
  474. CLI VMTRCTL,X'00' TRACING VIA DMKTRC ? @V200820 00429000
  475. BE USO05 NO -- @V200820 00430000
  476. CALL DMKTRCND RESET VIRTUAL MACHINE TRACE @V200820 00431000
  477. USO05 EQU * @V200820 00432000
  478. L R4,=V(DMKSSSVM) ADDR OF THE DMKMSS VIRT MACH @V60B6B8 00432010
  479. * NAME 00432020
  480. LTR R4,R4 IS VCON EQUAL TO ZERO? @VA09319 00432022
  481. BZ USO05A YES, INDICATES DMKSSS NOT IN SYS @VA09319 00432024
  482. OC 0(8,R4),0(R4) IS MSS INIT ? @VA13088 00432026
  483. BZ USO05A BRANCH, INDICATES MSS NOT INIT.@VA13088 00432028
  484. CLC VMUSER,0(R4) IS HE LOGGING OFF @V60B6B8 00432030
  485. BNE USO05A NO @V60B6B8 00432040
  486. CALL DMKSSSUS GO PURGE MSS QUEUES, IF ANY @V60B6B8 00432050
  487. NI PSAMSS,X'FF'-MSSPRES SET MSS FLAG OFF @V60B6B8 00432060
  488. USO05A EQU * @V60B6B8 00432070
  489. TM VMOSTAT,VMDISC IS THIS USER DISCONNECTED ? 00433000
  490. BZ US009 NO, CONTINUE @VA09408 00434050
  491. LH R8,VMVTERM YES, MAY BE CONSOLE SPOOLED @VA09408 00434100
  492. LTR R8,R8 VIRTUAL CONSOLE AVAILABLE? @VA09408 00434150
  493. BM DISCUSER NO, HE CAN'T HEAR US @VA09408 00434200
  494. AL R8,VMDVSTRT YES, GET VDEVBLOK POINTER @VA09408 00434250
  495. USING VDEVBLOK,R8 FOR ADDRESSABILITY @VA09408 00434300
  496. TM VDEVFLAG,VDEVCSPL CONSOLE SPOOLING ACTIVE? @VA09408 00434350
  497. BZ DISCUSER NO, GO TELL OPERATOR @VA09408 00434400
  498. DROP R8 @VA09408 00434450
  499. US009 EQU * @VA09408 00434500
  500. TM VMRSTAT,VMLOGON IF THE USER WAS LOGGING ON, 00435000
  501. BO USO11 DO NOT CALL THE ACCOUTNING ROUTINE 00436000
  502. CALL DMKACOTM CALL ACCOUNTING ROUTINE FOR CONNECT MSG 00437000
  503. USO11 LA R0,(LNR5+7)/8 GET ENOUGH FREE STORAGE FOR LONGEST MSG 00438000
  504. CALL DMKFREE ... 00439000
  505. LR R9,R1 REMEMBER THE ADDRESS IN R9 00440000
  506. LA R1,NR2 POINT TO 'LOGOFF AT' MSG 00441000
  507. LA R2,L'NR2-1 LENGTH - 1 IN R2 00442000
  508. BAL R3,MSGSUBR FILL IN MSG TO BE SENT TO THE USER 00443000
  509. SPACE 00444000
  510. CALL DMKQCNWT SEND MESSAGE, WAIT FOR IT @V200820 00445000
  511. TM VMOSTAT,VMDISC IS USER DISCONNECTED? @VA09408 00445020
  512. BO DISCUSER YES, RDEVBLOK ALREADY CLEARED @VA09408 00445040
  513. L R8,VMTERM GET TERM RDEVBLOK @VA04579 00445100
  514. ST R8,SAVEWRK4 SAVE IT FOR LATER USE @VA04579 00445200
  515. SR R15,R15 @VA04579 00445300
  516. ST R15,VMTERM CLEAR VMTERM @VA04579 00445400
  517. OI VMOSTAT,VMDISC SIGNAL USER NOW DISCONNECT @VA04579 00445500
  518. SPACE 1 00445530
  519. DISCUSER BAL R4,MSGOP GO TELL OPERATOR HE'S GONE @VA05738 00445560
  520. SPACE 1 00445590
  521. LA R0,CPEXSIZE WE'LL NEED ONE MORE CPEXBLOK @VA05738 00445620
  522. CALL DMKFREE ASK FOR THE STORAGE @VA05738 00445650
  523. USING CPEXBLOK,R1 TELL THE ASSEMBLER ABOUT IT @VA05738 00445680
  524. STM R0,R15,CPEXR0 SAVE REGS FOR LATER @VA05738 00445710
  525. LA R3,USOCONT THIS IS WHERE WE'LL CONTINUE @VA05738 00445740
  526. ST R3,CPEXADD INSERT INTO THE BLOCK @VA05738 00445770
  527. CALL DMKSTKCP ENSURE THAT EVERYONES DONE WITH @VA05738 00445800
  528. * THIS USER BEFORE WE PURGE HIM. 00445830
  529. GOTO DMKDSPCH @VA08501 00445910
  530. EJECT 00446000
  531. USOCONT DS 0H CONTINUE AFTER MSG TO USER (IF ANY) HAS BEEN GIVEN: 00447000
  532. NI VMMLEVEL,255-(VMMSGON+VMWNGON) NO SPOOL MSGS@VM08714 00448000
  533. OI VMQSTAT,VMINHMIG PREVENT MIGRATION @V408246 00449300
  534. USO20A TM VMOSTAT,VMSHR WAS USER RUNNING A SHARED SYSTEM @V304735 00454000
  535. BZ USO21 IF NOT - RESET THE VIRTUAL @V304735 00455000
  536. * MACHINE 00456000
  537. CL R11,LASTUSER WAS HE THE CURRENT RUNUSER @V304735 00457000
  538. BNE USO21 NO - CONTINUE @V304735 00458000
  539. CALL DMKVMASH CHECK IF ANY SHARED PAGES WERE @V304735 00459000
  540. * CHANGED 00460000
  541. SPACE 1 00464000
  542. USO21 CL R11,LASTUSER WAS USER THE LAST ONE DISPATCHED @V304735 00465000
  543. BNE *+10 NO - @V304735 00466000
  544. MVC LASTUSER,ASYSVM OTHERWISE SWITCH TO SYSTEM @V304735 00467000
  545. * VMBLOK 00468000
  546. TM VMRSTAT,VMPGWAIT VIRTUAL MACHINE IN PAGE WAIT? @V408246 00468100
  547. BO USOPRST YES, PRELIMINARY PAGE RESET @V408246 00468200
  548. ICM R2,B'0011',VMNDCNT ANY OTHER PAGING ACTIVE? @V408246 00468300
  549. BZ USO21A NO, CONTINUE @V408246 00468400
  550. USOPRST DS 0H PRELIMINARY RESET OF VIRTUAL @V408246 00468500
  551. * PAGES 00468600
  552. CALL DMKPTRPW @VA08037 00468710
  553. USO21A DS 0H @V408246 00468800
  554. CALL DMKCFPRR RESET THE VIRTUAL MACHINE @V304735 00469000
  555. TM VMRSTAT,VMLOGON VIRTUAL MACHINE LOGGING ON ? 00470000
  556. BNO USO21C NO....BRANCH @VA13304 00471150
  557. * ERROR WHEN USER LOGGING ON 00471300
  558. TM VMSPMFLG,VMLOGON2 HAD THE LOGON GOTTEN VEDV ? @VA13304 00471450
  559. BNO USO22 NO....BRANCH AROUND @VA13304 00471600
  560. USO21C DS 0H @VA13304 00471750
  561. SR R2,R2 TELL PAGE OUT TO CLEAR 00472000
  562. CALL DMKPGSPO AND RESET USERS PAGES 00473000
  563. * NOTE - ALSO CLEARS AN ADSTOP IF ANY THERE 00474000
  564. LH R8,VMVTERM CHECK FOR VIRT CONSOLE @VA03351 00475000
  565. LTR R8,R8 IS THERE A VIRT CONSOLE? @VA03351 00476000
  566. BM USO22 NO, FORGET IT @VA03351 00477000
  567. AL R8,VMDVSTRT GET VDEVBLOK ADDRESS @VA03351 00478000
  568. USING VDEVBLOK,R8 @VA03351 00479000
  569. CALL DMKSCNVD FIND VCUBLOCK AND VCHBLOCK @VA07859 00481000
  570. BNZ USO22 FORGET IT @VA03351 00482000
  571. USING VCHBLOK,R6 @VA03351 00483000
  572. USING VCUBLOK,R7 @VA03351 00484000
  573. * WE ARE NOW READY TO GET RID 00485000
  574. * OF THE VIRTUAL CONS BLOKS 00486000
  575. CALL DMKVDREL RESET AND RELEASE THE DEVICE @VA03351 00487000
  576. L R2,FFS X'FFFFFFFF' @VA03351 00488000
  577. STH R2,VCUDVTBL MARK DEVICE DETACHED @VA03351 00489000
  578. STH R2,VDEVADD @VA03351 00490000
  579. DROP R6,R7,R8 ADDRESSABILITY NO LONGER REQD @VA03351 00491000
  580. USO22 EQU * 00492000
  581. TM VMQLEVEL,VMAEXP FAVORED PERCENTAGE USER ? 00493000
  582. BZ USO22N NO -- 00494000
  583. L R2,=A(DMKSCHAU) GET ADDRESS OF VMBLOK POINTER 00495000
  584. SLR R0,R0 CLEAR OUT 00496000
  585. ST R0,0(,R2) VMBLOK POINTER 00497000
  586. USO22N EQU * 00498000
  587. TM VMRSTAT,VMLOGON ARE WE LOGGED ON @VM01168 00499000
  588. BO USOA BR, IF NO - BYPASS ACCOUNTING @VM01168 00500000
  589. CALL DMKACOFF CALL USER ACCOUNTING @VM01168 00501000
  590. USOA EQU * @VM01168 00502000
  591. TM VMPSTAT,VMV370R DO WE HAVE AN EXTENSION BLOCK? 00503000
  592. BZ USO24 NO 00504000
  593. CALL DMKVATBC RELEASE ALL SHADOW TABLES, IF ANY 00505000
  594. L R2,VMECEXT EXTENSION BLOCK ADDRESS 00506000
  595. USING ECBLOK,R2 00507000
  596. LA R4,EXTCPTRQ CPU TIMER TRQBLOK @V200820 00508000
  597. BAL R7,FRETRQS FRET TRQBLOK @V200820 00509000
  598. LA R4,EXTCCTRQ CLOCK COMPARATOR TRQBLOK @V200820 00510000
  599. BAL R7,FRETRQB RESET AND FRET THE BLOCK @V200820 00511000
  600. LR R1,R2 GET BLOK TO FRET 00512000
  601. DROP R2 ABANDON ADDRESSABILITY 00513000
  602. LA R0,EXTSIZE AND 00514000
  603. CALL DMKFRET 'FRET' THE CONTROL BLOCK ITSELF. 00515000
  604. USO24 L R1,VMSEG POINT TO SEGMENT TABLE 00516000
  605. LTR R1,R1 WE WOULD NORMALLY HAVE ONE 00517000
  606. BZ USO27 IF WE DO NOT HAVE ONE DONOT RELEASE IT 00518000
  607. ICM R0,B'0111',VMSWPMIG+1 PSUEDO MEMORY @V408246 00518010
  608. BZ USO25 NO @V408246 00518060
  609. L R1,VMSEG GET STO @V408246 00518110
  610. L R4,0(,R1) SAVE FIRST STE @VA07591 00518170
  611. STCM R0,B'0111',1(R1) REPLACE 1ST STE WITH PSUEDO @V408246 00518210
  612. * MEMORY 00518260
  613. MVI 0(R1),X'70' SIMULATE LENGTH OF 8 PAGES @V408246 00518310
  614. SR R1,R1 ADDRESS OF 1ST PAGE TO RELEASE @V408246 00518360
  615. L R2,=A(X'7000') ADDRESS OF LAST PAGE TO RELEASE @V408246 00518410
  616. CALL DMKPGSPP DO PARTIAL PAGE RESET ON PSUEDO @V408246 00518460
  617. * MEM. 00518510
  618. L R1,VMSEG RELOAD STO @V408246 00518560
  619. ST R4,0(,R1) RESTORE SAVED STE @VA07591 00518620
  620. USO25 DS 0H @V408246 00518660
  621. L R1,VMSIZE STORGE SIZE OF VM @V304635 00519000
  622. SRL R1,12 RELEASE TOTAL VM TABLES @V304635 00520000
  623. BCTR R1,R0 MINUS 1 PAGE. @V304635 00521000
  624. CALL DMKBLDRL,PARM=DELPAGES+DELSEGS GET RIDE OF ALL. @V304635 00522000
  625. ICM R1,B'0111',VMSWPMIG+1 PSUEDO MEMORY? @V408246 00522100
  626. BZ USO26 NO @V408246 00522200
  627. ICM R1,B'1000',=X'70' SIMULATE TABLE LENGTH OF 8 @V408246 00522300
  628. CALL DMKBLDRL,PARM=PAGTONLY+DELPAGES @V408246 00522400
  629. USO26 DS 0H @V408246 00522500
  630. CL R11,RUNUSER DOES RUNUSER POINT TO US @VA02869 00523000
  631. BNE USO27 NO--GO AHEAD @VA02869 00524000
  632. L R2,ASYSVM ADDR OF SYSTEM VMBLOK @VA02869 00525000
  633. ST R2,RUNUSER LET RUNUSER PT TO SYSTEM VMBLOK @VA02869 00526000
  634. USO27 LM R6,R8,VMCHSTRT POINT TO CHANNEL, CONTROL UNIT DEV BLOKS 00527000
  635. LA R0,VCHSIZE SIZE OF ONE CHANNEL BLOCK, 00528000
  636. MH R0,VMCHCNT * NO. OF BLOCKS = NO. DBL-WORDS 00529000
  637. LTR R1,R6 ADDRESS OF VCHBLOK INTO R1, 00530000
  638. BZ USO28 IF NOTHING THERE, FORGET THE WHOLE THING. 00531000
  639. CALL DMKFRET RETURN TABLE OF CHANNEL BLOCKS 00532000
  640. LA R0,VCUSIZE SIZE OF ONE CONTROL UNIT BLOCK, 00533000
  641. MH R0,VMCUCNT * NO. OF BLOCKS, 00534000
  642. LR R1,R7 ADDRESS OF VCUBLOK TABLE, 00535000
  643. CALL DMKFRET GIVE IT BACK; 00536000
  644. LA R0,VDEVSIZE DITTO VDEVBLOK TABLE 00537000
  645. MH R0,VMDVCNT ... 00538000
  646. LR R1,R8 ... 00539000
  647. CALL DMKFRET ... 00540000
  648. USO28 EQU * CHANNEL, CONTROL UNIT, DEVBLOKS GONE ... 00541000
  649. LA R4,VMTRQBLK TRQBLOK FOR REAL TIMER @V200820 00542000
  650. BAL R7,FRETRQS FRET THE TRQBLOK IF IT'S THERE @V200820 00543000
  651. L R1,VMMICRO GET ADDRESS OF MICBLOK @V201537 00544000
  652. LA R1,0(R1) CLEAR ANY FLAG BITS @V201537 00545000
  653. LTR R1,R1 IS THERE ONE? IE.,MICRO ASST ON? @V201537 00546000
  654. BE USO30 BRANCH IF NOT @V201537 00547000
  655. LA R0,MICSIZE GET MICBLOK SIZE @V201537 00548000
  656. CALL DMKFRET RELEASE MICBLOK STORAGE @V201537 00549000
  657. USO30 EQU * @V201537 00550000
  658. TM VMPSTAT,VMRPAGE RESERVED PAGES ??? 00551000
  659. BZ USO31 NOPE --- 00552000
  660. L R1,=A(DMKPTRRL) ADDRESS OF THE PAGE LIMIT COUNT 00553000
  661. L R2,=A(DMKPTRRU) ADDRESS OF THE VMBLOK POINTER 00554000
  662. SR R0,R0 . . . 00555000
  663. ST R0,0(,R1) CLEAR LIMIT 00556000
  664. ST R0,0(,R2) CLEAR VMBLOK POINTER 00557000
  665. USO31 L R2,VMPFUNC GET FUNC TABLE @V200730 00558000
  666. LTR R2,R2 IS THERE ONE ?? @V200730 00559000
  667. BZ USO80 NO, CONT @V200730 00560000
  668. SR R0,R0 CLEAR SIZE REG 00561000
  669. LA R3,24 TABLE ENTRY COUNT HRC029DK 00562490
  670. USO33 L R1,4(R2) GET ENTRY BUFFER @V200730 00563000
  671. LTR R1,R1 IS THER A FUNC ?? @V200730 00564000
  672. BZ USO32 NO, LOOP FOR ALL @V200730 00565000
  673. IC R0,1(R2) GET BUFFER SIZE @V200730 00566000
  674. CALL DMKFRET FRET IT @V200730 00567000
  675. USO32 LA R2,8(R2) POINT TO NEXT ENTRY @V200730 00568000
  676. BCT R3,USO33 LOOP FOR 12 ENTRIES @V200730 00569000
  677. L R1,VMPFUNC FUNC TABLE @V200730 00570000
  678. LA R0,24 SIZE HRC029DK 00571490
  679. CALL DMKFRET FRET IT @V200730 00572000
  680. B USO80 CONT @V200730 00573000
  681. EJECT 00574000
  682. * NOW SEND MESSAGE TO SYSTEM OPERATOR (AS A RULE): 00575000
  683. MSGOP L R10,ASYSOP GET THE OPERATOR'S VMBLOK @VA05738 00576100
  684. CLR R10,R11 IS HE THE ONE LOGGING OFF ? @VA05738 00576200
  685. BE OPOFF YES, DECREMENT NUMBER OF USERS @VA11749 00576300
  686. TM VMRSTAT,VMLOGON NOT COMPLETELY LOGGED ON? @VA11389 00576320
  687. BOR R4 YES, NO MESSAGE TO OPERATOR @VA11389 00576340
  688. TM SAVEWRK1,NOOPMSG SHOULD WE SKIP THE OP MSG? @VM03066 00579000
  689. BOR R4 YES, NO MESSAGE.. @VA05738 00580100
  690. LTR R9,R9 DO WE HAVE ANY FREE STORAGE FOR A MSG ? 00581000
  691. BNZ USO82 OK - GO. 00582000
  692. LA R0,(LNR5+7)/8 GET STORAGE FOR LONGEST MSG 00583000
  693. CALL DMKFREE ... 00584000
  694. LR R9,R1 REMEMBER WHERE WE GOT IT 00585000
  695. USO82 MVC 0(LMOP2345,R9),MOP2 MOVE COMPLETE MESSAGE TO STORAGE 00586000
  696. L R8,SAVEWRK4 SAVED RDEVBLOK PTR @VA04579 00587500
  697. LTR R8,R8 (HE SHOULD NORMALLY HAVE ONE) 00590000
  698. BZ USO84 BUT LEAVE WELL ENOUGH ALONE IF NOT 00591000
  699. CLI RDEVTYPC-RDEVBLOK(R8),CLASTERM A TERMINAL CLASS 00592000
  700. BNE *+12 NO, CHECK FOR 370X 00593000
  701. CLI RDEVTYPE-RDEVBLOK(R8),TYPBSC A BISYNC LINE 00594000
  702. BE USORESID YES, GET RESOURCE ID. 00595000
  703. LA R1,CLASSPEC*256+TYP3705 CLASS SPECIAL, TYPE 370@V200820 00596000
  704. CH R1,RDEVTYPC-RDEVBLOK(,R8) WIERD TERMINAL ? @V200820 00597000
  705. BNE USO83 NO - HANDLE EASILY@V200820 00598000
  706. USORESID EQU * GET RESOURCE ID. 00599000
  707. LH R1,VMTRMID TERMINAL IDENTIFICATION @V200820 00600000
  708. CALL DMKCVTBH CONVERT TO EBCDIC @V200820 00601000
  709. ST R1,4(0,R9) FOUR-CHARACTER I.D. @V200820 00602000
  710. MVC 0(4,R9),=C'DEV ' MNEMONIC @V200820 00603000
  711. B USO84 @V200820 00604000
  712. * 00604100
  713. USO83LDF EQU * HRC065DK 00604200
  714. MVC 0(5,R9),=C'GRF L' Short name if LDEV HRC065DK 00604300
  715. LH R1,RDEVADD-RDEVBLOK(,R8) Get the LDEV address HRC065DK 00604400
  716. N R1,F4095 Keep only the dev num HRC065DK 00604500
  717. CALL DMKCVTBH Make it displayable HRC065DK 00604600
  718. STCM R1,7,5(R9) Put dev addr in message HRC065DK 00604700
  719. B USO84 Continue normal process HRC065DK 00604800
  720. USO83 EQU * @V200820 00605000
  721. TM RDEVADD-RDEVBLOK(R8),RDEVLDEV Is this an LDEV? HRC065DK 00605100
  722. BO USO83LDF Yes, special handling HRC065DK 00605200
  723. CALL DMKSCNRD CONVERT TO CCU FORM, 00606000
  724. CALL DMKCVTBH AND BINARY TO HEX, 00607000
  725. STCM R1,7,5(R9) STORE TERMINAL DEVICE ADDRESS IN MSG 00608000
  726. CALL DMKSCNRN GET DEVICE NAME @V200930 00609000
  727. STCM R1,15,0(R9) PUT IN MESSAGE @V200930 00610000
  728. USO84 MVC DMOP3(8,R9),VMUSER STORE USERID IN THE MSG, 00611000
  729. OPOFF L R3,ASYSLC REFERENCE SYSLOCS INFORMATION @VA11749 00612000
  730. USING SYSLOCS,R3 ... 00613000
  731. L R1,DMKSYSNM PICK UP NO. OF USERS, 00614000
  732. TM VMRSTAT,VMLOGON WAS THIS GUY 'NOT YET LOGGED ON' ? 00616000
  733. BO USO85 YES 00617000
  734. BCTR R1,0 LESS ONE (IN THE REGISTER ONLY) 00618000
  735. ST R1,DMKSYSNM @VA09339 00618050
  736. DROP R3 @VA09339 00618100
  737. CLR R10,R11 OPERATOR LOGGING OFF ?? @VA11749 00618200
  738. BER R4 YES, HE ALREADY KNOWS HE'S GONE @VA11749 00618300
  739. USO85 CALL DMKCVTBD BINARY TO DECIMAL PLEASE, 00619000
  740. STCM R1,7,DMOP4(R9) STORE IN MSG 00620000
  741. LA R0,LMOP234 LENGTH OF MESSAGE, 00621000
  742. TM SAVEWRK1,FORCE FORCED LOGOFF ? @V200820 00622000
  743. BZ USO85A NOT THIS TIME. 00623000
  744. LA R0,LMOP2345 IF YES, USE 'FORCED' INCLUDED IN MSG. 00624000
  745. USO85A LR R1,R9 ADDRESS OF MESSAGE, 00625000
  746. CALL DMKQCNWT,PARM=OPERATOR+NORET SEND MESSAGE TO OPERATOR 00626000
  747. BR R4 RETURN TO MAIN LINE @VA05738 00626100
  748. SPACE 1 00626200
  749. USO80 EQU * CONTINUE @VA05738 00626300
  750. USO86 EQU * CONTINUE ... 00627000
  751. EJECT 00628000
  752. AIF (NOT &TRACE(6)).NOTRA1 **AIF** 00629000
  753. L R1,VMTREXT ANY TREXT BLOCK THERE ? 00630000
  754. LTR R1,R1 ... 00631000
  755. BZ USO88 NOPE - NO PROBLEM. 00632000
  756. LA R0,TREXSIZE YES - GIVE IT BACK 00633000
  757. CALL DMKFRET ... 00634000
  758. .NOTRA1 ANOP 00635000
  759. * NOW DELETE THIS USER FROM THE CHAIN OF USERS: 00636000
  760. USO88 L R2,ASYSVM LET R2 START FROM THE SYSTEM VMBLOK 00637000
  761. USO90 L R3,VMPNT-VMBLOK(,R2) LET R3 START WITH THE FIRST USER 00638000
  762. L R7,VMPNT GET POINTER TO NEXT VMBLOK, 00639000
  763. CLR R7,R11 DOES USER PERCHANCE POINT TO HIMSELF ? 00640000
  764. BNE USO92 TRF IF NOT (ONLY HAPPENS IF ONE GUY LEFT) 00641000
  765. SLR R4,R4 IF HE WAS THE LAST MAN ON EARTH, LET THE 00642000
  766. B USO92A SYSVM HAVE A VMPNT=0 FOR NO USERS AT ALL 00643000
  767. USO92 LR R4,R3 REMEMBER PREVIOUS BLOCK, 00644000
  768. L R3,VMPNT-VMBLOK(,R3) GET PNTR TO NEXT BLOCK, 00645000
  769. CLR R3,R11 IS IT US ? 00646000
  770. BE USO92AA YES, PATCH OUT OF CHAIN @V408246 00647100
  771. C R3,VMPNT-VMBLOK(,R2) COME FULL CIRCLE? @V408246 00647200
  772. BNE USO92 NO @V408246 00647300
  773. B USO92B YES, MUST BE ABORTIVE LOGON @V408246 00647400
  774. USO92AA DS 0H @V408246 00647500
  775. ST R7,VMPNT-VMBLOK(,R4) PATCH CHAIN TO LEAVE US OUT 00648000
  776. USO92A ST R4,VMPNT-VMBLOK(,R2) STORE NEW ANCHOR FOR CHAIN IN SYSVM 00649000
  777. USO92B DS 0H @V408246 00649100
  778. TM VMRSTAT,VMLOGON WAS THIS GUY 'NOT YET LOGGED ON' ? 00650000
  779. BO USO93 YES 00651000
  780. TM VMPSTAT,VMACCOUN IS THE ACCOUNTING OPTION SET ? @VA00881 00658000
  781. BZ USO93 NO, GO CHECK FOR OPERATOR @VA00881 00659000
  782. ICM R1,15,VMACOUNT GET THE ADDRESS OF THE @VA00881 00660000
  783. * ACCOUNTING BLOCK 00661000
  784. BZ USO93 IF ZERO, GO CHECK FOR OPERATOR @VA00881 00662000
  785. LA R0,ACCTLENG GET LENGTH OF BLOCK IN @VA00881 00663000
  786. * DOUBLEWORDS 00664000
  787. CALL DMKFRET RELEASE THE ACCOUNTING BLOCK @VA00881 00665000
  788. USO93 EQU * 00666000
  789. C R11,ASYSOP IS THIS THE OPERATOR'S VMBLOK ? 00667000
  790. BNE USO94 NOT THIS TIME. 00668000
  791. SPACE 00669000
  792. * FOR OPERATOR'S VMBLOK, RESET IT INSTEAD OF RETURNING TO FREE STORAGE: 00670000
  793. LM R2,R3,VMCOMND REMEMBER LAST COMMAND ('LOGOFF') 00671000
  794. L R0,VMDFTPNT SAVE DEFER TASK POINTER @V4M0148 00671100
  795. MVC VMBLOK(8),ZEROES CLEAR ENTIRE VMBLOK 00672000
  796. MVC VMBLOK+8(256),VMBLOK ... 00673000
  797. MVC VMBLOK+264(VMBSIZE*8-264),VMBLOK ... 00674000
  798. MVC VMCHTBL(8),FFS FFFF-FILL THE VM CHANNEL TABLE 00675000
  799. MVC VMCHTBL+8(24),VMCHTBL ... 00676000
  800. STM R2,R3,VMCOMND RESTORE THE LAST COMMAND ('LOGOFF') 00677000
  801. ST R0,VMDFTPNT RESTORE FOR LOGON. @V4M0148 00677100
  802. MVC VMACNT,BLANKS BLANK OUT THE ACCOUNTING NUMBER 00678000
  803. MVC VMUSER(8),BLANKS BLANK OUT THE USERID @VM08592 00679000
  804. MVC VMVTERM(2),FFS NO VIRTUAL CONSOLE DEFINED @VM08592 00680000
  805. MVI VMOSTAT,VMSYSOP IT'S STILL THE OPERATOR'S VMBLOK 00681000
  806. MVI VMPSW+1,WAIT SET VMPSW = DISABLED WAIT STATE 00682000
  807. B USO96 GO STORE NEW R11 AND THEN EXIT. 00683000
  808. SPACE 00684000
  809. USO94 L R1,VMDFTPNT LOAD DEFERRED TASK POINTER @V407594 00685000
  810. LTR R1,R1 IS THERE ONE @V407594 00685100
  811. BZ USO95 NO @V407594 00685200
  812. LA R0,CPEXSIZE SIZE OF BLOCK @V407594 00685300
  813. CALL DMKFRET RETURN TO FREE STORAGE @V407594 00685400
  814. USO95 LA R4,VMDELAY GET POSSIBLE TRQBLOK POINTER @VA12770 00685502
  815. BAL R7,FRETRQB RETURN IT IF IT'S THERE @VA12770 00685504
  816. LR R1,R11 RESTORE VMBLOK POINTER @VA12770 00685506
  817. C R11,STACKVM IS VMBLOK=STACKVM @VA08126 00685510
  818. BNE USO95A NO-DONT CLEAR STACKVM @VA08126 00685520
  819. MVC STACKVM,ZEROES CLEAR OUT STACKVM @VA08126 00685530
  820. USO95A EQU * @VA08126 00685540
  821. LA R0,VMBSIZE SIZE IN DBL-WORDS 00686000
  822. MVI VMUSER-VMBLOK+7(R1),X'00' NULLIFY USERID @VA13441 00686500
  823. CALL DMKFRET GIVE IT BACK TO FREE STORAGE. 00687000
  824. * 00688000
  825. USO96 L R11,ASYSVM IF NOT, POINT R11 TO SYSTEM VMBLOK, AND 00689000
  826. CHARGE START CHARGE OVERHEAD TO SYSTEM @V407594 00691000
  827. * 00692000
  828. USO98 LTR R1,R9 DID WE HAVE A FREE STORAGE BUFFER ? 00693000
  829. BZ USO99 NOPE - REALLY EXIT. 00694000
  830. USO98A LA R0,(LNR5+7)/8 THIS WAS THE NO. DBL-WORDS WE USED 00695000
  831. CALL DMKFRET GIVE IT BACK (WE DIDN'T FORGET) 00696000
  832. USO99 EQU * ALMOST DONE ... @VA00881 00697000
  833. CALL DMKUSOFM DO FREE STORAGE CLEAN UP @VA05738 00699100
  834. TM SAVEWRK1,ELOGOFF+EFORCE FORCE/LOGOFF VIA CFM? @VA08501 00699250
  835. BZ USO99X NO, NO COMMAND BUFFER TO FRET @VA08501 00699300
  836. LA R0,BUFSIZE SIZE OF COMMAND BUFFER @VA08501 00699350
  837. L R1,SAVER9 GET ITS ADDRESS FROM CFM @VA08501 00699400
  838. CALL DMKFRET THROW IT AWAY @VA08501 00699450
  839. SVC 16 ELIMINATE RETURN TO CFM @VA08501 00699500
  840. LTR R13,R13 DID CFM HAVE A CALLER? @VA08501 00699550
  841. BNZ USO99X YES, RETURN TO HIM @VA08501 00699600
  842. GOTO DMKDSPCH NO, NEXT BATTER UP, PLEASE @VA08501 00699650
  843. SPACE 1 00699700
  844. USO99X DS 0H @VA08501 00699750
  845. ST R11,SAVER11 PASS SYSTEM'S VMBLOK BACK @VA08501 00699800
  846. EXIT @VA08501 00699850
  847. SPACE 2 00701000
  848. FRETRQB EQU * RESET AND FRET A TRQBLOK @V200820 00702000
  849. L R1,0(0,R4) POINTER TO THE BLOCK @V200820 00703000
  850. LTR R1,R1 IS THERE ONE ? @V200820 00704000
  851. BCR 8,R7 NO -- RETURN @V200820 00705000
  852. CLC TRQBFPNT-TRQBLOK(4,R1),ZEROES QUEUED ? @V200820 00706000
  853. BE FRETRQC NO -- @V200820 00707000
  854. CALL DMKSCHRT RESET TIMER REQUEST BLOCK @V200820 00708000
  855. B FRETRQC @V200820 00709000
  856. FRETRQS EQU * RETURN TRQBLOK TO FREE STORAGE @V200820 00710000
  857. L R1,0(0,R4) PICK UP TRQBLOK ADDRESS @V200820 00711000
  858. LTR R1,R1 MAKE SURE THERE IS ONE @V200820 00712000
  859. BCR 8,R7 NOPE - JUST RETURN @V200820 00713000
  860. FRETRQC EQU * @V200820 00714000
  861. LA R0,TRQBSIZE SIZE IN DOUBLE-WORDS @V200820 00715000
  862. CALL DMKFRET RETURN IT TO FREE STORAGE @V200820 00716000
  863. SLR R0,R0 @V200820 00717000
  864. ST R0,0(0,R4) CLEAR OUT THE HOLD FIELD @V200820 00718000
  865. BR R7 RETURN @V200820 00719000
  866. EJECT 00720000
  867. *. 00721000
  868. * SUBROUTINE NAME - 00722000
  869. * 00723000
  870. * DMKUSOFM - FREE STORAGE MAINTENANCE SUBROUTINE 00724000
  871. * 00725000
  872. * FUNCTION - 00726000
  873. * 00727000
  874. * TO "CLEAN UP" THE FREE STORAGE SUBPOOLS AND FREE STORAGE 00728000
  875. * CHAIN INSOFAR AS PRACTICABLE, BY RETURNING SUBPOOLS 00729000
  876. * TO THE FREE STORAGE CHAIN, AND BY REMOVING SPOOL FILE 00730000
  877. * BLOCKS AND ALLOCATION BLOCKS FROM THE DYNAMIC PAGING 00731000
  878. * AREA (INSOFAR AS FEASIBLE). 00732000
  879. * 00733000
  880. * ATTRIBUTES - 00734000
  881. * 00735000
  882. * REENTRANT, PAGEABLE 00736000
  883. * 00737000
  884. * ENTRY POINTS - 00738000
  885. * 00739000
  886. * DMKUSOFM - EXTERNALLY REFERENCED NAME - CALLED VIA SVC 00740000
  887. * FREMSUBR - INTERNAL CODE - CALLED VIA BALR (FROM DMKUSOFF) 00741000
  888. * 00742000
  889. * ENTRY CONDITIONS - 00743000
  890. * 00744000
  891. * GPR 12 = ADDRESS OF ENTRY POINT 00745000
  892. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 00746000
  893. * 00747000
  894. * EXIT CONDITIONS - 00748000
  895. * 00749000
  896. * ALL GPR'S UNCHANGED 00750000
  897. * 00751000
  898. * CALLS TO OTHER ROUTINES - 00752000
  899. * 00753000
  900. * DMKFRERS - TO RETURN SUBPOOLS TO THE FREE STORAGE CHAIN 00754000
  901. * DMKFREE - TO OBTAIN A NEW STORAGE BLOCK 00755000
  902. * DMKFRET - TO RETURN AN OLD STORAGE BLOCK 00756000
  903. * 00757000
  904. * EXTERNAL REFERENCES - 00758000
  905. * 00759000
  906. * DMKFRENP = NPAGFREE & NPAGFRET 00760000
  907. * DMKFRELO (&DMKFREHI) 00761000
  908. * DMKSLC = END OF V=R AREA (IF GENERATED) 00762000
  909. * DMKPGTP5 - ANCHOR FOR FIRST ALLOCATION CHAIN 00763000
  910. * DMKVSPWA - ADDRESS OF 3211 INDEX WORK AREA (IF ANY) 00764000
  911. * 00765000
  912. * TABLES / WORK AREAS 00766000
  913. * 00767000
  914. * SAVEWRK1 = HOLDS RETURN REGISTER (R14) 00768000
  915. * SAVEWRK2 = HOLDS "DMKFRELO" 00769000
  916. * SAVEWRK3 = HOLDS "DMKFREHI" 00770000
  917. EJECT 00771000
  918. * REGISTER USAGE - 00772000
  919. * 00773000
  920. * GPR 0 - SIZE OF FREE STORAGE BLOCK 00774000
  921. * GPR 1 - ADDRESS OF FREE STORAGE BLOCK 00775000
  922. * GPR 4 - DMKFRELO MINUS LENGTH OF BLOCK 00776000
  923. * GPR 6 - LINKING REGISTER 00777000
  924. * GPR 12 - ADDRESSABILITY 00778000
  925. * GPR 13 - ADDRESS OF STANDARD SAVE AREA 00779000
  926. * GPR 14 - LINK REGISTER TO DMKFREE / DMKFRET 00780000
  927. * 00781000
  928. * GPR 11 IS NOT USED 00782000
  929. * 00783000
  930. * OTHER REGISTERS = WORK REGISTERS 00784000
  931. * 00785000
  932. * NOTES - 00786000
  933. * 00787000
  934. * THIS CODE WAS DEBUGGED IN THE CP NUCLEUS WITH STATISTICAL 00788000
  935. * COUNTERS, WHICH INDICATED THE VARIOUS PATHS WERE SUCCESSFUL. 00789000
  936. * (THE COUNTERS ARE NOT INCLUDED HEREIN - DMKUSO IS REENTRANT) 00790000
  937. * 00791000
  938. * OPERATION - 00792000
  939. * 00793000
  940. * 1. INVOKES CODE IN DMKFRE (DMKFRERS ENTRY POINT) 00794000
  941. * TO RETURN ALL SUBPOOLS TO THE FREE STORAGE CHAIN. 00795000
  942. * 00796000
  943. * 2. IF NO FREE STORAGE AREAS ARE PRESENTLY IN USE IN THE 00797000
  944. * DYNAMIC PAGING AREA, RETURNS FORTHWITH TO CALLER. 00798000
  945. * 00799000
  946. * 3. EXAMINES SPOOL FILE BLOCKS FOR READER, PRINTER, AND PUNCH; 00800000
  947. * IF ANY INACTIVE BLOCK THEREIN IS IN THE DYNAMIC PAGING AREA, 00801000
  948. * RELOCATES THE DATA TO A NEW FREE STORAGE BLOCK NOT WITHIN THE 00802000
  949. * DYNAMIC PAGING AREA (IF FEASIBLE), AND PATCHES THE CHAIN. 00803000
  950. * 00804000
  951. * 4. PERFORMS SIMILAR LOGIC FOR ALLOCATION BLOCKS. 00805000
  952. * 00806000
  953. * 5. PERFORMS SIMILAR LOGIC FOR 3211 INDEX WORK AREA (IF ANY) 00807000
  954. * 00808000
  955. * 6. RETURNS TO CALLER. 00809000
  956. *. 00810000
  957. EJECT 00811000
  958. * EXTERNALLY AVAILABLE ENTRY POINT TO TO INVOKE "FREMSUBR": 00812000
  959. DMKUSOFM RELOC @VA00881 00813000
  960. BAL R14,FREMSUBR "CALL" THE INTERNAL ROUTINE @VA00881 00814000
  961. EXIT AND EXIT - THAT'S ALL, FOLKS. @VA00881 00815000
  962. SPACE 00816000
  963. EXTRN DMKFRENP "NPAGFREE" & "NPAGFRET" @VA00881 00817000
  964. EXTRN DMKFREHI BEG. ADDRESS OF FIXED FREE SPACE @V3M4000 00817500
  965. EXTRN DMKFRELO ADDRESS OF LOWEST PAGEABLE PAGE @V3M4000 00818000
  966. EXTRN DMKPGTP5 POINT TO FIRST ALLOCATION CHAIN @VA00881 00819000
  967. EXTRN DMKVSPWA ADDR OF 3211 INDEX WORK AREA @VA00881 00820000
  968. EXTRN DMKSLC END OF V=R AREA (IF GENERATED) @VA00881 00821000
  969. EXTRN DMKFRERS RETURNS SUBPOOLS TO FREE STORAGE @VA00881 00822000
  970. EXTRN DMKLOCKQ,DMKLOCKD SERIALIZE WITH DMKCKS @V304298 00823000
  971. SPACE 00824000
  972. * INTERNAL ROUTINE (CALLED VIA R14) TO CLEAN UP FREE STORAGE BLOCKS: 00825000
  973. FREMSUBR ST R14,SAVEWRK1 ENTER, SAVE RETURN REGISTER @VA00881 00826000
  974. CALL DMKFRERS RETURN SUBPOOLS TO FREE STORAGE @VA00881 00827000
  975. * CHAIN 00828000
  976. L R15,=A(DMKFRENP) REFERENCE NPAGFREE & NPAGFRET @VA00881 00829000
  977. L R0,0(,R15) NPAGFREE - NPAGFRET = NUMBER OF @VA00881 00830000
  978. S R0,4(,R15) PAGES IN DYNAMIC PAGING AREA @VA00881 00831000
  979. BNP FREMREX1 IF NOT > 0, JUST EXIT @V304298 00832000
  980. LA R1,CKSLOCK SERIALIZE WITH DMKCKS @V304298 00833000
  981. CALL DMKLOCKQ @V304298 00834000
  982. L R15,=A(DMKFRELO) REFERENCE DMKFRELO @V3M4000 00834500
  983. L R4,0(R15) DMKFRELO --> R4 @V3M4000 00835000
  984. L R15,=A(DMKFREHI) REFERENCE DMKFREHI @V3M4000 00835500
  985. L R5,0(R15) DMKFREHI --> R5 @V3M4000 00836000
  986. STM R4,R5,SAVEWRK2 REMEMBER THESE IN SAVEWRK2/3 @VA00881 00837000
  987. LA R0,SFBSIZE SET TO FIX UP SPOOL FILE BLOCKS @VA00881 00838000
  988. LA R15,SFBSIZE*8 COMPUTE DMKFRELO - BLOCK LENGTH @VA00881 00839000
  989. SR R4,R15 ... @VA00881 00840000
  990. L R7,ARSPRD POINT TO SYSTEM READER FILE CHAIN@VA00881 00841000
  991. LA R10,FREMRSP5 SET R10 SWITCH FOR SPOOL FILE @VA00881 00842000
  992. LA R9,FREMR02 AND SET "ERROR-RETURN-VECTOR" @VA00881 00843000
  993. BAL R6,FREMRSP1 FIX READER SPOOL FILE CHAIN IF @VA00881 00844000
  994. * NEEDED 00845000
  995. L R7,ARSPPR POINT TO SYSTEM PRINTER FILE @VA00881 00846000
  996. * CHAIN 00847000
  997. BAL R6,FREMRSP2 FIX PRINTER SPOOL FILE CHAIN @VA00881 00848000
  998. L R7,ARSPPU AND THE SYSTEM PUNCH FILE CHAIN @VA00881 00849000
  999. BAL R6,FREMRSP2 FIX IT TOO @VA00881 00850000
  1000. FREMR02 LR R1,R3 ADDR. OF "NEW" (UNUSED) SPOOL @VA00881 00851000
  1001. * FILE BLOCK 00852000
  1002. CALL DMKFRET GIVE BACK UNUSED SPOOL FILE BLOCK@VA00881 00853000
  1003. * NOW DO SIMILAR LOGIC FOR PAGING / SPOOLING ALLOCATION BLOCKS: 00854000
  1004. LA R0,RECSIZE NOW SET R0 TO FIX UP ALLOC BLOCKS@VA00881 00855000
  1005. L R4,SAVEWRK2 COMPUTE DMKFRELO MINUS BLOCK @VA00881 00856000
  1006. * LENGTH AGAIN 00857000
  1007. LA R15,RECSIZE*8 ... @VA00881 00858000
  1008. SR R4,R15 ... @VA00881 00859000
  1009. LA R10,FREMRSP6 SET R10 SWITCH FOR "ALLOC" BLOCKS@VA00881 00860000
  1010. LA R9,FREMR08 AND SET "ERROR-RETURN-VECTOR" @VA00881 00861000
  1011. L R5,=A(DMKPGTP5) POINT TO FIRST ALLOCATION CHAIN @VA00881 00862000
  1012. FREMR03 ICM R8,15,0(R5) ... @VA00881 00863000
  1013. BP FREMR04 IF PLUS - GET STARTED. @VA00881 00864000
  1014. LA R5,4(,R5) IF NOT, GET NEXT ONE. @VA00881 00865000
  1015. BZ FREMR03 SHOULD BE ZERO. @VA00881 00866000
  1016. B FREMREX VERY STRANGE IF MINUS. @VA00881 00867000
  1017. USING RDEVBLOK,R8 REFERENCE REAL DEVICE BLOCKS @VA00881 00868000
  1018. FREMR04 LA R7,RDEVPAGE POINT TO FIRST PAGING CHAIN @VA00881 00869000
  1019. BAL R6,FREMRSP1 START FIXING ALLOC BLOCKS @VA00881 00870000
  1020. B FREMR06 JOIN LOOP AT "THE RIGHT PLACE". @VA00881 00871000
  1021. SPACE 00872000
  1022. * LOOP TO "FIX UP" PAGING / SPOOLING ALLOCATION BLOCKS: 00873000
  1023. FREMR05 LA R7,RDEVPAGE POINT TO PAGING CHAIN @VA00881 00874000
  1024. BAL R6,FREMRSP2 FIX UP PAGING CHAIN @VA00881 00875000
  1025. FREMR06 LA R7,RDEVRECS POINT TO SPOOLING CHAIN @VA00881 00876000
  1026. BAL R6,FREMRSP2 FIX UP SPOOLING CHAIN @VA00881 00877000
  1027. L R8,RDEVPNT POINT TO NEXT RDEVBLOK @VA00881 00878000
  1028. CL R8,0(,R5) ARE WE BACK AT THE BEGINNING ? @VA00881 00879000
  1029. BNE FREMR05 ITERATE IF STILL SOME LEFT. @VA00881 00880000
  1030. FREMR07 LA R5,4(,R5) POINT TO "NEXT" ALLOCATION CHAIN @VA00881 00881000
  1031. L R8,0(,R5) ... @VA00881 00882000
  1032. LTR R8,R8 0 = NONE; MINUS = ALL FINISHED. @VA00881 00883000
  1033. BP FREMR05 PLUS = GO TO IT. @VA00881 00884000
  1034. BZ FREMR07 ZERO = GET NEXT ONE. @VA00881 00885000
  1035. DROP R8 MINUS = WE'RE ALL DONE... @VA00881 00886000
  1036. FREMR08 LR R1,R3 WHEN THRU, GET ADDR OF UNUSED @VA00881 00887000
  1037. * ALLOC BLOCK 00888000
  1038. CALL DMKFRET AND GIVE BACK UNUSED BLOCK @VA00881 00889000
  1039. * NOW DO SIMILAR LOGIC FOR 3211 INDEX WORK AREA BUFFER (IF ANY): 00890000
  1040. SLR R2,R2 R2 = 0 @VA00881 00891000
  1041. L R7,=A(DMKVSPWA) ADDR OF 3211 INDEX WORK AREA @VA00881 00892000
  1042. L R1,0(,R7) ADDR OF ACTUAL BUFFER (IF ANY) @VA00881 00893000
  1043. CL R1,SAVEWRK3 AT OR ABOVE DMKFREHI ? @VA00881 00894000
  1044. BNL FREMREX YES - OK - NOTHING TO DO. @VA00881 00895000
  1045. CLR R2,R1 MAYBE NONEXISTENT (ADDR = 0) ? @VA00881 00896000
  1046. BE FREMREX YES - OK - NOTHING TO DO. @VA00881 00897000
  1047. LA R0,184/8 SIZE OF BUFFER (23 DBL WORDS) @VA00881 00898000
  1048. L R4,SAVEWRK2 COMPUTE DMKFRELO MINUS @VA00881 00899000
  1049. LA R15,184 BLOCK LENGTH @VA00881 00900000
  1050. SR R4,R15 ... @VA00881 00901000
  1051. LA R10,FREMRSP8 SET R10 "SWITCH" @VA00881 00902000
  1052. LA R9,FREMR09 AND R9 ERROR-RETURN-VECTOR @VA00881 00903000
  1053. BAL R6,FREMRSP1 CALL MAGIC SUBROUTINE ONCE AGAIN @VA00881 00904000
  1054. FREMR09 LR R1,R3 ADDRESS OF UNUSED BLOCK TO R1 @VA00881 00905000
  1055. FREMR10 CALL DMKFRET GIVE BACK OLD OR NEW BLOCK @VA00881 00906000
  1056. FREMREX LA R1,CKSLOCK UNLOCK US BEFORE WE EXIT @V304298 00907000
  1057. CALL DMKLOCKD @V304298 00908000
  1058. FREMREX1 DS 0H @V408246 00909010
  1059. L R10,=A(DMKPAGSK) AVAILABLE PAGE I/O BLOCKS @V408246 00909060
  1060. PGSKL DS 0H @VA10137 00909139
  1061. ICM R1,B'1111',0(R10) 1ST ON THE CHAIN? @V408246 00909160
  1062. BNP FRMXIT NONE @V408246 00909210
  1063. MVC 0(4,R10),IOBMISC-IOBLOK(R1) UNCHAIN 1ST @V408246 00909260
  1064. LA R0,PAGESIZE BLOCK SIZE @V408246 00909310
  1065. CALL DMKFRET RETURN TO FREE STORAGE POOL @V408246 00909360
  1066. B PGSKL LOOK FOR MORE @V408246 00909410
  1067. FRMXIT DS 0H @V408246 00909460
  1068. L R14,SAVEWRK1 RESTORE R14 = RETURN-REG @V408246 00909510
  1069. BR R14 AND RETURN TO CALLER. @VA00881 00910000
  1070. EJECT 00911000
  1071. * FREMRSP1 (& FREMRSP2) = FIX UP SYSTEM READER, PRINTER, & PUNCH 00912000
  1072. * CHAINS OF SPOOL FILE BLOCKS (IF NEEDED & FEASIBLE) SO NO SPOOL FILE 00913000
  1073. * BLOCKS ARE IN THE DYNAMIC PAGING AREA. 00914000
  1074. * R0 = SIZE IN DOUBLE WORDS OF BLOCK 00915000
  1075. * R4 = DMKFRELO - BLOCK LENGTH 00916000
  1076. * R6 = RETURN-REGISTER 00917000
  1077. * R7 = ANCHOR FOR CHAIN 00918000
  1078. * R9 = "ERROR-RETURN VECTOR" = A(FREMR02) OR A(FREMR08) 00919000
  1079. * R10 = "SWITCH" = A(FREMRSP5) OR A(FREMRSP6) 00920000
  1080. SPACE 00921000
  1081. FREMRSP1 DS 0H GET A "NEW" SPOOL FILE BLOCK SO @VA00881 00922000
  1082. * WE HAVE IT 00923000
  1083. CALL DMKFREE (IN ADVANCE SO WE DON'T LOSE @VA00881 00924000
  1084. * CONTROL) 00925000
  1085. LR R3,R1 REMEMBER ITS ADDRESS IN R3 @VA00881 00926000
  1086. CL R3,SAVEWRK3 IS BLOCK AT OR ABOVE DMKFREHI ? @VA00881 00927000
  1087. BNL FREMRSP2 YES - OK FOR US TO USE IT. @VA00881 00928000
  1088. CLR R3,R4 NO, CHECK AGAINST DMKFRELO @VA00881 00929000
  1089. BCR 2,R9 <BH> IF > DMKFRELO, GIVE IT @VA00881 00930000
  1090. * BACK & GIVE UP. 00931000
  1091. AIF (NOT &VIRREAL).J7 **AIF** 00932000
  1092. CL R3,=A(DMKSLC) BEWARE OF BLOCK IN UNLOCKED V=R @VA00881 00933000
  1093. * AREA 00934000
  1094. BCR 4,R9 <BL> IF < DMKSLC, GIVE IT @VA00881 00935000
  1095. * BACK & GIVE UP. 00936000
  1096. .J7 ANOP NEW BLOCK OK TO USE - NOT IN DYNAMIC PAGING AREA: 00937000
  1097. FREMRSP2 LR R1,R7 START FROM ANCHOR FOR SPOOL @VA00881 00938000
  1098. * FILE CHAIN (OR EQUIVALENT) 00939000
  1099. CL R7,=A(DMKVSPWA) IS THIS 3211 INDEX WORK AREA ? @VA00881 00940000
  1100. BNE FREMRSP3 NOPE - REGULAR CHAIN HANDLING @VA00881 00941000
  1101. L R15,0(,R7) YES - GET ADDRESS OF REAL BUFFER @VA00881 00942000
  1102. ST R2,0(,R15) AND CLEAR 1ST WORD (R2 STILL 0) @VA00881 00943000
  1103. * TO HANDLE ONE AND ONLY ONE BLOCK BELOW 00944000
  1104. FREMRSP3 LR R2,R1 REMEMBER OLD POINTER @VA00881 00945000
  1105. L R1,0(,R1) GET POINTER TO "NEXT" BLOCK @VA00881 00946000
  1106. CL R1,SAVEWRK3 > DMKFREHI ? @VA00881 00947000
  1107. BNL FREMRSP3 YES (OK) - CHECK THE NEXT ONE @VA00881 00948000
  1108. LTR R1,R1 0 = END OF CHAIN ? @VA00881 00949000
  1109. BCR 8,R6 <BZ> YES - EXIT TO MAIN @VA00881 00950000
  1110. * FREMR CODE. 00951000
  1111. CLR R1,R4 < DMKFRELO ? @VA00881 00952000
  1112. AIF (&VIRREAL).J7A **AIF** 00953000
  1113. BNH FREMRSP3 YES (OK) - CHECK THE NEXT ONE @VA00881 00954000
  1114. AGO .J7B 00955000
  1115. .J7A BH FREMRSP4 NOPE - GO RELOCATE IT. 00956000
  1116. CL R1,=A(DMKSLC) BEWARE OF BLOCK IN UNLOCKED V=R @VA00881 00957000
  1117. * AREA 00958000
  1118. BNL FREMRSP3 IF NOT BELOW "DMKSLC" IT'S OK @VA00881 00959000
  1119. * AS IS. 00960000
  1120. .J7B ANOP 00961000
  1121. FREMRSP4 BR R10 "SWITCH" - GO TO FREMRSP5 FOR @VA00881 00962000
  1122. * SPOOL FILE BLOCKS 00963000
  1123. * OR TO FREMRSP6 FOR ALLOC BLOCKS 00964000
  1124. * OR TO FREMRSP8 FOR 3211 INDEX WORK AREA 00965000
  1125. USING SFBLOK,R1 SPOOL FILE BLOCK IN DYNAMIC @VA00881 00966000
  1126. * PAGING AREA: 00967000
  1127. FREMRSP5 TM SFBFLAG,SFBINUSE IS THIS BLOCK ACTIVE ? @VA00881 00968000
  1128. BO FREMRSP3 YES - LEAVE WELL ENOUGH ALONE. @VA00881 00969000
  1129. DROP R1 @VA00881 00970000
  1130. MVC 0(SFBSIZE*8,R3),0(R1) NO - MOVE THE DATA @VA00881 00971000
  1131. B FREMRSP7 AND CONTINUE BELOW. @VA00881 00972000
  1132. FREMRSP6 MVC 0(RECSIZE*8,R3),0(R1) MOVE ALLOCATION BLOCK @VA00881 00973000
  1133. FREMRSP7 ST R3,0(,R2) PATCH THE CHAIN USING THE NEW @VA00881 00974000
  1134. * BLOCK 00975000
  1135. CALL DMKFRET RETURN THE OLD BLOCK @VA00881 00976000
  1136. B FREMRSP1 AND START ALL OVER AGAIN TO BE @VA00881 00977000
  1137. * SAFE. 00978000
  1138. SPACE 00979000
  1139. * OLD BLOCK WAS A 3211 INDEX WORK AREA: 00980000
  1140. FREMRSP8 ST R3,0(,R7) STORE ADDRESS OF NEW BLOCK @VA00881 00981000
  1141. B FREMR10 AND GO FRET THE OLD BLOCK @VA00881 00982000
  1142. * NOTE: NOT NECESSARY TO MOVE ANY DATA. 00983000
  1143. SPACE 2 00984000
  1144. CKSLOCK DC CL8'<SPLCHK>' LOCK FOR DMKCKS @V304298 00985000
  1145. EJECT 00986000
  1146. *. 00987000
  1147. * SUBROUTINE NAME - 00988000
  1148. * 00989000
  1149. * DMKUSODS - 'DISCONNECT' COMMAND 00990000
  1150. * 00991000
  1151. * FUNCTION - 00992000
  1152. * 00993000
  1153. * TO DISCONNECT A USER'S TERMINAL FROM HIS RUNNING VIRTUAL 00994000
  1154. * MACHINE, ALLOWING HIM TO CONTINUE TO RUN IN 'DISCONNECT' MODE. 00995000
  1155. * 00996000
  1156. * COMMAND LINE FORMAT - 00997000
  1157. * 00998000
  1158. * +------------+-----------------------------------------+ 00999000
  1159. * | | | 01000000
  1160. * | DISCONN | <HOLD> | 01001000
  1161. * | ---- | | 01002000
  1162. * +------------+-----------------------------------------+ 01003000
  1163. * 01004000
  1164. * SEE "NOTES" BELOW. 01005000
  1165. * 01006000
  1166. * ATTRIBUTES - 01007000
  1167. * 01008000
  1168. * REENTRANT, PAGEABLE, CALLED VIA SVC 01009000
  1169. * 01010000
  1170. * ENTRY POINT - 01011000
  1171. * 01012000
  1172. * DMKUSODS 01013000
  1173. * 01014000
  1174. * ENTRY CONDITIONS - 01015000
  1175. * 01016000
  1176. * GPR 2 = 0 01017000
  1177. * GPR 9 = ADDRESS OF 'DISCONNECT' COMMAND 01018000
  1178. * GPR 11 = ADDRESS OF CALLER'S VMBLOK 01019000
  1179. * GPR 12 = ADDRESS OF DMKUSODS 01020000
  1180. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 01021000
  1181. * 01022000
  1182. * EXIT CONDITIONS - 01023000
  1183. * 01024000
  1184. * RETURNS TO THE CALLER IF AN ERROR IN THE COMMAND LINE 01025000
  1185. * 01026000
  1186. * UPON A SUCCESSFUL DISCONNECT, RETURNS TO CP370 TO 01027000
  1187. * CONTINUE TO RUN THE USER, BUT WITH HIS TERMINAL DISCONNECTED. 01028000
  1188. * 01029000
  1189. * CALLS TO OTHER ROUTINES - 01030000
  1190. * 01031000
  1191. * DMKSCNFD - TO SCAN COMMAND LINE 01032000
  1192. * DMKSCNRD - TO COMPUTE TERMINAL REAL DEVICE ADDRESS IN CCU FORM 01033000
  1193. * DMKCVTDT - TO GET DATE/TIME FOR DISCONNECT MESSAGE 01034000
  1194. * DMKCVTBH - TO GET NEEDED FIELD(S) IN PRINTABLE HEX FORM 01035000
  1195. * DMKCVTBD - TO GET NNN USERS IN PRINTABLE DECIMAL FORM 01036000
  1196. * DMKQCNWT - TO SEND DISCONNECT MSG TO USER & SYSTEM OPERATOR 01037000
  1197. * DMKERMSG - TO SEND ERROR MESSAGE TO CALLER IF NECESSARY 01038000
  1198. * DMKFREE - OBTAIN STORAGE FOR MESSAGES. 01039000
  1199. * DMKFRET - RETURN MESSAGE BUFFER TO FREE STORAGE. 01040000
  1200. EJECT 01041000
  1201. * EXTERNAL REFERENCES - 01042000
  1202. * 01043000
  1203. * DMKSYSVM - SYSTEM VMBLOK 01044000
  1204. * DMKSYSOP - OPERATOR'S VMBLOK 01045000
  1205. * 01046000
  1206. * TABLES / WORK AREAS - 01047000
  1207. * 01048000
  1208. * NONE 01049000
  1209. * 01050000
  1210. * REGISTER USAGE - 01051000
  1211. * 01052000
  1212. * GPR 9 = ADDRESS OF COMMAND BUFFER 01053000
  1213. * GPR 10 = ADDRESS OF VMBLOK OF USER TO BE DISCONNECTED 01054000
  1214. * GPR 11 = ADDRESS OF CALLER'S / USER'S VMBLOK 01055000
  1215. * GPR 12 = BASE REGISTER 01056000
  1216. * GPR 13 = ADDRESS OF STANDARD SAVE AREA 01057000
  1217. * 01058000
  1218. * GPRS 0-1, 3-8, AND 14-15 ARE WORK REGISTERS. 01059000
  1219. * 01060000
  1220. * NOTES - 01061000
  1221. * 01062000
  1222. * 1. THE 'HOLD' OPTION IS USED TO KEEP A 2701/2702/2703 LINE 01063000
  1223. * ENABLED AFTER THE DISCONNECT HAS BEEN PERFORMED. 01064000
  1224. * 01065000
  1225. * 2. IF THE USER IS NOT YET LOGGED ON, "DISCONN" IS TREATED 01066000
  1226. * EXACTLY THE SAME AS A "LOGOFF" COMMAND. 01067000
  1227. * 01068000
  1228. * OPERATION - 01069000
  1229. * 01070000
  1230. * 1. CHECKS COMMAND LINE FOR PRESENCE OF 'HOLD'. IF PRESENT, 01071000
  1231. * CALLS DMKQCNWT WITH THE 'HOLD' OPTION WHEN SENDING THE 01072000
  1232. * DISCONNECT MESSAGE TO THE USER. IF A FIELD WAS PRESENT 01073000
  1233. * BUT WAS NOT 'HOLD', GIVES ERROR MESSAGE AND RETURN TO 01074000
  1234. * THE CALLER. 01075000
  1235. * 01076000
  1236. * 2. OBTAINS DATE-TIME FROM DMKCVTDT, AND SENDS A FILLED-IN 01077000
  1237. * DISCONNECT MESSAGE TO THE USER VIA DMKQCNWT (WITH 'HOLD' 01078000
  1238. * OPTION IF 'DISCONNECT HOLD' WAS SPECIFIED), THEN TRANSFERS 01079000
  1239. * TO DMKDSPCH. 01080000
  1240. * 01081000
  1241. * 3. UPON COMPLETION OF THE MESSAGE (RETURN FROM DMKDSPCH), 01082000
  1242. * SENDS FILLED-IN MESSAGE TO THE SYSTEM OPERATOR THAT THE 01083000
  1243. * USER HAS BEEN DISCONNECTED. SETS APPROPRIATE BITS IN 01084000
  1244. * USER'S VMBLOK AND TERMINAL DEVICE BLOCKS TO INDICATE THAT 01085000
  1245. * HE IS DISCONNECTED (AND CANNOT RECEIVE ANY MESSAGES 01086000
  1246. * OR WARNINGS), AND EXITS INDICATING THAT THE VIRTUAL MACHINE 01087000
  1247. * CAN BE RUN, BUT THAT A READ SHOULD NOT BE PUT UP TO THE 01088000
  1248. * TERMINAL. 01089000
  1249. EJECT 01090000
  1250. * MESSAGES - 01091000
  1251. * 01092000
  1252. * NORMAL RESPONSES TO USER: 01093000
  1253. * 01094000
  1254. * 'DISCONNECT AT HH:MM:SS TID WEEKDAY MM/DD/YY' 01095000
  1255. * 01096000
  1256. * MESSAGES SENT TO SYSTEM OPERATOR: 01097000
  1257. * 01098000
  1258. * 'LINE XXX DSCONNECT USERID USERS = NNN' 01099000
  1259. * 01100000
  1260. * ERROR MESSAGES (DISCONNECT NOT ACCOMPLISHED): 01101000
  1261. * 01102000
  1262. * DMKUSO003E INVALID OPTION - XXXX 01103000
  1263. *. 01104000
  1264. EJECT 01105000
  1265. *********************************************************************** 01106000
  1266. * 01107000
  1267. * DMKUSODS - 'DISCONNECT' COMMAND 01108000
  1268. * 01109000
  1269. *********************************************************************** 01110000
  1270. SPACE 01111000
  1271. DMKUSODS RELOC 01112000
  1272. TM VMOSTAT,VMDISC IS USER ALREADY DISCONNECTED 01113000
  1273. BO USO99X YES, EXIT WITH HASTE @VA00881 01114000
  1274. TM VMRSTAT,VMLOGON USER NOT YET LOGGED ON ? 01115000
  1275. BO USO06 YES - TREAT SAME AS "LOGOFF". 01116000
  1276. MVI SAVEWRK1,EDISCON SIGNAL: DISCONNECT ENTERED. 01117000
  1277. BAL R8,USOSUB AND CALL SUBROUTINE TO CHECK COMMAND LINE 01118000
  1278. * COMMAND LINE WAS OK, PROCEED: 01119000
  1279. LA R0,(LNR5+7)/8 GET ENOUGH FREE STORAGE FOR LONGEST MSG 01120000
  1280. CALL DMKFREE ... 01121000
  1281. LR R9,R1 ADDRESS INTO R9 PLEASE 01122000
  1282. LA R1,NR1 POINT TO 'DISCONNECT AT' MSG 01123000
  1283. LA R2,L'NR1-1 LENGTH - 1 IN R2 01124000
  1284. BAL R3,MSGSUBR FILL IN MSG TO BE SENT TO THE USER 01125000
  1285. SPACE 01126000
  1286. CALL DMKQCNWT PARMS ARE ALREADY IN GR2 @VM01017 01127000
  1287. * 01128000
  1288. L R15,SAVERETN GET RETURN-ADDRESS, 01129000
  1289. LA R15,4(,R15) +4 = LET VM RUN, DON'T POST READ. 01130000
  1290. ST R15,SAVERETN STORE CORRECTED RETURN-ADDRESS 01131000
  1291. L R8,VMTERM POINT R8 TO TERMINAL RDEVBLOK 01132000
  1292. SR R15,R15 CLEAR 'VMTERM' SLOT IN VMBLOK 01133000
  1293. ST R15,VMTERM ... 01134000
  1294. OI VMOSTAT,VMDISC SIGNAL USER NOW DISCONNECTED 01135000
  1295. LTR R8,R8 DISCONNECTED DURING QCN CALL? @VA02771 01136000
  1296. BZ DISCEXIT NO TERM --DONT SEND OPERATOR MSG @VA02771 01137000
  1297. * SEND MESSAGE TO SYSTEM OPERATOR RE DISCONNECTED USERID: 01138000
  1298. MVC 0(L'MOP1,R9),MOP1 1ST SKELETON TO MSG BUFFER 01139000
  1299. CLI RDEVTYPC-RDEVBLOK(R8),CLASGRAF 3277/3077 @VM08872 01140000
  1300. BNE *+10 NO - @VM08872 01141000
  1301. MVC 0(4,R9),=C'GRAF' CHANGE 'LINE' TO 'GRAF' @VM08872 01142000
  1302. MVC DMOP3(L'MOP3,R9),MOP3 2ND SKELETON TO MSG BUFFER 01143000
  1303. MVC DMOP3(8,R9),VMUSER PUT IN THE USERID 01144000
  1304. CLI RDEVTYPC-RDEVBLOK(R8),CLASTERM A TERMINAL CLASS 01145000
  1305. BNE *+12 NO, CHECK FOR 370X 01146000
  1306. CLI RDEVTYPE-RDEVBLOK(R8),TYPBSC A BISYNC LINE 01147000
  1307. BE USORESD YES, GET RESOURCE ID. 01148000
  1308. LA R1,CLASSPEC*256+TYP3705 3705 DESCRIPTION @V200820 01149000
  1309. CH R1,RDEVTYPC-RDEVBLOK(,R8) TERMINAL ON A 3705@V200820 01150000
  1310. BNE DISCTERM NO - THAT'S SIMPLE@V200820 01151000
  1311. USORESD EQU * GET RESOURCE ID. 01152000
  1312. LH R1,VMTRMID TERMINAL IDENTIFICATION @V200820 01153000
  1313. CALL DMKCVTBH CONVERT TO EBCDIC @V200820 01154000
  1314. ST R1,4(0,R9) SET IN MESSAGE @V200820 01155000
  1315. MVC 0(4,R9),=C'DEV ' MNEMONIC @V200820 01156000
  1316. B DISCMSG GO SEND MESSAGE TO OPERATOR @V200820 01157000
  1317. SPACE 2 01158000
  1318. DISCTERM EQU * @V200820 01159000
  1319. TM RDEVADD-RDEVBLOK(R8),RDEVLDEV Is this an LDEV? HRC065DK 01159100
  1320. BZ DISCNLDF No, its GRAF HRC065DK 01159150
  1321. MVC 0(5,R9),=C'GRF L' Short name if LDEV 01159200
  1322. LH R1,RDEVADD-RDEVBLOK(,R8) Get the LDEV address HRC065DK 01159250
  1323. N R1,F4095 Keep only the dev num HRC065DK 01159300
  1324. CALL DMKCVTBH Make it displayable HRC065DK 01159350
  1325. STCM R1,7,5(R9) Put dev addr in message HRC065DK 01159400
  1326. B DISCMSG Go display msg HRC065DK 01159450
  1327. * 01159500
  1328. DISCNLDF EQU * Here if not LDEV HRC065DK 01159550
  1329. CALL DMKSCNRD GET 'CCU' ADDRESS @V200820 01160000
  1330. CALL DMKCVTBH CONVERT THAT TO EBCDIC @V200820 01161000
  1331. STCM R1,B'0111',5(R9) @V200820 01162000
  1332. DISCMSG EQU * @V200820 01163000
  1333. L R15,ASYSLC REFERENCE SYSLOCS INFO 01164000
  1334. USING SYSLOCS,R15 ... 01165000
  1335. L R1,DMKSYSNM GET NUMBER OF USERS 01166000
  1336. DROP R15 01167000
  1337. CALL DMKCVTBD BINARY TO DECIMAL PLEASE 01168000
  1338. STCM R1,7,DMOP4(R9) AND STORE IN THE MESSAGE 01169000
  1339. LA R0,LMOP234 LENGTH OF MESSAGE 01170000
  1340. LR R1,R9 ADDRESS, AND ... 01171000
  1341. CALL DMKQCNWT,PARM=OPERATOR+NORET SEND MESSAGE TO OPERATOR 01172000
  1342. DISCEXIT LR R1,R9 ADDRESS OF MSG BUFFER 01173000
  1343. LA R0,(LNR5+7)/8 LENGTH OF MESSAGE BLOCK @VA00881 01174000
  1344. CALL DMKFRET GIVE IT BACK @VA00881 01175000
  1345. B USO99X AND GO EXIT WITHOUT FURTHER ADO. @VA00881 01176000
  1346. EJECT 01177000
  1347. * SUBROUTINE TO ANAYLZE THE COMMAND LINE 01178000
  1348. * (CALLED BY 'LOGOFF' AND 'DISCONNECT') 01179000
  1349. * R8 = RETURN-REGISTER 01180000
  1350. * R9 POINTS TO USUAL COMMAND BUFFER 01181000
  1351. * DMKSCNFD USED TO PICK UP ARGUMENTS IN THE USUAL WAY. 01182000
  1352. * 01183000
  1353. USOSUB DS 0H CHECK FOR POSSIBLE 'HOLD' OPTION: 01184000
  1354. CALL DMKSCNFD ANY ADDITIONAL FIELDS AT ALL ? 01185000
  1355. BCR 7,R8 NOPE - PROCEED WITH LOGOUT OR DISCONNECT. 01186000
  1356. LR R15,R0 SAVE BYTE COUNT 01187000
  1357. BCTR R15,0 LESS ONE FOR EXECUTED COMPARE 01188000
  1358. EX R15,CKHOLD IS IT HOLD ?? 01189000
  1359. BNE ERROR3 NOT EVEN CLOSE 01190000
  1360. LA R15,1 MINIMUM ABBREVIATION IS 'HO' 01191000
  1361. EX R15,CKHOLD CHECK FOR AT LEAST THAT .. 01192000
  1362. BNE ERROR3 CLOSE, BUT NO CIGAR 01193000
  1363. OI VMSVSTAT,VMLGHOLD SET FLAG BIT IF IT WAS 'HOLD' @VA13025 01194100
  1364. BR R8 AND EXIT. 01195000
  1365. SPACE 2 01196000
  1366. CKHOLD CLC HOLD(*-*),0(R1) EXECUTED FOR OPTION TEST 01197000
  1367. SPACE 01198000
  1368. HOLD DC CL6'HOLD' VALID OPTION .. 01199000
  1369. EJECT 01200000
  1370. * MSGSUBR = SUBROUTINE TO CONSTRUCT RESPONSE TO BE SENT TO USER: 01201000
  1371. * AT ENTRY: 01202000
  1372. * R1 = ADDRESS OF INITIAL CHUNK OF MESSAGE 01203000
  1373. * R2 = LENGTH (MINUS 1) OF INITIAL CHUNK OF MESSAGE 01204000
  1374. * R3 = RETURN-REGISTER 01205000
  1375. * R9 = ADDRESS OF MESSAGE BUFFER (LNR5 BYTES LONG) 01206000
  1376. * SAVEWRK1 FLAG HAS ADDITIONAL NEEDED INFO 01207000
  1377. * AT EXIT: 01208000
  1378. * R0 = BYTE-COUNT OF FINISHED MESSAGE 01209000
  1379. * R1 = R9 = ADDRESS OF FINISHED MESSAGE 01210000
  1380. * R2 = 'PRIORITY+LOGDROP' OR 'PRIORITY+LOGHOLD' FOR DMKQCNWT 01211000
  1381. * 01212000
  1382. MSGSUBR MVC 0(8,R9),BLANKS BLANK-FILL THE MSG BUFFER 01213000
  1383. MVC 8(LNR5-8,R9),0(R9) ... 01214000
  1384. EX R2,MVCHUNK MOVE THE FIRST CHUNK TO MSG BUFFER 01215000
  1385. LA R2,1(R9,R2) POINT TO WHERE THE TIME WILL GO 01216000
  1386. L R15,=A(DMKSYSTI) GET ADDR OF TIME ZONE IDENTIFIER 01217000
  1387. MVC 9(3,R2),0(R15) MOVE TO THE MESSAGE 01218000
  1388. LA R1,13(,R2) POINT TO WHERE THE WEEKDAY WILL GO 01219000
  1389. L R14,ASYSLC REFERENCE SYSLOCS INFO 01220000
  1390. USING SYSLOCS,R14 ... 01221000
  1391. SLR R15,R15 GET NUMBER OF BYTES (LESS 1) IN WEEKDAY 01222000
  1392. IC R15,DMKSYSDW+1 ... 01223000
  1393. LA R14,DMKSYSDW+2 POINT AT THE WEEKDAY 01224000
  1394. DROP R14 01225000
  1395. EX R15,MVCWKDAY MOVE TO OUR MESSAGE BUFFER 01226000
  1396. LA R1,2(R1,R15) NOW POINT TO WHERE TO PUT THE DATE 01227000
  1397. CALL DMKCVTDT MOVE DATE AND TIME TO THE RIGHT PLACES 01228000
  1398. TM SAVEWRK1,EFORCE+FORCE FORCED LOGOFF ? @V200820 01229000
  1399. BZ MSGSUBR8 NOPE - NOTHING TO ADD. 01230000
  1400. MVC 9(L'NR5,R1),NR5 ADD 'BY SYSTEM' 01231000
  1401. MSGSUBR8 LR R1,R9 R1 = R9 = ADDRESS OF MESSAGE 01232000
  1402. LA R0,LNR5 SET R0 FOR LENGTH OF WORST CASE MESSAGE 01233000
  1403. LA R15,LNR5-1(,R1) POINT TO LAST BYTE OF MESSAGE 01234000
  1404. LA R2,PRIORITY+LOGDROP SET TENTATIVE PARM FOR DMKQCNWT 01235000
  1405. TM VMSVSTAT,VMLGHOLD DID CALLER WANT 'HOLD' ? @VA13025 01236100
  1406. BCR 8,R3 NOPE - GR2 HAS THE RIGHT PAR@V200820 01237000
  1407. LA R2,PRIORITY+LOGHOLD YES - SET HOLD OPTION INSTEAD. 01238000
  1408. BR R3 RETURN @V200820 01239000
  1409. SPACE 01240000
  1410. MVCHUNK MVC 0(*-*,R9),0(R1) TO MOVE INITIAL CHUNK TO MSG BUFFER 01241000
  1411. MVCWKDAY MVC 0(*-*,R1),0(R14) TO MOVE WEEKDAY TO MSG BUFFER 01242000
  1412. EJECT 01243000
  1413. ERROR3 LA R2,3 ERROR 3 = INVALID OPTION 01244000
  1414. B ERRJOIN ... 01245000
  1415. SPACE 01246000
  1416. ERROR20 LA R2,20 ERROR 20 = USERID MISSING OR INVALID 01247000
  1417. SLR R1,R1 NO DATA PASSED TO ERROR HANDLER 01248000
  1418. B ERRJOIN ... 01249000
  1419. SPACE 01250000
  1420. ERROR45 LA R2,45 ERROR 45 = USERID NOT LOGGED ON 01251000
  1421. LM R0,R1,SAVEWRK2 RECOVER R0/R1 (LOST BY CALL TO DMKSCNAU) 01252000
  1422. * 01253000
  1423. ERRJOIN ICM R0,B'1110',DMKUSO+3 IDENTIFIER INTO R0 HIGH 3 BYTES 01254000
  1424. CALL DMKERMSG CALL ERROR MESSAGE HANDLER 01255000
  1425. * 01256000
  1426. * NOTE: DMKERMSG STORES R2 ERROR-CODE FOR 01257000
  1427. * MY CALLER, AND RETURNS TO MY CALLER. 01258000
  1428. SPACE 1 01259000
  1429. LTORG 01260000
  1430. SPACE 2 01261000
  1431. * VARIOUS MESSAGES, RESPONSES, AND SKELETONS FOR SAME: 01262000
  1432. * 01263000
  1433. * NORMAL RESPONSES: 01264000
  1434. *** 'CONNECT= HH:MM:SS VIRTCPU= MMM:SS.00 TOTCPU= MMM:SS.00' 01265000
  1435. NR1 DC C'DISCONNECT AT ' 01266000
  1436. NR2 DC C'LOGOFF AT ' 01267000
  1437. * DS C'HH:MM:SS ' TIME 01268000
  1438. * DS C'TID ' TIME ZONE = 'EST' OR 'EDT' ETC. 01269000
  1439. * DS C'WEEKDAY ' E.G. WEDNESDAY (WORST CASE) 01270000
  1440. * DS C'DD/MM/YY' DATE 01271000
  1441. NR5 DC C'BY SYSTEM' @V200820 01272000
  1442. SPACE 01273000
  1443. * LONGEST POSSIBLE MESSAGE ISSUED BY LOGOFF/FORCE/DISCONNECT: 01274000
  1444. * 'LOGOFF AT HH:MM:SS EST WEDNESDAY MM/DD/YY BY SYSTEM' 01275000
  1445. LNR5 EQU 52 LENGTH OF ABOVE WORST-CASE MSG @V200820 01276000
  1446. SPACE 01277000
  1447. * MESSAGES SENT TO SYSTEM OPERATOR: 01278000
  1448. MOP1 DC C'LINE XXX DSCONNECT ' NOTE: 8-BYTE USERID ADDED. 01279000
  1449. MOP2 DC C'USER DSC LOGOFF AS ' @V200930 01280000
  1450. MOP3 DC C'USERID USERS = ' 01281000
  1451. MOP4 DC C'NNN' 01282000
  1452. LMOP234 EQU *-MOP2 (LENGTH) 01283000
  1453. MOP5 DC C' FORCED' ADDED FOR FORCED LOGOUT CASES 01284000
  1454. LMOP2345 EQU *-MOP2 (LENGTH) 01285000
  1455. DMOP3 EQU MOP3-MOP2 DISP. OF USERID FROM BEGINNING OF MSG 01286000
  1456. DMOP4 EQU MOP4-MOP2 DISP. OF NNN FROM BEGINNING OF MSG 01287000
  1457. EJECT 01288000
  1458. COPY CORE 01289000
  1459. COPY SAVE 01290000
  1460. * FLAG-BITS USED IN SAVEWRK1: 01291000
  1461. * 01292000
  1462. ELOGOFF EQU X'80' LOGOFF ENTRY 01293000
  1463. EDISCON EQU X'40' DISCONNECT ENTRY 01294000
  1464. EFORCE EQU X'20' FORCE ENTRY 01295000
  1465. FORCE EQU X'02' FORCED LOGOFF BY THE SYSTEM @V200820 01297000
  1466. NOOPMSG EQU X'01' SKIP MESSAGE TO OPERATOR @VM03066 01298000
  1467. EJECT 01299000
  1468. COPY EQU 01300000
  1469. COPY VMBLOK 01301000
  1470. COPY TREXT 01302000
  1471. COPY ACCOUNT @VA00881 01303000
  1472. COPY RBLOKS 01304000
  1473. COPY IOBLOKS @V408246 01304100
  1474. IOBLOK DSECT CONTINUE THE DSECT @V408246 01304200
  1475. ORG , LOCATE END OF BLOCK @V408246 01304300
  1476. * ANY CHANGES IN PAGESIZE MUST ALSO BE REFLECTED 01304325
  1477. * IN DMKPAG AND DMKMON 01304375
  1478. * FOLLOWING SIZE MUST CORRESPOND WITH DMKPAG 01304400
  1479. DS 7D SIZE OF PAGE EXTENDED I/O BLOCK @V408246 01304500
  1480. PAGESIZE EQU (*-IOBLOK)/8 SIZE OF EXTENDED BLOCK @V408246 01304600
  1481. COPY SPOOL @VA00881 01305000
  1482. COPY ALLOC @VA00881 01306000
  1483. COPY VBLOKS 01307000
  1484. COPY TIMER 01308000
  1485. COPY DEVTYPES 01309000
  1486. PSA 01310000
  1487. SYSLOCS 01311000
  1488. COPY MICBLOK 01312000
  1489. COPY CONBUF @VA08501 01312100
  1490. END DMKUSO 01313000
ibm/vm370-lib/cp/dmkuso.assemble_src.txt ยท Last modified: 2023/08/06 13:37 by Site Administrator