Table of Contents

DMKQCN Source

References

Source Listing

DMKQCN.ASSEMBLE.txt
  1. QCN TITLE 'DMKQCN (CP) VM/370 - RELEASE 6' 00001000
  2. ISEQ 73,80 VALIDATE SEQUENCING OF SYSIN @V200820 00002000
  3. *. 00003000
  4. * MODULE NAME - 00004000
  5. * 00005000
  6. * DMKQCN 00006000
  7. * 00007000
  8. * CONTENTS - 00008000
  9. * 00009000
  10. * DMKQCNRD - QUEUE CONSOLE READ REQUEST 00010000
  11. * DMKQCNWT - QUEUE CONSOLE WRITE REQUEST 00011000
  12. * DMKQCNSY - SYNCHRONIZE CONSOLE ACTIVITY 00012000
  13. * DMKQCNTO - DISCONNECT VIRTUAL MACHINE DUE TO LINE FAILURE 00013000
  14. * DMKQCNCL - CLEAR CONSOLE REUEST STACK 00014000
  15. * DMKQCNET - PROCESS COMPLETED CONTASK REQUESTS 00015000
  16. *. 00016000
  17. EJECT 00017000
  18. COPY OPTIONS @V200820 00018000
  19. COPY LOCAL OPTIONS @V200820 00019000
  20. SPACE 2 00020000
  21. DMKQCN START , 00021000
  22. SPACE 3 00022000
  23. USING PSA,R0 @V200820 00023000
  24. USING CONTASK,R6 @V200820 00024000
  25. USING VMBLOK,R11 @V200820 00025000
  26. USING SAVEAREA,R13 @V200820 00026000
  27. SPACE 00027000
  28. ENTRY DMKQCNRD,DMKQCNWT,DMKQCNSY @V200820 00028000
  29. ENTRY DMKQCNTO,DMKQCNCL,DMKQCNET @V200820 00029000
  30. SPACE 00030000
  31. EXTRN DMKCVTDT,DMKVSPVP,DMKSTKCP @V200820 00031000
  32. EXTRN DMKSCNRD,DMKSCNRN,DMKCVTBH,DMKRGBIC @V305798 00032000
  33. EXTRN DMKSCHRT,DMKSCHST,DMKCVTBD,DMKSCHDL @V200820 00033000
  34. EXTRN DMKCNSIC,DMKGRFIC,DMKRNHIC,DMKSYSNM @V200820 00034000
  35. EXTRN DMKCVTAB @VA04301 00034100
  36. EXTRN DMKGRTDS @V60A6B6 00034550
  37. EXTRN DMKTBLSF @VA13491 00034800
  38. EJECT 00035000
  39. *. 00036000
  40. * SUBROUTINE NAME - 00037000
  41. * 00038000
  42. * DMKQCNRD 00039000
  43. * 00040000
  44. * FUNCTION - 00041000
  45. * 00042000
  46. * TO INITIATE A CONSOLE READ REQUEST 00043000
  47. * 00044000
  48. * ATTRIBUTES - 00045000
  49. * 00046000
  50. * SERIALLY REUSABLE, RESIDENT, CALLED VIA SVC 00047000
  51. * 00048000
  52. * ENTRY CONDITIONS - 00049000
  53. * 00050000
  54. * GPR0 = MAXIMUM NUMBER OF BYTES OF INPUT EXPECTED 00051000
  55. * GPR1 = ADDRESS OF INPUT BUFFER 00052000
  56. * GPR2 = PARAMETER AS FOLLOWS: 00053000
  57. * EDIT - REQUESTS THAT THE INPUT LINE BE EDITED FOR 00054000
  58. * LOGICAL LINE END, LINE DELETE, AND CHARACTER DELETE 00055000
  59. * CHARACTERS. 00056000
  60. * UCASE - REQUESTS THAT ALL CHARACTERS IN THE INPUT 00057000
  61. * LINE BE TRANSLATED TO UPPER-CASE. 00058000
  62. * VMGENIO - SPECIFIES THAT THIS REQUEST IS FOR VIRTUAL 00059000
  63. * MACHINE GENERATED I/O. 00060000
  64. * INHIBIT - SPECIFIES THAT THIS READ DATA SHOULD NOT BE 00061000
  65. * DISPLAYED AT THE TERMINAL OR SPOOLED. 00062000
  66. * GPR11 = ADDRESS OF USER'S VMBLOK 00063000
  67. * GPR12 = ADDRESS OF DMKQCNRD 00064000
  68. * 00065000
  69. * EXIT CONDITIONS - 00066000
  70. * 00067000
  71. * SUCCESSFUL READ COMPLETION: 00068000
  72. * CC = 0; GPR0 = NUMBER OF BYTES READ 00069000
  73. * UNSUCCESSFUL: 00070000
  74. * CC = 2; GPR2 = 4 => SINGLE ATTENTION HIT 00071000
  75. * GPR2 = 8 => MULTIPLE ATTENTIONS HIT 00072000
  76. * GPR2 = 12 => LINE BREAK OCCURRED DURING READ 00073000
  77. * 00074000
  78. * CALLS TO OTHER ROUTINES - 00075000
  79. * 00076000
  80. * DMKFREE 00077000
  81. * DMKSTKCP 00078000
  82. * DMKCNSIC 00079000
  83. * DMKGRFIC 00080000
  84. * DMKRNHIC 00081000
  85. * DMKRGBIC 00082000
  86. * DMKVSPVP 00083000
  87. * DMKLOKSW 00083100
  88. * 00084000
  89. * EXTERNAL REFERENCES - NONE 00085000
  90. * 00086000
  91. * TABLES / WORK AREAS - NONE 00087000
  92. * 00088000
  93. * REGISTER USAGE - 00089000
  94. * 00090000
  95. * GPR0 = MAXIMUM INPUT COUNT 00091000
  96. * GPR1 = ADDRESS OF INPUT BUFFER 00092000
  97. * GPR2 = PARAMETER REGISTER 00093000
  98. * GPR6 = ADDRESS OF CONTASK 00094000
  99. * GPR11 = ADDRESS OF USER'S VMBLOK 00095000
  100. * GPR12 = MODULE BASE REGISTER 00096000
  101. * GPR13 = ADDRESS OF SAVEAREA 00097000
  102. * 00098000
  103. * GPRS 3-5, 7-10 ARE WORK REGISTERS 00099000
  104. * 00100000
  105. * NOTES - 00101000
  106. * 00102000
  107. * THE INPUT BUFFER POINTED TO BY GPR1 MUST BE LARGE ENOUGH TO 00103000
  108. * CONTAIN THE NUMBER OF BYTES SPECIFIED IN GPR0 PLUS 2. 00104000
  109. * 00105000
  110. * OPERATION - 00106000
  111. * 00107000
  112. * 1. IF THE USER IS DISCONNECTED, CALL DMKQCNTO, SET 00108000
  113. * CC = 2, GPR2 = 12, AND EXIT. 00109000
  114. * 2. CLEAR INPUT BUFFER USING COUNT IN GPR0 00110000
  115. * 3. CALL DMKFREE TO GET A CONTASK 00111000
  116. * 4. INITIALIZE CONTASK FIELDS, SAVE INPUT PARMS 00112000
  117. * 5. QUEUE THE CONTASK ON THE TERMINAL RDEVBLOK 00113000
  118. * 6. IF THERE WERE NO OTHER CONTASKS QUEUED, OR IF THIS 00114000
  119. * CONTASK IS A 'PRIORITY' TASK, GOTO THE INTERRUPT 00115000
  120. * HANDLER ACCORDING TO DEVICE CLASS. 00116000
  121. * 7. OTHERWISE, GOTO DMKDSPCH AND WAIT FOR COMPLETION 00117000
  122. *. 00118000
  123. EJECT 00119000
  124. DMKQCNRD DS 0D ENTRY FOR CONSOLE INPUT @V200820 00120000
  125. ENTER @V200820 00121000
  126. USING DMKQCN,R12 @V200820 00122000
  127. SPACE 2 00123000
  128. TM VMOSTAT,VMDISC IS THERE A PHYSICAL TERMINAL@V200820 00124000
  129. BO DISLEEP NO -- START TIME-BOMB LOGOFF@V200820 00125000
  130. L R8,VMTERM REFERENCE TERMINAL RDEVBLOK @V200820 00126000
  131. LTR R8,R8 MAKE SURE IT EXISTS @V200820 00127000
  132. BZ DISLEEP IF NOT -- ASSUME DISCONNECTED @V200820 00128000
  133. SPACE 00129000
  134. SLR R4,R4 CLEAR RETURN CODE IN SAVE-AREA @V200820 00130000
  135. ST R4,SAVER2 ... @V200820 00131000
  136. SPACE 00132000
  137. LR R0,R1 EXCHANGE R0,R1 FOR CLEAR @V200820 00133000
  138. L R1,SAVER0 ... @V200820 00134000
  139. SR R5,R5 SET ZERO PAD AND COUNT @V200820 00135000
  140. MVCL R0,R4 CLEAR INPUT BUFFER @V200820 00136000
  141. SPACE 00137000
  142. LA R0,CONTSIZE GET A BASIC CONTASK @V200820 00138000
  143. BAL R9,INITCON ...FOR READ OPERATION @V200820 00139000
  144. NI CONPARM,VMGENIO+INHIBIT+EDIT+UCASE PARMS @V200820 00140000
  145. ST R13,CONRETN PUT SAVE-AREA ADDRESS IN CONTASK @V200820 00141000
  146. OI CONSTAT,CONRESP RESPONSE IS EXPECTED @V200820 00142000
  147. LM R3,R4,SAVER0 CALLER'S BUFFER AND LENGTH @V200820 00143000
  148. ST R4,CONADDR PASS DATA BUFFER START ADDRESS @V200820 00144000
  149. STH R3,CONCNT ...AND THE MAXIMUM DATA LENGTH @V200820 00145000
  150. SPACE 00146000
  151. QCNMC0 MC MNCOBRD,MNCLRESP RESPONSE CLASS, BEGIN READ @VM01017 00147000
  152. EJECT 00148000
  153. USING RDEVBLOK,R8 @V200820 00149000
  154. ENQUEUE EQU * STACK THE CONTASK FOR INTERRUPT HANDLER @V200820 00150000
  155. L R8,VMTERM MAKE SURE WE HAVE THE RDEVBLOK @V200820 00151000
  156. L R2,RDEVCON GET CONTASK STACK @V200820 00152000
  157. LTR R2,R2 EMPTY? @V200820 00153000
  158. BNZ FINDEND NO, QUEUE REQUEST @V200820 00154000
  159. ST R6,RDEVCON PUT THIS CONTASK AT TOP OF STACK @V200820 00155000
  160. TM CONSTAT,CONSPLT IS THIS A SPLIT CONTASK ? @V200820 00156000
  161. BZ WAKEUPR NO -- ALL SET FOR THE ALERT @V200820 00157000
  162. LR R6,R5 POINT TO THE LAST SPLIT TASK @V200820 00158000
  163. B WAKEUPR GO WAKE UP THE DEVICE HANDLER @V200820 00159000
  164. SPACE 00160000
  165. FINDEND EQU * @V200820 00161000
  166. TM CONPARM,PRIORITY PRIORITY OPTION ? @V200820 00162000
  167. BZ NORMEND NO -- STACK AT END OF CHAIN @V200820 00163000
  168. PRIORFR EQU * FIND FIRST TASK FOR THIS USER @V200820 00164000
  169. CL R11,CONUSER-CONTASK(,R2) SAME USER = OWNER ? @V200820 00165000
  170. BE PRIORIN YES - SEARCH @V200820 00166000
  171. L R3,CONPNT-CONTASK(,R2) INSERT AFTER FIRST TASK@V200820 00167000
  172. LTR R3,R3 ...WE FIND FOR THIS USER @V200820 00168000
  173. BNP PRIORPT END OF CHAIN - PUT IT HERE @V200820 00169000
  174. LR R2,R3 @V200820 00170000
  175. B PRIORFR CONTINUE UNTIL WE FIND ONE @V200820 00171000
  176. SPACE 00172000
  177. PRIORIN EQU * @V200820 00173000
  178. L R3,CONPNT-CONTASK(,R2) GET NEXT CONTASK @V200820 00174000
  179. LTR R3,R3 ZERO ? @V200820 00175000
  180. BZ PRIORPT YES @V200820 00176000
  181. CL R11,CONUSER-CONTASK(,R3) CORRECT USER ? @V200820 00177000
  182. BNE PRIORNX NO -- SKIP POSSIBLE INSERT HERE @V200820 00178000
  183. TM CONPARM-CONTASK(R3),PRIORITY PRIORITY ? @V200820 00179000
  184. BZ PRIORPT NO -- PUT IT HERE @V200820 00180000
  185. PRIORNX EQU * SKIP CONTASK'S FOR OTHER USERS @V200820 00181000
  186. LR R2,R3 KEEP SEARCHING CHAIN @V200820 00182000
  187. B PRIORIN @V200820 00183000
  188. PRIORPT EQU * @V200820 00184000
  189. ST R6,CONPNT-CONTASK(,R2) PATCH THE FORWARD CHAIN@V200820 00185000
  190. TM CONSTAT,CONSPLT IS THIS A STRING OF TASKS ? @V200820 00186000
  191. BZ *+6 NO -- JUST CHAIN IN ONE @V200820 00187000
  192. LR R6,R5 SET GR6 = LAST SPLIT TASK @V200820 00188000
  193. ST R3,CONPNT CHAIN CONTASK HERE @V200820 00189000
  194. * B WAKEUPR GO ALERT THE INTERRUPT HANDLER @V200820 00190000
  195. EJECT 00191000
  196. WAKEUPR EQU * ALERT THE DEVICE HANDLER ROUTINE @V200820 00192000
  197. L R4,=A(DMKRNHIC) SPECIAL-CLASS PROCESSOR @V200820 00193000
  198. CLI RDEVTYPC,CLASSPEC IS THIS 3704 OR 3705 ? @V200820 00194000
  199. BE WAKEMUP YES - ALL SET @V200820 00195000
  200. L R4,=A(DMKCNSIC) TERMINAL-CLASS PROCESSOR @V200820 00196000
  201. CLI RDEVTYPC,CLASTERM IS THIS 2741, 1050, TTY ? @V200820 00197000
  202. BNE GRAPHIC NO, GET GRAPHIC ROUTINE ADDRESS @V2D3931 00198000
  203. TM RDEVTYPE,TYPBSC IS THIS A BISYNC LINE @V2D3931 00199000
  204. BZ WAKEMUP NO, ... @V2D3931 00200000
  205. L R4,=A(DMKRGBIC) POINTER TO 3270 REMOTE MODULE @V305798 00201000
  206. B WAKEMUP GO TO THE ROUTINE @V2D3931 00202000
  207. GRAPHIC EQU * @V2D3931 00203000
  208. L R4,=A(DMKGRFIC) MUST BE A GRAPHICS DEVICE @V200820 00204000
  209. WAKEMUP EQU * @V200820 00205000
  210. TM CONSTAT,CONRESP NEED TO EXIT RIGHT NOW ? @V200820 00206000
  211. BO WAKERGO NO -- JUST GOTO THE SLIH @V200820 00207000
  212. BAL R10,STKCPEX STACK CPEXBLOK FOR SLIH ALERT @V200820 00208000
  213. B EXIT WE MUST EXIT TO CALLER FIRST @V200820 00209000
  214. SPACE 00210000
  215. WAKERGO EQU * GO WAKE UP THE INTERRUPT HANDLER @V200820 00211000
  216. LR R12,R4 ENTRY POINT ADDRESS @V200820 00212000
  217. BR R12 GO THERE @V200820 00213000
  218. EJECT 00214000
  219. NORMEND EQU * @V200820 00215000
  220. L R3,CONPNT-CONTASK(,R2) GET NEXT CONTASK @V200820 00216000
  221. LTR R3,R3 IS IT ZERO? @V200820 00217000
  222. BZ STFDEND YES, FOUND END @V200820 00218000
  223. LR R2,R3 SAVE THIS ONE @V200820 00219000
  224. B NORMEND AND LOOP @V200820 00220000
  225. STFDEND EQU * @V200820 00221000
  226. ST R6,CONPNT-CONTASK(,R2) QUEUE CONTASK @V200820 00222000
  227. TM CONSTAT,CONSPLT IS THIS A SPLIT CONTASK ? @V200820 00223000
  228. BZ *+6 NO -- O.K. AS IS @V200820 00224000
  229. LR R6,R5 SET GR6 = LAST OF SPLIT TASKS @V200820 00225000
  230. TM CONSTAT,CONRESP EXIT NOW OR LATER ? @V200820 00226000
  231. BO GODSPCH LATER - GOTO DMKDSPCH NOW @V200820 00227000
  232. SPACE 2 00228000
  233. EXIT EQU * @V200820 00229000
  234. L R1,SAVER11 GET CALLER'S VMBLOK ADDRESS @V407508 00230100
  235. SWTCHVM SWITCH TO CALLER'S VMBLOK @V407508 00231100
  236. SR R15,R15 RETURN CONDITION-CODE = 0 @V200820 00233000
  237. QCNEXIT EQU * EXIT TO CALLER @V200820 00234000
  238. EXIT @V200820 00235000
  239. SPACE 00236000
  240. GODSPCH EQU * GO AWAY FOR A WHILE @V200820 00237000
  241. GOTO DMKDSPCH @V200820 00238000
  242. SPACE 2 00239000
  243. DISLEEP EQU * START TIME-BOMB LOGOFF PROCESS @V200820 00240000
  244. CALL DMKQCNTO FORCE DISCONNECT TIME-OUT @V200820 00241000
  245. LA R2,12 LINE BREAK RETURN CODE @V200820 00242000
  246. ST R2,SAVER2 RETURN IN GR2 @V200820 00243000
  247. LTR R2,R2 SET CONDITION CODE TWO @V200820 00244000
  248. B QCNEXIT ...AND RETURN TO CALLER @V200820 00245000
  249. EJECT 00246000
  250. *. 00247000
  251. * SUBROUTINE NAME - 00248000
  252. * 00249000
  253. * DMKQCNWT 00250000
  254. * 00251000
  255. * FUNCTION - 00252000
  256. * 00253000
  257. * TO INITIATE A CONSOLE WRITE REQUEST 00254000
  258. * 00255000
  259. * ATTRIBUTES - 00256000
  260. * 00257000
  261. * SERIALLY REUSABLE, RESIDENT, CALLED VIA SVC 00258000
  262. * 00259000
  263. * ENTRY CONDITIONS - 00260000
  264. * 00261000
  265. * GPR0 = NUMBER OF BYTES IN MESSAGE 00262000
  266. * GPR1 = ADDRESS OF MESSAGE 00263000
  267. * GPR2 = PARAMETER AS FOLLOWS: 00264000
  268. * LOGHOLD - SPECIFIES THAT AFTER THIS MESSAGE THE USER 00265000
  269. * WILL BE LOGGED OUT, BUT THE TELEPHONE CONNECTION 00266000
  270. * SHOULD NOT BE DROPPED. 00267000
  271. * LOGDROP - SPECIFIES THAT AFTER THIS MESSAGE THE USER 00268000
  272. * WILL BE LOGGED OUT AND THAT THE TELEPHONE CONNECTION 00269000
  273. * SHOULD BE DROPPED. 00270000
  274. * DFRET - SPECIFIES THAT THE MESSAGE BUFFER SHOULD BE 00271000
  275. * RETURNED TO FREE STORAGE AFTER TRANSLATION. WHEN THIS 00272000
  276. * PARAMETER IS SPECIFIED GPR3 CONTAINS THE NUMBER OF 00273000
  277. * DOUBLE WORDS TO BE RETURNED. IF DFRET IS SPECIFIED 00274000
  278. * THE NORET PARAMETER MUST ALSO BE SPECIFIED. 00275000
  279. * NORET - SPECIFIES THAT THE RETURN WILL NOT BE DELAYED 00276000
  280. * UNTIL THE MESSAGE COMPLETES TYPING ON THE TERMINAL. 00277000
  281. * NO ABILITY EXISTS TO DETECT AN ATTENTION WHEN THIS 00278000
  282. * PARAMETER IS SPECIFIED. 00279000
  283. * OPERATOR - SPECIFIES THAT THIS MESSAGE IS TO BE TYPED 00280000
  284. * AT THE SYSTEM OPERATOR'S TERMINAL. 00281000
  285. * ALARM - SPECIFIES THAT THE CONSOLE ALARM IS TO BE SOUNDED 00282000
  286. * AS THE MESSAGE IS TYPED. IF THE MESSAGE IS NOT 00283000
  287. * TYPED AT A CONSOLE WITH AN ALARM, THE ALARM OPTION 00284000
  288. * WILL BE IGNORED. 00285000
  289. * PRIORITY - SPECIFIES THAT THIS MESSAGE SHOULD BE TYPED 00286000
  290. * IMMEDIATELY. IF A READ IS ACTIVE WHEN A PRIORITY 00287000
  291. * MESSAGE IS QUEUED, THE READ WILL BE TERMINATED AND 00288000
  292. * RESTARTED AFTER THE PRIORITY MESSAGE HAS BEEN TYPED. 00289000
  293. * NOAUTO - SPECIFIES THAT THE AUTOMATIC CARRIAGE RETURN 00290000
  294. * IS TO BE SUPPRESSED 00291000
  295. * NOTIME - SPECIFIES THAT ANY TIME STAMP BE SUPPRESSED. 00292000
  296. * VMGENIO - SPECIFIES THAT THIS REQUEST IS THE RESULT OF 00293000
  297. * A VIRTUAL MACHINE I/O OPERATION. 00294000
  298. * NOTRESP - SPECIFIES THAT FOLLOWING RESPONSES ARE NOT 00294250
  299. * COMMAND RESPONSES TO BE PLACED IN USER'S BUFFER. 00294500
  300. * WRITE THESE RESPONSES ON USER'S CONSOLE. 00294750
  301. * ERRMSG - SPECIFIES THAT THIS IS AN ERROR MESSAGE AND 00295000
  302. * SHOULD BE TYPED UNDER CONTROL OF THE 'VMMLEVEL' FLAGS 00296000
  303. * IN THE USER'S VMBLOK. 00297000
  304. * GPR11 = ADDRESS OF USER'S VMBLOK 00298000
  305. * GPR12 = ADDRESS OF DMKQCNWT 00299000
  306. * 00300000
  307. * EXIT CONDITIONS - 00301000
  308. * 00302000
  309. * GPR0-GPR1, GPR3-GPR13 ARE RESTORED. 00303000
  310. * 00304000
  311. * IF NEITHER 'NORET' NOR 'DFRET' WERE SPECIFIED, THEN: 00305000
  312. * SUCCESSFUL WRITE: CC = 0; GPR2 = 0 00306000
  313. * SINGLE ATTENTION: CC = 2; GPR2 = 4 00307000
  314. * MULTIPLE ATTEN'S: CC = 2; GPR2 = 8 00308000
  315. * LINE BREAK: CC = 2; GPR2 = 12 00309000
  316. * 00310000
  317. * CALLS TO OTHER ROUTINES - 00311000
  318. * 00312000
  319. * DMKFREE 00313000
  320. * DMKCVTDT 00314000
  321. * DMKSTKCP 00315000
  322. * DMKVSPVP 00316000
  323. * DMKCNSIC 00317000
  324. * DMKGRFIC 00318000
  325. * DMKRNHIC 00319000
  326. * DMKLOKSW 00319100
  327. * 00320000
  328. * EXTERNAL REFERENCES - NONE 00321000
  329. * 00322000
  330. * TABLES / WORK AREAS - NONE 00323000
  331. * 00324000
  332. * REGISTER USAGE - 00325000
  333. * 00326000
  334. * GPR0 = MESSAGE COUNT 00327000
  335. * GPR1 = ADDRESS OF MESSAGE 00328000
  336. * GPR2 = PARAMETER REGISTER 00329000
  337. * GPR6 = ADDRESS OF CONTASK 00330000
  338. * GPR11 = ADDRESS OF USER'S VMBLOK 00331000
  339. * GPR12 = MODULE BASE REGISTER 00332000
  340. * GPR13 = ADDRESS OF SAVEAREA 00333000
  341. * 00334000
  342. * GPRS 3-5, 7-10 ARE WORK REGISTERS 00335000
  343. * 00336000
  344. * NOTES - 00337000
  345. * 00338000
  346. * NONE 00339000
  347. * 00340000
  348. * OPERATION - 00341000
  349. * 00342000
  350. * (TO BE CONTINUED) 00343000
  351. *. 00344000
  352. EJECT 00345000
  353. DMKQCNWT DS 0D ENTRY POINT FOR CONSOLE OUTPUT @V200820 00346000
  354. USING *,R12 @V200820 00347000
  355. ENTER @V200820 00348000
  356. L R12,=A(DMKQCN) ESTABLISH MODULE BASE @V200820 00349000
  357. USING DMKQCN,R12 @V200820 00350000
  358. SPACE 2 00351000
  359. STM R0,R1,SAVEWRK2 SAVE R0,R1 FOR ADJUSTMENT @VM08816 00352000
  360. XC SAVEWRK9,SAVEWRK9 CLEAR FOR FLAGS LATER HRC101DK 00352500
  361. L R15,SAVER2 Get write parameters HRC064DK 00352503
  362. N R15,NOQMASK Any 'no queue' bits set?HRC064DK 00352506
  363. BNZ QCN000 Yes, dont queue msg HRC064DK 00352509
  364. TM SAVER2+2,NOTRESP/256 Dont put in resp buffer?HRC064DK 00352512
  365. BO CHKQUE Ok, but queue it HRC064DK 00352515
  366. ICM R15,15,VMCONBUF Is respond buffer avail?HRC064DK 00352518
  367. BNZ QCN000 Y, use respond buffer HRC064DK 00352521
  368. * HRC064DK 00352524
  369. CHKQUE EQU * Continue queuing checks HRC064DK 00352527
  370. CLC VMVTERM,=X'FFFF' Does virt console exist?HRC062DK 00352530
  371. BE QCN000 No vcons available HRC062DK 00352540
  372. ICM R8,15,VMTERM -> RDEVBLOK of virt consHRC062DK 00352550
  373. BZ QCN000 No RDEVBLOK, exit HRC062DK 00352560
  374. USING RDEVBLOK,R8 HRC062DK 00352570
  375. TM RDEVSTA3,RDEVFULL Dev in full screen mode?HRC062DK 00352580
  376. BZ QCN000 No HRC062DK 00352590
  377. DROP R8 RDEVBLOK HRC062DK 00352600
  378. C R0,=F'256' Message len > 256? HRC062DK 00352610
  379. BH QCN000 Don't queue it, send nowHRC062DK 00352620
  380. TM SAVER2+2,ERRMSG/256 Is this an error msg? HRC063DK 00352622
  381. BZ EMSGOFF N, skip EMSG checking HRC063DK 00352624
  382. TM VMMLEVEL,VMMCODE+VMMTEXT Use any part of msg? HRC063DK 00352626
  383. BZ QCN000 N, dont queue message HRC063DK 00352628
  384. * HRC062DK 00352630
  385. EMSGOFF EQU * HRC063DK 00352635
  386. SRL R0,3 Compute msg size in dwdsHRC062DK 00352640
  387. LA R1,QMBSIZE+1 Size of QMBLOK + 1 dwordHRC062DK 00352650
  388. AR R0,R1 Size of area needed HRC062DK 00352660
  389. CALL DMKFREE Get QMBLOK stg HRC062DK 00352670
  390. XC 0(QMBSIZE*8,R1),0(R1) Init fixed part QMBLOK HRC062DK 00352680
  391. USING QMBLOK,R1 QMBLOK is def in VBLOKS HRC062DK 00352690
  392. * HRC062DK 00352700
  393. ST R0,QMSIZE Save size of this QMBLOKHRC062DK 00352710
  394. N R2,=A(-1-DFRET-NORET) Set FRET stg flags off HRC063DK 00352715
  395. ST R2,QMQCNR2 Save QCN R2 options HRC062DK 00352720
  396. LH R8,VMVTERM Displ of vcons VDEVBLOK HRC062DK 00352730
  397. AL R8,VMDVSTRT -> vconsole VDEVBLOK HRC062DK 00352740
  398. USING VDEVBLOK,R8 HRC062DK 00352750
  399. LA R2,VDEVQMB -> QMBLOK anchor HRC062DK 00352760
  400. * 00352770
  401. QMCH000 EQU * 00352780
  402. ICM R0,15,QMNEXT-QMBLOK(R2) -> next QMBLOK HRC062DK 00352790
  403. BZ QMCH010 Find end of QMBLOK chainHRC062DK 00352800
  404. LR R2,R0 Copy QMBLOK ptr HRC062DK 00352810
  405. B QMCH000 Find end of chain HRC062DK 00352820
  406. * 00352830
  407. QMCH010 EQU * 00352840
  408. ST R1,QMNEXT-QMBLOK(,R2) Queue QMBLOK to chain HRC062DK 00352850
  409. LM R14,R15,SAVER0 Get message len, addr HRC062DK 00352860
  410. ST R14,QMQCNR0 Save original msg lengthHRC062DK 00352870
  411. BCTR R14,0 Make IBM length HRC062DK 00352880
  412. EX R14,QCNMVC Move msg to QMBLOK HRC062DK 00352890
  413. B WREX FRET msg stg and exit HRC063DK 00352900
  414. * HRC062DK 00352920
  415. QCNMVC MVC QMMSGTXT(0),0(R15) Executed instr HRC062DK 00352930
  416. DROP R1,R8 QMBLOK, VDEVBLOK HRC062DK 00352940
  417. * HRC062DK 00352950
  418. QCN000 EQU * HRC062DK 00352960
  419. LTR R4,R0 CHECK BYTE COUNT @V200820 00353000
  420. BNP QCN003 LEAVE COUNT ALONE @V200820 00354000
  421. TM SAVER2+3,NOAUTO WAS "NOAUTO" SPECIFIED ? @V200820 00355000
  422. BO QCN003 YES - LEAVE BYTE COUNT ALONE @V200820 00356000
  423. TM SAVER2,X'40' DIAGNOSE WRITE TO GRAPHIC DEVICE @V200820 00357000
  424. BO QCN003 YES - DO NOT ADJUST COUNT @V200820 00358000
  425. SPACE 00359000
  426. LA R15,0(R4,R1) POINT TO LAST BYTE PLUS ONE @V200820 00360000
  427. * DELETE TRAILING BLANKS (IF ANY) FROM THE BYTE-COUNT: 00361000
  428. QCN001 EQU * @V200820 00362000
  429. BCTR R15,0 POINT TO NEW "LAST BYTE" @V200820 00363000
  430. CLI 0(R15),C' ' A BLANK ? @V200820 00364000
  431. BNE QCN002 NOPE - WE'RE THRU CHECKING. @V200820 00365000
  432. BCT R4,QCN001 YES, DECREMENT BYTE-COUNT @V200820 00366000
  433. LA R4,1 SET COUNT = 1 FOR BLANK LINE @V200820 00367000
  434. QCN002 ST R4,SAVEWRK2 STORE ADJUSTED BYTE COUNT @VM08816 00368000
  435. SPACE 2 00369000
  436. QCN003 EQU * START DECODING PARAMETERS @V200820 00370000
  437. STC R2,SAVEWRK1 SAVE LOW-ORDER PARMS IN SAVEWRK1 @V200820 00371000
  438. TM VMMLEVEL,VMMSTMP ALL TIME STAMPS ON HRC101DK 00371100
  439. BNO QCN003A NO, CONTINUE HRC101DK 00371200
  440. NI SAVEWRK1,255-NOTIME RESET NO TIME STAMP HRC101DK 00371300
  441. B QCN003B CONTINUE HRC101DK 00371400
  442. QCN003A EQU * HRC101DK 00371500
  443. OI SAVEWRK1,NOTIME ASSUME NO TIME STAMP @V200820 00372000
  444. QCN003B EQU * HRC101DK 00372500
  445. TM VMOSTAT,VMSYSOP IS THIS THE SYSTEM OPERATOR @V200820 00373000
  446. BO WRSYSOP YES - HE IS A SPECIAL PERSON@V200820 00374000
  447. TM SAVER2+2,OPERATOR/256 MESSAGE FOR OPERATOR ? @V200820 00375000
  448. BZ WRTIMES NO -- CHECK FOR TIME STAMP @V200820 00376000
  449. L R1,ASYSOP GET ADDRESS OF OPERATOR'S VMBLOK @V407508 00377100
  450. SWTCHVM SWITCH TO OPERATOR'S VMBLOK @V407508 00378100
  451. L R1,SAVEWRK3 RESTORE ADDRESS OF MESSAGE @V407508 00379100
  452. SPACE 00380000
  453. WRSYSOP EQU * WRITE TO THE SYSTEM OPERATOR @V200820 00381000
  454. TM SAVER2+3,VMGENIO VIRTUAL MACHINE MESSAGE ? @V200820 00382000
  455. BO WRTERMG YES - NORMAL HANDLING @V200820 00383000
  456. TM SAVER2+3,NOTIME SUPPRESS THE TIME STAMP ? @V200820 00384000
  457. BO *+8 YES - LEAVE IT AS IS @V200820 00385000
  458. NI SAVEWRK1,255-NOTIME TIME STAMP THE MESSAGE @V200820 00386000
  459. TM SAVER2+2,ERRMSG/256 IS THIS AN ERROR MSG ? @V200820 00387000
  460. BZ WRDSCK NO -- LET IT GO @V200820 00388000
  461. OI SAVEWRK1,ALARM RING THE ALARM IF 3215 @V200820 00389000
  462. B WRTEMSG GO TEST 'VMMLEVEL' SETTINGS @V200820 00390000
  463. EJECT 00391000
  464. WRTIMES EQU * CHECK TERMINAL TIME-STAMP @V200820 00392000
  465. TM VMMLEVEL,VMMSTMP TIME STAMP DESIRED ? @V200820 00393000
  466. BZ WRTERMG NO -- CHECK FOR ERROR MSGS @V200820 00394000
  467. TM SAVER2+3,NOTIME+VMGENIO SUPPRESS TIME STAMP ? @V200820 00395000
  468. BNZ WRTERMG YES - GO CONTINUE CHECKING @V200820 00396000
  469. NI SAVEWRK1,255-NOTIME TIME STAMP THE MESSAGE @V200820 00397000
  470. WRTERMG EQU * @V200820 00398000
  471. TM SAVER2+2,ERRMSG/256 IS THIS AN ERROR MSG ? @V200820 00399000
  472. BZ WRDSCK NO -- CHECK TERMINAL @V200820 00400000
  473. WRTEMSG EQU * TEST 'VMMLEVEL' SETTINGS FOR ERRMSG @V200820 00401000
  474. TM VMMLEVEL,VMMCODE+VMMTEXT ANY PART OF MESSAGE ? @V200820 00402000
  475. BZ WRTDFT NO @V200820 00403000
  476. BO WRDSCK ENTIRE MESSAGE @V200820 00404000
  477. TM VMMLEVEL,VMMTEXT MESSAGE TEXT DESIRED ? @V200820 00405000
  478. BZ WRTERCD NO -- JUST WRITE THE CODE @V200820 00406000
  479. S R4,=F'11' ORIGINAL LENGTH MINUS CODE LENGTH@V200820 00407000
  480. BNP WRDSCK NOTHING BUT A CODE - TYPE IT @V200820 00408000
  481. ST R4,SAVEWRK2 RESET MESSAGE BYTE COUNT @VM08816 00409000
  482. LA R1,11(,R1) REPOINT TO TEXT PART OF MESSAGE @V200820 00410000
  483. ST R1,SAVEWRK3 . . . @VM08816 00411000
  484. B WRDSCK GO WRITE THE MESSAGE @V200820 00412000
  485. SPACE 00413000
  486. WRTERCD EQU * WRITE ERROR MESSAGE CODE ONLY @V200820 00414000
  487. LA R4,10(0) LENGTH OF CODE PORTION @V200820 00415000
  488. ST R4,SAVEWRK2 RESET MESSAGE LENGTH @VM08816 00416000
  489. B WRDSCK @V200820 00417000
  490. SPACE 00418000
  491. WRTDFT EQU * SUPPRESS MESSAGE EXCEPT IF SPOOLING @V200820 00419000
  492. OI SAVEWRK1,INHIBIT INHIBIT TYPING OF MESSAGE @V200820 00420000
  493. SPACE 00421000
  494. WRDSCK EQU * COMPUTE LENGTH NEEDED FOR CONTASK@V200820 00422000
  495. L R4,SAVEWRK2 ADJUSTED BYTE COUNT TO GR4 @VM08816 00423000
  496. L R5,SAVER2 GET WRITE PARAMETERS @V60C2B8 00423010
  497. N R5,RESPMASK ANY BITS ON THAT SAY NOT RESPONE @V60C2B8 00423020
  498. BNZ WR001 YES, THEN SKIP BUFFER MOVE @V60C2B8 00423030
  499. ICM R5,15,VMCONBUF IS DATA TO BE MOVED TO STORAGE @V60C2B8 00423040
  500. BNP WR001 NO, THEN CONTINUE @V60C2B8 00423050
  501. EJECT 1 00423060
  502. SR R3,R3 CLEAR RETURN CODE @V60C2B8 00423070
  503. LA R4,1(,R4) ADD 1 BYTE FOR THE LINEND CHAR @V60C2B8 00423080
  504. LH R9,VMCONLN GET BYTES LEFT IN BUFFER @V60C2B8 00423090
  505. SR R9,R4 - LENGTH OF THIS MESSAGE @V60C2B8 00423100
  506. BNM WRLNOK BRANCH IF MSG WILL FIT IN BUFFER @V60C2B8 00423110
  507. LPR R10,R9 SET TO TEST AMOUNT OF OVERFLOW @V60C2B8 00423120
  508. SR R10,R4 R10 = ABSOLUTE VALUE OF VMCONLN @V60C2B8 00423130
  509. C R10,=F'8192' NO SENSE RETURNING AN OVERFLOW @V60C2B8 00423140
  510. BL WRSETLN >8192 - BUFFER MAX @V60C2B8 00423150
  511. LA R3,8 STOP WRITES WITH RC=ATTENTION @V60C2B8 00423160
  512. B WREX AND LEAVE @V60C2B8 00423170
  513. SPACE 1 00423180
  514. WRLNOK LR R7,R1 SAVE ADDRESS OF TEXT TO MOVE @V60C2B8 00423190
  515. SR R6,R6 INDICATE NO PAGE CROSS @V60C2B8 00423200
  516. LA R10,0(R4,R5) ADDRESS OF 1 BYTE PAST LINEND @V60C2B8 00423210
  517. ST R10,VMCONBUF SAVE START OF NEXT MESSAGE (IF ON@V60C2B8 00423220
  518. BCTR R10,0 R10 IS NOW THE ADDRESS OF THE LIN@V60C2B8 00423230
  519. L R15,XPAGNUM SET TO GET PAGE NUMBER ONLY @V60C2B8 00423240
  520. NR R10,R15 GET PAGE ADDRESS OF LAST BYTE @V60C2B8 00423250
  521. NR R15,R5 GET PAGE ADDRESS OF FIRST BYTE @V60C2B8 00423260
  522. CR R15,R10 FIRST AND LAST BYTE IN SAME PAGE?@V60C2B8 00423270
  523. BE NOCROSS YES, THEN ALL SET TO MOVE @V60C2B8 00423280
  524. SPACE 1 00423290
  525. SLR R10,R5 LAST-FIRST = BYTES ON 1ST PAGE @V60C2B8 00423300
  526. SLR R4,R10 TOTAL-BYTES ON 1ST PAGE = 2ND LEN@V60C2B8 00423310
  527. LR R6,R4 SET LENGTH FOR SECOND PAGE @V60C2B8 00423320
  528. LR R4,R10 SET LENGTH FOR FIRST PAGE @V60C2B8 00423330
  529. SPACE 1 00423340
  530. NOCROSS TRANS R2,R5,OPT=(BRING+DEFER) GET THE RESPONSE BUFFER 00423350
  531. BNZ WREX EXIT IF ERROR, USER ALREADY NOTIF@V60C2B8 00423360
  532. BCTR R4,0 -1 FOR THE EXECUTE @V60C2B8 00423370
  533. EX R4,WRMVC MOVE SOME DATA @V60C2B8 00423380
  534. LTR R6,R6 IS THERE A SECOND PAGE? @V60C2B8 00423390
  535. BZ MVLINEND NO, THEN WE CAN MOVE IN A LINEND @V60C2B8 00423400
  536. LA R5,1(R4,R5) SET NEXT VIRTUAL (TO) ADDRESS @V60C2B8 00423410
  537. LA R7,1(R4,R7) AND NEXT REAL (FROM) ADDRESS @V60C2B8 00423420
  538. LR R4,R6 SET LENGTH @V60C2B8 00423430
  539. SR R6,R6 INDICATE LAST PAGE @V60C2B8 00423440
  540. B NOCROSS GO GET NEXT PAGE @V60C2B8 00423450
  541. SPACE 1 00423460
  542. MVLINEND LA R2,0(R4,R2) POINT TO LAST BYTE MOVED @V60C2B8 00423470
  543. MVI 0(R2),X'15' CHANGE EXTRA CHARACTER TO A LINEN@V60C2B8 00423480
  544. WRSETLN STH R9,VMCONLN SET NEW NUMBER OF BYTES LEFT @V60C2B8 00423490
  545. WREX TM SAVER2+2,DFRET/256 SHOULD BUFFER BE RELEASED? @V60C2B8 00423500
  546. BZ WRCKRC NO, THEN SEE IF RC NEEDED @V60C2B8 00423510
  547. L R1,SAVER1 GET BUFFER ADDRESS @V60C2B8 00423520
  548. L R0,SAVER3 AND SIZE IN DBL-WDS @V60C2B8 00423530
  549. CALL DMKFRET AND RELEASE IT @V60C2B8 00423540
  550. WRCKRC TM SAVER2+2,(DFRET+NORET)/256 SKIP SET OF RC ? @V60C2B8 00423550
  551. BNZ QCNEXIT YES, THEN JUST EXIT @V60C2B8 00423560
  552. ST R3,SAVER2 SET THE RETURN CODE FOR CALLER @V60C2B8 00423570
  553. LTR R3,R3 AND SET THE CC @V60C2B8 00423580
  554. B QCNEXIT RETURN @V60C2B8 00423590
  555. WRMVC MVC 0(0,R2),0(R7) EXECUTED MVC TO USER'S BUFFER @V60C2B8 00423600
  556. EJECT 1 00423610
  557. WR001 DS 0H HERE IF I/O TO BE DONE @V60C2B8 00423620
  558. TM SAVEWRK1,NOTIME TIME STAMP TO BE INCLUDED ? @V200820 00424000
  559. BO WRGLENT NO -- NO EXTRA LENGTH NEEDED@V200820 00425000
  560. LA R4,9(0,R4) ADD TO LENGTH FOR TIME STAMP @V200820 00426000
  561. SPACE 00427000
  562. WRGLENT EQU * ALLOW AT LEAST 9 EXTRA BYTES FOR @VA06176 00428100
  563. * CONTROL INFO, BUT ALLOW 1/8 OF 00428600
  564. * MSG. LENGTH FOR IDLES, ETC. 00429100
  565. TM SAVER2+2,HILIGHT/256 HILIGHT REQUESTED ? HRC101DK 00429120
  566. BZ WRNHLITE NO, SKIP THIS HRC101DK 00429140
  567. ICM R8,B'1111',VMTERM GET TERM RDEVBLOK ADDRESS HRC101DK 00429160
  568. USING RDEVBLOK,R8 HRC101DK 00429180
  569. BZ WRNHLITE NO, SKIP HILIGHT HRC101DK 00429200
  570. TM RDEVTYPC,CLASGRAF HRC101DK 00429220
  571. BZ CHKCLRGF NO, CHECK FOR REMOTE GRAF HRC101DK 00429240
  572. TM RDEVTYPE,TYP3277+TYP3278 3270 FAMILY ? HRC101DK 00429260
  573. BZ WRNHLITE NO, SKIP HILIGHT HRC101DK 00429280
  574. SPACE , HRC101DK 00429300
  575. MSGHILT EQU * HRC101DK 00429320
  576. LA R4,4(,R4) ADJUST LENGTH FOR HILIGHT HRC101DK 00429340
  577. MVI SAVEWRK9+3,X'01' INDICATE HILIGHTED MSG? HRC101DK 00429360
  578. B WRNHLITE HRC101DK 00429380
  579. SPACE , HRC101DK 00429400
  580. CHKCLRGF EQU * HRC101DK 00429420
  581. TM RDEVTYPC,CLASTERM TERMINAL CLASS FOR REMOTE HRC101DK 00429440
  582. BZ WRNHLITE HRC101DK 00429460
  583. TM RDEVTYPE,TYPBSC HRC101DK 00429480
  584. BO MSGHILT HRC101DK 00429500
  585. SPACE , HRC101DK 00429520
  586. WRNHLITE EQU * HRC101DK 00429540
  587. LA R5,7(0,R4) ROUND UP TO GET 1/8 @VA06176 00429600
  588. SRL R5,3(0) .. TO ALLOW FOR IDLES, ETC @VA06176 00430100
  589. LA R5,1(,R5) AND ADD ONE FOR GOOD MEASURE @VA06176 00430600
  590. C R5,F13 MUST HAVE AT LEAST 13 EXTRA HRC101DK 00432090
  591. BNL *+8 ALREADY > 13 HRC101DK 00433080
  592. LA R5,13 < 13, MAKE IT 13 (MINIMUM) HRC101DK 00434070
  593. LA R0,CONTSIZE*8+7(R5,R4) COMPOSITE SIZE IN BYTES@V200820 00436000
  594. SRL R0,3(0) ROUNDED UP AND IN DOUBLE-WORDS @V200820 00437000
  595. IC R2,SAVEWRK1 PICK UP ADJUSTED PARMS @V200820 00438000
  596. BAL R9,INITCON INITIALIZE THE CONTASK @V200820 00439000
  597. LA R2,CONDATA DATA START ADDRESS @V200820 00440000
  598. ST R2,CONADDR ...PASS ALONG TO THE SLIH @V200820 00441000
  599. STH R4,CONCNT ...ALONG WITH THE DATA COUNT @V200820 00442000
  600. IC R0,SAVER2 DIAGNOSE LINE NUMBER, MAYBE @V200820 00443000
  601. STC R0,CONDWC PASS IT ALONG TO DMKGRF @VA07542 00444100
  602. EJECT 00445000
  603. CLI SAVEWRK9+3,X'01' HILIGHTED MSG? HRC101DK 00445100
  604. BNE WRTIME NO, CONTINUE HRC101DK 00445200
  605. MVC 0(2,R2),=AL1(SF,ATTRPRHI) HRC101DK 00445300
  606. LA R2,2(,R2) INCREMENT THE POINTER HRC101DK 00445400
  607. SPACE , HRC101DK 00445500
  608. WRTIME EQU * HRC101DK 00445600
  609. TM SAVEWRK1,NOTIME TIME STAMP DESIRED ? @V200820 00446000
  610. BO WRMDATA NO -- JUST MOVE IN DATA @V200820 00447000
  611. SR R1,R1 NO DATE @V200820 00448000
  612. CALL DMKCVTDT PUT TIME DIRECTLY IN BUFFER @V200820 00449000
  613. MVI 8(R2),C' ' CLEAN UP HRC101DK 00450590
  614. LA R2,9(R2) NEW START ADDRESS FOR DATA HRC101DK 00451180
  615. SPACE 00452000
  616. WRMDATA EQU * SET DATA COUNT, MOVE IN USER DATA@V200820 00453000
  617. LM R3,R4,SAVEWRK2 PICK UP USER DATA POINTERS @VM08816 00454000
  618. LTR R5,R3 COUNT TO GR5 ALSO @V200820 00455000
  619. BNP WRMSKIP SKIP MOVE IF ZERO-LENGTH DATA 00456005
  620. LH R3,CONCNT DATA COUNT FROM CONTASK @VA13038 00456010
  621. ICM R5,8,BLANKS SET PAD CHARACTER TO X'40' FOR HRC101DK 00456310
  622. LR R1,R2 HRC101DK 00456600
  623. MVCL R2,R4 MOVE THE DATA INTO THE CONTASK @V60A6B6 00457000
  624. WRMSKIP DS 0H 00457500
  625. CLI SAVEWRK9+3,X'01' HRC101DK 00457570
  626. BNE WRMSKIP2 HRC101DK 00457640
  627. L R3,SAVEWRK2 HRC101DK 00457710
  628. AR R1,R3 HRC101DK 00457780
  629. MVC 0(2,R1),=AL1(SF,ATTRPRLO) HRC101DK 00457850
  630. WRMSKIP2 DS 0H HRC101DK 00457920
  631. OI CONSTAT,CONOUTPT THIS IS AN OUTPUT MESSAGE @V200820 00458000
  632. TM SAVER2+2,DFRET/256 RELEASE THE CALLER'S BUFFER @V200820 00459000
  633. BZ WRMCHEK NO -- CHECK RETURN OPTION @V200820 00460000
  634. L R1,SAVER1 ORIGINAL GR1 VALUE FOR FRET @VM08816 00461000
  635. L R0,SAVER3 NUMBER OF DBL-WDS FOR FRET @V200820 00462000
  636. CALL DMKFRET @V200820 00463000
  637. SPACE 00464000
  638. WRMCHEK EQU * @V200820 00465000
  639. TM SAVER2+1,NOMC MONITOR CALL ALLOWED? @VA04810 00465350
  640. BNZ *+8 NO...BYPASS CALL @VA04810 00465700
  641. QCNMC1 MC MNCOWRIT,MNCLRESP RESPONSE CLASS, WRITE @VM01017 00466000
  642. NI SAVER2+1,255-NOMC RESET NO MONITOR CALL FLAG @VA04810 00466500
  643. TM SAVER2+2,(NORET+DFRET)/256 WAIT FOR IT ? @V200820 00467000
  644. BNZ WRSPCHK NO -- EXIT DIRECTLY @V200820 00468000
  645. ST R13,CONRETN ATTACH THE SAVE-AREA TO CONTASK @V200820 00469000
  646. OI CONSTAT,CONRESP RESPONSE IS DESIRED @V200820 00470000
  647. SLR R2,R2 CLEAR RETURN CODE IN SAVEAREA @V200820 00471000
  648. ST R2,SAVER2 ... @V200820 00472000
  649. TM CONPARM,LOGDROP+LOGHOLD THIS LOGOFF COMMAND? HRC021DK 00472100
  650. BNZ NOSUPP YES...DON'T SUPPRESS LOGOFF MSG HRC021DK 00472200
  651. SPACE 00473000
  652. WRSPCHK EQU * CHECK FOR CONSOLE SPOOLING @V200820 00474000
  653. TM VMHRCFLG,VMTRMOFF SUPPRESSING CONS OUTPUT? HRC021DK 00474100
  654. BO WRSKIP YES... HRC021DK 00474200
  655. NOSUPP EQU * HRC021DK 00474300
  656. TM VMOSTAT,VMDISC+VMKILL DISCONNECTED OR DYING ? @V200820 00475000
  657. BNZ WRTINHB YES - INHIBIT MSG @V200820 00476000
  658. TM VMMLVL2,VMMDIAL USER ISSUED DIAL COMMAND? @VA11241 00476100
  659. BO WRTINHB YEP, INHIBIT MSG NOW Y'HEAR @VA11241 00476200
  660. L R8,VMTERM CHECK EXISTENCE OF HIS TERMINAL @V200820 00477000
  661. LTR R8,R8 @V200820 00478000
  662. BP WRSPOOL LOOKS O.K. FROM HERE @V200820 00479000
  663. SPACE 00480000
  664. WRTINHB EQU * INHIBIT MESSAGE TYPING @V200820 00481000
  665. OI SAVEWRK1,INHIBIT SET A FLAG BIT @V200820 00482000
  666. EJECT 00483000
  667. WRSPOOL EQU * CHECK FOR CONSOLE SPOOLING @V200820 00484000
  668. TM VMRSTAT,VMLOGON IS THE USER LOGGED ON YET ? @V200820 00485000
  669. BO WRNOSPL NO -- FORGET SPOOLING @V200820 00486000
  670. LH R8,VMVTERM DISPLACEMENT TO VIRTUAL CONSOLE @V200820 00487000
  671. LTR R8,R8 IS THERE ONE ? @V200820 00488000
  672. BM WRNOSPL NO -- @V200820 00489000
  673. AL R8,VMDVSTRT INDEX TO THE VDEVBLOK @V200820 00490000
  674. USING VDEVBLOK,R8 @V200820 00491000
  675. TM VDEVFLAG,VDEVCSPL CONSOLE SPOOLING ACTIVE ? @V200820 00492000
  676. BZ WRNOSPL NO -- @V200820 00493000
  677. TM CONDWC,X'40' DIAGNOSE WRITE TO GRAPHICS @VA07542 00494100
  678. BO WRNOSPL YES - SUPPRESS SPOOLING @V200820 00495000
  679. TM VDEVSFLG,VDEVTERM TERMINAL COPY WANTED ? @V200820 00496000
  680. BO WRSBOTH YES - LET IT TYPE @V200820 00497000
  681. TM CONPARM,PRIORITY+ALARM FORCE CONSOLE WRITE ? @V200820 00498000
  682. BNZ WRSBOTH YES - LET IT TYPE @V200820 00499000
  683. TM VMOSTAT,VMCF+VMVIRCF NON-DIAGNOSE C.F. MSG ?@V200820 00500000
  684. BM WRSBOTH YES - LET IT TYPE @V200820 00501000
  685. OI SAVEWRK1,INHIBIT SUPPRESS TERMINAL OUTPUT @V200820 00502000
  686. WRSBOTH EQU * @V200820 00503000
  687. LA R1,CONDATA @V200820 00504000
  688. LH R0,CONCNT @V200820 00505000
  689. LTR R0,R0 DO NOT SPOOL IF ZERO BYTES @V200820 00506000
  690. BNP WRNOSPL . . . @V200820 00507000
  691. SL R8,VMDVSTRT VDEVBLOK DISPLACEMENT @VA01460 00508000
  692. CALL DMKVSPVP SPOOL IT IMMEDIATELY @V200820 00509000
  693. DROP R8 @V200820 00510000
  694. WRNOSPL EQU * @V200820 00511000
  695. L R8,VMTERM GET THE TERMINAL RDEVBLOK @VM08909 00512000
  696. USING RDEVBLOK,R8 @VM08909 00513000
  697. LTR R8,R8 IS TERMINAL STILL THERE ? @VM08909 00514000
  698. BP *+8 YES - NO EXT BUTTON PRESSED @VM08909 00515000
  699. OI SAVEWRK1,INHIBIT SET FOR RELEASING CONTASK @VM08909 00516000
  700. TM SAVEWRK1,INHIBIT SHOULD THIS MSG BE TYPED ? @V200820 00517000
  701. BZ CHKSPLT YES - CHECK FOR LINE LENGTH@V200820 00518000
  702. WRSKIP EQU * HRC021DK 00518100
  703. BAL R9,FRETASK RELEASE THE CONTASK @V200820 00519000
  704. B EXIT ...AND RETURN TO CALLER @V200820 00520000
  705. SPACE 2 00521000
  706. CHKSPLT EQU * SPLIT LINES WHICH ARE TOO LONG @V200820 00522000
  707. CLI RDEVTYPC,CLASTERM IS THIS A TERMINAL CLASS @V2D3931 00523000
  708. BNE *+12 NO, BYPASS TEST FOR BISYNC LINE @V2D3931 00524000
  709. CLI RDEVTYPE,TYPBSC IS THIS A BISYNC LINE FOR 3270 @V2D3931 00525000
  710. BE *+12 YES, TEST FOR DIAG WRITE @V2D2931 00526000
  711. CLI RDEVTYPC,CLASGRAF IS THIS A GRAPHICS DEVICE ? @VA01645 00527000
  712. BNE CHKIMCR NO -- SPLIT IS REQUIRED @VA01645 00528000
  713. TM CONDWC,X'40' DIAGNOSE WRITE TO GRAPHICS ?? @VA07542 00529100
  714. BZ CHKIMCR NO -- SPLIT THE TASKS @VA01645 00530000
  715. CHKAPLEN SLR R10,R10 CLEAR DISPLAY INDEX REGISTER @V60A6B6 00530250
  716. CHKGRAF EQU * DEVICE IS NOT A REMOTE GRAPHIC @V60A6B6 00530500
  717. CLI RDEVTYPC,CLASGRAF IS DEVICE A LOCAL GRAPHIC ? @V60A6B6 00530750
  718. BNE CHKSIZE NO, INDEX IS ALREADY SET THEN. @V60A6B6 00531000
  719. IC R10,RDEVGRTY GET LOCAL DISPLAY'S SCREEN INDEX @V60A6B6 00531250
  720. CHKSIZE L R1,=A(DMKGRTDS) ADDRESS TABLE OF DISPLAY SIZES @V60A6B6 00531500
  721. L R10,0(R1,R10) AND GET THE RIGHT ONE FOR DEVICE @V60A6B6 00531750
  722. SPACE 1 @VA13491 00531757
  723. * SCAN THE LINE FOR ANY START FIELD ORDERS, @VA13491 00531764
  724. * IF A X'1D' IS FOUND, CHANGE IT TO A BLANK @VA13491 00531771
  725. SPACE 1 @VA13491 00531778
  726. LH R15,CONCNT LOAD DATA LENGTH @VA13491 00531785
  727. N R15,XRIGHT16 ZERO LEFTMOST HALFWORD @VA13491 00531792
  728. LA R1,CONDATA LOAD DATA START ADDRESS @VA13491 00531799
  729. AR R15,R1 SET DATA END ADDRESS @VA13491 00531806
  730. L R14,=A(DMKTBLSF) LOAD TRANSLATE TABLE ADDRES @VA13491 00531813
  731. CONTSCAN DS 0H @VA13491 00531820
  732. LR R3,R15 LOAD DATA END ADDR @VA13491 00531827
  733. SR R3,R1 COMPUTE DATA BALANCE @VA13491 00531834
  734. BZ APLSPLT IF NO DATA GO CONTINUE @VA13491 00531841
  735. C R3,F256 LAST SEGMENT? @VA13491 00531848
  736. BL DOTRT YES, USE CURRENT LENGTH @VA13491 00531855
  737. LA R3,256 LOAD MAX SEGMENT LENGTH @VA13491 00531862
  738. DOTRT DS 0H @VA13491 00531869
  739. BCTR R3,0 DECREMENT FOR EXECUTE @VA13491 00531876
  740. EX R3,EXTRTSCN ANY SF ORDERS? @VA13491 00531883
  741. BZ NEXTSCAN NO, GO CONTINUE WITH NEXT SEG @VA13491 00531890
  742. TM 1(R1),X'01' MDT ON ? HRC101DK 00531898
  743. BO BLANKIT YES, BLANK IT HRC101DK 00531899
  744. TM 1(R1),X'20' PROTECTED FIELD? HRC101DK 00531900
  745. BO NEXTSCAN YES, THEN OK. HRC101DK 00531901
  746. BLANKIT DS 0H HRC101DK 00531902
  747. MVI 0(R1),C' ' BLANK THE SF ORDER HRC101DK 00531903
  748. LA R1,1(R1) SET NEW SCAN START @VA13491 00531904
  749. B CONTSCAN GO CHECK THE REST OF THE DATA @VA13491 00531911
  750. NEXTSCAN DS 0H @VA13491 00531918
  751. LA R1,1(R1,R3) SET NEW SCAN START @VA13491 00531925
  752. B CONTSCAN GO SCAN THIS SEGMENT @VA13491 00531932
  753. SPACE 1 @VA13491 00531939
  754. EXTRTSCN TRT 0(*-*,R1),0(R14) LOCATE SF ORDER @VA13491 00531946
  755. SPACE 2 @VA13491 00531953
  756. * SPLIT INTO MULTIPLE CONTASKS IF NEEDED @VA13491 00531960
  757. APLSPLT DS 0H @VA13491 00531967
  758. CH R10,CONCNT GREATER THAN ONE SCREEN FULL ? @VA01645 00532000
  759. BNL ENQUEUE NO -- JUST SEND IT AS IS @VA01645 00533000
  760. LR R8,R6 SAVE CURRENT CONTASK POINTER @VA01645 00534000
  761. LA R4,CONDATA START OF OUTPUT DATA @VA01645 00535000
  762. LH R3,CONCNT FULL COUNT @VA01645 00536000
  763. CHKTASK EQU * SPLIT INTO MULTIPLE SCREENS @VA01645 00537000
  764. BAL R5,SPLTASK SPLIT CONTASK (SIZE IS IN R10) @V60A6B6 00538000
  765. BNP CHKLAST THAT WAS THE LAST ONE @VA01645 00539000
  766. CR R3,R10 ANOTHER FULL SCREEN WRITE ? @VA01645 00540000
  767. BNL CHKTASK YES - SPLIT IT AGAIN @VA01645 00541000
  768. LR R10,R3 LAST ONE IS SMALLER @VA01645 00542000
  769. B CHKTASK BUILD THE FINAL CONTASK @VA01645 00543000
  770. SPACE 2 00544000
  771. CHKIMCR EQU * CHECK FOR LINE LENGTH AND CR'S @VA01645 00545000
  772. SLR R10,R10 @VA01645 00546000
  773. IC R10,RDEVLLEN THIS IS THE LINE LENGTH NORMALLY@VA01645 00547000
  774. CLI RDEVTYPC,CLASTERM IS THIS A TERMINAL CLASS @V2D3931 00548000
  775. BNE QCN004B NO, MAYBE 3704/5 @VA05189 00549010
  776. CLI RDEVTYPE,TYPBSC BISYNC LINE FOR 3270 ?? @VA05189 00549510
  777. BNE QCN004B NO, MAYBE 3704/5 @VA05189 00550010
  778. QCN004A LH R1,VMTRMID TERMINAL RESOURCE ID @VA05189 00550510
  779. N R1,F4095 ..MINUS THE DEV CODE @VA05189 00551010
  780. MH R1,=AL2(NICSIZE*8) CONVERT TO INDEX @VA05189 00551510
  781. AL R1,RDEVNICL AND TO NICBLOK ITSELF @VA05189 00552010
  782. IC R10,NICLLEN-NICBLOK(,R1) PICK UP LINE LENGTH @VA05189 00552510
  783. TM SAVEWRK1,VMGENIO FROM A VIRT. MACHINE ?? @VA05189 00553010
  784. BZ QCN004 NO, EASY WAY OUT @VA05189 00553510
  785. TM NICTMCD-NICBLOK(R1),NICAPL APL ?? @VA05189 00554010
  786. BO CHKAPLEN YES, TRUST APL FOR NL CHARS. @VA05189 00554510
  787. B CHKLLEN NO, DOUBLECHECK WITH RDEVBLOK @VA05189 00555010
  788. QCN004B CLI RDEVTYPC,CLASSPEC 3704/5 TERMINAL ?? @VA05189 00555510
  789. BE QCN004A YES, GET TERMINAL LINE LENGTH @VA05189 00556010
  790. CHKLLEN TM SAVEWRK1,VMGENIO IS THIS FROM A VIRT MACH? @V2B4538 00559000
  791. BZ QCN004 NOPE, CONTINUE @VM01065 00560000
  792. TM RDEVTMCD,RDEVAPLP YES, IS 'TERM APL' ON? @V2B4538 00561000
  793. BNZ CHKAPLEN YUP, THEN TRUST APL FOR NL CHARS @V2B4538 00562000
  794. QCN004 LA R4,CONDATA START OF OUTPUT DATA @VM01065 00563000
  795. LH R3,CONCNT DATA LENGTH @VA01645 00564000
  796. CL R3,F1 AT LEAST ONE BYTE ? @VA08683 00565000
  797. BL ENQUEUE NO -- DON'T EVEN CHECK IT @VA01645 00566000
  798. ST R10,SAVEWRK4 SAVE THE LINE LENGTH VALUE @VA01645 00567000
  799. LR R8,R6 SAVE ADDRESS OF ORIGINAL CONTASK @VA01645 00568000
  800. CRSCAN1 EQU * SCAN FOR CARRIAGE RETURNS @VA01645 00569000
  801. L R10,SAVEWRK4 RESTORE LINE LENGTH VALUE @VA01645 00570000
  802. LR R5,R4 SCAN START TO GR5 @VA01645 00571000
  803. SR R7,R7 ZERO SCAN COUNT REGISTER @VA01645 00572000
  804. SLR R1,R1 TYPING ELEMENT IS BEFORE POS 1 @VA07248 00572050
  805. LA R0,2 NO. OF CHAR. TO DEDUCT FOR BS @VA07248 00572100
  806. DROP R8 @VA08351 00572110
  807. L R2,VMTERM MAKE SURE WE HAVE RDEVBLOK @VA08351 00572120
  808. USING RDEVBLOK,R2 ESTABLISH ADDRESSABILITY @VA08351 00572130
  809. CLI RDEVTYPC,CLASTERM IS IT TERMINAL ? @VA07248 00572150
  810. BNE GRAPH NO, TEST FOR GRAPH @VA07248 00572200
  811. CLI RDEVTYPE,TYPBSC IS REMOTE 3270 ? @VA07248 00572250
  812. BE ADDBS YES, THEN WE DONT HAVE BS @VA07248 00572300
  813. GRAPH CLI RDEVTYPC,CLASGRAF IS IT GRAPHICS ? @VA07248 00572350
  814. BNE *+6 NO, TERM CAN DO BACKSPACE @VA07248 00572400
  815. ADDBS SLR R0,R0 ADD FOR BS AS WELL @VA07248 00572450
  816. DROP R2 @VA08351 00572700
  817. CRSCAN2 EQU * @VA01645 00573000
  818. CLI 0(R5),X'15' IS THIS AN EMBEDDED 'CR' ? @VA01645 00574000
  819. BE CRSCAN3 YES - FIGURE OUT WHAT TO DO @VA01645 00575000
  820. A R1,F1 ADD ONE @VA08567 00575200
  821. CLI 0(R5),X'16' IS IT A BACKSPACE ? @VA07248 00575400
  822. BNE *+6 NO, LEAVE AS IS @VA07248 00575600
  823. SR R1,R0 MOVE BALL LEFT UNLESS GRAF @VA07248 00575800
  824. CLI 0(R5),X'1D' IS THIS A START FIELD? @VA13491 00575820
  825. BNE NOIMSF NO - GO COUNT IT @VA13491 00575840
  826. LTR R0,R0 YES - NON-GRAPHICS DEVICE? @VA13491 00575860
  827. BNZ NOIMSF YES - PASS IT AS A CHARACTER @VA13491 00575880
  828. TM 1(R5),X'01' IS MDT ON ? HRC101DK 00575882
  829. BO SFBLANK BLANK IT HRC101DK 00575884
  830. TM 1(R5),X'20' IS PROTECT ON ? HRC101DK 00575886
  831. BO NOIMSF YES, CONTINUE HRC101DK 00575888
  832. SPACE , HRC101DK 00575890
  833. SFBLANK DS 0H HRC101DK 00575892
  834. MVI 0(R5),C' ' BLANK THE SF ORDER @VA13491 00575900
  835. SPACE , HRC101DK 00575910
  836. NOIMSF DS 0H @VA13491 00575920
  837. LA R5,1(0,R5) NEXT BYTE OF DATA @VA01645 00576000
  838. LA R7,1(0,R7) COUNT THE BYTES @VA01645 00577000
  839. CR R7,R3 ANY MORE DATA TO BE SCANNED ? @VA01645 00578000
  840. BNL CRSCAN4 NO -- FINISH UP @VA01645 00579000
  841. CR R1,R10 HAVE WE HIT LINESIZE LIMIT @VA07248 00580500
  842. BL CRSCAN2 NO, KEEP SCANNING @VA09338 00581100
  843. CLI 0(R5),X'16' IS THIS A BACKSPACE? @VA09338 00581200
  844. BE CRSCAN2 YES, KEEP SCANNING @VA09338 00581300
  845. LR R10,R7 DATA LENGTH TO R10 @VA09338 00581400
  846. BAL R5,SPLTASK SPLIT OFF A CONTASK @VA01645 00582000
  847. B CRSCAN1 SCAN THE NEXT PIECE @VA01645 00583000
  848. EJECT 00584000
  849. CRSCAN3 EQU * EMBEDDED CARRIAGE RETURN FOUND @VA01645 00585000
  850. LA R10,1(0,R7) EXTRA BYTE (IN CASE OF ZERO) @VA01645 00586000
  851. C R3,F1 LENGTH = 1 ? @VA03434 00587000
  852. BE CRSCAN3C @VA14333 00588100
  853. CR R10,R3 THIS 'CR' AT END OF MSG? @VA03434 00589000
  854. BNE CRSCAN3B NO -- GO MAKE IT A BLANK @VA03434 00590000
  855. TM CONPARM-CONTASK(R8),NOAUTO 'NOAUTO' ON ? @VA07505 00591000
  856. BNO CRSCAN3A NO -- SPLIT @VA03434 00592000
  857. CRSCAN3C DS 0H @VA14333 00592100
  858. NI CONPARM-CONTASK(R8),X'FB' YES, TURN OFF 'NOAUTO'@VA03434 00593000
  859. B CRSCAN3B GO MAKE 'CR' A BLANK @VA03434 00594000
  860. CRSCAN3A BCTR R10,0 BACK UP LENGTH @VA03434 00595000
  861. BAL R5,SPLTASK YES -- GO SPLIT OUT MSG @VA03434 00596000
  862. B CRSCAN1 SCAN THE NEXT PIECE @VA03434 00597000
  863. CRSCAN3B MVI 0(R5),X'40' MAKE CARRIAGE RETURN A BLANK @VA03434 00598000
  864. BAL R5,SPLTASK SPLIT OFF A CONTASK @VA01645 00599000
  865. BNP CHKLAST THAT WAS THE LAST ONE @VA01645 00600000
  866. B CRSCAN1 SCAN THE NEXT PIECE @VA01645 00601000
  867. SPACE 00602000
  868. CRSCAN4 EQU * RAN OUT OF CONTASK DATA @VA01645 00603000
  869. CR R8,R6 DID WE BUILD ANOTHER CONTASK ? @VA01645 00604000
  870. BE ENQUEUE NO -- JUST QUEUE UP THE ORIGINAL @VA01645 00605000
  871. LR R10,R7 GR7 = LENGTH OF TAIL PIECE @VA01645 00606000
  872. BAL R5,SPLTASK ONE MORE TASK FOR THE REST OF IT @VA01645 00607000
  873. B CHKLAST STRAIGHTEN OUT PARAMTERS, ETC. @VA01645 00608000
  874. SPACE 2 00609000
  875. SPLTASK EQU * BUILD ANOTHER, SMALLER CONTASK @VA01645 00610000
  876. NI SAVEWRK1,PRIORITY+VMGENIO SAVE ONLY THESE @VA01645 00611000
  877. LA R7,7(0,R10) ROUND UP FOR PADDING CALCULATION@V200820 00612000
  878. SRL R7,3(0) CALCULATE PADDING NEEDED @V200820 00613000
  879. LA R7,1(,R7) ADD ONE FOR GOOD MEASURE @VA06176 00614100
  880. C R7,F13 MUST HAVE AT LEAST 14 EXTRA HRC101DK 00615190
  881. BNL *+8 ALREADY > 13 HRC101DK 00615780
  882. LA R7,13 < 13 MAKE IT 13 MINIMUM HRC101DK 00616370
  883. LA R0,CONTSIZE*8+7(R7,R10) CONTASK SIZE IN BYTES @V200820 00617000
  884. SRL R0,3(0) ...IN DOUBLE-WORDS FOR DMKFREE @V200820 00618000
  885. LR R7,R6 SAVE CURRENT CONTASK POINTER @VA01645 00619000
  886. IC R2,SAVEWRK1 PARMS FOR THE CONTASK @V200820 00620000
  887. BAL R9,INITCON BUILD A NEW TASK @V200820 00621000
  888. ST R6,CONPNT-CONTASK(,R7) CHAIN TO PREVIOUS ONE @VA01645 00622000
  889. LA R2,CONDATA DATA START ADDRESS @V200820 00623000
  890. ST R2,CONADDR ...FOR INTERRUPT HANDLER @V200820 00624000
  891. STH R10,CONCNT DATA LENGTH @V200820 00625000
  892. IC R1,CONDWC-CONTASK(,R8) DIAGNOSE PARMS, MAYBE ? @VA07542 00626100
  893. STC R1,CONDWC PASS THEM TO DMKGRF @VA07542 00627100
  894. MVI CONSTAT,CONOUTPT+CONSPLT STATUS FLAGS @V200820 00628000
  895. STM R3,R5,TEMPSAVE FREE UP SOME REGISTERS @V200820 00629000
  896. LR R3,R10 LENGTH TO BE MOVED @V200820 00630000
  897. LR R5,R3 ...GR5 ALSO FOR 'MVCL' @V200820 00631000
  898. MVCL R2,R4 MOVE DATA TO NEW CONTASK @V200820 00632000
  899. LM R3,R5,TEMPSAVE RESTORE THOSE REGISTERS NOW @V200820 00633000
  900. LA R4,0(R10,R4) NEXT DATA TO BE MOVED @V200820 00634000
  901. SR R3,R10 SEE IF MORE TO GO @V200820 00635000
  902. BR R5 RETURN WITH COND CODE SET @VA01645 00636000
  903. EJECT 00637000
  904. CHKLAST EQU * FILL IN PARMS FOR LAST CONTASK @V200820 00638000
  905. LH R2,CONSTAT-CONTASK(,R8) ORIGINAL STAT, PARM @V200820 00639000
  906. STH R2,CONSTAT ...COPIED INTO LAST TASK @V200820 00640000
  907. L R2,CONRETN-CONTASK(,R8) RETURN SAVE-AREA @V200820 00641000
  908. ST R2,CONRETN ...COPIED INTO LAST TASK @V200820 00642000
  909. LR R5,R6 GR5 = POINTER TO LAST SPLIT TASK @V200820 00643000
  910. L R6,CONPNT-CONTASK(,R8) GR6 = FIRST SPLIT TASK @V200820 00644000
  911. TM CONPARM-CONTASK(R5),ALARM RING ALARM ? @VA03725 00645000
  912. BNO NOALARM NO, DON'T CHANGE ALARM BIT @VA03725 00646000
  913. NI CONPARM-CONTASK(R5),255-ALARM TURN OFF IN LAST @VA03725 00647000
  914. OI CONPARM,ALARM TURN ALARM BIT ON IN FIRST @VA03725 00648000
  915. NOALARM EQU * @VA03725 00649000
  916. LR R1,R8 ORIGINAL CONTASK @V200820 00650000
  917. LH R0,CONTSKSZ-CONTASK(,R8) SIZE @V200820 00651000
  918. CALL DMKFRET RELEASE THE BIG CONTASK @V200820 00652000
  919. B ENQUEUE GO PROCESS MULTIPLE TASKS @V200820 00653000
  920. SPACE 3 00654000
  921. FRETASK EQU * RELEASE A CONTASK @V200820 00655000
  922. LH R0,CONTSKSZ GET CONTASK SIZE IN DBL-WDS @V200820 00656000
  923. LR R1,R6 @V200820 00657000
  924. CALL DMKFRET RELEASE THE CONTASK @V200820 00658000
  925. ENTRY DMKQCNFT ENTRY POINT TO TELL DMKFRE ... @VA05235 00658100
  926. DMKQCNFT EQU * ADDRESS OF ABOVE DMKFRET CALL. @VA05235 00658200
  927. BR R9 ...AND EXIT TO CALLER @V200820 00659000
  928. SPACE 2 00660000
  929. INITCON EQU * GET CONTASK AND CLEAR HEADER @V200820 00661000
  930. CALL DMKFREE (SIZE IS ALREADY IN GR0) @V200820 00662000
  931. LR R6,R1 SAVE PTR @V200820 00663000
  932. XC 0(CONTSIZE*8,R6),0(R6) CLEAR CONTASK HEADER @V200820 00664000
  933. STH R0,CONTSKSZ SAVE CONTASK SIZE IN THE CONTASK @V200820 00665000
  934. STC R2,CONPARM SAVE CALLING PARMS IN CONTASK @V200820 00666000
  935. ST R11,CONUSER REMEMBER WHO OWNS THIS TASK @V200820 00667000
  936. BR R9 RETURN @V200820 00668000
  937. EJECT 00669000
  938. *. 00670000
  939. * SUBROUTINE NAME - 00671000
  940. * 00672000
  941. * DMKQCNSY 00673000
  942. * 00674000
  943. * FUNCTION - 00675000
  944. * 00676000
  945. * TO PROVIDE A MEANS OF SYNCHRONIZING VIRTUAL MACHINE CONSOLE 00677000
  946. * ACTIVITY WITH INTERNAL SUPERVISOR ACTIVITY. (USED DURING A 00678000
  947. * VIRTUAL SYSTEM RESET, AND DURING THE LOGOFF PROCESS.) 00679000
  948. * 00680000
  949. * ATTRIBUTES - 00681000
  950. * 00682000
  951. * RE-ENTRANT, RESIDENT, CALLED VIA SVC 00683000
  952. * 00684000
  953. * ENTRY CONDITIONS - 00685000
  954. * 00686000
  955. * GPR 11 = VMBLOK ADDRESS OF ACTIVE USER 00687000
  956. * GPR 12 = ADDRESS OF DMKQCNSY 00688000
  957. * GPR 13 = ADDRESS OF A STANDARD SAVE-AREA 00689000
  958. * 00690000
  959. * EXIT CONDITIONS - 00691000
  960. * 00692000
  961. * GPR 0-15 UNCHANGED 00693000
  962. * 00694000
  963. * CALLS TO OTHER ROUTINES - 00695000
  964. * 00696000
  965. * DMKFREE 00697000
  966. * 00698000
  967. * EXTERNAL REFERENCES - NONE 00699000
  968. * 00700000
  969. * TABLES / WORK AREAS - NONE 00701000
  970. * 00702000
  971. * NOTES - NONE 00703000
  972. * 00704000
  973. * OPERATION - 00705000
  974. * 00706000
  975. * 1. IF THE SPECIFIED VIRTUAL MACHINE IS DISCONNECTED OR IN 00707000
  976. * THE LOGOFF PROCESS, EXIT IS TAKEN IMMEDIATELY. 00708000
  977. * 2. IF THE VIRTUAL MACHINE CONSOLE IS IDLE AT THE TIME OF 00709000
  978. * THE CALL TO DMKQCNSY, AN IMMEDIATE EXIT IS TAKEN. 00710000
  979. * 3. IF THE VIRTUAL CONSOLE IS NOT IDLE, A SPECIAL CONTASK 00711000
  980. * IS BUILT, WITH THE 'CONSYNC' FLAG SET IN CONSTAT, TO 00712000
  981. * INDICATE TO THE DEVICE INTERRUPT HANDLERS THAT THE 00713000
  982. * CONTASK DOES NOT REQUIRE ANY I/O OPERATION. 00714000
  983. * 4. EXIT TO DMKDSPCH. CONTROL WILL RETURN TO THE CALLER 00715000
  984. * WHEN THE SYNCHRONIZATION TASK IS ENCOUNTERED BY THE 00716000
  985. * DEVICE INTERRUPT HANDLER. 00717000
  986. *. 00718000
  987. EJECT 00719000
  988. USING DMKQCNSY,R12 @V200820 00720000
  989. DMKQCNSY DS 0D ENTRY TO SYNCHRONIZE TERMINAL OUTPUT@V200820 00721000
  990. ENTER @V200820 00722000
  991. L R12,=A(DMKQCN) MODULE BASE ADDRESSABILITY @V200820 00723000
  992. USING DMKQCN,R12 @V200820 00724000
  993. SPACE 00725000
  994. TM VMOSTAT,VMDISC+VMKILL DISCONNECTED OR DYING ?@V200820 00726000
  995. BNZ SYNEXIT YES - JUST EXIT @V200820 00727000
  996. TM VMRSTAT,VMLOGOFF LOGGING OFF ? @VA04846 00727350
  997. BO SYNEXIT YES - EXIT @VA04846 00727700
  998. L R8,VMTERM POINTER TO TERMINAL RDEVBLOK @V200820 00728000
  999. LTR R8,R8 IS THERE A TERMINAL NOW ? @V200820 00729000
  1000. BNP SYNEXIT NO -- JUST EXIT @V200820 00730000
  1001. USING RDEVBLOK,R8 ESTABLISH ADDRESSABILITY @VA08351 00730500
  1002. CLI RDEVTYPC,CLASTERM IS THIS A TERMINAL CLASS 00731000
  1003. BNE *+12 NO, BYPASS TEST FOR BISYNC LINE 00732000
  1004. CLI RDEVTYPE,TYPBSC IS THIS A BISYNC LINE 00733000
  1005. BE SYNTASK YES, GET STORAGE FOR CONTASK 00734000
  1006. CLI RDEVTYPC,CLASSPEC TERMINAL ON 370X NCP ? @V200820 00735000
  1007. BE SYNTASK YES - MUST BUILD A CONTASK @V200820 00736000
  1008. L R6,RDEVCON CHECK FOR ACTIVE CONTASK STACK @V200820 00737000
  1009. LTR R6,R6 IS THE TERMINAL ACTIVE ? @V200820 00738000
  1010. BP SYNTASK YES--BUILD A SYNCH TASK @VA05135 00739100
  1011. CLI RDEVTYPC,CLASGRAF IS THIS GRAPHICS DEVICE? @VA05135 00739200
  1012. BNE SYNEXIT NO--NO SYNCH TASK REQUIRED @VA05135 00739300
  1013. TM RDEVFLAG,RDEVACTV IS I/O ACTIVE ON DEVICE? @VA05135 00739400
  1014. BZ SYNEXIT NO--NO SYNCH TASK NEEDED @VA05135 00739500
  1015. SYNTASK EQU * SYNCHRONIZE VIA SPECIAL CONTASK @V200820 00740000
  1016. SLR R2,R2 NO PARAMETERS FOR THIS ENTRY @V200820 00741000
  1017. LA R0,CONTSIZE BASIC CONTASK @V200820 00742000
  1018. BAL R9,INITCON BUILD AND INITIALIZE A CONTASK @V200820 00743000
  1019. MVI CONSTAT,CONCNTL+CONSYNC+CONRESP SET FLAGS @V200820 00744000
  1020. ST R13,CONRETN CALLER'S SAVEAREA INTO CONTASK @V200820 00745000
  1021. B ENQUEUE CHAIN THE TASK, EXIT TO DMKDSPCH @V200820 00746000
  1022. SPACE 00747000
  1023. SYNEXIT EQU * SYNCHRONIZE WITH THE DISPATCHER @VM08908 00748000
  1024. LA R4,QCNEXIT ALL WE NEED IS AN 'EXIT' SVC @VM08908 00749000
  1025. BAL R10,STKCPEX SERIALIZE VIA A CPEXBLOK @VM08908 00750000
  1026. GOTO DMKDSPCH . . . @VM08908 00751000
  1027. EJECT 00752000
  1028. *. 00753000
  1029. * SUBROUTINE NAME - 00754000
  1030. * 00755000
  1031. * DMKQCNTO 00756000
  1032. * 00757000
  1033. * FUNCTION - 00758000
  1034. * 00759000
  1035. * TO FORCIBLY DISCONNECT A VIRTUAL MACHINE AND SET A TOD CLOCK 00760000
  1036. * COMPARATOR REQUEST TO LOGOFF THE VIRTUAL MACHINE AFTER A 00761000
  1037. * FIFTEEN MINUTE DELAY. 00762000
  1038. * 00763000
  1039. * ATTRIBUTES - 00764000
  1040. * 00765000
  1041. * RE-ENTRANT, RESIDENT, CALLED VIA SVC 00766000
  1042. * 00767000
  1043. * ENTRY CONDITIONS - 00768000
  1044. * 00769000
  1045. * GPR 11 = VMBLOK ADDRESS OF USER TO BE DISCONNECTED 00770000
  1046. * GPR 12 = ADDRESS OF DMKQCNTO 00771000
  1047. * GPR 13 = STANDARD SAVE-AREA ADDRESS 00772000
  1048. * 00773000
  1049. * EXIT CONDITIONS - 00774000
  1050. * 00775000
  1051. * GPRS 0-15 UNCHANGED 00776000
  1052. * 00777000
  1053. * CALL TO OTHER ROUTINES - 00778000
  1054. * 00779000
  1055. * DMKFREE 00780000
  1056. * DMKSTKCP 00781000
  1057. * DMKSCHRT 00782000
  1058. * DMKSCHST 00783000
  1059. * DMKSCHDL 00784000
  1060. * DMKSCNRN 00785000
  1061. * DMKSCNRD 00786000
  1062. * DMKCVTBH 00787000
  1063. * DMKCVTBD 00788000
  1064. * DMKQCNWT 00789000
  1065. * 00790000
  1066. * EXTERNAL REFERENCES - 00791000
  1067. * 00792000
  1068. * DMKSYSNM - NUMBER OF ACTIVE USERS 00793000
  1069. * 00794000
  1070. * TABLES / WORK AREAS - NONE 00795000
  1071. * 00796000
  1072. * NOTES - 00797000
  1073. * 00798000
  1074. * IF THE VIRTUAL MACHINE HAS NOT YET COMPLETED THE LOGON 00799000
  1075. * PROCESS, IT WILL BE IMMEDIATELY LOGGED OFF. 00800000
  1076. * 00801000
  1077. * OPERATION - 00802000
  1078. * 00803000
  1079. * 1. MARK THE VIRTUAL MACHINE NON-RUNNABLE (VMCFWAIT). 00804000
  1080. * 2. IF LOGON IS NOT COMPLETE, SET VMKILL IN VMOSTAT 00805000
  1081. * AND STACK A CPEXBLOK TO GOTO DMKDSPCH LATER. 00806000
  1082. * 3. DISCONNECT THE VIRTUAL MACHINE, BUILD A MESSAGE TO 00807000
  1083. * SEND TO THE SYSTEM OPERATOR, AS FOLLOWS: 00808000
  1084. * 00809000
  1085. * TYPE RADDR DSCONNECT USERID USERS = NNN FORCED 00810000
  1086. * 00811000
  1087. * (THE MESSAGE IS NOT SENT IF THIS IS THE OPERATOR) 00812000
  1088. * 4. CALL DMKFREE TO ALLOCATE A TRQBLOK, SET THE TRQBLOK 00813000
  1089. * FOR A FIFTEEN MINUTE DELAY, AND ISSUE THE 00814000
  1090. * TIMER REQUEST VIA A CALL TO DMKSCHST. 00815000
  1091. * 5. IF A TRQBLOK ALREADY EXISTS (E.G. FOR A SLEEP WITH 00816000
  1092. * TIMEOUT), THE SAME BLOCK IS RE-USED. 00817000
  1093. * 6. EXIT TO CALLER. 00818000
  1094. * 7. AFTER THE TRQBLOK EVENT OCCURS, SET VMKILL IN VMOSTAT 00819000
  1095. * AND GOTO DMKDSPCH. THE DISPATCHER WILL CALL DMKUSOFF. 00820000
  1096. *. 00821000
  1097. SPACE 2 00822000
  1098. USING DMKQCNTO,R12 @V200820 00823000
  1099. DMKQCNTO DS 0D ENTRY FOR DISCONNECT WITH TIMEOUT@V200820 00824000
  1100. ENTER @V200820 00825000
  1101. L R12,=A(DMKQCN) MODULE BASE ADDRESSABILITY @V200820 00826000
  1102. USING DMKQCN,R12 @V200820 00827000
  1103. SPACE 00828000
  1104. OI VMRSTAT,VMCFWAIT DO NOT RUN THIS MACHINE @V200820 00830000
  1105. OI VMOSTAT,VMDISC DISCONNECT THE VIRTUAL MACHINE @VA04273 00830200
  1106. L R8,VMTERM TERMINAL RDEVBLOK POINTER @VA04273 00830400
  1107. SR R0,R0 @VA04273 00830600
  1108. ST R0,VMTERM CLEAR VMBLOK POINTER TO RDEVBLOK @VA04273 00830800
  1109. TM VMRSTAT,VMLOGOFF ALREADY IN LOGOFF PROCESS ? @V200820 00831000
  1110. BO DSCEXIT YES...JUST EXIT @VA04635 00834500
  1111. TM VMOSTAT,VMKILL ALREADY BEING FORCED? @VA08501 00835000
  1112. BO DSCEXIT YES...JUST EXIT @VA08501 00835100
  1113. TM VMRSTAT,VMLOGON STILL IN LOGON PROCESS ? @V200820 00837000
  1114. BZ TSTMORE NO--BYPASS FOLLOWING TEST @VA02743 00838000
  1115. NI VMOSTAT,255-VMCF YES - STOP MACHINE @VA02849 00839000
  1116. TM VMQSTAT,VMCFREAD USER HAS READ UP ? @VA02743 00840000
  1117. BO DSCLLOG YES--LOG HIM OFF @VA02743 00841000
  1118. CLI VMCOMND,X'00' FIRST COMMAND ENTERED YET? @VA04635 00842100
  1119. BNH DSCLLOG NO...LOG HIM OFF @VA04635 00842200
  1120. TM VMOSTAT,VMSLEEP USER SLEEPING? @VA11535 00842210
  1121. BO DSCLLOG YES, LOG HIM OFF @VA11535 00842220
  1122. OI VMSVSTAT,VMLGFORC INDICATE USER WAS FORCED @VA13026 00842300
  1123. OI VMOSTAT,VMCF+VMKILL COMPLETE CF THEN LOGOFF @VA13026 00842350
  1124. B DSCEXIT EXIT FOR NOW @VA04635 00842400
  1125. SPACE 1 00844000
  1126. TSTMORE EQU * @VA02743 00845000
  1127. CALL DMKSCHDL ALTER STATUS FOR NON-RUNNABLE @V200820 00847000
  1128. LTR R8,R8 IS THERE AN ACTIVE TERMINAL ? @V200820 00851000
  1129. BNP DSCNMSG NO -- USER ALREADY DISCONNECTED @V200820 00852000
  1130. TM VMOSTAT,VMSYSOP IS THIS THE SYSTEM OPERATOR ? @V200820 00853000
  1131. BO DSCNMSG YES - DO NOT SEND THE MESSAGE @V200820 00854000
  1132. LA R0,6 GET A FREE STORAGE BUFFER FOR MSG@V200820 00855000
  1133. CALL DMKFREE ... @V200820 00856000
  1134. LR R5,R1 ADDRESS VIA GR5 @V200820 00857000
  1135. USING RDEVBLOK,R8 @V200820 00858000
  1136. CLI RDEVTYPC,CLASTERM IS THIS A TERMINAL CLASS @V2D3931 00859000
  1137. BNE *+12 NO, TEST FOR SPECIAL CLASS (370X)@V2D3931 00860000
  1138. CLI RDEVTYPE,TYPBSC IS THIS A BISYNC LINE FOR 3270 @V2D3931 00861000
  1139. BE *+12 YES, GET RESOURCE ID FROM VMBLOK @V2D3931 00862000
  1140. CLI RDEVTYPC,CLASSPEC IS THIS A 3705 TERMINAL ? @V200820 00863000
  1141. BNE DSCLDEV NO -- Msg for line/graf/ldevHRC065DK 00864000
  1142. LH R1,VMTRMID 370X NCP RESOURCE REFERENCE @V200820 00865000
  1143. CALL DMKCVTBH CONVERT FOR OUTPUT @V200820 00866000
  1144. MVC 0(4,R5),=C'DEV ' 370X TERMINAL IS A 'DEV' @V200820 00867000
  1145. ST R1,4(0,R5) FILL IN TERMINAL REFERENCE @V200820 00868000
  1146. B DSCFMSG GO FINISH OFF OPERATOR MESSAGE @V200820 00869000
  1147. DSCLDEV EQU * HRC065DK 00869100
  1148. TM RDEVADD,RDEVLDEV Is this an LDEV? HRC065DK 00869200
  1149. BZ DSCTERM No HRC065DK 00869300
  1150. MVC 0(5,R5),=CL5'GRF L' Use short GRAF name HRC065DK 00869400
  1151. LH R1,RDEVADD Get the LDEV address HRC065DK 00869500
  1152. N R1,F4095 Keep only the dev num HRC065DK 00869600
  1153. CALL DMKCVTBH Make it displayable HRC065DK 00869700
  1154. STCM R1,7,5(R5) Put dev addr in message HRC065DK 00869800
  1155. B DSCFMSG Go display msg HRC065DK 00869900
  1156. EJECT 00870000
  1157. DSCTERM EQU * @V200820 00871000
  1158. CALL DMKSCNRN GET THE DEVICE NAME FOR THE DEVIC@V200820 00872000
  1159. ST R1,0(0,R5) ... @V200820 00873000
  1160. CALL DMKSCNRD GET THE 'CCU' ADDRESS @V200820 00874000
  1161. CALL DMKCVTBH CONVERT FOR OUTPUT @V200820 00875000
  1162. ICM R1,8,BLANKS PUT A BLANK IN THE FIRST POSITION@V200820 00876000
  1163. ST R1,4(0,R5) ... @V200820 00877000
  1164. SPACE 00878000
  1165. DSCFMSG EQU * COMPLETE OPERATOR INFORMATION MSG@V200820 00879000
  1166. MVC 8(12,R5),=C' DSCONNECT ' ACTION CUE @V200820 00880000
  1167. MVC 19(8,R5),VMUSER FILL IN THE USERID @V200820 00881000
  1168. MVC 27(21,R5),=C' USERS = NNN FORCED ' TRAILER @V200820 00882000
  1169. L R1,=A(DMKSYSNM) NUMBER OF ACTIVE USERS @V200820 00883000
  1170. L R1,0(0,R1) ... @V200820 00884000
  1171. CALL DMKCVTBD CONVERT FOR OUTPUT @V200820 00885000
  1172. STCM R1,B'0111',36(R5) PLACE INTO THE MESSAGE @V200820 00886000
  1173. LR R1,R5 START OF THE MESSAGE DATA @V200820 00887000
  1174. LA R0,6*8 MESSAGE LENGTH @V200820 00888000
  1175. LA R3,6 NO. DBL-WDS FOR 'DFRET' @V200820 00889000
  1176. CALL DMKQCNWT,PARM=OPERATOR+NORET+DFRET @V200820 00890000
  1177. SPACE 00891000
  1178. DSCNMSG EQU * DISCONNECT WITH NO OPERATOR MSG @V200820 00892000
  1179. L R1,VMDELAY SEE IF THERE IS ALREADY A TRQBLOK@V200820 00893000
  1180. LTR R1,R1 ?? @V200820 00894000
  1181. BZ DSCGTRQ NO -- GET SOME FREE STORAGE @V200820 00895000
  1182. CALL DMKSCHRT RESET THE TIMER REQUEST @V200820 00896000
  1183. B DSCSTRQ GO FIX FOR OUR OWN USE @V200820 00897000
  1184. EJECT 00898000
  1185. DSCGTRQ EQU * @V200820 00899000
  1186. LA R0,TRQBSIZE SIZE OF THE TRQBLOK IN DBL-WDS @V200820 00900000
  1187. CALL DMKFREE GET FREE STORAGE FOR A TRQBLOK @V200820 00901000
  1188. USING TRQBLOK,R1 @V200820 00902000
  1189. ST R1,VMDELAY SAVE THE ADDRESS IN THE VMBLOK @V200820 00903000
  1190. XC 0(TRQBSIZE*8,R1),0(R1) CLEAR THE TRQBLOK @V200820 00904000
  1191. DSCSTRQ EQU * @V200820 00905000
  1192. LA R2,DSCTLOG INTERRUPT RETURN ADDRESS @V200820 00906000
  1193. ST R2,TRQBIRA ... @V200820 00907000
  1194. ST R11,TRQBUSER VMBLOK ADDRESS OF THIS USER @V200820 00908000
  1195. STCK TRQBVAL GET THE CURRENT TIME OF DAY @V200820 00909000
  1196. BC 12,CLOCKOK IS CLOCK FUNCTIONING? @VA04301 00909250
  1197. GOTO DMKCVTAB CLOCK DAMAGED...ABEND CVT001 @VA04301 00909500
  1198. CLOCKOK EQU * @VA04301 00909750
  1199. LA R2,DSCTIME DELAY VALUE = 15 MINUTES @V200820 00910000
  1200. AL R2,TRQBVAL ADD TO THE CURRENT VALUE @V200820 00911000
  1201. ST R2,TRQBVAL ... @V200820 00912000
  1202. CALL DMKSCHST SET A CLOCK COMPARATOR REQUEST @V200820 00913000
  1203. DSCEXIT EQU * @V200820 00914000
  1204. EXIT , RETURN TO CALLER @V200820 00915000
  1205. DROP R1 @V200820 00916000
  1206. SPACE 2 00917000
  1207. DSCLLOG EQU * LOGOFF 'LOGON0XX' USERID @V200820 00918000
  1208. LA R4,QCNLOG COME BACK FIRST @VA04688 00919500
  1209. BAL R10,STKCPEX GOTO DMKDSPCH A LITTLE LATER @V200820 00921000
  1210. B DSCEXIT EXIT FOR NOW @V200820 00922000
  1211. SPACE 2 00923000
  1212. USING DSCTLOG,R12 LOCAL ADDRESSABILITY @V200820 00924000
  1213. DSCTLOG EQU * RETURN ADDRESS TO LOGOFF THE USER@V200820 00925000
  1214. LA R0,TRQBSIZE SIZE OF THE TRQBLOK @V200820 00926000
  1215. LR R1,R10 ADDRESS IN GR10 FROM DMKDSPCH @V200820 00927000
  1216. CALL DMKFRET RELEASE THE TRQBLOK STORAGE @V200820 00928000
  1217. SLR R1,R1 @V200820 00929000
  1218. ST R1,VMDELAY CLEAR THE VMBLOK HOLD FIELD @V200820 00930000
  1219. B QCNKIL DONOT ADJUST R12 @VA10061 00930200
  1220. QCNLOG EQU * WHEN CPEXBLOK IS UNSTACKED @VA04688 00930500
  1221. USING QCNLOG,R12 @VA10061 00930600
  1222. SL R12,=A(QCNLOG-DSCTLOG) SET R12 TO DSCTLOG @VA10061 00930700
  1223. QCNKIL DS 0H @VA10061 00930800
  1224. OI VMOSTAT,VMKILL LOG THIS GUY OFF @V200820 00931000
  1225. OI VMSVSTAT,VMLGFORC FORCE @VA13026 00931500
  1226. OI VMRSTAT,VMCFWAIT DO NOT RUN VIRTUAL MACHINE @V200820 00932000
  1227. USING DSCTLOG,R12 @VA10061 00933100
  1228. GOTO DMKDSPCH GO TO DSPCH TO INITIATE FORCE @VA13026 00933200
  1229. SPACE 00934000
  1230. DSCTIME EQU X'0359' 15 MINUTES IN T.O.D. CLOCK UNITS @V200820 00935000
  1231. EJECT 00936000
  1232. *. 00937000
  1233. * SUBROUTINE NAME - 00938000
  1234. * 00939000
  1235. * DMKQCNCL 00940000
  1236. * 00941000
  1237. * FUNCTION - 00942000
  1238. * 00943000
  1239. * TO CLEAR THE CONTASK STACK RETURNING ALL BLOCKS TO FREE 00944000
  1240. * STORAGE 00945000
  1241. * 00946000
  1242. * ATTRIBUTES - 00947000
  1243. * 00948000
  1244. * SERIALLY REUSABLE, RESIDENT, CALLED VIA BALR 00949500
  1245. * 00950000
  1246. * ENTRY CONDITIONS - 00951000
  1247. * 00952000
  1248. * GPR8 = ADDRESS OF RDEVBLOK 00953000
  1249. * GPR11 = ADDRESS OF USER'S VMBLOK 00954000
  1250. * GPR12 = ADDRESS OF DMKQCNCL 00955000
  1251. * 00956000
  1252. * EXIT CONDITIONS - 00957000
  1253. * 00958000
  1254. * CONTASK STACK IS CLEARED - GENERAL REGISTERS ARE RESTORED 00959000
  1255. * 00960000
  1256. * CALLS TO OTHER ROUTINES - 00961000
  1257. * 00962000
  1258. * DMKFREE 00963000
  1259. * DMKQCNET 00964000
  1260. * 00965000
  1261. * EXTERNAL REFERENCES - NONE 00966000
  1262. * 00967000
  1263. * TABLES / WORK AREAS - NONE 00968000
  1264. * 00969000
  1265. * REGISTER USAGE - 00970000
  1266. * 00971000
  1267. * GPR8 = ADDRESS OF RDEVBLOK 00972000
  1268. * GPR11 = ADDRESS OF USER'S VMBLOK 00973000
  1269. * GPR12 = MODULE BASE REGISTER 00974000
  1270. * 00975000
  1271. * GPRS 0-3, 4-7, 9, 13-15 ARE WORK REGISTERS 00976000
  1272. * 00977000
  1273. * NOTES - NONE 00978000
  1274. * 00979000
  1275. * OPERATION - 00980000
  1276. * 00981000
  1277. * (TO BE CONTINUED) 00982000
  1278. *. 00983000
  1279. EJECT 00984000
  1280. DROP R12 @V200820 00985000
  1281. USING RDEVBLOK,R8 @V200820 00986000
  1282. USING DMKQCNCL,R15 @V200820 00987000
  1283. DMKQCNCL DS 0D ENTRY TO CLEAR A CONTASK STACK @V200820 00988000
  1284. SWITCH CONTINUE PROCESSING ON I/O PROC @V407508 00988100
  1285. STM R0,R15,BALRSAVE @V200820 00989000
  1286. L R12,=A(DMKQCN) STANDARD MODULE ADDRESSABILI@V200820 00990000
  1287. DROP R15 @V200820 00991000
  1288. USING DMKQCN,R12 @V200820 00992000
  1289. NI RDEVSTA2,255-RDEVDROP CLEAR FLAG @VA04688 00992500
  1290. SPACE 2 00993000
  1291. L R6,RDEVCON PICK UP POINTER TO FIRST CONTASK @V200820 00994000
  1292. LTR R6,R6 IS THERE ANYTHING TO CLEAR ? @V200820 00995000
  1293. BNP BALREXT NO -- JUST RETURN TO CALLER @V200820 00996000
  1294. SPACE 00997000
  1295. GETCONT EQU * CHECK NEXT CONTASK @V200820 00998000
  1296. OI CONSTAT,CONCNTL SUPPRESS SPOOLING @V200820 00999000
  1297. TM CONSTAT,CONRESP RESPONSE EXPECTED ? @V200820 01000000
  1298. BZ NEXTCON NO -- @V200820 01001000
  1299. TM CONSTAT,CONSYNC SYNCHRONIZATION CONTASK? @VA04453 01001300
  1300. BO NEXTCON YES--PRESERVE R2 @VA04453 01001600
  1301. L R13,CONRETN PICK UP SAVEAREA ADDRESS @V200820 01002000
  1302. LA R0,12 SET 'LINE BREAK' RETURN CODE @V200820 01003000
  1303. ST R0,SAVER2 ... @V200820 01004000
  1304. TM CONPARM,LOGHOLD+LOGDROP ANY OF THESE PARM? @VA04688 01004100
  1305. BZ NEXTCON NO-- NEXT @VA04688 01004200
  1306. C R11,SAVER11 THE SAME USER? @VA04688 01004300
  1307. BNE NEXTCON NO--NEXT @VA04688 01004400
  1308. OI RDEVSTA2,RDEVDROP LOGDROP/LOGHOLD INDICATED @VA04688 01004500
  1309. NEXTCON EQU * CHECK NEXT CONTASK @V200820 01005000
  1310. L R6,CONPNT GET NEXT ONE IN LINE @V200820 01006000
  1311. LTR R6,R6 ANY MORE TO CHECK ? @V200820 01007000
  1312. BNZ GETCONT YES - KEEP LOOKING @V200820 01008000
  1313. L R6,RDEVCON POINTER TO THE CONTASK STACK @V200820 01009000
  1314. SLR R0,R0 @V200820 01010000
  1315. ST R0,RDEVCON CONTASK STACK HAS BEEN CLEARED @V200820 01011000
  1316. B RETANON RETURN TASKS TO ORIGINATOR @V200820 01012000
  1317. EJECT 01013000
  1318. *. 01014000
  1319. * SUBROUTINE NAME - 01015000
  1320. * 01016000
  1321. * DMKQCNET 01017000
  1322. * 01018000
  1323. * FUNCTION - 01019000
  1324. * 01020000
  1325. * TO PROCESS COMPLETED CONTASKS FOR VIRTUAL CONSOLE SPOOLING, 01021000
  1326. * RETURN OR NO-RETURN OPTIONS, AND TO RETURN THE CONTASK BLOCKS 01022000
  1327. * TO FREE STORAGE. 01023000
  1328. * 01024000
  1329. * ATTRIBUTES - 01025000
  1330. * 01026000
  1331. * RE-ENTRANT, RESIDENT, ENTERED VIA 'GOTO' 01027000
  1332. * 01028000
  1333. * ENTRY CONDITIONS - 01029000
  1334. * 01030000
  1335. * GPR 12 = ADDRESS OF DMKQCNET 01031000
  1336. * GPR 11 = ADDRESS OF A VALID VMBLOK 01032000
  1337. * GPR 6 = ADDRESS OF A CHAIN OF CONTASK BLOCKS 01033000
  1338. * 01034000
  1339. * EXIT CONDITIONS - 01035000
  1340. * 01036000
  1341. * CONTASKS HAVE BEEN RETURNED TO FREE STORAGE, 'EXIT'S HAVE 01037000
  1342. * BEEN MADE FOR ANY WHICH REQUESTED A RETURN AFTER COMPLETION. 01038000
  1343. * 01039000
  1344. * CALLS TO OTHER ROUTINES - 01040000
  1345. * 01041000
  1346. * DMKSTKCP 01042000
  1347. * DMKFRET 01043000
  1348. * DMKVSPVP 01044000
  1349. * DMKFREE 01045000
  1350. * DMKLOKSW 01045100
  1351. * 01046000
  1352. * EXTERNAL REFERENCES - NONE 01047000
  1353. * 01048000
  1354. * TABLES / WORK AREAS - NONE 01049000
  1355. * 01050000
  1356. * REGISTER USAGE - 01051000
  1357. * 01052000
  1358. * GPR 12 = MODULE BASE REGISTER 01053000
  1359. * GPR 11 = VMBLOK ADDRESSABILITY 01054000
  1360. * GPR 6 = CONTASK ADDRESSABILITY 01055000
  1361. * 01056000
  1362. * GPRS 0-5, 7-10, 13-15 ARE WORK/LINKAGE REGISTERS 01057000
  1363. EJECT 01058000
  1364. * OPERATION - 01059000
  1365. * 01060000
  1366. * 1. LOAD GR11 WITH THE VMBLOK ADDRESS OF THE CONTASK OWNER. 01061000
  1367. * 2. IF THE USER IS NOT YET LOGGED ON, SKIP TO STEP 4. 01062000
  1368. * 3. IF THE USER HAS A VIRTUAL CONSOLE, AND IS SPOOLING 01063000
  1369. * CONSOLE I/O, CALL DMKVSPVP TO SPOOL THE CONTASK DATA. 01064000
  1370. * 4. PICK UP SAVEAREA POINTER (IF ANY), AND POINTER TO NEXT 01065000
  1371. * CONTASK (IF ANY) FROM THE CURRENT CONTASK. 01066000
  1372. * 5. CALL DMKFRET TO RETURN THE CONTASK TO FREE STORAGE. 01067000
  1373. * 6. IF THERE ARE NO OTHER CONTASKS AND A RETURN WAS REQUESTED, 01068000
  1374. * EXIT ON THE CONTASK SAVEAREA WITH CONDITION CODE SET. 01069000
  1375. * 7. IF THERE ARE NO OTHER CONTASKS AND NO RETURN IS NEEDED, 01070000
  1376. * 'GOTO DMKDSPCH'. 01071000
  1377. * 8. IF THERE ARE OTHER CONTASKS AND A RETURN IS REQUESTED, 01072000
  1378. * CALL DMKFREE TO BUILD A CPEXBLOK TO RESTART AT STEP 1. 01073000
  1379. * AND THEN GO TO STEP 6. 01074000
  1380. * 9. IF THERE ARE OTHER CONTASKS AND NO RETURN IS NEEDED, 01075000
  1381. * RESTART AT STEP 1. WITH NEXT CONTASK. 01076000
  1382. *. 01077000
  1383. SPACE 2 01078000
  1384. DROP R12 @V200820 01079000
  1385. USING DMKQCNET,R15 @V200820 01080000
  1386. DMKQCNET DS 0D ENTRY FOR COMPLETED CONTASK'S @V200820 01081000
  1387. STM R0,R15,BALRSAVE @V200820 01082000
  1388. L R12,=A(DMKQCN) ESTABLISH BASE ADDRESSABILITY @V200820 01083000
  1389. DROP R15 @V200820 01084000
  1390. USING DMKQCN,R12 @V200820 01085000
  1391. SPACE 01086000
  1392. RETANON EQU * RESTART HERE FOR MULTIPLE CONTASK@V200820 01087000
  1393. CHARGE SWITCH,CONUSER SWITCH TO CONTASK OWNER @V407508 01088100
  1394. SLR R13,R13 CLEAR COUNT REG @VM01023 01091000
  1395. TM CONSTAT,CONRESP WAITING FOR MSG ? @VM01023 01092000
  1396. BNZ CONWT YES..GOOD ENOUGH... @VM01023 01093000
  1397. TM CONSTAT,CONOUTPT OUTPUT CONTASK ? @VM01023 01094000
  1398. BZ RETNRET NO..CONTINUE... @VM01023 01095000
  1399. ICM R13,B'0001',VMRBSC PICK UP CONTASK COUNT @VM01023 01096000
  1400. BZ RETNRET NOT 3270R PROBABLY... @VM01023 01097000
  1401. BCTR R13,R0 DECREMENT COUNT BY ONE... @VM01023 01098000
  1402. STC R13,VMRBSC REPLACE COUNT @VM01023 01099000
  1403. B RETNRET CONTINUE... @VM01023 01100000
  1404. CONWT EQU * @VM01023 01101000
  1405. STC R13,VMRBSC CLEAR CONTASK COUNT... @VM01023 01102000
  1406. L R13,CONRETN PICK UP OLD SAVEAREA POINTER @V200820 01103000
  1407. MVC SAVEWRK1(2),CONSTAT SAVE CONSTAT, CONPARM HERE @V200820 01104000
  1408. LA R4,RETEXIT EXADD TO PERFORM 'EXIT' @V200820 01105000
  1409. BAL R10,STKCPEX STACK CPEXBLOK FOR LATER EXIT @V200820 01106000
  1410. TM CONSTAT,CONOUTPT+CONCNTL IS THIS A READ TASK ?@V200820 01107000
  1411. BNZ RETNRET NO -- ALL SET @V200820 01108000
  1412. TM CONPARM,INHIBIT CRITICAL DATA? @VM01007 01109000
  1413. BO *+8 YUP, SKIP THE MC DATA COLLECT @VM01007 01110000
  1414. QCNMC2 MC MNCOERD,MNCLRESP RESPONSE CLASS, END READ @VM01017 01111000
  1415. LH R5,CONCNT REFLECT THE COUNT @V200820 01112000
  1416. ST R5,SAVER0 ...IN CALLER'S GR0 @V200820 01113000
  1417. RETNRET EQU * @V200820 01114000
  1418. L R5,CONPNT POINTER TO NEXT CONTASK, IF ANY @V200820 01115000
  1419. BAL R9,FRETASK RETURN CONTASK TO FREE STORAGE @V200820 01116000
  1420. LTR R6,R5 SINGLE CONTASK TO PROCESS ? @V200820 01117000
  1421. BP RETANON NO -- GO PROCESS THE NEXT ONE @V200820 01118000
  1422. BALREXT EQU * RESTORE REGISTERS, RETURN TO CALLER @V200820 01119000
  1423. CHARGE SWITCH,BALR11 SWITCH BACK TO CALLER'S VMBLOK @V407508 01120100
  1424. LM R0,R15,BALRSAVE RESTORE CALLER'S REGS @V407508 01121100
  1425. BR R14 ... @V200820 01123000
  1426. EJECT 01124000
  1427. USING RETEXIT,R12 TEMPORARILY . . . @V200820 01125000
  1428. RETEXIT EQU * SET CONDITION CODE, RETURN TO CALLER @V200820 01126000
  1429. L R12,=A(DMKQCN) GET REGULAR ADDRESSABILITY BACK @V200820 01127000
  1430. USING DMKQCN,R12 . . . @V200820 01128000
  1431. SPACE 01129000
  1432. TM SAVEWRK1,CONOUTPT+CONCNTL INPUT CONTASK ? @V200820 01130000
  1433. BNZ RETNOSP NO -- SKIP SPOOLING CHECK @V200820 01131000
  1434. TM SAVEWRK1+1,INHIBIT CRITICAL DATA ? @V200820 01132000
  1435. BO RETNOSP YES - DO NOT SPOOL IT @V200820 01133000
  1436. TM VMRSTAT,VMLOGON IS HE LOGGED ON ALL THE WAY @V200820 01134000
  1437. BO RETNOSP NO -- SKIP SPOOLING CHECK @V200820 01135000
  1438. LH R8,VMVTERM DISPLACEMENT TO TERMINAL VDEVBLOK@V200820 01136000
  1439. LTR R8,R8 IS THERE A VIRTUAL TERMINAL ? @V200820 01137000
  1440. BM RETNOSP NO -- SKIP IT @V200820 01138000
  1441. AL R8,VMDVSTRT DISPLACE TO THE VDEVBLOK ITSELF @V200820 01139000
  1442. USING VDEVBLOK,R8 @V200820 01140000
  1443. TM VDEVFLAG,VDEVCSPL SPOOLING CONSOLE ACTIVITY ? @V200820 01141000
  1444. BZ RETNOSP NO -- @V200820 01142000
  1445. LM R0,R1,SAVER0 DATA START ADDRESS, LENGTH @V200820 01143000
  1446. LTR R0,R0 IS THIS A ZERO-LENGTH MESSAGE ? @V200820 01144000
  1447. BNP RETNOSP YES - SKIP CALL TO DMKVSP @V200820 01145000
  1448. SL R8,VMDVSTRT VDEVBLOK DISPLACEMENT @VA01460 01146000
  1449. CALL DMKVSPVP SPOOL IT @V200820 01147000
  1450. DROP R8 @V200820 01148000
  1451. RETNOSP EQU * NO SPOOLING REQUIRED, OR IT'S DONE @V200820 01149000
  1452. L R1,SAVER11 GET VMBLOK ADDR OF ORIG CALLER @V407508 01150100
  1453. SWTCHVM SWITCH TO THIS VMBLOK V407508 01151100
  1454. L R2,SAVER2 RETURN CODE FROM SLIH @V200820 01153000
  1455. LTR R2,R2 SET CONDITION CODE APPROPRIATELY @V200820 01154000
  1456. EXIT , RETURN TO ORIGINAL CALLER @V200820 01155000
  1457. EJECT 01156000
  1458. STKCPEX EQU * BUILD AND STACK A CPEXBLOK @V200820 01157000
  1459. LA R0,CPEXSIZE GET A CPEXBLOK @V200820 01158000
  1460. CALL DMKFREE @V200820 01159000
  1461. USING CPEXBLOK,R1 @V200820 01160000
  1462. XC 0(16,R1),0(R1) CLEAR THE HEADER SECTION @V200820 01161000
  1463. STM R0,R15,CPEXREGS SET REGISTERS @V200820 01162000
  1464. ST R4,CPEXADD ...AND EXECUTION ADDRESS @V200820 01163000
  1465. ST R4,CPEXR12 USE EXADD AS BASE FOR 'GOTO' USE @V200820 01164000
  1466. CALL DMKSTKCP ...STACK IT @V200820 01165000
  1467. BR R10 RETURN INTERNALLY @V200820 01166000
  1468. DROP R1 @V200820 01167000
  1469. SPACE , HRC101DK 01167100
  1470. F13 DC F'13' HRC101DK 01167150
  1471. SF EQU X'1D' START FIELD DEFINITION HRC101DK 01167200
  1472. ATTRPRHI EQU X'E8' PROTECTED, HI INTENSITY HRC101DK 01167250
  1473. ATTRPRLO EQU X'60' PROTECTED, LOW INTENSITY HRC101DK 01167300
  1474. SPACE , HRC101DK 01167350
  1475. NOMC EQU X'10' DON'T ALLOW MONITOR CALL @VA09459 01167500
  1476. FORCE EQU X'02' FORCED LOGOFF BY SYSTEM @VA08667 01167580
  1477. RESPMASK DS 0F BITS THAT INDICATE MESSAGE IS @V60C2B8 01167660
  1478. DC XL2'00' NOT TO BE MOVED TO A RESPONSE BUF@V60C2B8 01167740
  1479. DC AL1((OPERATOR+NOTRESP)/256) @V60C2B8 01167820
  1480. DC AL1(LOGDROP+LOGHOLD+VMGENIO) @V60C2B8 01167900
  1481. NOQMASK DS 0F Bits that indicate msg HRC064DK 01167910
  1482. DC XL2'00' is not to be queued HRC064DK 01167920
  1483. DC AL1((OPERATOR+NOQUEUE)/256) HRC064DK 01167930
  1484. DC AL1(LOGDROP+LOGHOLD+VMGENIO) HRC064DK 01167940
  1485. SPACE 2 01168000
  1486. DS 0F FORCE ALIGNMENT FOR MASK WORK @VA13491 01168100
  1487. ATTRMSK1 DC X'0000001C' MASK FOR VALID SF ORDER BITS @VA13491 01168200
  1488. SPACE 1 @VA13491 01168300
  1489. * TABLE OF ACCEPTABLE SF ATTRIBUTES @VA13491 01168400
  1490. ATTRTBL DC XL1'60',XL1'E4',XL1'E8',XL1'6C' @VA13491 01168500
  1491. DC XL1'F0',XL1'F4',XL1'F8',XL1'7C' @VA13491 01168600
  1492. EJECT , HRC101DK 01169190
  1493. LTORG , HRC101DK 01169680
  1494. EJECT , HRC101DK 01170170
  1495. COPY IOBLOKS @V200820 01171000
  1496. COPY RBLOKS @V200820 01172000
  1497. COPY NETWORK @V200820 01173000
  1498. COPY VBLOKS @V200820 01174000
  1499. COPY VMBLOK @V200820 01175000
  1500. COPY SAVE @V200820 01176000
  1501. COPY TIMER @V200820 01177000
  1502. COPY DEVTYPES @V200820 01178000
  1503. COPY EQU @V200820 01179000
  1504. PSA @V200820 01180000
  1505. END DMKQCN @V200820 01181000