Table of Contents

DMKCFD Source

References

Source Listing

DMKCFD.ASSEMBLE.txt
  1. CFD TITLE 'DMKCFD (CP) VM/370 - RELEASE 6' 00001000
  2. ISEQ 73,80 VALIDATE SEQUENCING OF INPUT 00002000
  3. *. 00003000
  4. * MODULE NAME - 00004000
  5. * DMKCFD 00005000
  6. * 00006000
  7. * FUNCTION - 00007000
  8. * TO HANDLE THE 'LOCATE' AND 'ADSTOP' COMMANDS. 00008000
  9. * 00009000
  10. * ATTRIBUTES - 00010000
  11. * REENTRANT, PAGEABLE, CALLED VIA SVC 00011000
  12. * 00012000
  13. * ENTRY POINTS - 00013000
  14. * DMKCFDLO - TO PRINT THE ADDRESS OF REAL DEVICE BLOKS 00014000
  15. * OR VMBLOK AND/OR VIRTUAL DEVICE BLOK ADDRESSES. 00015000
  16. * DMKCFDAD - TO STOP EXECUTION OF THE VIRTUAL MACHINE AT A 00016000
  17. * SPECIFIC ADDRESS. 00017000
  18. * 00018000
  19. * ENTRY CONDITIONS - 00019000
  20. * GPR9 - ADDRESS OF THE COMMAND LINE BUFFER. 00020000
  21. * GPR11- ADDRESS OF USERS VMBLOK. 00021000
  22. * GPR12- ADDRESS OF THE ENTRY POINT. 00022000
  23. * GPR13- ADDRESS OF THE STANDARD SAVE AREA. 00023000
  24. * 00024000
  25. * EXIT CONDITIONS - 00025000
  26. * NORMAL - 00026000
  27. * GPR2 = 0 00027000
  28. * 00028000
  29. * ERROR - 00029000
  30. * GPR2 = ERROR MESSAGE NUMBER 00030000
  31. * 00031000
  32. * CALLS TO OTHER ROUTINES - 00032000
  33. * DMKSCNFD - TO LOCATE THE NEXT ARGUMENT IN THE COMMAND LINE 00033000
  34. * BUFFER. 00034000
  35. * DMKSCNAU - TO LOCATE THE VMBLOK OF A SPECIFIED USERID. 00035000
  36. * DMKSCNVU - TO LOCATE THE ADDRESSES OF VITUAL DEVICE BLOKS. 00036000
  37. * DMKSCNRU - TO LOCATE THE ADDRESSES OF REAL DEVICE BLOKS. 00037000
  38. * DMKCVTHB - TO CONVERT HEXIDECIMAL NUMBERS TO BINARY. 00038000
  39. * DMKCVTBH - TO CONVERT BINARY NUMBERS TO HEXIDECIMAL. 00039000
  40. * DMKFREE - TO OBTAIN STORAGE FOR BUFFERS. 00040000
  41. * DMKFRET - TO RETURN ACQUIRED STORAGE TO THE SYSTEM. 00041000
  42. * DMKQCNWT - TO SEND MESSAGES TO THE TERMINAL. 00042000
  43. * DMKERMSG - SEND ERROR MESSAGES TO TERMINAL. 00043000
  44. * DMKPSASC - TO CHECK IF ADDRESS IS IN A SHARED PAGE 00044000
  45. * DMKATSCF - TO UNSHARE A NAMED SYSTEM 00045000
  46. * 00046000
  47. * TABLES AND WORKAREAS - 00047000
  48. * NONE 00048000
  49. * 00049000
  50. * REGISTER USAGE - 00050000
  51. * GPR0 - FIELD LENGTH REGISTER. 00051000
  52. * GPR1 - ADDRESS OF ARGUMENT IN COMMAND LINE. 00052000
  53. * GPR2 - PARAMETER REGISTER FOR CALLED ROUTINES. 00053000
  54. * GPR3 - PARAMETER REGISTER FOR CALLED ROUTINES. 00054000
  55. * GPR4 - WORK REGISTER. 00055000
  56. * GPR5 - WORK REGISTER. 00056000
  57. * GPR6 - ADDRESS OF RCHBLOK OR VCHBLOK 00057000
  58. * GPR7 - ADDRESS OF RCUBLOK OR VCUBLOK 00058000
  59. * GPR8 - ADDRESS OF RDEVBLOK OR VDEVBLOK. 00059000
  60. * GPR9 - ADDRESS OF COMMAND LINE BUFFER. 00060000
  61. * GPR10 - ADDRESS OF OUTPUT BUFFER. 00061000
  62. * GPR11 - ADDRESS OF VMBLOK 00062000
  63. * GPR12 - BASE REGISTER. 00063000
  64. * GPR13 - ADDRESS OF SAVEAREA. 00064000
  65. * GPR14 - LINKAGE REGISTER. 00065000
  66. * GPR15 - LINKAGE REGISTER. 00066000
  67. * 00067000
  68. * NOTES - 00068000
  69. * NONE 00069000
  70. * 00070000
  71. * OPERATION - 00071000
  72. * THE COMMAND ROUTINES ARE CALLED BY DMKCFM. THE FORMAT AND 00072000
  73. * DESCRIPTION OF EACH COMMAND IS LISTED IN SEPARATE PROLOGS 00073000
  74. * BELOW. 00074000
  75. *. 00075000
  76. EJECT 00076000
  77. DMKCFD CSECT 00077000
  78. MODID DC CL8'DMKCFD' 00078000
  79. SPACE 00079000
  80. EXTRN DMKSCNFD 00080000
  81. EXTRN DMKPSASC,DMKATSCF @V60BC11 00081000
  82. EXTRN DMKCVTHB 00082000
  83. EXTRN DMKCVTBH 00083000
  84. EXTRN DMKSCNAU 00084000
  85. EXTRN DMKSCNVU 00085000
  86. EXTRN DMKSCNRU 00086000
  87. EXTRN DMKERMSG 00087000
  88. EXTRN DMKCPEND,DMKSYMTB HRC104DK 00087500
  89. SPACE 00088000
  90. USING PSA,R0 00089000
  91. USING VMBLOK,R11 00090000
  92. USING SAVEAREA,R13 00091000
  93. SPACE 00092000
  94. NOFREE EQU X'80' INDICATES NO CALL TO DMKFREE 00093000
  95. EJECT 00094000
  96. *********************************************************************** 00095000
  97. * * 00096000
  98. * 'LOCATE' * 00097000
  99. * * 00098000
  100. *********************************************************************** 00099000
  101. *. 00100000
  102. * SUBROUTINE NAME - 00101000
  103. * DMKCFDLO 00102000
  104. * 00103000
  105. * 00104000
  106. * FUNCTION - 00105000
  107. * TO DISPLAY THE ADDRESS OF THE SYSTEM CONTROL BLOKS ASSOCIATED 00106000
  108. * WITH A SPECIFIC USER OR A REAL SYSTEM DEVICE. 00107000
  109. * 00108000
  110. * COMMAND FORMAT - 00109000
  111. * +----------+-----------------+ 00110000
  112. * | LOCATE | USERID <VADDR> | 00111000
  113. * | LOC | RADDR | 00112000
  114. * | | SYMBOL_NAME | HRC104DK 00112500
  115. * +----------+-----------------+ 00113000
  116. * 00114000
  117. * OPERATION - 00115000
  118. * 00116000
  119. * 1. CALL DMKSCNFD TO LOCATE THE FIRST ARGUMENT. IF NO ARGUMENT 00117000
  120. * IS FOUND, CALL DMKERMSG TO SEND ERROR MESSAGE 00118000
  121. * DMKCFD026E AND EXIT. 00119000
  122. * 2. CALL DMKSCNAU TO SEE IF IT IS A USERID. IF RETURN FROM 00120000
  123. * DMKSCNAU INDICATES A VALID USER, THEN CALL DMKCVTBH 00121000
  124. * TO CONVERT THE VMBLOK ADDRESS TO PRINTABLE FORM. 00122000
  125. * THEN CALL DMKSCNFD AGAIN TO SEE IF VADDR REQUEST. IF NONE 00123000
  126. * IS FOUND, OUTPUT JUST THE VMBLOK ADDRESS.IF ONE FOUND, CALL 00124000
  127. * DMKCVTHB TO CONVERT THE ADDRESS TO BINARY. IF CONVERT 00125000
  128. * FAILS, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFD022E AND 00126000
  129. * EXIT.ELSE, CALL DMKSCNVU TO LOCATE THE VIRTUAL DEVICE 00127000
  130. * BLOKS. IF BLOKS ARE NOT FOUND, CALL DMKERMSG TO SEND 00128000
  131. * ERROR MESSAGE DMKCFD040E AND EXIT. ELSE, CALL DMKCVTBH TO 00129000
  132. * CONVERT THESE ADDRESSES TO PRINTABLE FORM. THEN CALL 00130000
  133. * DMKQCNWT TO OUTPUT ADDRESSES. 00131000
  134. * 3. IF NOT A USERID, CALL DMKCVTHB TO CONVERT THE REAL 00132000
  135. * ADDRESS TO BINARY. IF CONVERT FAILS, CALL DMKERMSG TO 00133000
  136. * SEND ERROR MESSAGE DMKCFD021E AND EXIT. ELSE, CALL DMKSCNRU 00134000
  137. * TO LOCATE THE REAL DEVICE BLOKS. IF NOT FOUND, CALL 00135000
  138. * DMKERMSG TO SEND ERROR MESSAGE DMKCFD040E AND EXIT. IF OK, 00136000
  139. * CALL DMKCVTBH TO CONVERT THE REAL BLOK ADDRESSES 00137000
  140. * TO PRINTABLE FORM. THEN CALL DMKQCNWT TO SEND THE MESSAGE. 00138000
  141. * 00139000
  142. * RESPONSES - 00140000
  143. * 00141000
  144. * SYMBOL = XXXXXX PAGEABLE, REAL = XXXXXX HRC104DK 00142190
  145. * SYMBOL = XXXXXX RESIDENT HRC104DK 00142380
  146. * HRC104DK 00142570
  147. * VMBLOK = XXXXXX HRC104DK 00142760
  148. * 00143000
  149. * VMBLOK VCHBLOK VCUBLOK VDEVBLOK 00144000
  150. * XXXXXX XXXXXX XXXXXX XXXXXX 00145000
  151. * 00146000
  152. * RCHBLOK RCUBLOK RDEVBLOK 00147000
  153. * XXXXXX XXXXXX XXXXXX 00148000
  154. * 00149000
  155. * WHERE XXXXXX IS THE ADDRESS OF THE RESPECTIVE BLOK. 00150000
  156. * 00151000
  157. * ERROR MESSAGES - 00152000
  158. * DMKCFD021E RADDR MISSING OR INVALID 00153000
  159. * DMKCFD022E VADDR MISSING OR INVALID 00154000
  160. * DMKCFD026E OPERAND MISSING OR INVALID 00155000
  161. * DMKCFD040E DEV (ADDR) DOES NOT EXIST 00156000
  162. * DMKCFD1003E XXXXX WAS NOT FOUND. (THIS WILL BE ADDED) HRC104DK 00156500
  163. *. 00157000
  164. SPACE 3 00158000
  165. DMKCFDLO RELOC 00159000
  166. MVI SAVEWRK1,X'00' ZERO FLAG AREA 00160000
  167. CALL DMKSCNFD LOCATE FIRST ARGUMENT 00161000
  168. BNZ CFD026 MISSING ARGUMENT 00162000
  169. STM R0,R1,SAVEWRK2 SAVE LENGTH AND ADDRESS OF ARG. 00163000
  170. CALL DMKSCNAU SEE IF VALID USERID 00164000
  171. BNZ LOCRADDR BRANCH IF NOT - GO SEE IF VALID RADDR 00165000
  172. LR R3,R1 SAVE USERID VMBLOK ADDRESS 00166000
  173. CALL DMKCVTBH CONVERT VMBLOK ADDRESS 00167000
  174. LR R4,R0 SAVE VMBLOK ADDRESS 00168000
  175. LR R5,R1 . . 00169000
  176. CALL DMKSCNFD LOCATE VADDR IF ANY 00170000
  177. BNZ VMONLY BRANCH IF NONE FOUND 00171000
  178. CL R0,F3 ARGUMENT OVER THREE CHARACTERS 00172000
  179. BH CFD022 BAD NEWS IF TAKE BRANCH 00173000
  180. STM R0,R4,SAVEWRK2 SAVE REGISTERS 00174000
  181. LM R0,R4,SAVEWRK2 RESTORE REGISTERS 00175000
  182. CALL DMKCVTHB CONVERT ADDRESS 00176000
  183. BNZ CFD022 INVALID ADDRESS 00177000
  184. LR R10,R11 SAVE CALLERS VMBLOK ADDRESS 00178000
  185. LR R11,R3 POINT R11 TO USERID VMBLOK ADDRESS 00179000
  186. CALL DMKSCNVU GET BLOK ADDRESSES 00180000
  187. LR R11,R10 RESTORE CALLERS VMBLOK ADDRESS 00181000
  188. BNZ CFD040 UNIT NOT FOUND 00182000
  189. * 00183000
  190. * GPR6 = VCHBLOK ADR.;GPR7 = VCUBLOK ADR.; GPR8 = VDEVBLOK ADR. 00184000
  191. * 00185000
  192. LA R0,38 LOAD LENGTH OF HEADER RECORD 00186000
  193. LA R1,VMHDR ADDRESS OF HEADER 00187000
  194. CALL DMKQCNWT,PARM=NORET SEND HEADER 00188000
  195. LA R0,LOCMSGSZ SIZE OF BUFFER 00189000
  196. CALL DMKFREE GET BUFFER 00190000
  197. LR R10,R1 ADDRESS OF BUFFER TO R10 00191000
  198. USING LOCMSG,R10 00192000
  199. MVC LOCMSG(8),BLANKS BLANK MSG AREA 00193000
  200. MVC LOCMSG+8((LOCMSGSZ*8)-8),LOCMSG . . 00194000
  201. STCM R4,3,VMBLKADR STORE VMBLOK ADDRESS IN MESSAGE 00195000
  202. STCM R5,15,VMBLKADR+2 . . 00196000
  203. LR R1,R6 ADDRESS OF VCHBLOK TO R1 00197000
  204. CALL DMKCVTBH CONVERT TO PRINTABLE FORM 00198000
  205. STCM R0,3,VMCHADR STORE VCHBLOK ADDRESS IN MESSAGE 00199000
  206. STCM R1,15,VMCHADR+2 . . 00200000
  207. LR R1,R7 VCUBLOK ADDRESS TO R1 00201000
  208. CALL DMKCVTBH CONVERT 00202000
  209. STCM R0,3,VMCUADR STORE INTO MESSAGE 00203000
  210. STCM R1,15,VMCUADR+2 00204000
  211. LR R1,R8 ADDRESS OF VDEVBLOK TO R1 00205000
  212. CALL DMKCVTBH CONVERT 00206000
  213. STCM R0,3,VMDEVADR STORE INTO MESSAGE 00207000
  214. STCM R1,15,VMDEVADR+2 00208000
  215. LA R0,36 LENGTH OF MESSAGE 00209000
  216. LR R1,R10 ADDRESS OF MESSAGE 00210000
  217. DROP R10 00211000
  218. B CFDWRIT GO SEND MESSAGE AND EXIT 00212000
  219. SPACE 6 00213000
  220. VMONLY OI SAVEWRK1,NOFREE SET NO CALL TO DMKFREE BIT 00214000
  221. MVC SAVEWRK2(6),VMHDR MOVE 'VMBLOK' TO MESSAGE 00215000
  222. MVC SAVEWRK3+2(3),=C' = ' INSERT EQUAL 00216000
  223. STCM R4,3,SAVEWRK4+1 STORE VMBLOK ADDRESS INTO MESSAGE 00217000
  224. STCM R5,15,SAVEWRK4+3 . . 00218000
  225. LA R0,15 MESSAGE LENGTH 00219000
  226. LA R1,SAVEWRK2 ADDRESS OF MESSAGE 00220000
  227. B CFDWRIT GO SEND IT 00221000
  228. SPACE 6 00222000
  229. LOCRADDR OI SAVEWRK1,NOFREE SET NO CALL TO DMKFREE BIT 00223000
  230. LM R0,R1,SAVEWRK2 LOAD LENGTH AND ADDRESS OF ARG. 00224000
  231. CL R0,F3 CHECK FOR VALID RADDR 00225000
  232. BH SCNSYM BRANCH IF TOO MANY CHARACTERS HRC104DK 00226490
  233. CALL DMKCVTHB CONVERT REAL ADDRESS TO BINARY 00227000
  234. BNZ CFD021 INVALID RADDR 00228000
  235. CALL DMKSCNRU GET ADDRESSES OF BLOKS 00229000
  236. BNZ CFD040 CAN'T FIND 00230000
  237. LA R0,28 LENGTH OF HEADER 00231000
  238. LA R1,RADRHDR ADDRESS OF HEADER 00232000
  239. CALL DMKQCNWT,PARM=NORET SEND IT 00233000
  240. MVC SAVEWRK2(8),BLANKS BLANK MESSAGE AREA 00234000
  241. MVC SAVEWRK4(22),SAVEWRK2 . . 00235000
  242. LR R1,R6 RCHBLOK ADDRESS TO R1 00236000
  243. CALL DMKCVTBH CONVERT ADDRESS 00237000
  244. STCM R0,3,SAVEWRK2 STORE ADDRESS IN MESSAGE 00238000
  245. STCM R1,15,SAVEWRK2+2 . . 00239000
  246. LR R1,R7 ADDRESS OF RCUBLOK 00240000
  247. CALL DMKCVTBH CONVERT 00241000
  248. STCM R0,3,SAVEWRK4+2 STORE INTO MESSAGE 00242000
  249. STCM R1,15,SAVEWRK5 . . 00243000
  250. LR R1,R8 ADDRESS OF RDEVBLOK 00244000
  251. CALL DMKCVTBH CONVERT 00245000
  252. STCM R0,3,SAVEWRK7 STORE IT 00246000
  253. STCM R1,15,SAVEWRK7+2 . . 00247000
  254. LA R0,26 MESSAGE LENGTH 00248000
  255. LA R1,SAVEWRK2 MESSAGE ADDRESS 00249000
  256. B CFDWRIT SEND MESSAGE NEXT HRC104DK 00249010
  257. SPACE , HRC104DK 00249020
  258. SCNSYM DS 0H HRC104DK 00249030
  259. LM R2,R3,SAVEWRK2 LOAD LENGTH AND ADDRESS OF ARG. HRC104DK 00249040
  260. L R1,=A(DMKSYMTB) HRC104DK 00249050
  261. BCTR R2,0 DECREMENT FOR EXECUTE HRC104DK 00249060
  262. SPACE , HRC104DK 00249070
  263. SCNSYMLP DS 0H HRC104DK 00249080
  264. CLI 0(R1),X'00' END OF LIST? HRC104DK 00249090
  265. BE SCNSYMDN HRC104DK 00249100
  266. EX R2,SYMCLC HRC104DK 00249110
  267. BE SYMFND HRC104DK 00249120
  268. LA R1,12(,R1) INCREMENT TO NEXT HRC104DK 00249130
  269. B SCNSYMLP HRC104DK 00249140
  270. SPACE , HRC104DK 00249150
  271. SYMCLC CLC 0(0,R3),0(R1) HRC104DK 00249160
  272. SPACE , HRC104DK 00249170
  273. SCNSYMDN DS 0H HRC104DK 00249180
  274. B CFD1003 HRC104DK 00249190
  275. SPACE , HRC104DK 00249200
  276. SYMFND DS 0H HRC104DK 00249210
  277. LR R3,R1 GET ADDRESS OF DATA HRC104DK 00249220
  278. LA R0,SYMMSGSZ HRC104DK 00249230
  279. CALL DMKFREE GET BUFFER HRC104DK 00249240
  280. LR R10,R1 HRC104DK 00249250
  281. USING SYMMSG,R10 HRC104DK 00249260
  282. MVC SYMBOL,0(R3) MOVE SYMBOL NAME HRC104DK 00249270
  283. MVC SYMBOL+8,=C' = ' HRC104DK 00249280
  284. L R1,8(R3) GET ADDRESS OF DATA HRC104DK 00249290
  285. CALL DMKCVTBH HRC104DK 00249300
  286. STCM R0,B'0011',SYMADR HRC104DK 00249310
  287. STCM R1,B'1111',SYMADR+2 HRC104DK 00249320
  288. MVC SYMRES,=C' RESIDENT' HRC104DK 00249330
  289. LA R0,26 HRC104DK 00249340
  290. L R2,8(R3) GET ADDRESS OF DATA HRC104DK 00249350
  291. CL R2,=A(DMKCPEND) END OF NUCLEUS HRC104DK 00249360
  292. BNH SYMADDR HRC104DK 00249370
  293. MVC SYMRES,=C' PAGEABLE' HRC104DK 00249380
  294. L R15,ASYSVM SYSTEM VMBLOK HRC104DK 00249390
  295. LCTL C1,C1,VMSEG-VMBLOK(R15) SEGMENT TABLE HRC104DK 00249400
  296. LRA R1,0(0,R2) GET REAL ADDRESS HRC104DK 00249410
  297. BNZ SYMNREAL HRC104DK 00249420
  298. LCTL C1,C1,VMSEG RESTORE USERS SEGMENT TABLE HRC104DK 00249430
  299. MVC SYMREAL,=C', REAL = ' HRC104DK 00249440
  300. CALL DMKCVTBH HRC104DK 00249450
  301. STCM R0,B'0011',SYMRADR HRC104DK 00249460
  302. STCM R1,B'1111',SYMRADR+2 HRC104DK 00249470
  303. LA R0,41 HRC104DK 00249480
  304. B SYMADDR HRC104DK 00249490
  305. SPACE , HRC104DK 00249500
  306. SYMNREAL DS 0H HRC104DK 00249510
  307. LCTL C1,C1,VMSEG RESTORE USERS SEGMENT TABLE HRC104DK 00249520
  308. SPACE , HRC104DK 00249530
  309. SYMADDR DS 0H HRC104DK 00249540
  310. LR R1,R10 HRC104DK 00249550
  311. CALL DMKQCNWT,PARM=NORET SEND MESSAGE HRC104DK 00249560
  312. LA R0,SYMMSGSZ SIZE OF BUFFER HRC104DK 00249570
  313. B CFDFRET HRC104DK 00249580
  314. SPACE 00250000
  315. CFDWRIT CALL DMKQCNWT,PARM=NORET SEND MESSAGE 00251000
  316. TM SAVEWRK1,NOFREE MUST I FRET ??? 00252000
  317. BO CFDEXIT NO - GO EXIT 00253000
  318. LA R0,LOCMSGSZ SIZE OF BUFFER 00254000
  319. CFDFRET LR R1,R10 ADDRESS OF BUFFER HRC104DK 00255490
  320. CALL DMKFRET 00256000
  321. CFDEXIT EXIT RETURN 00257000
  322. EJECT 00258000
  323. VMHDR DC CL38'VMBLOK VCHBLOK VCUBLOK VDEVBLOK' 00259000
  324. RADRHDR DC CL28'RCHBLOK RCUBLOK RDEVBLOK' 00260000
  325. EJECT 00261000
  326. *********************************************************************** 00262000
  327. * * 00263000
  328. * 'ADSTOP' * 00264000
  329. * * 00265000
  330. *********************************************************************** 00266000
  331. *. 00267000
  332. * SUBROUTINE NAME - 00268000
  333. * DMKCFDAD 00269000
  334. * 00270000
  335. * FUNCTION - 00271000
  336. * TO STOP EXECUTION OF THE VIRTUAL MACHINE WHEN THE INSTRUCTION 00272000
  337. * AT THE LOCATION SPECIFIED IS HIT. 00273000
  338. * 00274000
  339. * COMMAND FORMAT - 00275000
  340. * +----------+------------+ 00276000
  341. * | ADSTOP | LOCATION | 00277000
  342. * | ADSTOP | OFF | 00278000
  343. * +----------+------------+ 00279000
  344. * 00280000
  345. * OPERATION - 00281000
  346. * 1. CALL DMKSCNFD TO LOCATE THE ARGUMENT. IF NONE FOUND, 00282000
  347. * CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFD026E AND EXIT. 00283000
  348. * 2. IF 'OFF' IS SPECIFIED, SEE IF USER WANTS SVCS HANDLED 00284000
  349. * BY VM ASSIST, AND IF SO, TURN ON VM ASSIST SVC HANDLING. 00285000
  350. * GET THE BUFFER ADDRESS FOUND 00286000
  351. * IN THE VMBLOK FROM THE PREVIOUS ADSTOP. THIS BUFFER 00287000
  352. * CONTAINS THE INSTRUCTION AND ITS LOCATION THAT IS TO BE 00288000
  353. * RESTORED. GO TO STEP 5. WHEN RETURN FROM STEP 5, CALL 00289000
  354. * DMKFRET TO FRET THE BUFFER AND THEN EXIT. 00290000
  355. * 3. IF NOT 'OFF', CALL DMKCVTHB TO CONVERT THE ADDRESS TO 00291000
  356. * BINARY. IF CONVERT FAILS, SEND ERROR MESSAGE DMKCFD004E AND 00292000
  357. * EXIT. IF GOOD, CHECK ADDRESS TO SEE IF WITHIN BOUNDS OF 00293000
  358. * VIRTUAL STORAGE. IF NOT, CALL DMKERMSG TO SEND ERROR 00294000
  359. * MESSAGE DMKCFD160E AND EXIT. IF GOOD, TURN OFF VM ASSIST 00295000
  360. * SVC HANDLING (BECAUSE CP MUST HANDLE SVCS IN ORDER TO 00296000
  361. * DO THE ADSTOP). THEN CHECK TO SEE IF ADDRESS IS 00297000
  362. * IN A SHARED PAGE. IF IT IS , CALL DMKERMSG TO SEND ERROR 00298000
  363. * MESSAGE DMKCFD161E AND EXIT. 00299000
  364. * 4. IF PREVIOUS ADSTOP IS ACTIVE, GO TO STEP 5 TO RESTORE 00300000
  365. * INSTRUCTION. WHEN RETURN FROM STEP 5, GO TO STEP 4A. IF 00301000
  366. * NO PREVIOUS ADSTOP, CALL DMKFREE TO GET A BUFFER. 00302000
  367. * 4A. SAVE THE INSTRUCTION AND INST. ADDRESS IN THE BUFFER. 00303000
  368. * OVERLAY THE INSTRUCTION WITH AN SVC B3 AND EXIT. 00304000
  369. * 5. TRANS IN THE ADSTOP LOCATION. RESTORE THE INTRUCTION 00305000
  370. * WITH THE INSTRUCTION FOUND IN THE BUFFER AND RETURN. 00306000
  371. * 00307000
  372. * RESPONSES - 00308000
  373. * 00309000
  374. * ADDRESS STOP AT XXXXXX 00310000
  375. * 00311000
  376. * ERROR MESSAGES - 00312000
  377. * DMKCFD004E INVALID HEXLOC - (HEXLOC) 00313000
  378. * DMKCFD026E OPERAND MISSING OR INVALID 00314000
  379. * DMKCFD160E HEXLOC (HEXLOC) EXCEEDS STORAGE 00315000
  380. * DMKCFD161E HEXLOC (HEXLOC) IN SHARED STORAGE 00316000
  381. *. 00317000
  382. EJECT 00318000
  383. USING ADSTBLOK,R10 00319000
  384. SPACE 00320000
  385. DMKCFDAD RELOC SIMULATE ADDRESS STOP 00321000
  386. CALL DMKSCNFD LOCATE ARGUMENT 00322000
  387. BNZ CFD026 NO ARGUMENT 00323000
  388. L R10,VMADSTOP LOAD ADDRESS OF ADSTOP BUFFER 00324000
  389. STM R0,R1,SAVEWRK2 SAVE ADDRESS AND LENGTH OF ARG. 00325000
  390. CL R0,F6 ARGUMENT OVER SIX CHARACTERS ??? 00326000
  391. BH CFD004 BRANCH TO ERROR IF IT IS 00327000
  392. LM R0,R1,SAVEWRK2 RESTORE REGISTERS 00328000
  393. LR R2,R0 LENGTH TO GPR2 00329000
  394. BCTR R2,0 MINUS ONE FOR 'EX' 00330000
  395. EX R2,COMPOFF IS THIS AN 'OFF' REQUEST ??? 00331000
  396. BE ADSTPOFF TAKE BRANCH IF IT IS 00332000
  397. CALL DMKCVTHB CONVERT ADDRESS TO BINARY 00333000
  398. BNZ CFD004 INVALID ADDRESS 00334000
  399. CL R1,VMSIZE LOCATION WITHIN USER STORAGE ? 00335000
  400. BNL CFD160 ADDRESS TOO HIGH 00336000
  401. LR R8,R1 SAVE ADDRESS 00337000
  402. OI VMMCR6,VMMSVC INDICATE MICROCDE NOT HANDLE SVCS@V201537 00338000
  403. LTR R10,R10 IS THERE AN ADSTOP IN PROGRESS ?? 00339000
  404. BZ CHEKSHR BRANCH IF NO 00340000
  405. BAL R4,RESTINST YES - GO RESTORE INSTRUCTION 00341000
  406. CHEKSHR LR R1,R8 LOAD VIRTUAL ADDRESS IN REG1 00342000
  407. TRANS 2,1,OPT=(BRING,DEFER),ADEX=CFD164 GET PAGE @V304635 00343000
  408. EX R1,TESTODD ADDRESS MUST BE EVEN @V304635 00344000
  409. BNZ CFD004 ERROR IF ODD ADDRESS SPECIFIED. @V304635 00345000
  410. LR R7,R2 SAVE REAL ADDRESS @V304635 00346000
  411. LH R6,VMSHRSYS RUNNING ANY SHARED SYSTEM'S @V304635 00347000
  412. LTR R6,R6 . . 00348000
  413. BZ GETBFR BRANCH IF NO 00349000
  414. SLR R0,R0 INDICATE ABLE TO STORE ANYWHERE @V304735 00350000
  415. CALL DMKPSASC STORING INTO A SHARED PAGE? @V304735 00351000
  416. BZ GETBFR NO - OK TO ALTER PAGE @V304735 00352000
  417. LR R2,R8 GET VITURAL ADDRESS @VA12533 00352500
  418. CALL DMKATSCF BUILD NON-SHARED PAGE TABLES @V60BC11 00353000
  419. B CHEKSHR RE-ISSUE TRANS FOR PAGE @VA07408 00354200
  420. GETBFR LTR R10,R10 DO WE ALREADY HAVE BUFFER ?? 00355000
  421. BNZ SETSTOP BRANCH IF YES 00356000
  422. LA R0,ADSTBFSZ SIZE OF BUFFER NEEDED 00357000
  423. CALL DMKFREE GET BUFFER 00358000
  424. LR R10,R1 ADDRESS OF ADSTOP BUFFER TO GPR10 00359000
  425. SETSTOP ST R8,ADSTINAD SAVE INSRUCTION ADDRESS 00360000
  426. MVC ADSTINST(2),0(R7) SAVE INSTRUCTION 00361000
  427. MVC 0(2,R7),=XL2'0AB3' MOVE SVC B3 IN PLACE OF INST 00362000
  428. MVC ADSTFLAG(2),ZEROES ZERO FLAG AREA 00363000
  429. ST R10,VMADSTOP SAVE BUFFER ADDRESS IN VMBLOK 00364000
  430. NORMEXIT EXIT RETURN 00365000
  431. SPACE 4 00366000
  432. ADSTPOFF LTR R10,R10 DO WE HAVE BUFFER 00367000
  433. BZ NORMEXIT NO - TAKE BRANCH 00368000
  434. TM VMESTAT,VMMICSVC USER RQST MICRO HANDLE SVCS?@V201537 00369000
  435. BZ NOMICRO NO, LEAVE SVC BIT SET TO 1 @V201537 00370000
  436. NI VMMCR6,X'FF'-VMMSVC YES, INDICATE MICRO DO SVCS @V201537 00371000
  437. NOMICRO DS 0H @V201537 00372000
  438. BAL R4,RESTINST RESTORE INSTRUCTION 00373000
  439. LA R0,ADSTBFSZ SIZE OF BUFFER 00374000
  440. LR R1,R10 ADDRESS OF BUFFER 00375000
  441. CALL DMKFRET RETURN BUFFER TO FREE STORAGE 00376000
  442. SR R10,R10 ZERO REG 00377000
  443. ST R10,VMADSTOP CLEAR BUFFER ADDRESS 00378000
  444. B NORMEXIT 00379000
  445. SPACE 3 00380000
  446. RESTINST L R1,ADSTINAD LOAD ADDRESS OF INSTRUCTION TO RESTORE 00381000
  447. TRANS 2,1,OPT=(BRING,DEFER) BRING INST. INTO CORE 00382000
  448. BNZR R4 RETURN IF PAGE NO-LONGER THERE @V304635 00383000
  449. LH R15,ADSTINST GET INSTRUCTION TO RESTORE 00384000
  450. CLC 0(2,R2),=XL2'0AB3' IS THE "SVC B3" STILL THERE ? 00385000
  451. BNE RESTINX1 IF NOT, WE NEED AN EXTRA CHECK 00386000
  452. STH R15,0(,R2) YES - RESTORE THE INSTRUCTION, AND 00387000
  453. BR R4 RETURN 00388000
  454. * 00389000
  455. RESTINX1 CLI 0(R2),X'0A' IS THE "SVC" STILL THERE ? 00390000
  456. BNE RESTINX2 NO - LEAVE WELL ENOUGH ALONE 00391000
  457. STCM R15,B'0010',0(R2) YES - PUT BACK THE 1ST BYTE 00392000
  458. RESTINX2 CLI 1(R2),X'B3' IS THE "B3" STILL THERE ? 00393000
  459. BCR 7,R4 <BNE> NO - RETURN TO CALLER. 00394000
  460. STC R15,1(,R2) YES - PUT BACK THE 2ND BYTE 00395000
  461. BR R4 AND RETURN TO CALLER. 00396000
  462. DROP R10 00397000
  463. SPACE 2 00398000
  464. TESTODD TM F1+3,0 EXECUTED TO CHECK FOR ODD ADDRESS 00399000
  465. COMPOFF CLC 0(0,R1),=C'OFF ' EXECUTED COMPARE 00400000
  466. EJECT 00401000
  467. CFD004 LM R0,R1,SAVEWRK2 LOAD ARGUMENT ADDRESS AND LENGTH 00402000
  468. LA R2,4 ERROR CODE 00403000
  469. B CALLERM . . . 00404000
  470. SPACE 00405000
  471. CFD021 LA R2,21 ERROR CODE 00406000
  472. B NOVAR . . . 00407000
  473. SPACE 00408000
  474. CFD022 LA R2,22 ERROR CODE 00409000
  475. B NOVAR . . . 00410000
  476. SPACE 00411000
  477. CFD1003 EQU * LATER HRC104DK 00411500
  478. CFD026 LA R2,26 ERROR CODE 00412000
  479. B NOVAR . . . 00413000
  480. CFD040 LM R0,R1,SAVEWRK2 LOAD ADDRESS AND LENGTH 00414000
  481. LA R2,40 ERROR CODE 00415000
  482. B CALLERM 00416000
  483. SPACE 00417000
  484. CFD160 LM R0,R1,SAVEWRK2 ADDRESS AND LENGTH OF BAD ARGUMENT 00418000
  485. LA R2,160 ERROR CODE 00419000
  486. B CALLERM . . . 00420000
  487. SPACE 1 00421000
  488. CFD164 LA R2,164 DMKCFD164E ERROR @V304635 00422000
  489. LM R0,R1,SAVEWRK2 ADDR. AND LENGTH OF MESSAGE @VM03009 00423000
  490. B CALLERM @V304635 00424000
  491. NOVAR SR R1,R1 ZERO PARM REG. 00425000
  492. CALLERM ICM R0,14,MODID+3 INSERT MODULE ID 00426000
  493. CALL DMKERMSG GO SEND ERROR MESSAGE 00427000
  494. * 00428000
  495. * CSM WILL RETURN DIRECTLY TO DMKCFM TO PROCESS NEXT COMMAND 00429000
  496. * 00430000
  497. EJECT 00431000
  498. LTORG 00432000
  499. EJECT 00433000
  500. LOCMSG DSECT 00434000
  501. VMBLKADR DS CL6 00435000
  502. DS CL4 00436000
  503. VMCHADR DS CL6 00437000
  504. DS CL4 00438000
  505. VMCUADR DS CL6 00439000
  506. DS CL4 00440000
  507. VMDEVADR DS CL6 00441000
  508. DS CL4 00442000
  509. LOCMSGSZ EQU (*-LOCMSG)/8 SIZE IN DOUBLE WORDS 00443000
  510. SPACE 3 , HRC104DK 00443100
  511. SYMMSG DSECT HRC104DK 00443200
  512. SYMBOL DS CL8 HRC104DK 00443300
  513. DS CL3 HRC104DK 00443400
  514. SYMADR DS CL6 HRC104DK 00443500
  515. SYMRES DS CL9 HRC104DK 00443600
  516. SYMREAL DS CL9 ', REAL = ' HRC104DK 00443700
  517. SYMRADR DS CL6 HRC104DK 00443800
  518. SYMMSGSZ EQU (*-SYMMSG+7)/8 SIZE IN DOUBLE WORDS HRC104DK 00443900
  519. EJECT 00444000
  520. ADSTBLOK DSECT 00445000
  521. ADSTINAD DS 1F ADDRESS OF INSTRUCTION 00446000
  522. ADSTINST DS 1F INSRUCTION 00447000
  523. ADSTFLAG DS 1H 00448000
  524. DS 0D 00449000
  525. ADSTBFSZ EQU (*-ADSTBLOK)/8 SIZE IN DOUBLE WORDS 00450000
  526. EJECT 00451000
  527. PSA , @V306638 00452000
  528. COPY EQU @V306638 00453000
  529. COPY RBLOKS @V306638 00454000
  530. COPY CORE @V304735 00455000
  531. COPY SAVE @V306638 00456000
  532. COPY VBLOKS @V306638 00457000
  533. COPY VMBLOK @V306638 00458000
  534. END 00459000