Table of Contents

DMKCSP Source

References

Source Listing

DMKCSP.ASSEMBLE.txt
  1. CSP TITLE 'DMKCSP (CP) VM/370 - RELEASE 6' 00001000
  2. ISEQ 73,80 VALIDATE SEQUENCING OF INPUT 00002000
  3. *. 00003000
  4. * MODULE NAME - 00004000
  5. * 00005000
  6. * DMKCSP 00006000
  7. * 00007000
  8. * FUNCTION - 00008000
  9. * 00009000
  10. * DMKCSP CONTAINS THE SPOOL COMMAND FOR 00010000
  11. * CLASS G USERS. 00011000
  12. * 00013000
  13. * ATTRIBUTES - 00014000
  14. * 00015000
  15. * REENTRANT, PAGEABLE, CALLED VIA SVC 00016000
  16. * 00017000
  17. * ENTRY POINTS - 00018000
  18. * 00019000
  19. * DMKCSPSP - SPOOL COMMAND 00023000
  20. * 00024000
  21. * ENTRY CONDITIONS - 00025000
  22. * 00026000
  23. * GPR9 = ADDRESS OF THE COMMAND LINE BUFFER; MUST BE PRESERVED 00027000
  24. * FOR CALLS TO DMKSCNFD 00028000
  25. * GPR12 = ADDRESS OF ENTRY POINT 00029000
  26. * GPR13 = ADDRESS OF SAVEAREA 00030000
  27. * 00031000
  28. * EXIT CONDITIONS - 00032000
  29. * 00033000
  30. * NORMAL - 00034000
  31. * GPR2 = 0 00035000
  32. * 00036000
  33. * ERROR - 00037000
  34. * 00038000
  35. * GPR2 = CONTAINS THE BINARY MESSAGE NUMBER 00039000
  36. * - EITHER AN OPTION IS ILLEGAL OR SOME CONDITION 00040000
  37. * EXISTS THAT MAKES IT IMPOSSIBLE TO EXECUTE THE COMMAND 00041000
  38. * A MESSAGE IS TYPED TO DESCRIBE THE ERROR; THE ERROR 00042000
  39. * MESSAGES THAT MAY OCCUR ARE LISTED WITH EACH COMMAND 00043000
  40. EJECT 00044000
  41. * 00045000
  42. * CALLS TO OTHER ROUTINES - 00046000
  43. * 00047000
  44. * DMKFREE - TO OBTAIN A BLOCK FROM FREE STORAGE 00048000
  45. * DMKFRET - TO RETURN STORAGE 00049000
  46. * DMKUDRFU - TO VERIFY A 'USERID' 00050000
  47. * DMKCSOSD - TO START RDR, PRINTER OR PUNCH 00051000
  48. * DMKSTKIO - TO STACK AN IOBLOK 00052000
  49. * DMKSCNVU - LOCATE A VDEVBLOK 00053000
  50. * DMKUDRRV - TO CLOSE THE DIRECTORY 00054000
  51. * DMKSCNFD - SCAN THE COMMAND LINE BUFFER FOR OPTIONS 00055000
  52. * DMKQCNWT - WRITE RESPONSE AND ERROR MESSAGES 00056000
  53. * DMKVSPCO - CLOSE (AND OPTIONALLY PURGE) OUTPUT SPOOL FILES 00057000
  54. * DMKVSPCR - CLOSE READER FILES 00058000
  55. * DMKSPLDL - DELETE PURGED FILES FROM THE SYSTEM 00059000
  56. * DMKCVTHB - CONVERT HEX ADDRESS OPTIONS TO BINARY 00060000
  57. * DMKCVTDB - CONVERT DECIMAL SPOOLID NUMBERS TO BINARY 00061000
  58. * DMKERMSG - WRITE ERROR MESSAGES 00062000
  59. * DMKCKSPL - CHECKPOINT THE BLOCKS 00063000
  60. * EXTERNAL REFERENCES - 00064000
  61. * 00065000
  62. * DMKRSPHQ - SPOOL HOLD QUEUE CHAIN ANCHOR 00066000
  63. * DMKRSPRD - (ARSPRD) READER FILE CHAIN ANCHOR 00067000
  64. * DMKRSPPR - (ARSPPR) PRINTER FILE CHAIN ANCHOR 00068000
  65. * DMKRSPPU - (ARSPPU) PUNCH FILE CHAIN ANCHOR 00069000
  66. * DMKRSPID - SYSTEM SPOOL ID COUNTER 00070000
  67. * DMKRSPDL - SPOOL DELETE CHAIN ANCHOR 00071000
  68. * DMKVIOIN - IOBIRA ADDRESS FOR IOBLOK 00072000
  69. * 00073000
  70. * TABLES / WORKAREAS - 00074000
  71. * 00075000
  72. * IOBLOK 00076000
  73. * 00077000
  74. * VDEVBLOK, VSPXBLOK, AND SFBLOKS ARE UPDATED OR DELETED 00078000
  75. * 00079000
  76. * THE SAVEWRK FIELDS IN THE STANDARD SAVEAREA ARE USED BY THE 00080000
  77. * OPTION PROCESSING SUBROUTINES FOR THE FOLLOWING VALUES - 00081000
  78. * 00082000
  79. * SAVEWRK1 - FILE OUTPUT CLASS (1 BYTE) 00083000
  80. * SAVEWRK1+1 - NUMBER OF COPIES (1 BYTE) 00084000
  81. * SAVEWRK1+2 - SPOOLID NUMBER (HALF-WORD) 00085000
  82. * SAVEWRK2,3 - USERID OF FILE'S OWNER 00086000
  83. * SAVEWRK4 - VALUE OF CHARS PARAMETER IF SPECIFIED 00087000
  84. * SAVEWRK5 - VALUE OF FLASH OVERLY IS SPECIFIED 00087500
  85. * SAVEWRK6,7 - SAVE AREA FOR R0,R1 SCAN OPTIONS (TYPE ERROR) 00088000
  86. * SAVEWRK6 - COPY MOD NAME IF SPECIFIED (WHEN NO TYPE ERROR) 00088500
  87. * SAVEWRK7 - FCB NAME (WHEN NO TYPE ERROR) 00089000
  88. * SAVEWRK8 - USED FOR FLAGS 00089500
  89. * SAVEWRK9 - FIRST BYTE USED FOR FLASH COUNT IF SPECIFIED 00090000
  90. * 00091000
  91. * REGISTER USAGE - 00092000
  92. * 00093000
  93. * ALL SUBROUTINES IN THE MODULE CONFORM GENERALLY TO THIS USAGE; 00094000
  94. * ANY INDIVIDUAL DEVIATIONS OR EXTENSIONS ARE LISTED WITH THE 00095000
  95. * COMMAND DESCRIPTION 00096000
  96. * 00097000
  97. * GPR0 = LENGTH OF OPTION - RETURNED FROM DMKSCNFD 00098000
  98. * GPR1 = ADDRESS OF OPTION - RETURNED FROM DMKSCNFD 00099000
  99. * GPR2 = SCRATCH 00100000
  100. * GPR3 = INTERNAL LINKAGE - 2ND LEVEL 00101000
  101. * GPR4 = INTERNAL LINKAGE - 1ST LEVEL 00102000
  102. * GPR5 = DEVICE TYPE FLAGS - LOGICAL SUM OF TYPES 00103000
  103. * GPR6 = POINTER TO PREVIOUS SFBLOK ON CHAIN 00104000
  104. * GPR7 = SFBLOK BASE 00105000
  105. * GPR8 = VDEVBLOK BASE 00106000
  106. * GPR9 = INPUT COMMAND LINE ADDRESS 00107000
  107. * GPR10 = REMAINING DEVICE COUNT AND IOBLOK ADDRESS 00108000
  108. * GPR11 = VMBLOK BASE 00109000
  109. * GPR12 = DMKCSP BASE 00110000
  110. * GPR13 = SAVEAREA BASE 00111000
  111. * GPR14 = EXTERNAL LINKAGE 00112000
  112. * GPR15 = EXTERNAL LINKAGE 00113000
  113. * 00114000
  114. * NOTES - 00115000
  115. * 00116000
  116. * NONE 00117000
  117. * 00118000
  118. * OPERATION - 00119000
  119. * 00120000
  120. * EACH COMMAND PROCESSOR IS ENTERED VIA A CALL FROM DMKCFM. THE 00121000
  121. * PROCESSING LOGIC IS EMBODIED IN A SERIES OF INTERNAL CALLS TO 00122000
  122. * A SET OF OPTION PROCESSORS AND LIST SCANNERS. IN GENERAL, 00123000
  123. * THE OPTION PROCESSORS ARE CALLED WHEN IT IS KNOWN, EITHER BY 00124000
  124. * POSITION OR KEYWORD, WHAT TYPE OF OPERAND MUST APPEAR NEXT ON 00125000
  125. * THE COMMAND LINE. THE OPTION PROCESSORS SCAN FOR THE NEXT 00126000
  126. * FIELD, VERIFY ITS VALIDITY, AND SET UP INFORMATION FOR USE BY 00127000
  127. * THE LIST SCANNERS. SINCE THE OPERATIONAL DESCRIPTION OF EACH 00128000
  128. * OF EACH COMMAND PROCESSOR REFERENCES THESE SUBROUTINES, A LIST 00129000
  129. * OF THEIR NAMES AND FUNCTIONS IS GIVEN HERE; A DESCRIPTION OF 00130000
  130. * THE OPERATIONAL LOGIC AND REGISTER SETS FOR EACH SUBROUTINE 00131000
  131. * APPEAR AT THE END OF THE MODULE 00132000
  132. * 00133000
  133. * OPTION PROCESSORS - 00134000
  134. * 1. GETUSER - SAVE THE USER ID OF THE FILE'S OWNER 00135000
  135. * 2. GETYPE - SAVE THE FILE TYPE (OR DEVICE TYPE) 00136000
  136. * 3. GETCOPY - LOCATE AND SAVE THE NUMBER OF COPIES REQUESTED 00137000
  137. * AND METHOD OF MULTIPLE COPY TRANSMISSION 00137500
  138. * 4. GETNAME - LOCATE AND SAVE THE FILE NAME (AND TYPE) 00138000
  139. * 5. GETCLASS - LOCATE AND VERIFY THE CLASS REQUESTED (2ND LEVEL 00139000
  140. * ROUTINE) 00140000
  141. * 6. GETCHARS - SAVE AND VERIFY CHARS VALUE SPECIFIED 00140200
  142. * 7. GETFLASH - SAVE AND VERIFY FLASH VALUES SPECIFIED 00140400
  143. * 8. GETCMOD - SAVE AND VERIFY COPY MOD NAME 00140600
  144. * 9. GETFCB - SAVE AND VERIFY FCB NAME SPECIFIED 00140800
  145. * 00141000
  146. * LIST SCANNING ROUTINES - 00142000
  147. * 1. GETDEVIC - LOCATE THE NEXT VDEVBLOK OF THE APPROPRIATE 00143000
  148. * ADDRESS, CLASS AND TYPE (2ND LEVEL ROUTINE) 00144000
  149. * 2. GETFILE - LOCATE THE NEXT FILE OF THE CORRECT CLASS, ID, 00145000
  150. * AND OWNER 00146000
  151. * 3. GETCHAIN - LOCATE THE NEXT FILE CHAIN TO SEARCH (2ND 00147000
  152. * LEVEL ROUTINE) 00148000
  153. * 00149000
  154. *. 00150000
  155. EJECT 00151000
  156. COPY OPTIONS 00152000
  157. SPACE 2 00153000
  158. COPY LOCAL OPTIONS 00154000
  159. DMKCSP CSECT 00155000
  160. SPACE 3 00156000
  161. EXTRN DMKSCNVU,DMKSCNFD 00157000
  162. EXTRN DMKVSPCO,DMKVSPCR,DMKCVTHB 00158000
  163. EXTRN DMKCVTDB,DMKRSPHQ 00159000
  164. EXTRN DMKVIOIN,DMKSTKIO @VM01016 00160000
  165. EXTRN DMKCSOSD,DMKUDRFU,DMKERMSG 00161000
  166. EXTRN DMKUDRRV @V200930 00162000
  167. EXTRN DMKCKSPL @V304298 00163000
  168. SPACE 3 00164000
  169. USING PSA,R0 00165000
  170. USING SFBLOK,R7 00166000
  171. USING VDEVBLOK,R8 00167000
  172. USING BUFFER,R9 00168000
  173. USING VMBLOK,R11 00169000
  174. USING SAVEAREA,R13 00170000
  175. SPACE 2 00171000
  176. ID DC CL8'DMKCSP' MODULE NAME 00172000
  177. EJECT 00173000
  178. *. 00660000
  179. * 00661000
  180. * SUBROUTINE NAME - 00662000
  181. * 00663000
  182. * DMKCSPSP 00664000
  183. * 00665000
  184. * FUNCTION - 00666000
  185. * 00667000
  186. * TO SPECIFY THE SPOOLING CHARACTERISTICS OF A DEVICE OR CLASS 00668000
  187. * OF DEVICES. THE DEVICE(S) MAY BE SPECIFIED BY ADDRESS OR GEN- 00669000
  188. * ERIC TYPE; THE OPTIONS FOLLOWING DEVICE TYPE MAY BE SPECIFIED 00670000
  189. * IN ANY ORDER. 00671000
  190. * 00672000
  191. * COMMAND LINE FORMAT - 00673000
  192. * 00674000
  193. * +-------+---------------------------------------+ 00675000
  194. * | SPOOL | READER CLASS A | 00676000
  195. * | SP | VADDR <CONT|NOCONT> | 00677000
  196. * | | <HOLD|NOHOLD> ....... | 00678000
  197. * | | <EOF|NOEOF> | 00679000
  198. * | | | 00680000
  199. * | | CONSOLE <START|STOP> <TERM|NOTERM> ---| 00681000
  200. * | | PRINTER <TO> <USERID|*> | 00682000
  201. * | | PUNCH <FOR><SYSTEM> | 00683000
  202. * | | VADDR OFF | 00684000
  203. * | | | 00685000
  204. * | | ----CONT HOLD CLASS A ------ | 00686000
  205. * | | NOCONT NOHOLD <CLOSE|PURGE> | 00687000
  206. * | | | 00688000
  207. * | | ----COPY <*>NN CHARS CCCC---------- | 00688100
  208. * | | | 00688200
  209. * | | ----FLASH NAME NN MODIFY CCCC---- | 00688300
  210. * | | | 00688400
  211. * | | ----FCB NAME | 00688500
  212. * | | | 00688600
  213. * +-------+---------------------------------------+ 00689000
  214. * 00690000
  215. * READER PRINTER PUNCH CONSOLE CLASS CONT NOCONT 00691000
  216. * R RDR P PRT PU PCH CON CL CON NOC 00692000
  217. * 00693000
  218. * HOLD NOHOLD EOF NOEOF TO OFF COPY START STOP TERM NOTERM 00694000
  219. * HO NOH EOF NOE T OFF CO STA STO TE NOTE 00695000
  220. * 00696000
  221. * CHARS FLASH MODIFY FCB 00697000
  222. * CH FL MO FCB 00697300
  223. * 00697600
  224. * OPERATION - 00698000
  225. * 00699000
  226. * 1. CALL GETYPE; IF TYPE = 'ALL', EXIT GIVING ERROR MSG006E. 00700000
  227. * IF MISSING OR INVALID, EXIT GIVING MSG022E. 00701000
  228. * 2. SP03- IF OUTPUT DEVICE GO TO STEP 3. 00702000
  229. * IF NONE, GO TO STEP 5. IF OPTION = 'EOF' OR 'NOEOF' 00703000
  230. * OR 'CONT' OR 'NOCONT' OR 'HOLD' OR 'NOHOLD', 00704000
  231. * SET FLAG IN SAVEWRK8 AND GO TO STEP 2. 00705000
  232. * IF OPTION = 'CLASS': CALL GETCLASS: GO TO STEP 2. 00706000
  233. * EXIT GIVING ERROR MSG003E. 00707000
  234. * 3. CALL DMKSCNFD: LOCATE NEXT OPTION: 00708000
  235. * IF NONE, GO TO STEP 5. 00709000
  236. * IF OPTION = 'TO', GO TO STEP 4 00710000
  237. * IF OPTION = 'OFF' OR 'HOLD' OR 'NOHOLD' OR 00711000
  238. * 'CONT' OR 'NOCONT', SET FLAG SAVEWRK8 AND GO TO STEP 3. 00712000
  239. * IF OPTION = 'CLASS', CALL GETCLASS AND GO TO STEP 3. 00713000
  240. * IF OPTION = 'COPY', CALL GETCOPY AND GO TO STEP 3. 00714000
  241. * IF CONSOLE AND OPTION = 'START' OR 'STOP' OR 'TERM' OR 00715000
  242. * 'NOTERM' SET OR RESET THE PROPER FLAGS AND GO TO STEP 3. 00716000
  243. * 4. CALL GETUSER 00717000
  244. * CALL DMKUDRFU TO VERIFY USERID. 00718000
  245. * IF NOT FOUND TEST FOR SYSTEM, PROCESS AS OFF 00719000
  246. * IF INVALID USERID, EXIT GIVING ERROR MSG020E. 00720000
  247. * OTHERWISE, GO TO STEP 3. 00721000
  248. * 5. RESET ANY NONZERO FIELDS IN VDEVBLOK AND 'NI' 00722000
  249. * SAVEWRK8+1 INTO VDEVSFLG, SET SAVEWRK8 INTO VDEVSFLG. 00723000
  250. * TEST FOR CALL TO CLOSE (DMKVSPCO) WITH OR WITHOUT PURGE FLAG. 00724000
  251. * CALL GETDEVIC: IF LAST DEVICE, EXIT; OTHERWISE GO TO 00725000
  252. * STEP 5. 00726000
  253. * 00727000
  254. * RESPONSE - 00728000
  255. * 00729000
  256. * NONE 00730000
  257. * 00731000
  258. * ERROR MESSAGES - 00732000
  259. * 00733000
  260. * DMKCSP003E INVALID OPTION - (OPTION) 00734000
  261. * DMKCSP006E INVALID DEVICE TYPE - (ADDR) 00735000
  262. * DMKCSP007E INVALID USERID - (USERID) 00736000
  263. * DMKCSP013E CONFLICTING OPTION - (OPTION) 00737000
  264. * DMKCSP020E USERID MISSING OR INVALID 00738000
  265. * DMKCSP022E VADDR MISSING OR INVALID 00739000
  266. * DMKCSP026E OPERAND MISSING OR INVALID 00740000
  267. * DMKCSP028E CLASS MISSING OR INVALID 00741000
  268. * DMKCSP030E COPIES MISSING OR INVALID 00742000
  269. * DMKCSP040E DEV (ADDR) DOES NOT EXIST 00743000
  270. * DMKCSP053E (USERID) NOT IN CP DIRECTORY 00744000
  271. *. 00745000
  272. SPACE 3 00746000
  273. DMKCSPSP RELOC 00747000
  274. SPACE 00748000
  275. * SAVEWRK8+3 X'80' OPTIONS PROCESSED 00749000
  276. * SAVEWRK8+3 X'40' CONSOLE START OPTION IN COMMAND 00750000
  277. * SAVEWRK8+3 X'20' CONSOLE STIOP OPTION IN COMMAND 00751000
  278. * SAVEWRK8+3 X'10' SPOOL CONSOLE ACTIVITY 00752000
  279. * SAVEWRK8+3 X'04' CLOSE DEVICE 00753000
  280. * SAVEWRK8+3 X'02' CLOSE AND PURGE FILE 00754000
  281. * SAVEWRK8+3 X'01' MULT COPY IN 1 XMISSION FLAG 00754500
  282. SPACE 00755000
  283. USING VSPLCTL,R9 ADDRESSIBILITY @V60B9BA 00755500
  284. SPACE 00756000
  285. BAL R4,CLEAR CLEAR SAVEWRK1,2-9 00757000
  286. SR R6,R6 INDICATE POSSIBLE VADDR 00758000
  287. BAL R4,GETYPE GET DEVICE TYPE @V200930 00759000
  288. MVC SAVEWRK8+2(1),VDEVTYPC SAVE DEVICE CLASS @VW01375 00760000
  289. SPACE 00761000
  290. SP02 EX R5,CLIALL TYPE = ALL ?? 00762000
  291. BE MSG006E YES - INVALID TYPE 00763000
  292. MVC SAVEWRK8(2),=AL2(255) SET TO X'00FF' 00764000
  293. SPACE 00765000
  294. SPACE 00766000
  295. SP04 BALR R4,R0 SET UP RETURN REG 00767000
  296. CALL DMKSCNFD LOCATE NEXT OPTION 00768000
  297. BNZ SP25 NONE- ALL OPTION READ NOW PROCESS 00769000
  298. OI SAVEWRK8+3,X'80' INDICATE AT LEAST ONE OPTION 00770000
  299. LR R14,R0 COUNT 00771000
  300. BCTR R14,0 -1 00772000
  301. C R0,F2 COUNT LESS THAN 2 00773000
  302. BL SP12 TEST FOR TO AND FOR @V200930 00774000
  303. BE SP10 GO DO COUNT 2 OPTIONS 00775000
  304. TM VDEVTYPC,CLASURO+CLASTERM IS IT OUTPUT TYPE ? @VM08757 00776000
  305. BNZ SP07 YES -- @VM08757 00777000
  306. SPACE 00778000
  307. SP05 EX R14,CLCEOF EOF ?? 00779000
  308. BNE SP06 NO 00780000
  309. TM SAVEWRK8,VDEVEOF EOF FLAG SET ?? 00781000
  310. BO MSG013E YES -- CONFLICTING OPTION 00782000
  311. TM SAVEWRK8+1,VDEVEOF NOEOF SET ?? 00783000
  312. BZ MSG013E YES -- CONFLICTING OPTION 00784000
  313. OI SAVEWRK8,VDEVEOF SET EOF 00785000
  314. BR R4 RETURN TO SCAN COMMAND LINE 00786000
  315. SPACE 00787000
  316. SP06 EX R14,CLCNOEOF NOEOF ?? 00788000
  317. BNE SP07 NO 00789000
  318. TM SAVEWRK8+1,VDEVEOF NOEOF FLAG SET ?? 00790000
  319. BZ MSG013E YES -- CONFLICTING OPTION 00791000
  320. TM SAVEWRK8,VDEVEOF EOF SET ?? 00792000
  321. BO MSG013E YES -- CONFLICTING OPTION 00793000
  322. NI SAVEWRK8+1,X'FF'-VDEVEOF SET UP RESET FLAG 00794000
  323. BR R4 RETURN TO SCAN COMMAND LINE @VM08757 00795000
  324. SPACE 00796000
  325. SP07 EX R14,CLCCON CONT CONTINUOUS INPUT READING ?? 00797000
  326. BNE SP08 NO 00798000
  327. TM SAVEWRK8,VDEVCONT CONT SET ?? 00799000
  328. BO MSG013E YES -- CONFLICTING OPTION 00800000
  329. TM SAVEWRK8+1,VDEVCONT NOCONT SET ?? 00801000
  330. BZ MSG013E YES -- CONFLICTING OPTION 00802000
  331. OI SAVEWRK8,VDEVCONT SET CONT 00803000
  332. BR R4 RETURN TO SCAN COMMAND LINE 00804000
  333. SPACE 00805000
  334. SP08 EX R14,CLCNOCON NO CONTINOUS INPUT READING ?? 00806000
  335. BNE SP09 NO 00807000
  336. TM SAVEWRK8,VDEVCONT CONT SET ?? 00808000
  337. BO MSG013E YES -- CONFLICTING OPTION 00809000
  338. TM SAVEWRK8+1,VDEVCONT NOCONT SET ?? 00810000
  339. BZ MSG013E YES -- CONFLICTING OPTION 00811000
  340. NI SAVEWRK8+1,X'FF'-VDEVCONT RESET 00812000
  341. BR R4 RETURN TO SCAN COMMAND LINE 00813000
  342. SPACE 00814000
  343. SP09 EX R14,CLCNOHLD NOHOLD ?? 00815000
  344. BNE SP09A NO @V60B9BA 00816000
  345. TM SAVEWRK8,VDEVHOLD HOLD SET ?? 00817000
  346. BO MSG013E YES -- CONFLICTING OPTION 00818000
  347. TM SAVEWRK8+1,VDEVHOLD NOHOLD SET ?? 00819000
  348. BZ MSG013E YES -- CONFLICTING OPTION 00820000
  349. NI SAVEWRK8+1,X'FF'-VDEVHOLD 00821000
  350. BR R4 00822000
  351. SPACE 1 00822100
  352. SP09A TM VDEVTYPC,CLASURI INPUT DEVICE ? @V60B9BA 00822200
  353. BO SP10 XFER IF SO @V60B9BA 00822300
  354. EX R14,CLCFCB IS IT FCB OPTION ? @V60B9BA 00822400
  355. BNE SP10 XFER IF NOT @V60B9BA 00822500
  356. CLI SAVEWRK7,X'00' FCB PRESENT ? @V60B9BA 00822600
  357. BNE MSG013E YES - CONFLICTING OPTION @V60B9BA 00822700
  358. BAL R4,GETFCB GET FCB SPECIFIED @V60B9BA 00822800
  359. B SP04 SCAN FOR NEXT FIELD @V60B9BA 00822900
  360. SPACE 00823000
  361. SP10 EX R14,CLCHOLD HOLD ?? 00824000
  362. BNE SP11 NO 00825000
  363. TM SAVEWRK8,VDEVHOLD HOLD SET ?? 00826000
  364. BO MSG013E YES -- CONFLICTING OPTION 00827000
  365. TM SAVEWRK8+1,VDEVHOLD NOHOLD SET ?? 00828000
  366. BZ MSG013E YES -- CONFLICTING OPTION 00829000
  367. OI SAVEWRK8,VDEVHOLD SET HOLD 00830000
  368. BR R4 RETURN TO SCAN COMMAND LINE 00831000
  369. SPACE 00832000
  370. SP11 EX R14,CLCCLASS CLASS ?? 00833000
  371. BNE SP12 NO, TEST FOR TO AND FOR @V200930 00834000
  372. CLI SAVEWRK1,X'00' CLASS PRESENT ?? 00835000
  373. BNE MSG013E YES -- CONFLICTING OPTION 00836000
  374. BAL R3,GETCLASS GET FILE CLASS @V200930 00837000
  375. BR R4 00838000
  376. SPACE 00839000
  377. SP12 TM VDEVTYPC,CLASURI IS THIS A READER ?? @V200930 00840000
  378. BO MSG003E YES, ANYTHING ELSE INVALID @V200930 00841000
  379. EX R14,CLCTO IS IT TO ?? @V200930 00842000
  380. BE SP14 YES, DO IT @V200930 00843000
  381. EX R14,CLCFOR IS IT FOR ?? @V200930 00844000
  382. BE SP30 YES, DO IT @V200930 00845000
  383. CL R0,F2 IS IT ONE BYTE OPTION ?? @V200930 00846000
  384. BL SP24A YES, TEST FOR USERID @V200930 00847000
  385. B SP17 TEST FOR OTHER OPTIONS @V200930 00848000
  386. SP30 TM SAVEWRK8+1,VDEVFOR+VDEVXFER OPTIONS BEFORE ?? @V200930 00849000
  387. BNO MSG013E YES, CONFLICT @V200930 00850000
  388. OI SAVEWRK8,VDEVFOR SET FOR USERID @V200930 00851000
  389. NI SAVEWRK8+1,X'FF'-VDEVXFER RESET TO USERID @V200930 00852000
  390. B SP14A CHECK OUT CONFLICTS @V200930 00853000
  391. SPACE 00854000
  392. SP14 TM SAVEWRK8+1,VDEVFOR+VDEVXFER OPTIONS BEFORE ?? @V200930 00855000
  393. BNO MSG013E YES, CONFLICT @V200930 00856000
  394. OI SAVEWRK8,VDEVXFER SET TO USERID @V200930 00857000
  395. NI SAVEWRK8+1,X'FF'-VDEVFOR RESET FOR USERID @V200930 00858000
  396. SP14A DS 0H @V200930 00859000
  397. CALL DMKSCNFD LOCATE USER ID 00860000
  398. BNZ MSG020E USERID MISSING 00861000
  399. SPACE 00862000
  400. SP15 LR R14,R0 LENGTH OF USER ID 00863000
  401. BCTR R14,0 LENGTH -1 00864000
  402. SP15A C R0,F8 VALID LENGTH ?? 00865000
  403. BH MSG007E INVALID USERID 00866000
  404. C R0,F1 LENGTH OF ONE 00867000
  405. BNE SP15B NO -NOT * 00868000
  406. MVC SAVEWRK2(8),VMUSER GET SELF USERID @V200930 00869000
  407. CLI 0(R1),C'*' IS IT SELF ?? @V200930 00870000
  408. BE SP15C YES, TEST FOR SELF FOR @V200930 00871000
  409. SP15B MVC SAVEWRK2(8),BLANKS BLANK AREA 00872000
  410. EX R14,MVCID MOVE USERID TO SAVEWRK2,3 00873000
  411. SP15C TM SAVEWRK8,VDEVFOR FOR OPTION ?? @V200930 00874000
  412. BZ SP16 NO, CONT @V200930 00875000
  413. CLC SAVEWRK2(8),VMUSER FOR SELF ?? SAME AS OFF @V200930 00876000
  414. BNE SP16 NO, CONT @V200930 00877000
  415. NI SAVEWRK8,X'FF'-VDEVFOR TURN FOR OFF @V200930 00878000
  416. B SP17A CONT @V200930 00879000
  417. SP16 LA R0,UDIRSIZE GET DIRECTORY BUFFER @V200930 00880000
  418. CALL DMKFREE FOR USER SEARCH @V200930 00881000
  419. LR R2,R1 BUFFER ADDRESS @V200930 00882000
  420. LA R1,SAVEWRK2 USERID TO SEARCH @V200930 00883000
  421. LA R0,8 USERID SIZE @V200930 00884000
  422. SL R8,VMDVSTRT SAVE VDEV DISPLACEMENT @VA05147 00884500
  423. CALL DMKUDRFU VERIFY USER ID 00885000
  424. BALR R0,0 SAVE CONDITION CODE @VA05147 00885250
  425. AL R8,VMDVSTRT RESTORE VDEVBLOK ADDRESS @VA05147 00885500
  426. SPM R0 RESTORE CONDITION CODE @VA05147 00885750
  427. BNZ UDRFRET NOT FOUND @V200930 00886000
  428. TM SAVEWRK8,VDEVXFER IS IT TO USERID OPTION ON ?? @V200930 00887000
  429. BZ OKFRET NO, FOR USERID IS OK @V200930 00888000
  430. USING UDIRBLOK,R2 @V200930 00889000
  431. CLC UDIRPASS,=CL8'NOLOG' CAN USER LOGON ?? @V200930 00890000
  432. BE UDRFRET NO, CONT @V200930 00891000
  433. OKFRET LA R0,UDIRSIZE GET SIZE @V200930 00892000
  434. LR R1,R2 BUFFER ADDRESS @V200930 00893000
  435. CALL DMKFRET RETURN @V200930 00894000
  436. B SP04 GET NEXT FIELD @V200930 00895000
  437. UDRFRET LA R0,UDIRSIZE GET SIZE @V200930 00896000
  438. LR R1,R2 BUFFER ADDRESS @V200930 00897000
  439. CALL DMKFRET RETURN @V200930 00898000
  440. LA R1,SAVEWRK2 USERID THAT IS INVALID @V200930 00899000
  441. LA R0,8 SET TO 8 CHARACTERS @V200930 00900000
  442. CLC SAVEWRK2(8),=CL8'SYSTEM' SPOOL TO SYSTEM ?? @V200930 00901000
  443. BNE MSG053E NO, INVALID USERID, NOT KNOWN @V200930 00902000
  444. NI SAVEWRK8,X'FF'-VDEVFOR-VDEVXFER RESET FOR OR TO @V200930 00903000
  445. B SP17A PROCESS AS OFF @V200930 00904000
  446. SPACE 00905000
  447. SP17 EX R14,CLCOFF IS IT OFF ?? @V200930 00906000
  448. BNE SP22 NO, TEST FOR COPY @V200930 00907000
  449. C R14,F2 DID HE SAY OTHER THAN 'OFF' @VM08758 00908000
  450. BNE SP22 YES, ITS NOT THE OFF OPTION THEN @VM08758 00909000
  451. SP17A TM SAVEWRK8,VDEVXFER+VDEVFOR TO OR FOR ALREADY ?? @V200930 00910000
  452. BNZ MSG013E YES, CONFLICT @V200930 00911000
  453. TM SAVEWRK8+1,VDEVXFER+VDEVFOR USERID OFF ALREADY @V200930 00912000
  454. BZ MSG013E YES -- CONFLICTING OPTION 00913000
  455. NI SAVEWRK8+1,X'FF'-VDEVXFER-VDEVFOR FLAG OFF DONE @V200930 00914000
  456. B SP04 GET NEXT @V200930 00915000
  457. SPACE 00916000
  458. SP22 C R0,F2 COUNT CORRECT 00917000
  459. BL SP24A TEST FOR USERID 00918000
  460. EX R14,CLCCOPY COPY ?? 00919000
  461. BNE SP22A NO, TEST FOR CLOSE @V200930 00920000
  462. CLI SAVEWRK1+1,X'00' COPIES PRESENT ?? 00921000
  463. BNE MSG013E YES -- CONFLICTING OPTION 00922000
  464. BAL R4,GETCOPY GET COPIES @V200930 00923000
  465. B SP04 GET NEXT @V200930 00924000
  466. SPACE 00925000
  467. SP22A EX R14,CLCCLOSE TEST FOR CLOSE @V200930 00926000
  468. BNE SP23 NO, TEST FOR PURGE @V200930 00927000
  469. TM SAVEWRK8+3,X'06' CLOSE OR PURGE BEFORE ?? @V200930 00928000
  470. BNZ MSG013E YES @V200930 00929000
  471. OI SAVEWRK8+3,X'04' CLOSE OPTION @V200930 00930000
  472. B SP04 GET NEXT @V200930 00931000
  473. SPACE 00932000
  474. SP23 EX R14,CLCPURG TEST FOR PURGE @V200930 00933000
  475. BNE SP23A NO, TEST FOR FLASH @V60B9BA 00934000
  476. C R0,F3 MIN IS PUR @V200930 00935000
  477. BL SP24AA NO GOOD @V200930 00936000
  478. TM SAVEWRK8+3,X'06' CLOSE OR PURGE BEFORE ?? @V200930 00937000
  479. BNZ MSG013E YES @V200930 00938000
  480. OI SAVEWRK8+3,X'02' PURGE OPTION @V200930 00939000
  481. B SP04 GET NEXT OPTION @V200930 00940000
  482. SPACE 00940100
  483. SP23A EX R14,CLCFLASH TEST FOR FLASH @V60B9BA 00940200
  484. BNE SP23B XFER IF NOT FLASH @V60B9BA 00940300
  485. CLI SAVEWRK5,X'00' FLASH PRESENT? @V60B9BA 00940400
  486. BNE MSG013E YES - CONFLICTING OPTION @V60B9BA 00940500
  487. BAL R4,GETFLASH GET FLASH PARAMETERS @V60B9BA 00940600
  488. B SP04 SCAN FOR NEXT PARAMETER @V60B9BA 00940700
  489. SPACE 00941000
  490. SP23B EX R14,CLCCHARS TEST FOR CHARS @V60B9BA 00941060
  491. BNE SP23C XFER IF NOT CHARS @V60B9BA 00941120
  492. CLI SAVEWRK4,X'00' CHARS PRESENT? @V60B9BA 00941180
  493. BNE MSG013E YES - CONFLICTING OPTION @V60B9BA 00941240
  494. BAL R4,GETCHARS GET CHARS PARAMETER @V60B9BA 00941300
  495. B SP04 SCAN FOR NEXT PARAMETER @V60B9BA 00941360
  496. SPACE 00941420
  497. SP23C EX R14,CLCCMOD TEST FOR MODIFY @V60B9BA 00941480
  498. BNE SP24AA XFER IF NOT FLASH @V60B9BA 00941540
  499. CLI SAVEWRK6,X'00' MODIFY PRESENT ? @V60B9BA 00941600
  500. BNE MSG013E YES - CONFLICTING OPTION @V60B9BA 00941660
  501. BAL R4,GETCMOD GET MODIFY PARAMETER @V60B9BA 00941720
  502. B SP04 SCAN FOR NEXT PARAMETER @V60B9BA 00941780
  503. SPACE 00941840
  504. SP24AA CLI VDEVTYPE,TYP3210 CONSOLE TYPE ?? 00942000
  505. BNE SP24A NO -- 00943000
  506. EX R14,CLCTERM TERM OPTION ? 00944000
  507. BNE SP24B NO -- 00945000
  508. TM SAVEWRK8,VDEVTERM TERM SET ? 00946000
  509. BO MSG013E YES -- CONFLICTING OPTION 00947000
  510. TM SAVEWRK8+1,VDEVTERM NOTERM SET ? 00948000
  511. BZ MSG013E YES -- CONFLICTIONG OPTION 00949000
  512. OI SAVEWRK8,VDEVTERM SET TERM FLAG 00950000
  513. B SP04 GET NEXT @V200930 00951000
  514. SP24B C R0,F3 COUNT OF 3 OR MORE 00952000
  515. BL SP24A NO -- CHECK FOR USERID 00953000
  516. EX R14,CLCSTART START OPTION ?? 00954000
  517. BNE SP24C NO -- CHECK FOR STOP 00955000
  518. TM SAVEWRK8+3,X'60' START OR STOP SET ? 00956000
  519. BNZ MSG013E YES -- CONFLICTING OPTION 00957000
  520. OI SAVEWRK8+3,X'40' INDICATE START OPTION 00958000
  521. B SP04 GET NEXT @V200930 00959000
  522. SP24C EX R14,CLCSTOP STOP OPTION ?? 00960000
  523. BNE SP24D CHECK NOTERM OR TERM 00961000
  524. TM SAVEWRK8+3,X'60' START OR STOP SET ?? 00962000
  525. BNZ MSG013E YES -- CONFLICTING OPTION 00963000
  526. OI SAVEWRK8+3,X'20' SET STOP FLAG 00964000
  527. B SP04 GET NEXT @V200930 00965000
  528. SP24D C R0,F4 VALID COUNT FOR NOTERM 00966000
  529. BL SP24A NO -- CHECK USERID 00967000
  530. EX R14,CLCNOTE NOTERM OPTION ?? 00968000
  531. BNE SP24A NO -- 00969000
  532. TM SAVEWRK8,VDEVTERM TERM OPTION SET ?? 00970000
  533. BO MSG013E YES - CONFLICTING OPTION 00971000
  534. TM SAVEWRK8+1,VDEVTERM NOTERM OPTION SET ?? 00972000
  535. BZ MSG013E YES -- CONFLICTING OPTION 00973000
  536. NI SAVEWRK8+1,X'FF'-VDEVTERM SET NOTERM FLAG 00974000
  537. B SP04 GET NEXT @V200930 00975000
  538. SPACE 00976000
  539. SP24A TM SAVEWRK8+1,VDEVXFER+VDEVFOR USERID OFF ?? @V200930 00977000
  540. BNO MSG003E INVALID OPTION @V200930 00978000
  541. OI SAVEWRK8,VDEVXFER ASSUME SPOOL TO USERID @V200930 00979000
  542. NI SAVEWRK8+1,X'FF'-VDEVFOR RESET FOR USERID @V200930 00980000
  543. B SP15A CHECK FOR USERID 00981000
  544. SPACE 00982000
  545. SP25 EQU * ALL OPTIONS HAVE READ AND NOW TO PROCESS THEM 00983000
  546. SPACE 00984000
  547. TM SAVEWRK8+3,X'80' ANY OPTIONS ?? 00985000
  548. BZ MSG026E NO - MSG026E MISSING OPTION 00986000
  549. SPACE 00987000
  550. L R1,VDEVEXTN XBLOK ADDRESS @V60B9BA 00987250
  551. USING VSPXBLOK,R1 ADDRESSIBILITY @V60B9BA 00987500
  552. SPACE 00987750
  553. CLI SAVEWRK1,X'00' DID CLASS CHANGE ?? 00988000
  554. BE CKCOPY NO 00989000
  555. MVC VDEVCLAS(1),SAVEWRK1 MOVE NEW CLASS 00990000
  556. CKCOPY CLI SAVEWRK1+1,X'00' DID COPY CHANGE ?? 00991000
  557. BE CKXFER NO 00992000
  558. MVC VDEVCOPY+1(1),SAVEWRK1+1 MOVE NEW COPY 00993000
  559. MVI VDEVCOPY,X'00' 00994000
  560. NI VSPXFLG1,X'FF'-VSPXCPYF RESET FLAG @V60B9BA 00995000
  561. TM SAVEWRK8+3,X'01' SHOULD WE SET FLAG ? @V60B9BA 00995500
  562. BZ CKXFER XFER IF NOT @V60B9BA 00996000
  563. OI VSPXFLG1,VSPXCPYF SET THE FLAG @V60B9BA 00996500
  564. CKXFER TM SAVEWRK8+1,VDEVXFER+VDEVFOR SET XFER OFF ?? @V60B9BA 00997000
  565. BZ SP26 JUST GO ONWARD IF SO @V60B9BA 00997500
  566. TM SAVEWRK8,VDEVXFER+VDEVFOR SET XFER ON ?? @V293598 00998000
  567. BZ SP26 XFER TO BE LEFT ALONE @V60B9BA 00999000
  568. CKXUPDAT MVC VSPXXUSR(8),SAVEWRK2 SET NEW XFER VM ID @V293598 01012000
  569. SPACE 01013000
  570. SP26 CLI SAVEWRK7,X'00' FCB CHANGED ? @V60B9BA 01013030
  571. BE SP26A XFER IF NOT @V60B9BA 01013060
  572. MVC VSPXFCB,SAVEWRK7 MOVE IN NEW FCB @V60B9BA 01013090
  573. CLC VSPXFCB,=C'NULL' NULL FCB SPECIFIED ? @V60B9BA 01013120
  574. BNE SP26A XFER IF NOT @V60B9BA 01013150
  575. MVC VSPXFCB,ZEROES MAKE IT INITIALIZED @V60B9BA 01013180
  576. SP26A CLI SAVEWRK5,X'00' FLASH CHANGE ? @V60B9BA 01013210
  577. BE SP26B XFER IF NOT @V60B9BA 01013240
  578. MVC VSPXOVLY,SAVEWRK5 MOVE IN NEW FLASH NAME @V60B9BA 01013270
  579. MVC VSPXFLSH,SAVEWRK9 MOVE IN NEW FLASH COUNT @V60B9BA 01013300
  580. CLI VSPXFLSH,X'00' FLASH COUNT OF ZERO ? @V60B9BA 01013330
  581. BNE SP26B XFER IF NOT @V60B9BA 01013360
  582. XC VSPXOVLY,VSPXOVLY NULLIFY THE FLASH NAME @V60B9BA 01013390
  583. SP26B CLI SAVEWRK4,X'00' CHARS CHANGED ? @V60B9BA 01013420
  584. BE SP26C XFER IF NOT @V60B9BA 01013450
  585. MVC VSPXCHAR,SAVEWRK4 MOVE IN NEW CHARS @V60B9BA 01013480
  586. CLC VSPXCHAR,=C'NULL' NULL CHARS SPECIFIED ? @V60B9BA 01013510
  587. BNE SP26C XFER IF NOT @V60B9BA 01013540
  588. MVC VSPXCHAR,ZEROES MAKE IT INITIALIZED @V60B9BA 01013570
  589. SP26C CLI SAVEWRK6,X'00' MODIFY CHANGED ? @V60B9BA 01013600
  590. BE DOFLAG XFER IF NOT @V60B9BA 01013630
  591. MVC VSPXCMOD,SAVEWRK6 MOVE IN NEW MODIFY @V60B9BA 01013660
  592. CLC VSPXCMOD,=C'NULL' NULL COPY MOD SPECIFIED? @V60B9BA 01013690
  593. BNE DOFLAG XFER IF NOT @V60B9BA 01013720
  594. MVC VSPXCMOD,ZEROES MAKE IT INITIALIZED @V60B9BA 01013750
  595. DROP R1 NO LONGER NEEDED @V60B9BA 01013780
  596. SPACE 01014000
  597. DOFLAG IC R1,SAVEWRK8+1 GET RESET FLAG MASK 01028000
  598. EX R1,NIVDEVFG RESET VEDV FLAG 01029000
  599. IC R1,SAVEWRK8 GET SET FLAG MASK 01030000
  600. EX R1,OIVDEVFG SET NEW FLAGS 01031000
  601. TM SAVEWRK8+3,X'60' START OR STOP OPTION ?? 01032000
  602. BZ SP27 NO -- 01033000
  603. OI VDEVFLAG,VDEVCSPL INDICATE START FLAG 01034000
  604. TM SAVEWRK8+3,X'40' START OPTION IN COMMAND ? 01035000
  605. BO SP27 YES -- LEAVE FLAG SET 01036000
  606. NI VDEVFLAG,X'FF'-VDEVCSPL INDICATE STOP OPTION 01037000
  607. SPACE 01038000
  608. SP27 TM SAVEWRK8+3,X'06' CLOSE OR PURGE ?? @V200930 01039000
  609. BZ SP27A NO, CONT @V200930 01040000
  610. L R9,VDEVSPL GET VDEVSPL BLOK @V200930 01041000
  611. LTR R9,R9 ANY THERE ?? @V200930 01042000
  612. BZ SP27A NO, CONT @V200930 01043000
  613. L R7,VSPSFBLK ANY FILE OPEN ?? @V200930 01044000
  614. LTR R7,R7 .. @V200930 01045000
  615. BZ SP27A NO, CONT @V200930 01046000
  616. SR R2,R2 CLEAR PARM REG @VA01460 01047000
  617. TM SAVEWRK8+3,X'04' CLOSE OPTION ?? @V200930 01048000
  618. BO SP27B YES, CLOSE @V200930 01049000
  619. LA R2,VDEVPURG PURGE ACTIVE FILE @VA01460 01050000
  620. SP27B SL R8,VMDVSTRT VDEVBLOK DISPLACEMENT @VA01460 01051000
  621. CALL DMKVSPCO CLOSE DEVICE @V200930 01052000
  622. AL R8,VMDVSTRT VDEVBLOK ADDRESS @VA01460 01053000
  623. SP27A LTR R5,R5 MORE DEVICES ?? @V200930 01054000
  624. BZ SP28 NO - 01055000
  625. BAL R3,GETDEVIC GET NEXT DEVICE @V200930 01056000
  626. LTR R10,R10 ALL DONE ?? 01057000
  627. BNZ SP25 NO - PROCESS THIS DEVICE 01058000
  628. SP28 CLI SAVEWRK1,X'00' CHANGING CLASS ? @VW01375 01059000
  629. BE CSPEXIT NO - EXIT @V60B9BA 01060000
  630. CLI SAVEWRK8+2,CLASURI READER DEVICE CLASS ? @VW01375 01061000
  631. BNE CSPEXIT NO - EXIT @V60B9BA 01062000
  632. MVC SAVEWRK2(8),VMUSER GET SEARCH USERID @VW01375 01063000
  633. L R7,ARSPRD ADDRESS OF READER CHAIN @VW01375 01064000
  634. PENDLP BAL R4,GETFILE LOCATE RDR SPOOL FILE FOR @VW01375 01065000
  635. * THIS CLASS CHANGE 01066000
  636. LTR R7,R7 SPOOL FILE LOCATED ? @VW01375 01067000
  637. BZ CSPEXIT NO - EXIT @V60B9BA 01068000
  638. TM SFBFLAG,SFBUHOLD FILE IN USER HOLD STATUS ? @VW01375 01069000
  639. BO PENDLP YES - GET NEXT FILE @VW01375 01070000
  640. SPACE 3 01071000
  641. SETPEND EQU * HERE TO POST PENDIN INTERRUPT @VM01016 01072000
  642. SPACE 01073000
  643. USING VCHBLOK,R6 @VM01016 01074000
  644. USING VCUBLOK,R9 @VM01016 01075000
  645. USING IOBLOK,R10 @VM01016 01076000
  646. SPACE 01077000
  647. SR R1,R1 CLEAR CHANNEL TABLE INDEX @VM01016 01078000
  648. LA R4,2 GET GENERAL INDEX INCREMENT @VM01016 01079000
  649. LA R5,30 GET GENERAL COMPARAND FOR BXLE @VM01016 01080000
  650. SPACE 01081000
  651. NEXTCH LH R6,VMCHTBL(R1) GET INDEX TO NEXT VIRTUAL CHANNEL@VM01016 01082000
  652. LTR R6,R6 IS THERE ONE AT THIS ADDRESS @VM01016 01083000
  653. BM CHINDEX NO -- @VM01016 01084000
  654. A R6,VMCHSTRT POINT TO VCHBLOK @VM01016 01085000
  655. SR R2,R2 CLEAR CU TABLE INDEX @VM01016 01086000
  656. NEXTCU LH R9,VCHCUTBL(R2) GET INDEX TO VIRTUAL CU BLOK @VM01016 01087000
  657. LTR R9,R9 IS THERE ONE AT THIS ADDRESS ? @VM01016 01088000
  658. BM CUINDEX NO -- @VM01016 01089000
  659. A R9,VMCUSTRT POINT TO VCUBLOK @VM01016 01090000
  660. SR R3,R3 CLEAR DEVICE BLOK TABLE INDEX @VM01016 01091000
  661. NEXTDEV LH R8,VCUDVTBL(R3) GET INDEX TO DEVICE BLOK @VM01016 01092000
  662. LTR R8,R8 IS THERE ONE AT THIS ADDRESS @VM01016 01093000
  663. BM DEVINDEX NO -- @VM01016 01094000
  664. A R8,VMDVSTRT POINT TO DEVICE BLOK @VM01016 01095000
  665. SPACE 01096000
  666. CLI VDEVTYPC,CLASURI INPUT DEVICE @VM01016 01097000
  667. BNE DEVINDEX NO - @VM01016 01098000
  668. TM VDEVTYPE,TYPRDR IS IT THE RIGHT TYPE ?? @VM01016 01099000
  669. BZ DEVINDEX NO -- @VM01016 01100000
  670. TM VDEVSTAT,X'FF' ANY STATUS PENDING ?? @VM01016 01101000
  671. BNZ DEVINDEX YES, CHECK NEXT DEVICE @VM01016 01102000
  672. CLI VDEVCLAS,C'*' ALL CLASS READER ? @VM01016 01103000
  673. BE TSTBUSY YES, TEST FOR ACTIVE DEVICE @VM01016 01104000
  674. CLC VDEVCLAS(1),SFBCLAS FILE CLASS SAME AS DEVICE ? @VM01016 01105000
  675. BNE DEVINDEX NO - @VM01016 01106000
  676. TSTBUSY ICM R14,B'1111',VDEVSPL IS THE DEVICE BUSY ?? @VM01016 01107000
  677. BZ RDRPEND NO -- FINALLY FOUND A DEVICE @VM01016 01108000
  678. SPACE 01109000
  679. DEVINDEX BXLE R3,R4,NEXTDEV INDEX TO NEXT DEVICE ON CONTROL @VM01016 01110000
  680. * UNIT 01111000
  681. CUINDEX BXLE R2,R4,NEXTCU INDEX TO NEXT CONTROL UNIT ON @VM01016 01112000
  682. * CHANNEL 01113000
  683. CHINDEX BXLE R1,R4,NEXTCH INDEX TO NEXT CHANNEL ON MACHINE @VM01016 01114000
  684. SP31 B CSPEXIT EXIT TO CALLER @VM01016 01115000
  685. SPACE 01116000
  686. RDRPEND EQU * HERE TO QUEUE DEVICE END @VM01016 01117000
  687. LH R2,VDEVADD GET FULL ADDRESS OF DEVICE @VM01016 01118000
  688. LH R5,VCUADD .. @VM01016 01119000
  689. OR R2,R5 .. @VM01016 01120000
  690. AH R2,VCHADD .. @VM01016 01121000
  691. LA R0,IOBSIZE BUILD IOBLOK @VM01016 01122000
  692. CALL DMKFREE .. @VM01016 01123000
  693. LR R10,R1 ADDRESS OF IOBLOK @VM01016 01124000
  694. XC IOBLOK(IOBSIZE*8),IOBLOK CLEAR BLOK @VM01016 01125000
  695. ST R10,IOBLINK INDICATE ORIGINAL COPY @VM01016 01126000
  696. MVI IOBCSW+4,DE FAKE DEVICE END CSW @VM01016 01127000
  697. ST R11,IOBUSER MOVE USER ADDRESS OF VMBLOK @VM01016 01128000
  698. MVC IOBIRA,=A(DMKVIOIN) RETURN ADDRESS @VM01016 01129000
  699. STH R2,IOBVADD PUT ADDRESS IN IOBLOK @VM01016 01130000
  700. OI VDEVSTAT,VDEVPEND SET PENDING FLAG @VM01016 01131000
  701. MVC VDEVCSW(8),IOBCSW MOVE IN DEVICE END CSW @VM01016 01132000
  702. CALL DMKSTKIO GO STACK IO @VM01016 01133000
  703. B PENDLP GET NEXT FILE @VM01016 01134000
  704. DROP R6 @VM01016 01135000
  705. DROP R9 @VM01016 01136000
  706. DROP R10 @VM01016 01137000
  707. SPACE 3 01138000
  708. * ***EXECUTED INSTRUCTIONS*** 01139000
  709. NIVDEVFG NI VDEVSFLG,X'00' 01140000
  710. OIVDEVFG OI VDEVSFLG,X'00' 01141000
  711. MVCID MVC SAVEWRK2(0),0(R1) @V60B9BA 01142000
  712. MVCCHARS MVC SAVEWRK4(0),0(R1) @V60B9BA 01143000
  713. MVCFLASH MVC SAVEWRK5(0),0(R1) @V60B9BA 01144000
  714. MVCCMOD MVC SAVEWRK6(0),0(R1) @V60B9BA 01145000
  715. MVCFCB MVC SAVEWRK7(0),0(R1) @V60B9BA 01146000
  716. CLIALL CLI =AL1(CSPRDR+TYPPRT+TYPPUN),X'00' MASK = READER PRINTER 01147000
  717. * PUNCH 01148000
  718. TMRDR TM =AL1(CSPRDR),X'00' MASK = READER 01149000
  719. TMPRT TM =AL1(TYPPRT),X'00' MASK = PRINTER 01150000
  720. TMPUN TM =AL1(TYPPUN),X'00' MASK = PUNCH 01151000
  721. TMTYPE TM VDEVTYPE,X'00' TEST VDEV TYPE 01152000
  722. TMCON TM =AL1(CSPCON),X'00' MASK = CONSOLE 01153000
  723. SPACE 3 01183000
  724. CLEAR XC SAVEWRK2(32),SAVEWRK2 CLEAR SAVEWRK AREA 01184000
  725. XC SAVEWRK1(4),SAVEWRK1 01185000
  726. BR R4 RETURN TO CALLER 01186000
  727. EJECT 01187000
  728. *. 01188000
  729. * 01189000
  730. * OPERATION OF GETYPE - 01190000
  731. * 01191000
  732. * 1. CALL DMKSCNFD TO LOCATE DEVICE TYPE FIELD 01192000
  733. * 2. IF OPTION='READER','PRINTER','PUNCH','CONSOLE','ALL' ; SET 01193000
  734. * GPR5 = APPROPRIATE DEVICE TYPE. IF OPTION = 'ALL', SET 01194000
  735. * GPR5 EQUAL TO CSPRDR+TYPPRT+TYPPUN; THEN, GO TO STEP 4 01195000
  736. * IF MISSING OR INVALID AND COMMAND IS SPOOL OR CLOSE, 01196000
  737. * EXIT GIVING MSG022E. 01197000
  738. * 3. IF OPTION = VADDR, CALL DMKSCNVU TO LOCATE THE VDEVBLOK, 01198000
  739. * SET GPR5 AND GPR10 = 0, AND EXIT 01199000
  740. * 4. IF TYPE WAS NOT VADDR, LOAD GPR8 WITH VMDVSTRT-VDEVSIZE, 01200000
  741. * AND GPR10 WITH VMDVCNT, AND CALL GETDEVIC TO LOCATE THE 01201000
  742. * FIRST DEVICE OF THE CORRECT TYPE 01202000
  743. * 5. SET GPR6 TO FFS, CALL GETCHAIN (GPR6 WILL BE FILLED BY 01203000
  744. * GETCHAIN WITH THE APPROPRIATE FILE CHAIN ANCHOR) 01204000
  745. * 6. EXIT 01205000
  746. *. 01206000
  747. SPACE 3 01207000
  748. GETYPE EQU * 01208000
  749. SPACE 01209000
  750. GT01 LA R5,CSPRDR+TYPPRT+TYPPUN SET FOR ALL TYPE 01210000
  751. CALL DMKSCNFD LOCATE DEVICE TYPE FIELD 01211000
  752. STM R0,R1,SAVEWRK6 SAVE COUNT AND ADDRESS OF TYPE 01212000
  753. BZ GT02 -- 01213000
  754. LTR R6,R6 VIRTUAL ADDRESS POSSIBLE ?? 01214000
  755. BZ MSG022E YES -- VADDR MISSING 01215000
  756. B DEVIC NO OPTION DEFAULT TO ALL 01216000
  757. SPACE 01217000
  758. GT02 EQU * 01218000
  759. * GPR1 ADDRESS OF TYPE 01219000
  760. LR R14,R0 GET OPTION COUNT 01220000
  761. BCTR R14,0 -1 01221000
  762. C R0,F2 COUNT LENGTH OF 2 01222000
  763. BE GT02A VALID FOR PUNCH 01223000
  764. BL GT02B VALID FOR READER PRINTER 01224000
  765. EX R14,CLCALL ALL ?? 01225000
  766. BE DEVIC YES 01226000
  767. LA R5,CSPCON SET R5 TO CONSOLE TYPE 01227000
  768. EX R14,CLCCONS CONSOLE ?? 01228000
  769. BE DEVIC YES -- 01229000
  770. LA R5,CSPRDR SET R5 TO READER TYPE 01230000
  771. EX R14,CLCRDR RDR ?? 01231000
  772. BE DEVIC YES 01232000
  773. LA R5,TYPPRT PRINTER MASK 01233000
  774. EX R14,CLCPRT PRT ?? 01234000
  775. BE DEVIC YES - 01235000
  776. SPACE 01236000
  777. LA R5,TYPPUN SET GPR5 TO PUNCH TYPE 01237000
  778. EX R14,CLCPCH PCH ?? 01238000
  779. BE DEVIC YES 01239000
  780. GT02A LA R5,TYPPUN PUNCH MASK 01240000
  781. EX R14,CLCPUN PUNCH ?? 01241000
  782. BE DEVIC YES - 01242000
  783. SPACE 01243000
  784. GT02B LA R5,TYPPRT SET GPR5 TO PRINTER TYPE 01244000
  785. EX R14,CLCPRINT PRINTER ?? 01245000
  786. BE DEVIC YES - 01246000
  787. SPACE 01247000
  788. LA R5,CSPRDR TYPE MASK FOR READER 01248000
  789. EX R14,CLCREAD READER ?? 01249000
  790. BE DEVIC 01250000
  791. LTR R6,R6 POSSIBLE VADDR ?? 01251000
  792. BZ GT03 YES -- 01252000
  793. B MSG006E NO -- ERROR DMKCSP006E 01253000
  794. SPACE 01254000
  795. GT03 EQU * MUST BE VADDR 01255000
  796. SPACE 01256000
  797. STM R0,R1,SAVEWRK6 SAVE COUNT AND DEVICE ADDRESS 01257000
  798. C R0,F3 COUNT OF 3 OR LESS ?? 01258000
  799. BH MSG022E VADDR INVALID 01259000
  800. CALL DMKCVTHB CONVERT TO BINARY 01260000
  801. BNZ MSG022E INVALID VADDRESS 01261000
  802. CALL DMKSCNVU LOCATE VDEVBLOK 01262000
  803. BNZ MSG040E NONEXISTENT UNIT 01263000
  804. TM VDEVTYPC,CLASURO+CLASTERM OUTPUT OR CONSOLE CLASS ? 01264000
  805. BZ GT03A NO - CHECK INPUT TYPE 01265000
  806. TM VDEVTYPE,TYPPRT+TYPPUN PRINTER OR PUNCH ?? 01266000
  807. BNZ GT03B YES -- 01267000
  808. CLI VDEVTYPE,TYP3210 CONSOLE TYPE ? 01268000
  809. BE GT03B YES -- 01269000
  810. B MSG006E INVALID DEVICE TYPE 01270000
  811. GT03A TM VDEVTYPC,CLASURI INPUT DEVICE TYPE ?? 01271000
  812. BZ MSG006E NO -- 01272000
  813. TM VDEVTYPE,TYPRDR READER ?? 01273000
  814. BZ MSG006E NO -- INVALID DEVICE TYPE 01274000
  815. GT03B EQU * 01275000
  816. TM VDEVSTAT,VDEVDED DEDICATED TO REAL DEVICE ?? 01276000
  817. BO MSG006E YES -- INVALID DEVICE TYPE 01277000
  818. SR R5,R5 SET GPR5 TO ZERO 01278000
  819. SR R10,10 SET GPR10 TO ZERO 01279000
  820. B GT06 RETURN TO CALLER 01280000
  821. SPACE 2 01281000
  822. DEVIC EQU * HERE TO SET UP FOR GETDEVIC 01282000
  823. C R6,FFS DO WE NEED VDEVBLOK ADDRESS ?? 01283000
  824. BE GT05 NO -- MUST BE HOLD OR FREE CMD 01284000
  825. GT04 L R8,VMDVSTRT POINTER TO VDEVBLOK TABLE 01285000
  826. S R8,=A(VDEVSIZE*8) SUBSTRACT BLOK SIZE 01286000
  827. LH R10,VMDVCNT VDEVICE COUNT 01287000
  828. LTR R10,R10 ANY DEVICES FOR THIS USER ?? 01288000
  829. BP GT04A YES -- 01289000
  830. MSG040 LA R2,40 NO -- DOES NOT EXIST 01290000
  831. B EXIT8 ERROR MSG DMKCSP040E 01291000
  832. GT04A EQU * 01292000
  833. A R10,F1 INCREASE DEVICE COUNT BY ONE 01293000
  834. BAL R3,GETDEVIC GET NEXT DEVICE @V200930 01294000
  835. LTR R10,R10 ANY MORE VDEVBLOKS ?? 01295000
  836. BZ MSG040 NO -- ERROR DMKCSP040E 01296000
  837. B GT06 SET ZERO COND @V200930 01297000
  838. SPACE 01298000
  839. GT05 L R6,FFS SET 1ST TIME SWITCH FOR GETCHAIN 01299000
  840. BAL R3,GETCHAIN GET NEXT FILE CHAIN @V200930 01300000
  841. SPACE 01301000
  842. GT06 CR R2,R2 SET CC = ZERO 01302000
  843. BR R4 RETURN TO CALLER 01303000
  844. SPACE 3 01304000
  845. SPACE 3 01305000
  846. CLCALL CLC 0(0,R1),=C'ALL ' COMPARE FOR ALL 01306000
  847. CLCRDR CLC 0(0,R1),=C'RDR ' COMPARE FOR RDR 01307000
  848. CLCPCH CLC 0(0,R1),=C'PCH ' COMPARE FOR PCH 01308000
  849. CLCPRT CLC 0(0,R1),=C'PRT ' COMPARE FOR PRT 01309000
  850. CLCPRINT CLC 0(0,R1),=C'PRINTER ' COMPARE FOR PRINTER 01310000
  851. CLCPUN CLC 0(0,R1),=C'PUNCH ' COMPARE FOR PUNCH 01311000
  852. CLCREAD CLC 0(0,R1),=C'READER ' COMPARE FOR READER 01312000
  853. CLCCLASS CLC 0(0,R1),=C'CLASS ' COMPARE FOR CLASS 01313000
  854. CLCCON CLC 0(0,R1),=C'CONT ' COPARE FOR CONT 01314000
  855. CLCNOCON CLC 0(0,R1),=C'NOCONT ' COMPARE FOR NOCONT 01315000
  856. CLCHOLD CLC 0(0,R1),=C'HOLD ' COMPARE FOR HOLD 01316000
  857. CLCNOHLD CLC 0(0,R1),=C'NOHOLD ' COMPARE FOR NOHOLD 01317000
  858. CLCEOF CLC 0(0,R1),=C'EOF ' COMPARE FOR EOF 01318000
  859. CLCNOEOF CLC 0(0,R1),=C'NOEOF ' COMPARE FOR NOEOF 01319000
  860. CLCTO CLC 0(0,R1),=C'TO ' COMPARE FOR TO 01320000
  861. CLCFOR CLC 0(0,R1),=C'FOR ' COMPARE FOR FOR @V200930 01321000
  862. CLCOFF CLC 0(0,R1),=C'OFF ' COMPARE FOR OFF 01322000
  863. CLCCOPY CLC 0(0,R1),=C'COPY ' COMPARE FOR COPY 01323000
  864. CLCPURG CLC 0(0,R1),=C'PURGE ' COMPARE FOR PURGE 01325000
  865. CLCCLOSE CLC 0(0,R1),=C'CLOSE ' COMPARE FOR CLOSE @V200930 01326000
  866. CLCCONS CLC 0(0,R1),=C'CONSOLE ' COMPARE FOR CONSOLE 01328000
  867. CLCSTART CLC 0(0,R1),=C'START ' COMPARE FOR START 01329000
  868. CLCSTOP CLC 0(0,R1),=C'STOP ' COMPARE FOR STOP 01330000
  869. CLCTERM CLC 0(0,R1),=C'TERM ' COMPARE FOR TERM 01331000
  870. CLCNOTE CLC 0(0,R1),=C'NOTERM ' COMPARE FOR NOTERM 01332000
  871. CLCCHARS CLC 0(0,R1),=C'CHARS ' COMPARE FOR CHARS @V60B9BA 01333000
  872. CLCFLASH CLC 0(0,R1),=C'FLASH ' COMPARE FOR FLASH @V60B9BA 01333250
  873. CLCCMOD CLC 0(0,R1),=C'MODIFY ' COMPARE FOR MODIFY @V60B9BA 01333500
  874. CLCFCB CLC 0(0,R1),=C'FCB ' COMPARE FOR FCB @V60B9BA 01333750
  875. EJECT 01334000
  876. *. 01335000
  877. * OPERATION OF GETCLASS - 01336000
  878. * 01337000
  879. * 1. CALL DMKSCNFD TO LOCATE THE DESIRED CLASS 01338000
  880. * 2. VERIFY THAT ONLY ONE CLASS IS GIVEN, AND TRT THE CLASS 01339000
  881. * AGAINST A TABLE OF VALID CLASSES TO VERIFY ITS VALIDITY; 01340000
  882. * IF MISSING OR INVALID, EXIT GIVING MSG028E. 01341000
  883. * THE FUNCTION TABLE IS SET TO STORE THE VALID CLASS IN GPR2 01342000
  884. * SAVE THE VALID CLASS IN SAVEWRK1. 01343000
  885. * 3. NOTE THAT GETCLASS IS A 2ND LEVEL ROUTINE; LINKAGE IS VIA 01344000
  886. * GPR3 01345000
  887. *. 01346000
  888. SPACE 3 01347000
  889. GETCLASS EQU * HERE TO LOCATE AND VERIFY CLASS 01348000
  890. SPACE 01349000
  891. GCL01 CALL DMKSCNFD 01350000
  892. BNZ MSG028E CLASS MISSING - EXIT 01351000
  893. SPACE 01352000
  894. GCL02 C R0,F1 MUST BE ONLY ON CLASS COUNT=1 01353000
  895. BNE MSG028E NO-- 01354000
  896. TM VDEVTYPC,CLASURI IS IT A READER CLASS ?? @V200930 01355000
  897. BZ GCL05 NO, CONT @V200930 01356000
  898. TM VDEVTYPE,TYPRDR IS IT A READER ?? @V200930 01357000
  899. BZ GCL05 NO, CONT @V200930 01358000
  900. CLI 0(R1),C'*' IS IT CLASS * ... READ ANY ?? @V200930 01359000
  901. BNE GCL05 NO, CONT @V200930 01360000
  902. IC R2,0(R1) GET CLASS IN R2 @V200930 01361000
  903. B GCL03 SET DEVICE CLASS @V200930 01362000
  904. GCL05 DS 0H @V200930 01363000
  905. CLI 0(R1),C'A' CLASS LOWER THAN A 01364000
  906. BL MSG028E YES - INVALID CLASS 01365000
  907. ST R2,TEMPR2 SAVE GPR2 01366000
  908. TRT 0(1,R1),CLTABLE CLASS VALID ?? 01367000
  909. BH GCL03 VALID 01368000
  910. B MSG028E NO - INVALID CLASS 01369000
  911. SPACE 01370000
  912. GCL03 EQU * 01371000
  913. STC R2,SAVEWRK1 SAVE CLASS 01372000
  914. GCL04 CR R1,R1 CC = ZERO 01373000
  915. L R2,TEMPR2 RESTORE GPR2 01374000
  916. BR R3 RETURN TO CALLER 01375000
  917. SPACE 3 01376000
  918. ORG *-193 01377000
  919. CLTABLE EQU * 01378000
  920. ORG 01379000
  921. DC C'ABCDEFGHI' 01380000
  922. DC XL7'00' 01381000
  923. DC C'JKLMNOPQR' 01382000
  924. DC XL8'00' 01383000
  925. DC C'STUVWXYZ' 01384000
  926. DC XL6'00' 01385000
  927. DC C'0123456789' 01386000
  928. DC XL6'00' 01387000
  929. DS 0H 01388000
  930. SPACE 01389000
  931. EJECT 01390000
  932. *. 01391000
  933. * 01392000
  934. * OPERATION OF GETFILE - 01393000
  935. * 01394000
  936. * 1. UPON ENTRY, GPR6 = ADDRESS OF A POINTER TO THE NEXT SFBLOK 01395000
  937. * TO TEST 01396000
  938. * 2. LOAD GPR7 WITH POINTER TO NEXT BLOK; IF ZERO, EXIT 01397000
  939. * 3. IF SAVEWRK2,3 EQUALS ZERO OR SFBUSER, GO TO STEP 4; 01398000
  940. * OTHERWISE GO TO STEP 6 01399000
  941. * 4. IF SAVEWRK1(1) EQUALS ZERO OR SFBCLAS,GO TO STEP 5; 01400000
  942. * OTHERWISE GO TO STEP 6 01401000
  943. * 5. IF SAVEWRK1+2(2) EQUALS ZERO OR SFBFILID, EXIT 01402000
  944. * 6. IF NO MATCH, GO TO STEP 2 01403000
  945. *. 01404000
  946. SPACE 01405000
  947. GETFILE EQU * HERE TO LOCATE THE REQUESTED FILE 01406000
  948. SPACE 01407000
  949. GF01 EQU * GPR7 = POINTER TO NEXT SFBLOK 01408000
  950. GF02 LR R6,R7 SFBLOK PRESENT ?? 01409000
  951. L R7,0(R7) 01410000
  952. LTR R7,R7 01411000
  953. BCR 8,R4 NO -RETURN TO CALLER WITH GPR7 ZERO 01412000
  954. SPACE 01413000
  955. GF03 TM SFBFLAG,SFBINUSE FILE IN USE ?? 01414000
  956. BO GF02 GET NEXT FILE 01415000
  957. CLI SAVEWRK2,X'40' USERID PRESENT ?? 01416000
  958. BNH GF04 NO -- USE ALL FILES 01417000
  959. CLC SAVEWRK2(8),SFBUSER USERID EQUALS ?? 01418000
  960. BNE GF02 NO 01419000
  961. SPACE 01420000
  962. GF04 CLI SAVEWRK1,X'00' SEARCH BY CLASS ?? 01421000
  963. BE GF05 NO 01422000
  964. CLI SAVEWRK1,C'*' ALL CLASS DEVICE ?? @VM01016 01423000
  965. BE GF05 YES, @VM01016 01424000
  966. CLC SAVEWRK1(1),SFBCLAS CLASS EQUALS ?? 01425000
  967. BNE GF02 NO - 01426000
  968. SPACE 01427000
  969. GF05 CLC SAVEWRK1+2(2),ZEROES SEARCH BY SPOOLID 01428000
  970. BE GF06 YES 01429000
  971. CLC SAVEWRK1+2(2),SFBFILID SPOOLID EQUAL ?? 01430000
  972. BNE GF02 NO - 01431000
  973. SPACE 01432000
  974. GF06 EQU * 01433000
  975. BR R4 RETURN TO CALLER 01434000
  976. EJECT 01435000
  977. *. 01436000
  978. * OPERATION OF GETCOPY - 01437000
  979. * 01438000
  980. * 1. CALL DMKSCNFD TO LOCATE NUMBER OF COPIES 01439000
  981. * IF MISSING OR INVALID, EXIT GIVING MSG030E. 01440000
  982. * 2. CONVERT DECIMAL NUMBER TO BINARY, AND VERIFY THAT 01441000
  983. * IT IS LESS THAN 100 01442000
  984. * 3. STORE NUMBER OF COPIES IN SAVEWRK1+1(1) 01443000
  985. *. 01444000
  986. SPACE 3 01445000
  987. GETCOPY EQU * HERE TO LOCATE NUMBER OF COPIES AND CONVERT TO BINARY 01446000
  988. CALL DMKSCNFD LOCATE NUMBER OF COPIES 01447000
  989. BNZ MSG030E NUMBER OF COPIES MISSING 01448000
  990. CLI 0(R1),C'*' SPECIAL COPY FOR 3800 ? @V60B9BA 01448200
  991. BNE GETCOPY2 XFER IF NOT @V60B9BA 01448400
  992. OI SAVEWRK8+3,X'01' SET THE FLAG @V60B9BA 01448600
  993. BCTR R0,0 DECREMENT THE COUNT @V60B9BA 01448800
  994. LTR R0,R0 IS IT ZERO ? @V60B9BA 01449000
  995. BZ MSG030E ERROR IF SO @V60B9BA 01449200
  996. LA R1,1(R1) POINT PAST THE ASTERISK @V60B9BA 01449400
  997. GETCOPY2 C R0,F2 LENGTH GREATER THAN 2 ? @V60B9BA 01449600
  998. BH MSG030E YES - INVALID 01450000
  999. CALL DMKCVTDB CONVERT TO BINARY 01451000
  1000. BNZ MSG030E INVALID NUMBER OF COP8&IES 01452000
  1001. SPACE 01453000
  1002. CH R1,=H'99' LARGER THAN 99 ?? 01454000
  1003. BH MSG030E YES - 01455000
  1004. LTR R1,R1 COPY EQUAL ZERO 01456000
  1005. BNP MSG030E 01457000
  1006. STC R1,SAVEWRK1+1 SAVE NUMBER OF COPIES 01458000
  1007. BR R4 RETURN TO CALLER 01459000
  1008. EJECT 01460000
  1009. *. OPERATION OF GETCHARS - 01460010
  1010. * 01460020
  1011. * 1. CALL DMKSCNFD TO LOCATE CHARS SPECIFIED 01460030
  1012. * 2. IF MISSING OR GREATER THAN 4 CHARACTERS, EXIT 01460040
  1013. * GIVING MSG245E. 01460050
  1014. * 3. STORE VALUE IN SAVEWRK4. 01460060
  1015. *. 01460070
  1016. SPACE 3 01460080
  1017. GETCHARS CALL DMKSCNFD LOCATE CHARS VALUE @V60B9BA 01460090
  1018. BNZ MSG245E CHARS PARAMETER MISSING @V60B9BA 01460100
  1019. C R0,F4 LENGTH GREATER THAN 4 ? @V60B9BA 01460110
  1020. BH MSG245E YES - INVLALID @V60B9BA 01460120
  1021. MVC SAVEWRK4(4),BLANKS INITIALIZE @V60B9BA 01460130
  1022. LR R2,R0 EXECUTE FROM R2 @V60B9BA 01460140
  1023. BCTR R2,0 LESS ONE FOR EXECUTE INST @V60B9BA 01460150
  1024. EX R2,MVCCHARS SAVE THE CHARS VALUE @V60B9BA 01460160
  1025. BR R4 RETURN TO CALLER @V60B9BA 01460170
  1026. EJECT 01460180
  1027. *. 01460190
  1028. * OPERATION OF GETFLASH - 01460200
  1029. * 01460210
  1030. * 1. CALL DMKSCNFD TO GET FLASH OVERLAY NAME. 01460220
  1031. * 2. IF MISSING OR GREATER THAN 4 CHARS EXIT 01460230
  1032. * GIVING MSG243E. 01460240
  1033. * 3. SAVE FLASH OVERLAY NAME IN SAVEWRK5. 01460250
  1034. * 4. CALL DMKSCNFD TO GET FLASH COUNT. 01460260
  1035. * 5. IF MISSING OF NOT BETWEEN 0 AND 99, EXIT 01460270
  1036. * GIVING MSG243E. 01460280
  1037. * 6. SAVE FLASH COUNT IN SAVEWRK9. 01460290
  1038. *. 01460300
  1039. SPACE 3 01460310
  1040. GETFLASH CALL DMKSCNFD LOCATE FLASH OVERLAY NAME @V60B9BA 01460320
  1041. BNZ MSG243E FLASH NAME MISSING @V60B9BA 01460330
  1042. C R0,F4 GREATER THAN 4 CHARS ? @V60B9BA 01460340
  1043. BH MSG243E INVALID IF SO @V60B9BA 01460350
  1044. MVC SAVEWRK5(4),BLANKS INITIALIZE @V60B9BA 01460360
  1045. LR R2,R0 WHERE TO EX FROM @V60B9BA 01460370
  1046. BCTR R2,0 DECREMENT FOR EXECUTE @V60B9BA 01460380
  1047. EX R2,MVCFLASH SAVE THE FLASH NAME @V60B9BA 01460390
  1048. CALL DMKSCNFD LOCATE FLASH COUNT @V60B9BA 01460400
  1049. BNZ MSG243E FLASH COUNT MISSING @V60B9BA 01460410
  1050. C R0,F2 LENGTH GREATER THAN 2 @V60B9BA 01460420
  1051. BH MSG243E INVALID IF SO @V60B9BA 01460430
  1052. CALL DMKCVTDB CONVERT TO BINARY @V60B9BA 01460440
  1053. BNZ MSG243E INVALID FLASH COUNT @V60B9BA 01460450
  1054. CH R1,=H'99' LARGER THAN 99 ? @V60B9BA 01460460
  1055. BH MSG243E XFER IF SO @V60B9BA 01460470
  1056. STC R1,SAVEWRK9 SAVE THE COUNT @V60B9BA 01460480
  1057. BR R4 RETURN TO CALLER @V60B9BA 01460490
  1058. EJECT 01460500
  1059. *. 01460510
  1060. * OPERATION OF GETCMOD - 01460520
  1061. * 01460530
  1062. * 1. CALL DMKSCNFD TO LOCATE MODIFY VALUE. 01460540
  1063. * 2. IF MISSING OR GREATER THAN 4 CHARACTERS, 01460550
  1064. * EXIT GIVING MSG253E. 01460560
  1065. * 3. SAVE THE MODIFY VALUE IN SAVEWRK6. 01460570
  1066. *. 01460580
  1067. SPACE 3 01460590
  1068. GETCMOD CALL DMKSCNFD LOCATE MODIFY VALUE @V60B9BA 01460600
  1069. BNZ MSG253E ERROR IF MISSING @V60B9BA 01460610
  1070. C R0,F4 MORE THAN 4 CHARACTERS ? @V60B9BA 01460620
  1071. BH MSG253E INVALID IF SO @V60B9BA 01460630
  1072. MVC SAVEWRK6(4),BLANKS INITIALIZE @V60B9BA 01460640
  1073. LR R2,R0 COUNT FOR EXECUTE @V60B9BA 01460650
  1074. BCTR R2,0 DECREMENT FOR EXECUTE @V60B9BA 01460660
  1075. EX R2,MVCCMOD SAVE THE MODIFY VALUE @V60B9BA 01460670
  1076. BR R4 RETURN TO CALLER @V60B9BA 01460680
  1077. EJECT 01460690
  1078. *. 01460700
  1079. * OPERATION OF GETFCB - 01460710
  1080. * 01460720
  1081. * 1. CALL DMKSCNFD TO LOCATE FCB VALUE. 01460730
  1082. * 2. IF MISSING OR GREATER THAN 4 CHARACTERS, 01460740
  1083. * EXIT GIVING MSG246E. 01460750
  1084. * 3. SAVE THE FCB VALUE IN SAVEWRK7. 01460760
  1085. *. 01460770
  1086. SPACE 3 01460780
  1087. GETFCB CALL DMKSCNFD LOCATE FCB VALUE @V60B9BA 01460790
  1088. BNZ MSG246E ERROR IF MISSING @V60B9BA 01460800
  1089. C R0,F4 GREATER THAN 4 CHARS ? @V60B9BA 01460810
  1090. BH MSG246E XFER IF SO @V60B9BA 01460820
  1091. MVC SAVEWRK7(4),BLANKS INITIALIZE @V60B9BA 01460830
  1092. LR R2,R0 GET THE COUNT IN R2 @V60B9BA 01460840
  1093. BCTR R2,0 DECREMENT FOR EXECUTE @V60B9BA 01460850
  1094. EX R2,MVCFCB SAVE THE FCB VALUE @V60B9BA 01460860
  1095. BR R4 RETURN TO CALLER @V60B9BA 01460870
  1096. EJECT 01460880
  1097. *. 01461000
  1098. * OPERATION OF GETDEVIC - 01462000
  1099. * 01463000
  1100. * 1. UPON ENTRY, THE FOLLOWING REGISTERS MUST BE LOADED - 01464000
  1101. * GPR5 = THE DEVICE TYPE TO SEARCH FOR 01465000
  1102. * GPR8 = ADDRESS OF VDEVBLOK AT WHICH TO START SEARCH 01466000
  1103. * GPR10 = NUMBER OF VDEVBLOKS TO SEARCH 01467000
  1104. * 2. ADD VDEVSIZE TO GPR8 AND DECREMENT GPR10; IF GPR10 = 0,EXIT 01468000
  1105. * 3. TEST FOR DEVICE CLASS OF UNIT RECORD; IF NOT U/R, GO TO 2 01469000
  1106. * 4. EXECUTE TM USING MASK IN GPR5 AGAINST VDEVTYPE; BRANCH 01470000
  1107. * ON ONES BACK TO CALLER; OTHERWISE, GO TO STEP 2 01471000
  1108. * 5. NOTE THAT GETDEVIC IS A 2ND LEVEL ROUTINE; LINKAGE IS VIA 01472000
  1109. * GPR3 01473000
  1110. *. 01474000
  1111. SPACE 3 01475000
  1112. GETDEVIC EQU * HERE TO LOCATE NEXT DEVICE FOR THIS TYPE 01476000
  1113. SPACE 01477000
  1114. * GPR5 = DEVICE TYPE TO SEARCH FOR 01478000
  1115. * GPR8 = ADDRESS OF VDEVBLOK TO START SEARCH 01479000
  1116. * GPR10 = NUMBER OF VDEVBLOKS TO SEARCH 01480000
  1117. SPACE 01481000
  1118. GD02 A R8,=A(VDEVSIZE*8) POINT TO NEXT DEVBLOK 01482000
  1119. BCT R10,GD03 DECREMENT COUNT 01483000
  1120. BR R3 COUNT IS ZERO, RETURN TO CALLER 01484000
  1121. SPACE 01485000
  1122. GD03 CLC VDEVADD,FFS ACTIVE DEVICE 01486000
  1123. BE GD02 NO -- 01487000
  1124. TM VDEVSTAT,VDEVDED DEDICATED TO REAL DEVICE ?? 01488000
  1125. BO GD02 YES -- TRY NEXT 01489000
  1126. TM VDEVTYPC,CLASURI INPUT UNIT RECORD ?? 01490000
  1127. BZ GD04 NO - CHECK OUTPUT 01491000
  1128. TM VDEVTYPE,TYPRDR IS IT A READER? @VA03722 01492000
  1129. BZ GD02 NO, TRY NEXT BLOCK @VA03722 01493000
  1130. EX R5,TMRDR VALID READER ?? 01494000
  1131. BCR 7,R3 YES - 01495000
  1132. B GD02 NO - TRY NEXT BLOK 01496000
  1133. SPACE 01497000
  1134. GD04 EQU * 01498000
  1135. CLI VDEVTYPC,CLASURO OUTPUT CLASS ?? 01499000
  1136. BNE GD05 NO -- 01500000
  1137. TM VDEVTYPE,TYPPUN+TYPPRT TYPE PUNCH OR PRINTER 01501000
  1138. BZ GD02 NO - 01502000
  1139. EX R5,TMTYPE MATCH SEARCH DEVICE PUNCH OR PRINTER 01503000
  1140. BZ GD02 NO 01504000
  1141. BR R3 YES - 01505000
  1142. SPACE 01506000
  1143. GD05 CLI VDEVTYPC,CLASTERM CONSOLE CLASS ? 01507000
  1144. BNE GD02 NO -- GET NEXT DEVICE 01508000
  1145. CLI VDEVTYPE,TYP3210 CONSOLE TYPE ? 01509000
  1146. BNE GD02 NO -- GET NEXT DEVICE 01510000
  1147. EX R5,TMCON CONSOLE TYPE REQUESTED ? 01511000
  1148. BZ GD02 NO -- GET NEXT DEVICE 01512000
  1149. BR R3 RETURN TO CALLER 01513000
  1150. SPACE 01514000
  1151. EJECT 01515000
  1152. *. 01564000
  1153. * OPERATION OF GETCHAIN - 01565000
  1154. * 01566000
  1155. * 1. IF GPR5 = 0, SET GPR6 = 0 AND EXIT; 01567000
  1156. * 2. IF GPR6 = FFS, GO TO STEP 6; 01568000
  1157. * 3. IF GPR5 HAS CSPRDR BIT ON,REMOVE BIT, GO TO STEP 7; 01569000
  1158. * 4. IF GPR5 HAS TYPPRT BIT ON,REMOVE BIT, GO TO STEP 8; 01570000
  1159. * 5. REMOVE TYPPUN BIT IN GPR5, SET GPR6 TO ZERO, EXIT 01571000
  1160. * 6. IF GPR5 HAS CSPRDR BIT ON, LOAD GPR6 WITH ARSPRD, EXIT; 01572000
  1161. * 7. IF GPR5 HAS TYPPRT BIT ON, LOAD GPR6 WITH ARSPPR, EXIT; 01573000
  1162. * 8. IF GPR5 HAS TYPPUN BIT ON, LOAD GPR6 WITH ARSPPU,EXIT; 01574000
  1163. * 9. SET GPR6 = 0, EXIT 01575000
  1164. *. 01576000
  1165. SPACE 3 01577000
  1166. GETCHAIN EQU * HERE TO GET NEXT FILE CHAIN ANCHOR POINTER 01578000
  1167. SPACE 01579000
  1168. GC01 LTR R5,R5 FILE TYPE ZERO ?? 01580000
  1169. BNZ GC02 NO-- 01581000
  1170. SR R6,R6 YES - ZERO GPR6 01582000
  1171. BR R3 RETURN TO CALLER 01583000
  1172. SPACE 01584000
  1173. GC02 C R6,FFS 1ST TIME SWITCH ON ?? 01585000
  1174. LR R6,R5 SAVE DEVICE TYPE FOR CHANGE COMPARE 01586000
  1175. BE GC06 YES - DO NOT RESET ANY BITS, JUST 01587000
  1176. * LOAD GPR6 01588000
  1177. SPACE 01589000
  1178. GC03 N R5,=A(255-CSPRDR) REMOVE READER BIT 01590000
  1179. CR R6,R5 WAS IT ON ?? 01591000
  1180. BNE GC07 NO 01592000
  1181. SPACE 01593000
  1182. GC04 N R5,=A(255-TYPPRT) REMOVE PRINTER BIT 01594000
  1183. CR R6,R5 WAS IT ON ?? 01595000
  1184. BNE GC08 NO 01596000
  1185. SPACE 01597000
  1186. GC05 SR R5,R5 REMOVE PUNCH BIT 01598000
  1187. SR R6,R6 SET GPR6 TO ZERO 01599000
  1188. BR R3 RETURN TO CALLER - END OF CHAIN 01600000
  1189. SPACE 01601000
  1190. GC06 L R7,ARSPRD LOAD READER FILE CHAIN POINTER 01602000
  1191. * ANCHOR 01603000
  1192. EX R5,TMRDR READER BIT ON ?? 01604000
  1193. BCR 7,R3 YES - RETURN TO CALLER 01605000
  1194. SPACE 01606000
  1195. GC07 L R7,ARSPPR LOAD PRINTER FILE CHAIN POINTER 01607000
  1196. * ANCHOR 01608000
  1197. EX R5,TMPRT PRINTER BIT ON ?? 01609000
  1198. BCR 7,R3 YES - RETURN TO CALLER 01610000
  1199. SPACE 01611000
  1200. GC08 L R7,ARSPPU LOAD PUNCH FILE CHAIN POINTER ANCHOR 01612000
  1201. EX R5,TMPUN PUNCH BIT ON ?? 01613000
  1202. BCR 7,R3 YES - RETURN TO CALLER 01614000
  1203. SPACE 01615000
  1204. GC09 SR R6,R6 SET GPR6 = ZERO - ALL DONE 01616000
  1205. SR R7,R7 01617000
  1206. BR R3 RETURN TO CALLER 01618000
  1207. EJECT 01619000
  1208. **************************************** 01620000
  1209. * 01621000
  1210. * ERROR EXITS FROM DMKCSP 01622000
  1211. * 01623000
  1212. **************************************** 01624000
  1213. SPACE 2 01625000
  1214. MSG003E EQU * HERE IF INVALID OPTION FOR THIS COMMAND 01626000
  1215. LA R2,003 ERROR MSG DMKCSP003E 01627000
  1216. B EXIT8 EXIT TO ERROR MODULE 01628000
  1217. SPACE 2 01629000
  1218. MSG006E EQU * HERE IF DEVICE TYPE IS INVALID 01630000
  1219. LA R2,006 ERROR MSG DMKCSP006E 01631000
  1220. LM R0,R1,SAVEWRK6 COUNT AND ADDRESS OF INVALID TYPE 01632000
  1221. B EXIT8 EXIT TO ERROR MODULE 01633000
  1222. SPACE 2 01634000
  1223. MSG007E EQU * HERE IF USERID IS INVALID 01635000
  1224. LA R2,007 ERROR MSG DMKCSP007E 01636000
  1225. B EXIT8 01637000
  1226. SPACE 2 01638000
  1227. MSG013E EQU * HERE IF CONFLICTING OPTIONS 01639000
  1228. LA R2,013 ERROR MSG DMKCSP013E 01640000
  1229. B EXIT8 01641000
  1230. SPACE 2 01642000
  1231. MSG020E EQU * HERE IF USERID IS MISSING OR INVALID 01643000
  1232. LA R2,020 ERROR MSG DMKCSP020E 01644000
  1233. B EXIT8R1 EXIT TO ERROR MODULE 01645000
  1234. SPACE 2 01646000
  1235. MSG022E EQU * HERE IF VIRTUAL ADDRESS MISSING OR 01647000
  1236. * INVALID 01648000
  1237. LA R2,022 ERROR MSG DMKCSP022E 01649000
  1238. B EXIT8R1 .. 01650000
  1239. SPACE 01651000
  1240. MSG026E EQU * HERE IF OPERAND MISSING OR INVALID 01652000
  1241. LA R2,026 ERROR MSG DMKCSP026E 01653000
  1242. B EXIT8R1 EXIT TO ERROR MODULE 01654000
  1243. SPACE 2 01655000
  1244. MSG028E EQU * HERE IF CLASS IS MISSING OR INVALID 01656000
  1245. LA R2,028 ERROR MSG DMKCSP028E 01657000
  1246. B EXIT8R1 01658000
  1247. SPACE 01659000
  1248. MSG029E EQU * HERE IF FNAME FTYPE MISSING OR INVALID 01660000
  1249. LA R2,029 ERROR MSG DMKCSP029E 01661000
  1250. B EXIT8R1 EXIT TO ERROR MODULE 01662000
  1251. SPACE 2 01663000
  1252. MSG030E EQU * HERE IF COPIES IS MISSING OR INVALID 01664000
  1253. LA R2,030 ERROR MSG DMKCSP030E 01665000
  1254. B EXIT8R1 EXIT TO ERROR MODULE 01666000
  1255. SPACE 2 01667000
  1256. MSG032E EQU * HERE IF DISTCODE IS MISSING OR INVALID 01668000
  1257. LA R2,032 ERROR MSG DMKCSP032E 01669000
  1258. B EXIT8R1 EXIT TO ERROR MODULE 01670000
  1259. SPACE 2 01671000
  1260. MSG040E EQU * HERE IF DEVICE DOES NOT EXIST 01672000
  1261. LA R2,040 ERROR MSG DMKCSP040E 01673000
  1262. LM R0,R1,SAVEWRK6 COUNT AND ADDRESS OF OPTION 01674000
  1263. B EXIT8 01675000
  1264. SPACE 2 01676000
  1265. MSG053E EQU * HERE IF USERID NOT IN CP DIRECTORY 01677000
  1266. LA R2,053 ERROR MSG DMKCSP053E 01678000
  1267. B EXIT8 01679000
  1268. SPACE 2 01679050
  1269. MSG243E EQU * HERE IF FLASH MISSING OR INVALID @V60B9BA 01679100
  1270. LA R2,243 ERROR MSG DMKCSP243E @V60B9BA 01679150
  1271. B EXIT8R1 EXIT TO ERROR MODULE @V60B9BA 01679200
  1272. SPACE 2 01679250
  1273. MSG245E EQU * HERE IF CHARS MISSING OR INVALID @V60B9BA 01679300
  1274. LA R2,245 ERROR MSG DMKCSP245E @V60B9BA 01679350
  1275. B EXIT8R1 EXIT TO ERROR MODULE @V60B9BA 01679400
  1276. SPACE 2 01679450
  1277. MSG246E EQU * HERE IS FCB MISSING OR INVALID @V60B9BA 01679500
  1278. LA R2,246 ERROR MSG DMKCSP246E @V60B9BA 01679550
  1279. B EXIT8R1 EXIT TO ERROR MODULE @V60B9BA 01679600
  1280. SPACE 2 01679650
  1281. MSG253E EQU * HERE IS MODIFY MISSING OR INVALID @V60B9BA 01679700
  1282. LA R2,253 ERROR MSG DMKCSP253E @V60B9BA 01679750
  1283. B EXIT8R1 EXIT TO ERROR MODULE @V60B9BA 01679800
  1284. EJECT 01680000
  1285. **************************************** 01681000
  1286. * 01682000
  1287. * FINAL EXIT BACK TO DMKCFM 01683000
  1288. * 01684000
  1289. **************************************** 01685000
  1290. SPACE 3 01686000
  1291. CSPEXIT EQU * HERE FOR NORMAL EXIT FROM DMKCSP 01687000
  1292. SR R2,R2 CLEAR ERROR REGISTER 01688000
  1293. B EXIT1 NOW EXIT 01689000
  1294. SPACE 2 01690000
  1295. EXIT8R1 SR R1,R1 01691000
  1296. SR R0,R0 01692000
  1297. EXIT8 ICM R0,14,ID+3 MOVE IN MODULE ID 01693000
  1298. EXIT1 LTR R2,R2 ERROR CODE PRESENT ?? 01694000
  1299. BNZ ERREXIT YES -- 01702000
  1300. EXIT3 EXIT EXIT NO ERROR @V60B9BA 01703000
  1301. SPACE 01704000
  1302. ERREXIT CALL DMKERMSG EXIT TO MESSAGE MODULE 01705000
  1303. SPACE 01706000
  1304. * MODULE DMKERMSG WILL GIVE SVC16 AND RETURN CONTROL TO DMKCFM 01707000
  1305. EJECT 01708000
  1306. **************************************** 01709000
  1307. * 01710000
  1308. * MESSAGES AND CONSTANTS 01711000
  1309. * 01712000
  1310. **************************************** 01713000
  1311. SPACE 2 01714000
  1312. LTORG 01715000
  1313. EJECT 01716000
  1314. CSPRDR EQU X'20' 01717000
  1315. CSPCON EQU X'10' 01718000
  1316. SPACE 01719000
  1317. PSA , @V306638 01720000
  1318. COPY CONBUF @V306638 01721000
  1319. COPY DEVTYPES @V306638 01722000
  1320. COPY EQU @V306638 01723000
  1321. COPY IOBLOKS @V306638 01724000
  1322. COPY RBLOKS @V306638 01725000
  1323. COPY SAVE @V306638 01726000
  1324. COPY SPOOL @V306638 01727000
  1325. COPY UDIRECT @V306638 01728000
  1326. COPY VBLOKS @V306638 01729000
  1327. COPY VMBLOK @V306638 01730000
  1328. END 01731000