LDS TITLE 'DMSLDS (CMS) VM/370 - RELEASE 6' 00001000 SPACE 2 00002000 *. 00003000 * 00004000 * MODULE NAME: 00005000 * 00006000 * DMSLDS (LISTDS) 00007000 * 00008000 * FUNCTION: 00009000 * 00010000 * TO LIST INFORMATION ABOUT SPECIFIED DATA SETS RESIDING 00011000 * ON AN O/S DISK. THIS FUNCTION IS PROVIDED BY INVOKING 00012000 * THE COMMAND 'LISTDS'. 00013000 * 00014000 * ATTRIBUTES: 00015000 * 00016000 * DISK RESIDENT 00017000 * 00018000 * ENTRY POINTS 00019000 * 00020000 * DMSLDS 00021000 * 00022000 * ENTRY CONDITIONS: 00023000 * 00024000 * LA R1,PLIST 00025000 * SVC 202 00026000 * DC AL4(ERROR) 00027000 * 00028000 * 00029000 * R1 MUST POINT TO THE PARAMETER LIST AS USUAL: 00030000 * 00031000 * DS 0D 00032000 * PLIST DC CL8'LISTDS' 00033000 * DC CL8'QUAL1' 1ST. QUALIFIER OF DATA SET NAME 00034000 * DC CL8'QUAL2' 2ND. QUALIFIER OF DATA SET NAME 00035000 * DC CL8'QUALN' NTH. QUALIFIER OF DATA SET NAME 00036000 * DC CL8'FMODE' FILE MODE OF O/S DISK 00037000 * DC CL8'(' BEGINNING OF OPTIONS 00038000 * DC CL8'PDS' TYPE ALL MEMBERS OF PO DATA SET 00039000 * DC CL8'FORMAT' TYPE EXTENDED INFORMATION 00040000 * DC CL8'FREE' TYPE FREESPACE EXTENTS 00041000 * DC CL8'EXTENT' TYPE DATA SET EXTENTS 00042000 * DC XL8'FF' FENCE 00043000 * 00044000 * EXIT CONDITIONS: 00045000 * 00046000 * NORMAL RETURN - 00047000 * 00048000 * R15 = 0 00049000 * 00050000 * ERROR RETURNS - 00051000 * 00052000 * R15 = 4: WARNING 00053000 * INVALID EXTENT FOUND 00054000 * 00055000 * R15 = 24: SYNTAX ERROR 00056000 * INVALID FILE MODE SPECIFIED, 00057000 * NO FILEMODE SPECIFIED, 00058000 * INVALID OPTION FOUND, 00059000 * INVAID DATA SET NAME 00060000 * INVALID DATA SET NAME WITH FREE OPTION 00061000 * INVALID DATA SET NAME WITH EXTENT OPTION 00062000 * 00063000 * R15 = 28: DISK ERRORS 00064000 * I/O ERROR READING O/S DISK, 00065000 * DATA SET NOT FOUND. 00066000 * 00067000 * CALLS TO OTHER ROUTINES: 00068000 * 00069000 * DMSLAD, DMSROS, DMSSTT, DMSFLD, DMSCWR, DMSERR 00070000 * 00071000 * EXTERNAL REFERENCES: 00072000 * 00073000 * NUCON, ADT, CMSCB 00074000 * 00075000 * TABLES/WORK AREAS: 00076000 * 00077000 * NONE 00078000 * 00079000 * 00080000 * REGISTER USAGE 00081000 * 00082000 * R1 PLIST ADDRESS 00083000 * R5 ADT ADDRESSABILITY 00084000 * R7 FCBSECT ADDRESSABILITY 00085000 * R11+12 LISTDS ADDRESSABILITY 00086000 * R14 LINKAGE REGISTER 00087000 * R15 RETURN CODE 00088000 * REST WORK 00089000 * 00090000 * OPERATION: 00091000 * 00092000 * LISTDS SAVES RETURN REGISTER, SETS ITSELF IN NUCLEUS 00093000 * PROTECT KEY, CLEARS THE DSNAME KEY, AND INITIALIZES 00094000 * ITS INTERNAL FLAG. 00095000 * 00096000 * THE PARAMETER LIST IS CHECKED FOR ERRORS. THE 00097000 * DATA SET NAME MUST NOT EXCEED 44 CHARACTERS, AND THE 00098000 * DISK - MODE, (THE LAST PARAMETER BEFORE THE OPTIONS) 00099000 * MUST BE ALPHABETIC. THE QUALIFIERS ARE JOINED WITH 00100000 * DOTS (.) TO FORM VALID DSNAME 'S. (IF THE DSNAME IS 00101000 * SPECIFIED AS A QUESTION MARK (?), THE USER IS PROMP- 00102000 * TED TO ENTER THE DSNAME INTERACTIVELY IN EXACTLY THE 00103000 * SAME FORM AS THE DSNAME APPEARS ON THE O/S DISK.) 00104000 * 00105000 * DMSLAD IS CALLED TO FIND THE ACTIVE DISK TABLE (ADT) 00106000 * BLOCK. IF FMODE IS SPECIFIED AS ASTERICK , THEN THE 00107000 * SEARCH IS MADE FOR ALL ADT BLOCKS. IF THE FMODE IS 00108000 * SPECIFIED AS ALPHABETIC, THEN ONLY THE ADT BLOCK FOR 00109000 * THE SPECIFIED FMODE IS ACQUIRED. 00110000 * 00111000 * IF THE DSNAME IS SPECIFIED (WHICH IS OPTIONAL), THEN 00112000 * THE CHANNEL PROGRAMS ARE SET TO READ BY KEY, IF NOT 00113000 * THE WHOLE VTOC IS SEARCHED FOR FORMAT 1 DSCB AND ALL 00114000 * THE NEEDED INFORMATION IN THE DSCB IS TYPED TO THE 00115000 * USER'S CONSOLE. IF THE FORMAT OPTION IS SPECIFIED,WE 00116000 * TYPE THE RECFM, LRECL, BLKSI, DSORG, DATE, LABEL, FM 00117000 * AND DATA SET NAME; OTHERWISE WE ONLY TYPE THE FMODE 00118000 * AND DATA SET NAME. 00119000 * 00120000 * IF THE PDS OPTION IS SPECIFIED, WE LET THE 'FIND' 00121000 * ROUTINE IN DMSROS READ THE MEMBER DIRECTORY AND GIVE 00122000 * US IN THE FCBMEMBR FIELD OF 'CMSCB' THE NAME OF EACH 00123000 * MEMBER IN THE DATA SET (PROVIDED THE DATA SET IS PO) 00124000 * 00125000 * IF THE FREE OPTION IS SPECIFIED, A CHECK IS MADE 00126000 * TO ENSURE THAT NO DATA SET NAME HAS BEEN SPECIFIED, 00127000 * A VALID , UNIQUE DISK HAS BEEN SPECIFIED, AND NO 00128000 * OTHER OPTIONS ARE PRESENT. THE DEVICE TYPE AND NUMBER 00129000 * OF CYLINDERS ARE OBTAINED FROM THE ADT, AND THE 00130000 * NUMBER OF TRACKS IS CALCULATED. 00131000 * A GETMAIN IS ISSUED FOR ENOUGH FREE STORAGE TO MAP 00132000 * EACH TRACK ON THE DISK TO A BIT. THE VTOC IS MAPPED 00133000 * USING THE EXTENTS IN THE ADT. ALL DSCB'S IN THE VTOC 00134000 * ARE READ IN ONE AT A TIME AND THE FORMAT 1 AND FORMAT 00135000 * 3 DSCB'S ARE SCANNED FOR EXTENTS. THE TRACKS 00136000 * SPECIFIED BY THE EXTENTS ARE MAPPED IN THE FREE 00137000 * STORAGE AREA. 00138000 * WHEN THE END OF THE VTOC IS REACHED, THE TRACK MAP 00139000 * IS SCANNED FOR NON-ALLOCATED TRACKS. CONTIGUOUS 00140000 * NON-ALLOCATED TRACKS MAKE UP AN EXTENT WHICH IS TYPED 00141000 * TO THE TERMINAL. 00142000 * 00143000 * IF THE EXTENT OPTION IS SPECIFIED, A CHECK IS MADE 00144000 * THAT NO OTHER OPTIONS ARE PRESENT. VTOC INFORMATION 00145000 * IS OBTAINED FROM THE ADT AND A SEARCH ON KEY IS 00146000 * DONE FOR THE FORMAT 1 DSCB. THE EXTENT INFORMATION 00147000 * IS ANALYZED FOR TYPE AND NUMBER AND OUTPUT LINES 00148000 * ARE BUILT, 3 EXTENTS TO EACH LINE. IF MORE THAN 3 00149000 * EXTENTS EXIST FOR THE DATA SET, THE FORMAT 3 DSCB IS 00150000 * READ IN USING THE POINTER AT THE END OF THE FORMAT 1 00151000 * DSCB. WHEN A LINE IS FILLED IT IS TYPED TO THE 00152000 * TERMINAL. 00153000 * 00154000 * AFTER ALL THE PROCESSING HAS BEEN DONE,LISTDS RESETS 00155000 * THE NUCLEUS KEY TO USER KEY, GETS THE RETURN CODE IN 00156000 * REG. 15 AND RETURN TO ITS CALLER. 00157000 * 00158000 *. 00159000 EJECT 00160000 DMSLDS CSECT @V201101 00161000 USING NUCON,R0 NUCON ADDRESSABILITY @V201101 00162000 USING ADTSECT,R5 ADT ADDRESSABILITY @V201101 00163000 USING DMSLDS,R11 LISTDS ADDRESSABILITY 1ST PAGE @V305114 00164000 USING DMSLDS+4096,R12 AND 2ND PAGE @V305114 00165000 SPACE 1 00166000 LR R11,R15 SETUP BASE REGISTERS @V305114 00167000 LA R15,4095 ...... @V305114 00168000 LA R12,1(R11,R15) ...... @V305114 00169000 ST R14,SAVR14 SAVE RETURN ADDRESS @V201101 00170000 MVI LVSW,0 INITIALIZE OUR FLAGS @V201101 00171000 DMSKEY NUCLEUS DISABLE NUCLEUS PROTECT @V201101 00172000 * 00173000 MVC SAVDOS(1),DOSFLAGS RESET DOS INDICATORS @V305114 00174000 NI DOSFLAGS,255-DOSSVC FOR PROPER SVC HANDLING @V305114 00175000 CLI 8(R1),FENCE ANYTHING SPECIFIED ? @V201101 00176000 BE NOFMODE NO..ERROR @V201101 00177000 CLI 8(R1),LPAR ANY FILEMODE SPECIFIED ? @VM03015 00178000 BE NOFMODE NO..ERROR @VM03015 00179000 CLC 8(2,R1),=C'? ' USER WANTS TO ENTER DSNAME ? @V201101 00180000 BE GETDSN YES..GO GET IT @V201101 00181000 LA R2,DSNAME GET DSNAME ADDRESS @V201101 00182000 MVI 0(R2),BLANK PREPARE TO BLANK @V201101 00183000 MVC 1(43,R2),0(R2) OUT DSNAME FIELD @V201101 00184000 SR R3,R3 ZERO DSNAME COUNT @V201101 00185000 * 00186000 CHKQUALS LA R1,8(,R1) GET QUALIFIER OF DSN @V201101 00187000 CLI 8(R1),FENCE END OF LINE ? @V201101 00188000 BE CHKMODE YES..GO CHECK FMODE @V201101 00189000 CLI 8(R1),LPAR BEGINNING OF OPTIONS ? @V201101 00190000 BE CHKMODE YES..GO CHECK FMODE @V201101 00191000 * 00192000 LA R5,9 SET QUALIFIER LENGTH+1 @V201101 00193000 LR R4,R1 GET QUALIFIER BEGIN @V201101 00194000 LOOP CLI 0(R4),BLANK BLANK CHAR. ? @V201101 00195000 BE CHKLEN YES..CHECK LENGTH @V201101 00196000 CLI 0(R4),DOT PERIOD SPECIFIED? @V201101 00197000 BE BADDSN YES, THEN BAD DATA SET NAME @V201101 00198000 LA R4,1(,R4) BUMP TO NEXT CHAR. @V201101 00199000 BCT R5,LOOP KEEP SEARCHING @V201101 00200000 BCTR R4,0 ... @V201101 00201000 * 00202000 CHKLEN SR R4,R1 BEGIN LESS END @V201101 00203000 LTR R4,R4 IS LENGTH ZERO ? @V201101 00204000 BZ CHKQUALS YES..GET NEXT QUALIFIER @V201101 00205000 LA R3,1(R4,R3) GET DSNAME TOTAL LENGTH @V201101 00206000 CH R3,H45 EXCEEDS MAXIMUN ? @V201101 00207000 BH BADDSN YES..ERROR @V201101 00208000 TM LVSW,DSN IS THIS THE FIRST QUALIFIER ?@V201101 00209000 BO SETDOT NO..INSERT DOT @V201101 00210000 OI LVSW,DSN SET NOT FIRST @V201101 00211000 B SETDSN MOVE THE QUALIFIER @V201101 00212000 * 00213000 SETDOT MVI 0(R2),DOT INSERT DOT AFTER LAST QUAL. @V201101 00214000 LA R2,1(,R2) BUMP DSNAME POINTER BY ONE @V201101 00215000 SETDSN BCTR R4,0 LENGTH LESS ONE FOR EXECUTE @V201101 00216000 EX R4,MVEDSN MOVE DSNAME TO KEY @V201101 00217000 LA R2,1(R4,R2) BUMP DSNAME POINTER BY LENGTH@V201101 00218000 B CHKQUALS GET NEXT QUALIFIER @V201101 00219000 * 00220000 MVEDSN MVC 0(0,R2),0(R1) MOVE DSNAME TO KEY @V201101 00221000 EJECT 1 00222000 * 00223000 GETDSN LA R1,16(,R1) BUMP POINTER TO MODE @V201101 00224000 CLI 0(R1),FENCE ANYTHING THERE ? @V201101 00225000 BE NOFMODE NO..ERROR @V201101 00226000 CLI 0(R1),LPAR TRY AGAIN @V201101 00227000 BE NOFMODE NO..ERROR @V201101 00228000 LR R3,R1 SAVE R1 TEMPORARILY @V201101 00229000 BAL R14,DSNMSG LET USER KNOW YOUR WHEREABOUT@V201101 00230000 LA R1,CONRD GET CONSOLE READ PLIST @V201101 00231000 SVC 202 GET DSNAME FROM CONSOLE @V201101 00232000 DC AL4(*+4) ... @V201101 00233000 LR R1,R3 RESTORE R1 @V201101 00234000 LH R3,CONCNT+2 GET NUMBER BYTES READ @V201101 00235000 LTR R3,R3 ANYTHING READ ? @V201101 00236000 BZ CHKMODE NO..LIST ALL DATA SETS THEN @V201101 00237000 LA R3,1(,R3) MY FOOLNESS @V201101 00238000 SH R3,H45 EXCEEDS MAX DSNAME LEN ? @V201101 00239000 BNP DSNOK NO..GOOD DSNAME @V201101 00240000 CKOVR44 LA R5,DSNAME+43(R3) GET END TYPED LINE @V201101 00241000 CLI 0(R5),BLANK IS IT BLANK ? @V201101 00242000 BNE BADDSN NO..ERROR @V201101 00243000 BCT R3,CKOVR44 KEEP LOOKING PAST 44 @V201101 00244000 DSNOK OI LVSW,DSN SET TO SEARCH VTOC BY KEY @V201101 00245000 * 00246000 CHKMODE CLI 2(R1),BLANK TWO CHAR. MODE ? @V201101 00247000 BNE BADMODE NO..INVALID FMODE @V201101 00248000 CLI 1(R1),BLANK ONE CHAR. MODE ? @V201101 00249000 BE CHKSTAR YES..SEE IF ASTERICK @V201101 00250000 CLI 1(R1),X'F0' IS MODE NO. VALID ? @V201101 00251000 BL BADMODE NO..INVALID FMODE @V201101 00252000 CLI 1(R1),X'F5' ... @V201101 00253000 BH BADMODE DITTO @V201101 00254000 CHKSTAR CLI 0(R1),STAR SEARCH ALL DISKS ? @V201101 00255000 BNE CHKABLE NO..SEE IF MODE ALPHA @V201101 00256000 OI LVSW,ALLOS SEARCH ALL ADTS @V201101 00257000 B SETMODE CONTINUE.. @V201101 00258000 * 00259000 CHKABLE CLI 0(R1),ABLE IS IT MODE A ? @V201101 00260000 BL BADMODE IF LOWER..ERROR @V201101 00261000 CLI 0(R1),ZEBRA IS IT MODE Z ? @V201101 00262000 BH BADMODE IF HIGHER..ERROR @V201101 00263000 * 00264000 SETMODE MVC FMODE(1),0(R1) SAVE FMODE FOR ADTLKUP @V201101 00265000 LA R5,SETLNTH LOAD FOR FUTURE BRANCH @V305114 00266000 EJECT 1 00267000 LA R6,LVMOD-LVBUF GET DEFAULT BUFFER INDEX @V201101 00268000 LA R7,LVEND-LVMOD GET DEFAULT BUFFER LENGTH @V201101 00269000 CLI 8(R1),FENCE ANY OPTIONS ? @V201101 00270000 BER R5 NO ... SET TYPLIN BUFFER LENGTH @V305114 00271000 LA R1,16(,R1) UP TO OPTION @V201101 00272000 CLC 0(5,R1),FREE FREE OPTION SPECIFIED ? @V305114 00273000 BE SETFREE YES ... BR @V305114 00274000 CLC 0(7,R1),XTNT EXTENT OPTION SPECIFIED ? @V305114 00275000 BE SETXTNT YES ... BR @V305114 00276000 CLC 0(4,R1),EX ALLOW EXTENT ABBREVIATION @V305114 00277000 BE SETXTNT ....... @V305114 00278000 CHKOPTS CLC 0(8,R1),FORMAT IS IT VALID OPTION ? @V201101 00279000 BE SETINDX YES..SET NEW BUFF INDEX @V201101 00280000 CLC 0(4,R1),FO ONE MORE CHANCE.. @V201101 00281000 BE SETINDX YES..SET NEW BUFF INDEX @V201101 00282000 CLC 0(4,R1),PDS IS IT PDS OPTION ? @V201101 00283000 BE SETMEMSW YES, CHECK NEXT OPTION @V201101 00284000 CLI 0(R1),C')' RIGHT PAREN? @V201101 00285000 BNE BADOPT NO..ERROR @V201101 00286000 B CHKNXT YES, THROUGH WITH LINE @V201101 00287000 SETMEMSW OI LVSW,MEM SET PDS OPTION FLAG @V201101 00288000 B CHKNXT GO SEE IF MORE OPTIONS @V201101 00289000 SETFREE TM LVSW,DSN NO DSN ALLOWED @V305114 00290000 BO FREERR ELSE ERROR @V305114 00291000 LA R1,8(,R1) BUMP PTR FOR POSSIBLE ERROR MSG @VM03091 00292000 CLI 0(R1),FENCE NO OTHER OPTIONS ALLOWED @VM03091 00293000 BE FOPTOK BR IF FENCE @V305114 00294000 CLI 0(R1),RTPAREN RIGHT PAREN OK TOO @VM03091 00295000 BNE BADOPT ERROR IF NEITHER @V305114 00296000 FOPTOK OI LVSW,FREESW FLAG FREESPACE REQUEST @V305114 00297000 LA R7,LEN70 PRESET LENGTH OF OUTPUT @V305066 00298000 BR R5 SET TYPLIN BUFFER LENGTH @V305114 00299000 SPACE 1 00300000 SETXTNT LA R1,8(,R1) BUMP PTR FOR POSSIBLE ERROR MSG @VM03091 00301000 CLI 0(R1),FENCE NO OTHER OPTIONS ALLOWED @VM03091 00302000 BE XOPTOK BR IF FENCE @V305114 00303000 CLI 0(R1),RTPAREN RIGHT PAREN IS OK @VM03091 00304000 BNE BADOPT ERROR IF NEITHER @V305114 00305000 XOPTOK OI LVSW,XTNTSW FLAG EXTENT REQUEST @V305114 00306000 LA R7,LEN30 PRESET LENGTH OF OUTPUT @V305066 00307000 BR R5 SET TYPLIN BUFFER LENGTH @V305114 00308000 SPACE 1 00309000 SETINDX AR R7,R6 SET OPTIONAL BUFFER LENGTH @V201101 00310000 SR R6,R6 SET OPTIONAL BUFFER INDEX @V201101 00311000 CHKNXT CLI 8(R1),FENCE ANY MORE OPTIONS ? @V201101 00312000 BER R5 NO ... SET TYPLIN BUFFER LENGTH @V305114 00313000 LA R1,8(,R1) BUMP TO NEXT OPTION @V201101 00314000 B CHKOPTS GO AND CHECK IT.. @V201101 00315000 SETLNTH STCM R7,B'0111',LVLNTH+1 BUFFER LENGTH IN PLIST @V201101 00316000 LA R1,RDDSCB1 GET GENERAL CHAN PROG. @V201101 00317000 TM LVSW,FREESW FREE SPECIFIED ? @V305114 00318000 BO SETCHAN YES ... ALL SET @V305114 00319000 TM LVSW,DSN SEARCHING BY KEY ? @V201101 00320000 BZ SETCHAN NO..USE THIS ONE @V201101 00321000 LA R1,RDDSCB1K GET CHAN PROG TO SEARCH BY KE@V201101 00322000 SETCHAN ST R1,CHNPROG SAVE CHAN PROG ADDRESS @V201101 00323000 SR R5,R5 ... @V201101 00324000 * 00325000 TM LVSW,ALLOS SEARCHING ALL ADTS ? @V201101 00326000 BO SRCHADTS YES..USE ADTNXT @V201101 00327000 LA R1,FMODE-24 GET PLIST FOR ADTLKP @V201101 00328000 L R15,VCADTLKP GET ADTLKP ADDRESS @VM03093 00329000 BALR R14,R15 FIND ADT FOR ASSOCIATED MODE @V201101 00330000 BZ CHKMORE DO MORE CHECKS @VA02610 00331000 LA R1,FMODE GET FILEMODE ADDRESS @VA02610 00332000 B BADMODE GIVE ERROR MSG @VA02610 00333000 CHKMORE LR R5,R1 GET ADT ADDRESS IN REG 5 @VA02610 00334000 TM ADTFLG2,ADTFROS IS IT AN O/S DISK ? @V201101 00335000 BNZ SETSEEK YES..GO SET VTOC SEEK ADDR. @V201101 00336000 LA R1,FMODE GET FILEMODE DISK IN ERROR @V201101 00337000 B BADMODE2 GIVE ERROR MSG @VA02610 00338000 * 00339000 SRCHADTS LR R1,R5 GET NEXT ADT ADDRESS @V201101 00340000 L R15,VCADTNXT GET ADTNXT ADDRESS @VM03093 00341000 BALR R14,R15 FIND NEXT ADT @V201101 00342000 BZ TESTADT FOUND..TEST FOR O/S DISK @V201101 00343000 B TSTDSNF THAT IS ALL FOLKS @VA05780 00344000 TESTADT LR R5,R1 GET ADT ADDR IN R5 @V201101 00346000 TM ADTFLG2,ADTFROS IS IT O/S DISK ? @V201101 00347000 BZ SRCHADTS NO..GET NEXT ONE THEN @V201101 00348000 SETSEEK MVC CCHHR(5),OSADTVTA SET SEEK ADDRESS @V201101 00349000 TM LVSW,FREESW+XTNTSW FREE OR EXTENT REQUEST ? @V305114 00350000 BZ GOTDSN NO ... BR @V305114 00351000 ************************************************************** 00352000 * DETERMINE THE NUMBER OF TRACKS PER CYLINDER FOR FREE 00353000 * REQUEST AND EXTENT REQUEST. 00354000 ************************************************************** 00355000 LA R7,CON20 PLUG 2314 TYPE TRKS PER CYL @V305066 00356000 CLI OSADTDSK+3,T2314 2314 ? @V305114 00357000 BE SETTC YES ... BR @V305114 00358000 LA R7,CON19 PLUG 3330 TYPE TRACKS PER CYL @V305066 00359000 CLI OSADTDSK+3,T3330 3330 ? @V305114 00360000 BE SETTC YES ... BR @V305114 00361000 CLI OSADTDSK+3,T333B 3330-11? @V505098 00361080 BE SETTC YES ... BR @V505098 00361160 LA R7,CON30 PLUG 3350 TRK/CYL @VA06168 00361250 CLI OSADTDSK+3,T3350 IS IT A 3350? @VA06168 00361500 BE SETTC YES ---- BRANCH @VA06168 00361750 LA R7,CON15 PLUG 3380 TRK/CYL HRC004DS 00361810 CLI OSADTDSK+3,T3380 IS IT A 3380? HRC004DS 00361870 BE SETTC YES ---- BRANCH HRC004DS 00361930 LA R7,CON12 PLUG 3340 TYPE TRACKS PER CYL @V305066 00362000 SETTC STH R7,TRKCYL SET TRACKS PER CYL @V305114 00363000 TM LVSW,DSN DSN SPECIFIED ? @V305114 00364000 BO GOTDSN YES ... BR @V305114 00365000 OI LVSW,DSFND INDICATE DATA SET FOUND @V305114 00366000 TM LVSW,XTNTSW EXTENT REQUEST ? @V305114 00367000 BNO MAPVTOC MUST BE FREESPACE REQUEST @V305114 00368000 SPACE 1 00369000 OI LVSW,DSFND DATA SET AUTOMATICALLY FOUND @V305114 00370000 OI XTNTFLG,VTOCFLG SET VTOC INDICATOR ON @V305114 00371000 MVC DSNAME(5),VTOC PLUG 'VTOC' INTO DSN @V305114 00372000 MVC DSNAME+5(39),DSNAME+4 CLEAR THE REST @V305114 00373000 USING FMT1,R9 WE'LL FOOL THE XTNT ROUTINE @V305114 00374000 LA R9,DSCB AND BUILD AN EXTENT FOR VTOC @V305114 00375000 SPACE 1 00376000 MVI X1SEQ,SEQ0 FORCE SEQ. NUM. TO ZERO @V305066 00377000 MVC X1LCC(4),OSADTVTA PLUG LOW CYL AND HEAD @V305114 00378000 MVC X1HCC(4),OSADTVTB PLUG HIGH CYL AND HEAD @V305114 00379000 MVI XTNUM,EXT1 ONLY ONE EXTENT FOR VTOC @V305066 00380000 B VTOCENT GET INTO NORMAL EXTENT ROUTINE @V305114 00381000 DROP R9 @V305114 00382000 SPACE 1 00383000 ************************************************************** 00384000 * THIS ROUTINE IS USED TO DETERMINE THE FREE SPACE EXTENTS ON 00385000 * THE VTOC AND SET THE TRACK MAP BITS FOR THE VTOC. 00386000 ************************************************************** 00387000 MAPVTOC L R7,ADTCYL GET NUMBER OF CYLINDERS AND @V305114 00388000 MH R7,TRKCYL CALCULATE TOTAL TRACKS ON DISK @V305114 00389000 STH R7,TRKTOTAL SAVE THE TOTAL @V305114 00390000 SRL R7,3 DIVIDE BY EIGHT FOR TRACK MAP @V305114 00391000 LA R7,1(,R7) ADD 1 FOR POSSIBLE REMAINDER @V305114 00392000 STH R7,MAPNUM AND SAVE THE BYTE COUNT @V305114 00393000 SPACE 1 00394000 GETMAIN R,LV=(7) @V305114 00395000 LR R6,R1 SET ADR FOR CLEAR OP @V305114 00396000 SR R8,R8 THIS WILL RESULT @V305114 00397000 SR R9,R9 IN A CLEAR OPERATION @V305114 00398000 MVCL R6,R8 BY MVCL @V305114 00399000 SPACE 1 00400000 ST R1,MAPAD SAVE TRACK MAP ADDRESS @V305114 00401000 OI 0(R1),HEX80 TRACK 0 IS NEVER AVAILABLE @V305066 00402000 LH R7,OSADTVTA GET LOW CYL @V305114 00403000 MH R7,TRKCYL MULTIPLY BY TRACKS PER CYL @V305114 00404000 LH R8,OSADTVTA+2 INSERT LOW TRACK NUMBER @V305114 00405000 AR R7,R8 AND ADD TO THE REST @V305114 00406000 LH R8,OSADTVTB DO THE SAME FOR @V305114 00407000 MH R8,TRKCYL THE HIGH EXTENT @V305114 00408000 LH R6,OSADTVTB+2 THEN DETERMINE THE @V305114 00409000 AR R8,R6 NUMBER OF TRACKS @V305114 00410000 SR R8,R7 IN THE EXTENT @V305114 00411000 LA R8,1(,R8) PLUS 1 FOR TRUE TOTAL @V305114 00412000 SPACE 1 00413000 BAL R14,FILLMAP SET PROPER BITS ON IN TRACK MAP @V305114 00414000 SPACE 1 00415000 EJECT 1 00416000 *************************************************************** 00417000 * 00418000 * READ AND VERIFY FORMAT 1 DSCB FOR DATA SET 00419000 * 00420000 *************************************************************** 00421000 SPACE 1 00422000 GOTDSN L R0,CHNPROG CHAN PROG TO READ FORMAT 1 DS@V201101 00423000 BAL R14,DISKIO GO READ IT @V201101 00424000 B DSCB1UC UNIT CHECK DURING I/O @V201101 00425000 B DSCB1SLI POSSIBLE INCORRECT LENGTH @V201101 00426000 B GOTDSCB1 DATA SET FOUND @V201101 00427000 * 00428000 DSCB1UC BAL R14,CHKSENSE GO CHECK SENSE DATA @V201101 00429000 TM SNSEBYTE,X'09' NO REC FOUND OR OVERFLOW ? @V201101 00430000 BNZ VTOCERR IF ANY..VTOC I/O ERROR @V201101 00431000 TM SNSEBYTE,X'20' WAS IT CYLINDER END ? @V201101 00432000 BZ VTOCERR NO..ASSUME VTOC I/O ERROR @V201101 00433000 BAL R14,INCRCYL GO INCREMENT CYLINDER ADDRESS@V201101 00434000 * 00435000 CHKXTNT1 CLC CCHHR(4),OSADTVTB EXCEEDS UPPER LIM OF VTOC? @VA03666 00436000 BNH GOTDSN NO.. GO TRY NEXT CYLINDER @VA03666 00437000 TM LVSW,FREESW FREE OPTION PROCESSING ? @V305101 00438000 BO TYPFREE YES, FINISH UP FREE LIST @V305101 00439000 SRCHDISK TM LVSW,ALLOS MORE DISKS TO SEARCH ? @VA05780 00440000 BO SRCHADTS YES - GET NEXT ADT @VA05780 00440200 B TSTDSNF GO TEST FOR DATA SET FOUND @VA05780 00440400 * 00445000 DSCB1SLI EQU * @VA06431 00446500 TM LVSW,FREESW FREE OPTION SPECIFIED ? @VA05780 00447200 BO TYPFREE YES - FREE OPTION PROCESSING @VA05780 00447400 B SRCHDISK GO TEST FOR MORE DISKS @VA05780 00447600 * 00449000 GOTDSCB1 TM LVSW,FREESW FREE OPTION SPECIFIED ? @V305114 00450000 BO FREEREQ YES ... BR @V305114 00451000 TM LVSW,XTNTSW EXTENT REQUEST ? @V305114 00452000 BO XTNTREQ YES ... BR @V305114 00453000 CLI DSCB1+44-44,C'1' IS IT FORMAT 1 DSCB ? @V201101 00454000 BE CHKDSCB1 YES..CHECK ALL FIELDS @V201101 00455000 * 00456000 GETNXT TM LVSW,DSN SEARCHING BY KEY ? @V201101 00457000 BNO BLNKDSN NO..BLANK OUT DSNAME @V201101 00458000 TM LVSW,ALLOS SEARCHING ALL DISKS ? @V201101 00459000 BO SRCHADTS YES..GET NEXT O/S DISK @V201101 00460000 B EXIT IF NOT..RETURN @V201101 00461000 BLNKDSN NI LVSW,255-MEMHDG SET TO TYPE MEMBER HEADING @V201101 00462000 LA R2,DSNAME GET DSNAME ADDRESS @V201101 00463000 MVI 0(R2),BLANK PREPARE TO BLANK @V201101 00464000 MVC 1(43,R2),0(R2) OUT DSNAME FIELD @V201101 00465000 MVC CCHHR(5),NEXTSEEK GET NEXT FROMAT 1 DSCB @V201101 00466000 B CHKXTNT1 ..... @V305114 00467000 EJECT 1 00468000 CHKDSCB1 TM LVSW,DSHDNG FIRST TIME THROUGH ? @V201101 00469000 BO CHKDSN NO..PROCESS DSCB1 @V201101 00470000 OI LVSW,DSHDNG+DSFND MAIN HEADING TYPED..DATA SET @V201101 00471000 LA R10,LVHEAD(R6) GET HEADING ADDRESS @V201101 00472000 STCM R10,B'0111',LVBUFF+1 STORE IN TYPLIN LIST @V201101 00473000 LA R1,LVLINE GET HEADING ADDRESS @V201101 00474000 SVC 202 TYPE HEADING @V201101 00475000 DC AL4(*+4) ... @V201101 00476000 * 00477000 CHKDSN LA R10,LVDSN GET DSNAME AREA @V201101 00478000 MVC 0(44,R10),DSNAME MOVE FOUND DSNAME @V201101 00479000 * 00480000 LA R10,LVREC GET LRECL AREA @V201101 00481000 TM DSCB1+84-44,U IS RECFM U ? @V201101 00482000 BM CHKF NO..CHECK FOR FIXED @V201101 00483000 BZ CHKLREC IF ZERO..NO RECFM SPEC. @V201101 00484000 MVI 0(R10),C'U' SET RECFM U @V201101 00485000 LA R10,1(,R10) UP RECFM POINTER @V201101 00486000 B CHKS KEEP CHECKING @V201101 00487000 * 00488000 CHKF TM DSCB1+84-44,F IS RECFM FIXED ? @V201101 00489000 BZ CHKV NO..MUST BE VAR. @V201101 00490000 MVI 0(R10),C'F' MOVE F TO RECFM @V201101 00491000 B CHKV+4 KEEP CHECKING @V201101 00492000 * 00493000 CHKV MVI 0(R10),C'V' MOVE V TO RECFM @V201101 00494000 LA R10,1(,R10) UP RECFM POINTER @V201101 00495000 * 00496000 CHKB TM DSCB1+84-44,B BLOCKED RECORDS ? @V201101 00497000 BZ CHKS NO..SEE IF SPANNED @V201101 00498000 MVI 0(R10),C'B' MOVE B TO RECFM @V201101 00499000 LA R10,1(,R10) UP RECFM POINTER @V201101 00500000 * 00501000 CHKS TM DSCB1+84-44,S SPANNED RECORDS ? @V201101 00502000 BZ CHKT NO..SEE IF TRK OVFLW @V201101 00503000 MVI 0(R10),C'S' MOVE S TO RECFM @V201101 00504000 LA R10,1(,R10) UP RECFM POINTER @V201101 00505000 * 00506000 CHKT TM DSCB1+84-44,T TRK OVFLW ? @V201101 00507000 BZ CHKA NO..CHECK CONTROL CHAR. @V201101 00508000 MVI 0(R10),C'T' MOVE T TO RECFM @V201101 00509000 LA R10,1(,R10) UP RECFM POINTER @V201101 00510000 * 00511000 CHKA TM DSCB1+84-44,A+M CONTROL A OR M ? @V201101 00512000 BZ CHKLREC NONE..PROCESS LRECL @V201101 00513000 TM DSCB1+84-44,A IS IT A ? @V201101 00514000 BZ CHKM NO..MUST BE MACHINE CODE @V201101 00515000 MVI 0(R10),C'A' MOVE A TO RECFM @V201101 00516000 B CHKLREC GO CHECK LRECL @V201101 00517000 CHKM MVI 0(R10),C'M' MOVE M TO RECFM @V201101 00518000 EJECT 1 00519000 * 00520000 CHKLREC LH R9,DSCB1+88-44 GET LRECL FROM DSCB @V201101 00521000 LA R10,LVLRL GET LRECL POINTER @V201101 00522000 BAL R14,CONVERT CONVERT LRECL @V201101 00523000 * 00524000 LH R9,DSCB1+86-44 GET BLKSIZE FROM DSCB @V201101 00525000 LA R10,LVBLK GET BLKSIZE POINTER @V201101 00526000 BAL R14,CONVERT CONVERT BLKSIZE @V201101 00527000 * 00528000 SR R9,R9 ... @V201101 00529000 IC R9,DSCB1+53-44 GET YEAR FROM DSCB @V201101 00530000 LA R10,LVYY GET YEAR POINTER @V201101 00531000 BAL R14,CONVERT CONVERT YEAR @V201101 00532000 * 00533000 SR R8,R8 ... @V201101 00534000 D R8,=F'4' DIVIDE YEAR BY 4 @V201101 00535000 LTR R8,R8 IS IT LEAP YEAR ? @V201101 00536000 BZ LEAPYR YES..BRANCH @V201101 00537000 MVI FEB+1,X'1C' MAKE FEB 28 DAYS @V201101 00538000 B CHKMMDD BRANCH.. @V201101 00539000 LEAPYR MVI FEB+1,X'1D' MAKE FEB 29 DAYS @V201101 00540000 CHKMMDD LA R8,1 GET FIRST MONTH @V201101 00541000 LH R9,DSCB1+54-44 GET DAYS FROM DSCB @V201101 00542000 LA R10,JAN GET FIRST MONTH ADDRESS @V201101 00543000 * 00544000 MMDDLUP CH R9,0(,R10) HIGHER THAN DAYS IN MO ? @V201101 00545000 BNH DONE NO..ALL DONE WITH MMDD @V201101 00546000 SH R9,0(,R10) SUB DAYS IN LAST MO. @V201101 00547000 LA R8,1(,R8) UP TO NEXT MO. @V201101 00548000 LA R10,2(,R10) ... @V201101 00549000 B MMDDLUP @V201101 00550000 * 00551000 DONE LA R10,LVDD GET DAY POINTER @V201101 00552000 BAL R14,CONVERT CONVERT DAYS @V201101 00553000 LR R9,R8 GET MONTH NUMBER @V201101 00554000 LA R10,LVMM GET MONTH POINTER @V201101 00555000 BAL R14,CONVERT CONVERT MONTH @V201101 00556000 MVI LVSL1,SLASH MOVE / TO BUFFER @V201101 00557000 MVI LVSL2,SLASH .... @V201101 00558000 * 00559000 LA R9,LOOP7 @VA06395 00560100 LA R10,DSORGS GET DSORG TABLE @V201101 00561000 CHKDSORG CLC DSCB1+82-44(2),0(R10) FIND DSORG CODE @V305114 00562000 BE MVDSORG IF FOUND..MOVE IT @V201101 00563000 LA R10,6(,R10) POINT TO NEXT CODE @V305114 00564000 BCT R9,CHKDSORG LOOP TILL FOUND @V201101 00565000 B MVEMODE NO DSORG.. @V201101 00566000 * 00567000 MVDSORG MVC LVDSO(4),2(R10) MOVE DSORG TO BUFFER @V305114 00568000 MVEMODE MVC LVMOD(1),ADTM MOVE FMODE TO BUFFER @V201101 00569000 MVC LVLAB(6),ADTID MOVE LABEL TO BUFFER @V201101 00570000 * 00571000 EJECT 1 00572000 * 00573000 LINEOK LA R10,LVBUF(R6) GET LINE TO TYPE @V201101 00574000 STCM R10,B'0111',LVBUFF+1 STORE IN TYPLIN LIST @V201101 00575000 LH R7,LVLNTH+2 GET LENGTH OF LINE @VA04829 00575500 LA R1,LVLINE GET TYPLIN LIST @V201101 00576000 SVC 202 TYPE THE LINE @V201101 00577000 DC AL4(*+4) ... @V201101 00578000 * 00579000 MVI 0(R10),C' ' PREPARE TO BLANK BUFFER @V201101 00580000 SH R7,=H'2' LESS 2 FOR MVC @V201101 00581000 EX R7,BLNKBUF ... @V201101 00582000 AH R7,=H'2' RESET REG. @V201101 00583000 TM LVSW,MEM USER WANTS MEMBERS LISTED ? @V201101 00584000 BZ GETNXT NO..GET NEXT FORMAT 1 DSCB @V201101 00585000 CLI DSCB1+82-44,PO IS DATA SET PARTITIONED ? @V201101 00586000 BE MEMBERS YES - LIST MEMBERS @VA06395 00587100 CLI DSCB1+82-44,POU IS DATA SET PARTITIONED? @VA06395 00587600 BE MEMBERS YES - LIST MEMBERS @VA06395 00588100 B GETNXT NO - GET NEXT FORMAT 1 DSCB @VA06395 00588600 * 00589000 BLNKBUF MVC 1(0,R10),0(R10) MVC TO BLANK BUFFER @V201101 00590000 * 00591000 CONVERT CVD R9,CVDWK CONVERT TO DECIMAL @V201101 00592000 UNPK UNPKWK(5),CVDWK+3(5) MOVE TO WORK AREA @V201101 00593000 OI UNPKWK+4,X'F0' FIX LAST BYTE @V201101 00594000 LA R1,UNPKWK AREA ADDRESS @V201101 00595000 LA R2,4 AREA LENGHT LESS 1 @V201101 00596000 CHKZERO CLI 0(R1),X'F0' IS BYTE ZERO ? @V201101 00597000 BNE MOVEIT NO..MOVE KEY WORD @V201101 00598000 LA R1,1(0,R1) UP AREA BY ONE @V201101 00599000 BCT R2,CHKZERO KEEP SEARCHING.. @V201101 00600000 CLI 0(R1),X'F0' IS LAST BYTE ZERO ? @V201101 00601000 BCR 8,R14 YES..RETURN @V201101 00602000 BCTR R1,0 PRECEDE ONLY NON-ZERO @V201101 00603000 LA R2,1(,R2) BYTE WITH A ZERO @V201101 00604000 MOVEIT EX R2,KEYMOVE MOVE TO BUFFER @V201101 00605000 BR R14 RETURN TO CALLER @V201101 00606000 * 00607000 KEYMOVE MVC 0(0,R10),0(R1) ... @V201101 00608000 * 00609000 EJECT 1 00610000 *************************************************************** 00611000 * 00612000 * TO PROCESS MEMBERS WE LET 'FIND' ROUTINE IN 00613000 * DMSROS DO THE WORK..UPON RETURN, THE MEMBER 00614000 * NAME WILL BE IN THE FCBMEMBR FIELD OF THE FCB. 00615000 * 00616000 *************************************************************** 00617000 SPACE 1 00618000 MEMBERS LA R1,FINDFDF GET $LISTDS$ FILEDEF LIST @V201101 00619000 IC R3,FMODE SAVE FMODE TEMPORARILY @V201122 00620000 MVC FMODE(1),ADTM SET FMODE TO ADT MODE @V201101 00621000 SVC 202 FILEDEF IT @V201101 00622000 DC AL4(*+4) ... @V201101 00623000 LPR R7,R0 GET FCB ADDRESS @V305114 00624000 USING FCBSECT,R7 FCB ADDRESSABILITY @V305114 00625000 OI FCBIOSW2,FCBMVPDS SET FLAG FOR MEMBER FIND @V201101 00626000 XC FCBMEMBR(8),FCBMEMBR CLEAR MEMBER FIELD @V201101 00627000 LA R1,DSNAME GET DSNAME ADDRESS @V201101 00628000 ST R1,FCBOSDSN SAVE IF FCB @V201101 00629000 MVC STTFM,FMODE SET FILEMODE IS STATE PLIST @V201101 00630000 LA R1,FINDSTT GET STATE PLIST ADDR @V201101 00631000 SVC 202 STATE WITH DSN @V201101 00632000 DC AL4(*+4) ... @V201101 00633000 STC R3,FMODE RESTORE FMODE @V201122 00634000 LR R10,R5 SAVE ADT ADDR. @V201101 00635000 MEMINT LA R2,MNAMES GET MEMBER NAMES BUFFER @V201101 00636000 LA R3,8 GET NUMBER NAMES IN BUFF @V201101 00637000 GETMEM L R15,ADMSROS GET DMSROS ADDRESS @V201101 00638000 LA R9,FCBMEMBR PASS ADDR OF CURRENT MEMBR NA@V201101 00639000 LR R1,R11 SAVE BASE REG FROM DMSROS @V305114 00640000 LR R11,R7 GET FCBSECT ADDRESSABILITY @V305114 00641000 BAL R14,12(,R15) GO TO FIND ROUTINE IN DMSROS @V201101 00642000 LR R11,R1 RESTORE BASE @V305114 00643000 LTR R14,R15 ANY ERRORS ? @V201101 00644000 BNZ TYPELINE YES..GO PRINT BUFFER @V201101 00645000 TM LVSW,MEMHDG MEMBER HEADING TYPED ? @V201101 00646000 BO MEMOK YES..BRANCH @V201101 00647000 LA R1,MEMBER GET MEMBER HEADING @V201101 00648000 STCM R1,B'0111',MEMBUFF+1 SAVE ADDR IN TYPLIN LIST @V201101 00649000 LA R1,L'MEMBER GET LENGTH MEMBER HEADING @V201101 00650000 STCM R1,B'0111',MEMLNTH+1 SAVE LNTH IN TYPLIN LIST @V201101 00651000 LA R1,MEMLINE GET TYPLIN LIST ADDR @V201101 00652000 SVC 202 TYPE MEMBER HEADING @V201101 00653000 DC AL4(*+4) ... @V201101 00654000 OI LVSW,MEMHDG SET MEMBER HDNG TYPED @V201101 00655000 MEMOK MVC 0(8,R2),FCBMEMBR MOVE MEMBER NAME TO BUFFER @V201101 00656000 LA R2,9(,R2) UP BUFFER POINTER @V201101 00657000 BCT R3,GETMEM KEEP SEARCHING @V201101 00658000 EJECT 1 00659000 TYPELINE LA R3,MNAMES GET BEGIN OF BUFFER @V201101 00660000 SR R2,R3 GET LENGTH OF BUFFER @V201101 00661000 LTR R2,R2 ANYTHING IN BUFFER ? @V201101 00662000 BZ POSSEOF NO..DO NOT TYPE LINE @V201101 00663000 STCM R2,B'0111',MEMLNTH+1 SAVE BUFF LNTH IN TYPLIN L@V201101 00664000 STCM R3,B'0111',MEMBUFF+1 SAVE BUFF ADDR IN TYPLIN L@V201101 00665000 LA R1,MEMLINE GET TYPLIN LIST ADDR @V201101 00666000 SVC 202 TYPE MEMBER NAMES @V201101 00667000 DC AL4(*+4) ... @V201101 00668000 POSSEOF LTR R15,R14 ANY RETURN CODE FROM FIND ? @V201101 00669000 BZ MEMINT NO..KEEP LOOKING FOR MEMBERS @V201101 00670000 XC FCBOSDSN,FCBOSDSN CLEAR DSN POINTER IN FCB @V201101 00671000 LR R5,R10 RESTORE ADT ADDR @V201122 00672000 CH R15,H8 I/O ERROR IN FIND ROUTINE ? @V201101 00673000 BE IOERROR YES..GIVE ERROR MSG @V201101 00674000 TM LVSW,MEMHDG ANY MEMBERS FOUND @V201101 00675000 BZ NOMEMS NO..TELL USER @V201101 00676000 SRCHON XC MEMLNTH+1(3),MEMLNTH+1 ZERO LNTH IN TYPLIN LIST@V201122 00677000 LA R1,MEMLINE GET TYPLIN LIST ADDRESS @V201101 00678000 SVC 202 JUST TYPE A NULL LINE @V201101 00679000 DC AL4(*+4) ... @V201101 00680000 NI LVSW,255-DSHDNG TYPE MAIN HEADING FOR NEXT D.@V201101 00681000 B GETNXT RETURN..IT IS EOF @V201101 00682000 EJECT 00683000 FREEREQ EQU * @V305114 00684000 LA R9,DSCB ADDRESS DSCB READ @V305114 00685000 MVC CCHHR(5),NEXTSEEK GET NEXT DSCB @V305114 00686000 CLI DSCB+44,DSCBONE FORMAT 1 DSCB ? @V305066 00687000 BNE FREEFM3 NO ... SEE IF FORMAT 3 @V305114 00688000 SPACE 1 00689000 USING FMT1,R9 @V305114 00690000 LA R3,POSEXT EXTENTS POSSIBLE THIS DSCB @V305066 00691000 MVC XTNUM(1),F1XNUM SAVE NUMBER OF EXTENTS @V305114 00692000 SR R4,R4 CLEAR FOR ICM @V305114 00693000 ICM R4,BIN0001,XTNUM EXTENT COUNT HERE TOO @V305066 00694000 LA R1,X1TYP POINT TO EXTENT TYPE @V305114 00695000 XLOOP CLI 0(R1),SPLITX SPLIT CYLINDERS ? @V305114 00696000 BNE XLOOP1 NO ... BR @V305114 00697000 OI FREEFLG,SPLIT TELL XCALC @V305114 00698000 SPACE 1 00699000 XLOOP1 BAL R14,XCALC SET EXTENT BITS IN TRKMAP @V305114 00700000 CLI 0(R1),LABX LABEL EXTENTS NOT COUNTED @V305114 00701000 BE MOREX IN EXTENT COUNT FIELD @V305114 00702000 BCT R4,MOREX MORE EXTENTS ? @V305114 00703000 B CHKXTNT1 NO ... GET NEXT DSCB @V305114 00704000 MOREX BCT R3,NEXTX YES, GET ALL FROM THIS DSCB ? @V305114 00705000 B CHKXTNT1 YES ... GET NEXT DSCB @V305114 00706000 NEXTX LA R1,10(,R1) BUMP TO NEXT TYPE @V305114 00707000 B XLOOP AND CONTINUE @V305114 00708000 SPACE 1 00709000 FREEFM3 EQU * @V305114 00710000 CLI DSCB+44,FORM3 FORMAT 3 ? @V305066 00711000 BNE CHKXTNT1 NO ... GET ANOTHER ONE @V305114 00712000 SPACE 1 00713000 USING FMT3,R9 @V305114 00714000 LA R3,MAXEXT13 MAX EXTENTS THIS DSCB @V305066 00715000 LA R1,X4TYP POINT TO 1ST FMT3 EXTENT @V305114 00716000 SPACE 1 00717000 F3LOOP CLI 0(R1),CHAR3 WE MUST SKIP OVER @V305066 00718000 BNE NOSKIP THE FMTID BYTE @V305114 00719000 LA R1,1(,R1) .... @V305114 00720000 NOSKIP EQU * @VA09107 00720400 CLI 0(R1),HEX00 NO EXTENT INDICATOR? @VA09107 00720800 BE CHKXTNT1 GET NEXT DSCB @VA09107 00721200 CLI 0(R1),SPLITCYL SPLIT CYLINDER EXTENT? @VA09107 00721600 BNE NOSPLIT NO ... BR @V305114 00722000 OI FREEFLG,SPLIT TELL XCALC @V305114 00723000 SPACE 1 00724000 NOSPLIT BAL R14,XCALC SET EXTENT BITS IN TRKMAP @V305114 00725000 SPACE 1 00728000 MORE3X BCT R3,NEXT3X GET ALL FROM THIS DSCB ? @V305114 00729000 B CHKXTNT1 YES, GET NEXT DSCB @V305114 00730000 NEXT3X LA R1,10(,R1) BUMP EXTENT POINTER @V305114 00731000 B F3LOOP AND CONTINUE @V305114 00732000 EJECT 00733000 ************************************************************** 00734000 * THE TYPFREE ROUTINE SEARCHES THE TRACK MAP FOR FREE SPACE 00735000 * AND ASSEMBLES THE OUTPUT LINES CONTAINING THE FREESPACE 00736000 * EXTENTS FOR THE TERMINAL. 00737000 ************************************************************** 00738000 TYPFREE EQU * @V305114 00739000 ST R5,SAVADT SAVE CURRENT ADT ADDRESS @V305114 00740000 LINEDIT TEXT='FREESPACE EXTENTS FOR ''..'' DISK:',DOT=NO,SUB=(X00741000 CHARA,(ADTM,1)) @V305114 00742000 LA R10,LVBUF ESTABLISH ADDRESSABILITY @V305114 00743000 USING FDATA,R10 FOR DATA LINE BUFFER @V305114 00744000 L R4,MAPAD POINT TO TRACK MAP @V305114 00745000 SR R5,R5 CLEAR CYL NUMBER @V305114 00746000 SR R6,R6 CLEAR HEAD NUMBER @V305114 00747000 LH R8,TRKTOTAL AND NUMBER OF BITS IN TRKMAP @V305114 00748000 INITBIT LA R7,EIGHT INITIALIZE BIT COUNTER @V305066 00749000 LA R9,CON128 INITIALIZE BIT COMPARE REG @V305066 00750000 SPACE 1 00751000 FREELOOP EX R9,FREETM TEST FOR BIT ALLOCATED @V305114 00752000 BO BITON BRANCH IF ALLOCATED @V305114 00753000 OI FREEFLG,SPACE THERE IS SOME SPACE HERE @V305114 00754000 SPACE 1 00755000 TM FREEFLG,HDG HEADING TYPED YET ? @V305114 00756000 BO HDTYPD YES ... BR @V305114 00757000 OI FREEFLG,HDG OTHERWISE, SET THE FLAG.. @V305114 00758000 LA R2,CON41 SET THE HEADING LINE LENGTH @V305066 00759000 LA R3,FHEAD POINT TO THE HEADING @V305114 00760000 BAL R14,TYPF AND TYPE IT @V305114 00761000 SPACE 1 00762000 HDTYPD TM FREEFLG,ON IF SWITCH IS OFF, THIS IS THE @V305114 00763000 BO INFREE 1ST BIT OF A FREE SPACE @V305114 00764000 SPACE 1 00765000 OI FREEFLG,ON TURN SWITCH ON @V305114 00766000 SR R3,R3 INITIALIZE TRACK COUNT @V305114 00767000 LR R1,R5 GET CYL NUMBER @V305114 00768000 STH R1,CYLTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00769000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00770000 MVC LCYL(3),2(R1) AND MOVE TO DATA LINE @V305114 00771000 SPACE 1 00772000 LR R1,R6 GET HEAD NUMBER @V305114 00773000 STH R1,HDTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00774000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00775000 MVC LHD(2),3(R1) AND MOVE TO DATA LINE @V305114 00776000 SPACE 1 00777000 LH R1,TRKCYL NUMBER OF TRACKS PER CYL @V305114 00778000 MH R1,CYLTEMP TIMES CYLINDER NUMBER @V305114 00779000 AH R1,HDTEMP PLUS HEAD NUMBER @V305114 00780000 BAL R14,EDCNT1 UNPACK AND EDIT @V305114 00781000 MVC RELTRK1(5),UNPKWK+3 PLUG RELTRK INTO LINE @V305114 00782000 SPACE 1 00783000 INFREE LA R3,1(,R3) ADD 1 TO TRACK COUNT @V305114 00784000 B NOTFUL GO ADVANCE POINTERS @V305114 00785000 SPACE 1 00786000 BITON EQU * TRACK IS ALLOCATED @V305114 00787000 TM FREEFLG,ON START OF AN ALLOCATED EXTENT ? @V305114 00788000 BNO NOTFUL NO ... BR @V305114 00789000 NI FREEFLG,255-ON RESET THE SWITCH @V305114 00790000 LTR R1,R6 GET HEAD NUMBER @V305114 00791000 BNZ NOADJ IF CURRENTLY 0 ADJUST CYL @V305114 00792000 SPACE 1 00793000 LH R1,TRKCYL GET THE LARGEST HEAD VALUE @V305114 00794000 BCTR R1,R0 ........ @V305114 00795000 STH R1,HDTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00796000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00797000 MVC HHD(2),3(R1) AND MOVE TO DATA LINE @V305114 00798000 LR R1,R5 GET CYLINDER NUMBER @V305114 00799000 BCTR R1,R0 AND DECREMENT @V305114 00800000 STH R1,CYLTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00801000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00802000 MVC HCYL(3),2(R1) AND MOVE TO DATA LINE @V305114 00803000 B SETTRKS GO SET TRKS FIELD @V305114 00804000 SPACE 1 00805000 NOADJ BCTR R1,R0 DECREMENT HEAD NUMBER @V305114 00806000 LASFIL2 STH R1,HDTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00807000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00808000 MVC HHD(2),3(R1) AND MOVE TO DATA LINE @V305114 00809000 LR R1,R5 GET CYLINDER NUMBER @V305114 00810000 STH R1,CYLTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00811000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00812000 MVC HCYL(3),2(R1) AND MOVE TO DATA LINE @V305114 00813000 SPACE 1 00814000 SETTRKS LH R1,TRKCYL TRACKS PER CYLINDER @V305114 00815000 MH R1,CYLTEMP TIMES CYLINDER NUMBER @V305114 00816000 AH R1,HDTEMP PLUS HEAD NUMBER @V305114 00817000 BAL R14,EDCNT1 UNPACK AND EDIT @V305114 00818000 MVC RELTRK2(5),UNPKWK+3 PLUG RELTRKS INTO LINE @V305114 00819000 SPACE 1 00820000 CVD R3,CVDWK MAKE NUMBER OF TRACKS @V305114 00821000 BAL R14,EDCNT3 NOW GO EDIT @V305114 00822000 MVC FTRKS(5),UNPKWK+3 MOVE TO DATA LINE @V305114 00823000 SPACE 1 00824000 LA R2,CON41 SET LINE LENGTH @V305066 00825000 LA R3,LVBUF NOW POINT TO DATA LINE @V305114 00826000 BAL R14,TYPF AND TYPE LINE @V305114 00827000 SPACE 1 00828000 NOTFUL BCTR R8,R0 DECREMENT MAP BIT COUNT @V305114 00829000 LTR R8,R8 IF ZERO ... @V305114 00830000 BZ LASFIL1 WE'RE DONE @V305114 00831000 BM CHKANY MINUS IF END OF PACK FREE @V305114 00832000 SPACE 1 00833000 LA R6,1(,R6) BUMP HEAD NUMBER @V305114 00834000 CH R6,TRKCYL WAS THAT LAST HEAD ON CYL ? @V305114 00835000 BL BITDECR NO ... BR @V305114 00836000 SR R6,R6 YES, ZERO HEAD NUMBER @V305114 00837000 LA R5,1(,R5) AND BUMP THE CYLINDER NUMBER @V305114 00838000 SPACE 1 00839000 BITDECR BCT R7,INBYTE BR IF STILL IN BYTE BOUNDARY @V305114 00840000 LA R4,1(,R4) BUMP MAP POINTER @V305114 00841000 B INITBIT AND INITIALIZE BIT COMPARE REG @V305114 00842000 SPACE 1 00843000 INBYTE SRL R9,1 SHIFT BIT COMPARE REG @V305114 00844000 B FREELOOP AND CHECK NEXT BIT @V305114 00845000 SPACE 1 00846000 LASFIL1 TM FREEFLG,ON LAST TRACK ALLOCATED ? @V305114 00847000 BNO CHKANY YES ... BR @V305114 00848000 LR R1,R6 NECESSARY FOR FREESPACE AT @V305114 00849000 B LASFIL2 END OF PACK @V305114 00850000 SPACE 1 00851000 CHKANY L R5,SAVADT RESTORE ADT POINTER @V305114 00852000 TM FREEFLG,SPACE ANY SPACE AVAILABLE @V305114 00853000 BNO NOSPACE TELL USER ABOUT IT @V305114 00854000 SPACE 1 00855000 FEXIT L R7,MAPAD POINT TO FREE STOR ADDRESS @V305114 00856000 LH R6,MAPNUM AND ITS' LENGTH @V305114 00857000 FREEMAIN R,LV=(6),A=(7) @V305114 00858000 NI FREEFLG,255-(SPACE+HDG+ON) RESET FLAG BITS @V305114 00859000 TM LVSW,ALLOS MULTI-DISK REQUEST ? @V305114 00860000 BO SRCHADTS YES, BR @V305114 00861000 B EXIT NOW EXIT LISTDS @V305114 00862000 SPACE 1 00863000 FREETM TM 0(R4),HEX00 TEST FOR BIT ALLOCATED @V305066 00864000 EJECT 00865000 XTNTREQ EQU * @V305114 00866000 TM XTNTFLG,FM3SW DON'T CHECK FOR END OF VTOC @V305114 00867000 BO SKENDCK IF A FORMAT 3 DSCB IS EXPECTED @V305114 00868000 CLC NEXTSEEK(4),OSADTVTB AT END OF VTOC ? @V305114 00869000 BH PREEXIT YES ... BR @V305114 00870000 SKENDCK LA R9,DSCB POINT TO DSCB READ IN AREA @V305114 00871000 CLI DSCB+44,DSCBONE FORMAT 1 ? @V305066 00872000 BNE CHKFM3X NO ... BR @V305114 00873000 SPACE 1 00874000 OI LVSW,DSFND FOUND A DATA SET @V305114 00875000 USING FMT1,R9 ESTABLISH ADDRESSABILITY @V305114 00876000 MVC TCCHHR(5),NEXTSEEK SAVE FOR NEXT FMT1 SEARCH @V305114 00877000 MVC XTNUM(1),F1XNUM GET NUMBER OF EXTENTS @V305114 00878000 VTOCENT SR R4,R4 ALSO SAVE THAT NUMBER @V305114 00879000 ICM R4,BIN0001,XTNUM .... @V305066 00880000 SPACE 1 00881000 SR R2,R2 SPACE A LINE BETWEEN @V305114 00882000 BAL R14,TYPF GROUPS OF EXTENTS @V305114 00883000 SPACE 1 00884000 LINEDIT SUB=(CHARA,DSNAME,CHARA,(ADTM,1)),TEXT='EXTENT INFORMAX00885000 TION FOR ''............................................'X00886000 ' ON ''..'' DISK:',DOT=NO,RENT=NO @V305114 00887000 LA R2,CON51 SET LINE LENGTH PERMANENTLY @V305066 00888000 LA R3,XHEAD POINT TO EXTENT HEADER @V305114 00889000 BAL R14,TYPF AND TYPE @V305114 00890000 SPACE 1 00891000 LA R3,LVBUF POINT TO DATA AREA @V305114 00892000 USING XDATA,R3 ESTABLISH DSECT ADDRESSABILITY @V305114 00893000 LA R7,X1TYP POINT TO EXTENT TYPE @V305114 00894000 LA R6,MAXEXT3 MAX EXTENTS THIS DSCB @V305066 00895000 SPACE 1 00896000 TYLOOP1 BAL R14,TYLOOP BUILD AND TYPE THE EXTENT DATA @V305114 00897000 CLI 0(R7),LABX LABEL EXTENT NOT COUNTED @V305114 00898000 BE MOREA IN EXTENT COUNT FIELD @V305114 00899000 BCT R4,MOREA BRANCH IF MORE DS EXTENTS @V305114 00900000 B EXEXIT OTHERWISE, WE MAY BE DONE @V305114 00901000 SPACE 1 00902000 MOREA LA R7,10(,R7) BUMP TO NEXT EXTENT @V305114 00903000 BCT R6,TYLOOP1 LOOP IF MORE FMT1 EXTENTS @V305114 00904000 SKIPF2 EQU * RESET AFTER FORMAT2 DSCB @VA09881 00904500 LA R1,RDDSCB3 BETTER CHANGE THE CCW CHAIN @V305114 00905000 ST R1,CHNPROG .... @V305114 00906000 OI XTNTFLG,FM3SW DON'T IGNORE FORMAT 3 DSCB @V305114 00907000 MVC CCHHR(5),F1PTR PLUG FMT3 CCHHR @V305114 00908000 B GOTDSN AND GO GET FMT3 DSCB @V305114 00909000 SPACE 1 00910000 ************************************************************** 00911000 * PROCESS FORMAT 3 DSCB EXTENTS. 00912000 ************************************************************** 00913000 CHKFM3X EQU * @V305114 00914000 TM XTNTFLG,FM3SW EXPECTING A FORMAT 3 DSCB ? @V305114 00915000 BNO EXEXIT NO, JUST LOOKING FOR FORMAT 1 @V305114 00916000 CLI DSCB+44,FORM2 FORMAT 2 DSCB (ISAM)? @VA09881 00916300 BE SKIPF2 YES, SKIP AND GET FORMAT 3 @VA09881 00916600 CLI DSCB+44,FORM3 THIS HAS TO BE A FORMAT 3 DSCB @V305066 00917000 BNE VTOCERR ELSE, ERROR @V305114 00918000 USING FMT3,R9 ESTABLISH ADDRESSABILITY @V305114 00919000 LA R6,MAXEXT13 MAX EXTENTS THIS DSCB @V305066 00920000 LA R7,X4TYP POINT TO 1ST FMT3 EXTENT @V305114 00921000 SPACE 1 00922000 TYLOOP3 BAL R14,TYLOOP BUILD AND TYPE LINE @V305114 00923000 LA R7,10(,R7) BUMP EXTENT POINTER @V305114 00924000 CLI 0(R7),HEXF3 WE MUST SKIP OVER @V305066 00925000 BNE SKFID THE FORMAT IDENTIFIER @V305114 00926000 LA R7,1(,R7) ...... @V305114 00927000 SPACE 1 00928000 SKFID BCT R4,MORE3A ANY EXTENTS LEFT THIS DS ? @V305114 00929000 B EXEXIT NO, WE'RE DONE @V305114 00930000 MORE3A BCT R6,TYLOOP3 MORE THIS DSCB ? @V305114 00931000 MVC CCHHR(5),F3PTR NO,POINT TO NEXT DSCB @V305114 00932000 LA R1,RDDSCB3 POINT TO CCW CHAIN @V305114 00933000 ST R1,CHNPROG FOR FORMAT 3 DSCB @V305114 00934000 OI XTNTFLG,FM3SW FORMAT 3 EXPECTED @V305114 00935000 B GOTDSN AND GET THE NEXT ONE @V305114 00936000 SPACE 1 00937000 EXEXIT TM XTNTFLG,VTOCFLG VTOC JUST LISTED ? @V305114 00938000 BNO NOTVTOC NO ... BR @V305114 00939000 NI XTNTFLG,255-VTOCFLG RESET INDICATOR @V305114 00940000 B CHKXTNT1 AND START GETTING EXTENTS @V305114 00941000 SPACE 1 00942000 NOTVTOC TM LVSW,DSN DSN SPECIFIED ? @V305114 00943000 BO PREEXIT YES ... WE'RE DONE @V305114 00944000 TM XTNTFLG,FM3SW FORMAT 3 DSCB READ ? @V305114 00945000 BNO RDNEXT NO ... BR @V305114 00946000 MVC CCHHR(5),TCCHHR YES, FM3 MAY NOT BE IN @V305114 00947000 B SETCCW SEQUENCE AFTER FM1 @V305114 00948000 SPACE 1 00949000 RDNEXT MVC CCHHR(5),NEXTSEEK POINT TO NEXT CCHHR @V305114 00950000 SETCCW NI XTNTFLG,255-FM3SW RESET FM3 FLAG @V305114 00951000 LA R1,RDDSCB1 SET UP FOR SEARCH FOR @V305114 00952000 ST R1,CHNPROG NEXT FORMAT 1 DSCB @V305114 00953000 B CHKXTNT1 NOW GET IT @V305114 00954000 SPACE 1 00955000 EJECT 00956000 ************************************************************** 00957000 * TYLOOP RECEIVES A POINTER TO A SET OF EXTENTS AND BUILDS 00958000 * A DATA LINE FOR OUTPUT TO THE TERMINAL. IT THEN CALLS THE 00959000 * TYPF ROUTINE TO TYPE TO THE TERMINAL. 00960000 ************************************************************** 00961000 TYLOOP EQU * @V305114 00962000 ST R14,RETSAVE SAVE THE RETURN ADDRESS @VA07903 00962070 USING EXTNT,R7 @VA06034 00962140 CLI DSCB+44,DSCBONE IS THIS A FORMAT 1 LABEL? @VA06034 00962280 BNE XTNTLOOP NO, DON'T LOOK FOR A MODEL DSCB @VA06034 00962420 CLI TYPX,MODL IS THIS ONE A MODEL DSCB? @VA06034 00962560 BNE XTNTLOOP NO, BUILD EXTENT DATA @VA06034 00962700 MVI XDATA,BLANK MOVE BLANK TO FIRST BYTE @VA09250 00962790 MVC XDATA+1(50),XDATA RESET FIELD TO BLANKS @VA09250 00962880 MVC XTYPE(5),MCONST INDICATE MODEL DSCB WITH @VA06034 00962980 MVI XTRKS+4,CHAR0 NO TRACKS USED @VA06034 00963120 LA R4,EXT1 USE SAME COUNT AS SINGLE EXTENT @VA06034 00963260 B SETYP TYPE OUTPUT LINE @VA06034 00963400 SPACE 00963540 XTNTLOOP EQU * @VA06034 00963680 SR R1,R1 CLEAR FOR ICM @V305114 00965000 ICM R1,BIN0001,SEQX GET SEQUENCE NUMBER @V305066 00966000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00967000 MVC XSEQ(3),2(R1) PLUG INTO DATA LINE @V305114 00968000 SPACE 1 00969000 SR R1,R1 CLEAR FOR ICM @V305114 00970000 ICM R1,BIN0011,LCYLX GET LOW CYLINDER @V305066 00971000 STH R1,CYLTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00972000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00973000 MVC XLCYL(3),2(R1) PLUG INTO DATA LINE @V305114 00974000 SPACE 1 00975000 SR R1,R1 CLEAR FOR ICM @V305114 00976000 ICM R1,BIN0011,LHDX GET LOW HEAD @V305066 00977000 STH R1,HDTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00978000 BAL R14,CNVRT CONVERT TO PRINTABE FORM @V305114 00979000 MVC XLHD(2),3(R1) PLUG INTO DATA LINE @V305114 00980000 SPACE 1 00981000 LH R1,TRKCYL TRACKS PER CYLINDER @V305114 00982000 MH R1,CYLTEMP TIMES TRACK NUMBER @V305114 00983000 AH R1,HDTEMP PLUS HEAD NUMBER @V305114 00984000 BAL R14,EDCNT1 CONVERT AND EDIT @V305114 00985000 MVC XRTRK1(5),UNPKWK+3 PLUG INTO LINE @V305114 00986000 SPACE 1 00987000 SR R1,R1 CLEAR FOR ICM @V305114 00988000 ICM R1,BIN0011,HCYLX GET HIGH CYLINDER @V305066 00989000 STH R1,CYLTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00990000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00991000 MVC XHCYL(3),2(R1) PLUG INTO DATA LINE @V305114 00992000 SPACE 1 00993000 SR R1,R1 CLEAR FOR ICM @V305114 00994000 ICM R1,BIN0011,HHDX GET HIGH HEAD @V305066 00995000 STH R1,HDTEMP SAVE FOR RELATIVE TRACK CALC @V305114 00996000 BAL R14,CNVRT CONVERT TO PRINTABLE FORM @V305114 00997000 MVC XHHD(2),3(R1) PLUG INTO DATA LINE @V305114 00998000 SPACE 1 00999000 LH R1,TRKCYL TRACKS PER CYLINDER @V305114 01000000 MH R1,CYLTEMP TIMES TRACK NUMBER @V305114 01001000 AH R1,HDTEMP PLUS HEAD NUMBER @V305114 01002000 BAL R14,EDCNT1 CONVERT AND EDIT @V305114 01003000 MVC XRTRK2(5),UNPKWK+3 PLUG INTO LINE @V305114 01004000 SPACE 1 01005000 CLI TYPX,SPLITX SPLIT CYLINDER EXTENT ? @V305114 01006000 BNE NOTSPLT NO ... BR @V305114 01007000 OI FREEFLG,SPLIT LET XCALC KNOW @V305114 01008000 NOTSPLT LR R1,R7 USE THE XCALC @V305114 01009000 BAL R14,XCALC ROUTINE TO GIVE US THE NUMBER @V305114 01010000 SPACE 1 01011000 LR R1,R8 TRANSFER NUMBER OF TRACKS @V305114 01012000 BAL R14,EDCNT1 CONVERT AND EDIT @V305114 01013000 MVC XTRKS(5),UNPKWK+3 PLUG INTO LINE @V305114 01014000 SPACE 1 01015000 MVC XTYPE(5),DCONST PLUG DATA TYPE @V305114 01016000 TM 0(R7),DATX DATA EXTENT ? @V305114 01017000 BO SETYP YES ... BR @V305114 01018000 MVC XTYPE(5),SCONST PLUG SPLIT CYL TYPE @V305114 01019000 CLI 0(R7),SPLITX SPLIT CYL EXTENT ? @V305114 01020000 BE SETYP YES ... BR @V305114 01021000 MVC XTYPE(5),LCONST PLUG LABEL CONSTANT @V305114 01022000 CLI 0(R7),LABX USER LABEL EXTENT ? @V305114 01023000 BE SETYP YES ... BR @V305114 01024000 MVC XTYPE(5),ICONST PLUG INDEX TYPE @V305114 01025000 CLI 0(R7),INDX INDEX EXTENT ? @V305114 01026000 BE SETYP YES ... BR @V305114 01027000 MVC XTYPE(5),VTOC PLUG VTOC TYPE @V305114 01028000 TM XTNTFLG,VTOCFLG VTOC EXTENT ? @V305114 01029000 BO SETYP YES ... BR @V305114 01030000 MVC XTYPE(5),OCONST MUST BE ISAM OVFLO @V305114 01031000 SPACE 1 01032000 SETYP LA R3,XDATA POINT TO DATA LINE @V305114 01033000 BAL R14,TYPF AND TYPE IT @V305114 01034000 L R14,RETSAVE RESTORE THE RETURN REG @V305114 01035000 BR R14 RETURN TO CALLER @V305114 01036000 DROP R7 @V305114 01037000 SPACE 1 01038000 ************************************************************** 01039000 * FILLMAP SETS BITS ON IN THE TRACK MAP ACCORDING TO THE 01040000 * FOLLOWING INPUT: 01041000 * R7 = DISPLACEMENT INTO TRKMAP OF THE 1ST BIT 01042000 * R8 = NUMBER OF TRACKS IN THE EXTENT 01043000 ************************************************************** 01044000 FILLMAP EQU * @V305114 01045000 LA R3,CON8 CONSTANT FOR DIVIDE + 1ST BYTE @V305066 01046000 SR R6,R6 CLEAR FOR DIVIDE @V305114 01047000 DR R6,R3 CALC TRKMAP BYTES + REMAINDER @V305114 01048000 SPACE 1 01049000 L R4,MAPAD POINT TO 1ST BYTE @V305114 01050000 AR R7,R4 AFFECTED BY THIS EXTENT @V305114 01051000 LA R4,CON128 SET SHIFT BIT @V305066 01052000 SRL R4,0(R6) TO 1ST TRACK BIT @V305114 01053000 SR R3,R6 CALC BITS SETTABLE IN 1ST BYTE @V305114 01054000 B GETBYT 1ST BIT IS ALREADY SET @V305114 01055000 SPACE 1 01056000 SHFTBIT SRL R4,1 SHIFT 'OR' BIT FOR NEXT TRACK @V305114 01057000 GETBYT ICM R1,BIN0001,0(R7) GET TRKMAP BYTE @V305066 01058000 OR R1,R4 TURN ON BIT @V305114 01059000 STCM R1,BIN0001,0(R7) SET TRKMAP BYTE @V305066 01060000 SPACE 1 01061000 BCT R8,CHKBIT GET OUT IF ALL BITS ARE SET @V305114 01062000 BR R14 ----- @V305114 01063000 CHKBIT BCT R3,SHFTBIT THROUGH WITH THIS BYTE ? @V305114 01064000 LA R4,CON128 YES, RESET 'OR' BIT @V305066 01065000 LA R7,1(,R7) UPDATE BYTE POINTER @V305114 01066000 LA R3,EIGHT AND RESET BIT COUNT @V305066 01067000 B GETBYT STAY IN LOOP @V305114 01068000 SPACE 1 01069000 ************************************************************** 01070000 * XCALC USES THE LOW AND HIGH EXTENTS OF A FORMAT 1 OR 01071000 * FORMAT 3 DSCB TO CALCULATE THE NUMBER OF TRACKS IN THE 01072000 * EXTENT AND THE BIT DISPLACEMENT OF THE 1ST ALLOCATED 01073000 * BIT INTO THE TRACK MAP. IT CALLS FILLMAP TO EXECUTE THE 01074000 * TRACK MAP ALLOCATION. 01075000 * UPON ENTRY REG1 POINTS TO THE 10 BYTE EXTENT FIELD. 01076000 ************************************************************** 01077000 XCALC EQU * @V305114 01078000 USING EXTNT,R1 @V305114 01079000 STM R9,R7,0(R13) SAVE CALLERS REGS @V305114 01080000 SR R2,R2 CLEAR .. @V305114 01081000 SR R3,R3 REGISTERS .. @V305114 01082000 SR R7,R7 FOR .. @V305114 01083000 SR R8,R8 ICM @V305114 01084000 ICM R7,BIN0011,LCYLX GET LOW CYLINDER @V305066 01085000 ICM R8,BIN0011,HCYLX AND HIGH CYLINDER @V305066 01086000 SR R8,R7 CALC POSSIBLE FULL CYLS @V305114 01087000 SPACE 1 01088000 SR R4,R4 CLEAR LOW EXTENT OVERLAP @V305114 01089000 ICM R2,BIN0011,LHDX GET LOW HEAD @V305066 01090000 ICM R3,BIN0011,HHDX AND HIGH HEAD @V305066 01091000 SPACE 1 01092000 LTR R8,R8 CHECK FOR VALID EXTENT @V305114 01093000 BM XTNTERR1 ...... @V305114 01094000 BP XTNTOK ...... @V305114 01095000 CR R2,R3 ...... @V305114 01096000 BH XTNTERR1 ...... @V305114 01097000 SPACE 1 01098000 XTNTOK LA R3,1(,R3) BUMP HIGH HH BY ONE @V305114 01099000 CR R2,R3 HIGH HH = OR > LOW HH ? @V305114 01100000 BH XCALC1 NO ... BR, CALC BOTH OVERLAPS @V305114 01101000 SR R3,R2 CALC TRKS OVER CYL BOUNDARY @V305114 01102000 B ADTRKS ......... @V305114 01103000 DROP R1 @V305114 01104000 SPACE 1 01105000 XCALC1 BCTR R8,R0 DECREMENT CYL COUNT @V305114 01106000 LH R4,TRKCYL TRKS PER CYL MINUS LOW HH @V305114 01107000 SR R4,R2 PLUS 1 = LOW EXTENT OVERLAP @V305114 01108000 SPACE 1 01110000 ADTRKS AR R4,R3 LOW + HIGH OVERLAP TRKS @V305114 01111000 TM FREEFLG,SPLIT SPLIT CYLINDERS ? @V305114 01112000 BO SCALC YES ...BR @V305114 01113000 MH R8,TRKCYL CALC TRACKS IN FULL CYLINDERS @V305114 01114000 AR R8,R4 ADD OVERLAP TRACKS @V305114 01115000 TM LVSW,XTNTSW EXTENT REQUEST ? @V305114 01116000 BO XEXIT YES ... BR @V305114 01117000 SPACE 1 01118000 MH R7,TRKCYL GET DISPL IN BITS OF @V305114 01119000 AR R7,R2 1ST ALLOCATED BIT @V305114 01120000 BAL R14,FILLMAP SET ALLOCATED TRACK BITS @V305114 01121000 XEXIT NI FREEFLG,255-SPLIT RESET SPLIT CYL INDICATOR @V305114 01122000 LM R9,R7,0(R13) RESTORE REGS @V305114 01123000 BR R14 RETURN TO CALLER @V305114 01124000 SPACE 1 01125000 SCALC EQU * FOR SPLIT CYLINDERS ONLY @V305114 01126000 LA R5,1(R8) BUMP FOR LOOP COUNT @V305114 01127000 STH R4,STRKCYL SAVE SPLIT TRKS PER CYL @V305114 01128000 LR R9,R7 SAVE FOR INCREMENT @V305114 01129000 TM LVSW,XTNTSW EXTENT REQUEST ? @V305114 01130000 BNO SLOOP NO ... BR @V305114 01131000 LA R8,1(,R8) BUMP CYL NUMBER FOR CALC @V305114 01132000 MH R8,STRKCYL CALC NUMBER OF TRACKS @V305114 01133000 B XEXIT AND RETURN @V305114 01134000 SPACE 1 01135000 SLOOP MH R7,TRKCYL CALC DISPLACEMENT IN BITS @V305114 01136000 AR R7,R2 OF 1ST ALLOCATED BIT @V305114 01137000 LH R8,STRKCYL SET TRKS PER CYL @V305114 01138000 BAL R14,FILLMAP SET A CYL WORTH OF BITS @V305114 01139000 LA R9,1(,R9) BUMP CYLINDER NUMBER @V305114 01140000 LR R7,R9 TRANSFER FOR FILLMAP @V305114 01141000 BCT R5,SLOOP DO FOR EACH SPLIT CYL @V305114 01142000 B XEXIT RETURN TO CALLER @V305114 01143000 EJECT 01144000 TYPF EQU * @V305114 01145000 STCM R2,BIN0111,LVLNTH+1 SET LENGTH @V305066 01146000 STCM R3,BIN0111,LVBUFF+1 AND ADDRESS OF LINE @V305066 01147000 LA R1,LVLINE POINT TO PLIST @V305114 01148000 SVC 202 AND TYPE @V305114 01149000 DC AL4(*+4) ...... @V305114 01150000 BR R14 RETURN TO CALLER @V305114 01151000 SPACE 1 01152000 CNVRT EQU * @V305114 01153000 CVD R1,CVDWK CONVERT @V305114 01154000 UNPK UNPKWK(5),CVDWK+3(5) TO PRINTABLE @V305114 01155000 OI UNPKWK+4,SIGN FORM ... @V305066 01156000 LA R1,UNPKWK POINT TO IT AND @V305114 01157000 BR R14 RETURN @V305114 01158000 SPACE 1 01159000 EDCNT1 EQU * @V305114 01160000 CVD R1,CVDWK CONVERT AND @V305114 01161000 EDCNT3 MVC UNPKWK(8),PATTERN EDIT LEADING @V305114 01162000 ED UNPKWK(8),HALF ZEROES @V305114 01163000 BR R14 RETURN TO CALLER @V305114 01164000 SPACE 1 01165000 *************************************************************** 01166000 * 01167000 * DISK I/O SUBROUTINE 01168000 * 01169000 *************************************************************** 01170000 SPACE 1 01171000 DISKIO L R1,CCHHR GET SEARCH INFO @V201101 01172000 ST R1,SEEK+2 AND USE IT FOR SEEKING AS WELL @V201101 01173000 ST R1,NEXTSEEK SAVE TRACK ADDRESS CURRENTLY IN V@V201101 01174000 LH R1,OSADTDSK GET DEVICE ADDRESS @V201101 01175000 XC CSW(8),CSW RESET CSW @V201101 01176000 DC X'83100020' DIAGNOSE READ TO CP @V201101 01177000 BC 8,8(,R14) NORMAL RETURN..ALL OK @V201101 01178000 BC 4,VTOCERR DISK NOT ATTACHED @V201101 01179000 BC 2,4(,R14) INCORR LENGTH OR UNIT EXEC @V201101 01180000 STH R0,SNSEDATA UNIT CHECK @V201101 01181000 BR R14 RETURN @V201101 01182000 SPACE 1 01183000 *************************************************************** 01184000 * 01185000 * TEST INFORMATION RETURNED BY SENSE FOR UNEXPECTED STAT 01186000 * 01187000 *************************************************************** 01188000 SPACE 1 01189000 CHKSENSE TM SNSEDATA,X'FD' ANYTHING BUT TRACK CONDITION @V201101 01190000 BNZ VTOCERR YES..VTOC I/O ERROR @V201101 01191000 TRKBYTE TM SNSEDATA+1,X'D6' ALLOW CYLEND, NOREC, OVERINC @V201101 01192000 BNZ VTOCERR VTOC I/O ERROR @V201101 01193000 MVC SNSEBYTE(1),SNSEDATA MAKE A COMPOUND BYTE @V201101 01194000 OC SNSEBYTE(1),SNSEDATA+1 OUT OF BOTH FOR EASY INSP@V201101 01195000 BR R14 NOW RETURN TO CALLER @V201101 01196000 SPACE 1 01197000 *************************************************************** 01198000 * 01199000 * INCREMENT DASD ADDRESS TO TRK 0, REC 0 OF NEXT CYL 01200000 * 01201000 *************************************************************** 01202000 SPACE 1 01203000 INCRCYL LH R1,CCHHR GET CYLINDER ADDRESS @V201101 01204000 LA R1,1(,R1) ADD ONE TO IT @V201101 01205000 SLL R1,16 CREATE CCHH WITH HEAD ZERO @V201101 01206000 ST R1,CCHHR PUT INTO SEARCH DATA AREA @V201101 01207000 STC R1,CCHHR+4 R0 ON TRK 0 BECOMES TARGET @V201101 01208000 BR R14 RETURN TO USER @V201101 01209000 EJECT 1 01210000 *************************************************************** 01211000 * 01212000 * CHANNEL PROGRAMS FOR DISK PACK FORMATTED FOR OS 01213000 * 01214000 *************************************************************** 01215000 SPACE 1 01216000 RDDSCB1 CCW 7,SEEK,CC,6 CONTROL - SEEK @V201101 01217000 CCW 31,MASK,CC,1 CONTROL - SET FILE MASK @V201101 01218000 CCW 49,CCHHR,CC,5 SEARCH - ID EQUAL @V201101 01219000 CCW 8,*-8,CC+SLI,1 CONTROL - T.I.C. @V201101 01220000 CCW 146,NEXTSEEK,CC,8 READ - COUNT (M-T ON) @V201101 01221000 CCW 14,DSNAME,0,140 READ - KEY AND DATA @V305114 01222000 SPACE 1 01223000 RDDSCB1K CCW 7,SEEK,CC,6 CONTROL - SEEK @V201101 01224000 CCW 31,MASK,CC,1 CONTROL - SET FILE MASK @V201101 01225000 CCW 49,CCHHR,CC,5 SEARCH - ID EQUAL @V201101 01226000 CCW 8,*-8,CC+SLI,1 CONTROL - T.I.C. @V201101 01227000 CCW 146,NEXTSEEK,CC,8 READ - COUNT (M-T ON) @V201101 01228000 CCW 41,DSNAME,CC,44 SEARCH - KEY EQUAL @V201101 01229000 CCW 8,*-16,CC+SLI,1 CONTROL - T.I.C. @V201101 01230000 CCW 6,DSCB1,0,96 READ - DATA @V305114 01231000 SPACE 1 01232000 RDDSCB3 CCW 7,SEEK,CC,6 SEEK FORMAT 3 DSCB @V305114 01233000 CCW 31,MASK,CC,1 SET FILE MASK @V305114 01234000 CCW 49,CCHHR,CC,5 SEARCH ID EQUAL @V305114 01235000 CCW 8,*-8,CC+SLI,1 TIC @V305114 01236000 CCW 14,DSNAME,0,140 READ KEY + DATA @V305114 01237000 EJECT 1 01238000 * 01239000 BADMODE LR R2,R1 GET MODE ADDRESS @V201101 01240000 DMSERR TEXT='INVALID MODE ''........''', @V201101*01241000 NUM=048,LET=E,SUB=(CHARA,(R2)) @V201101 01242000 B RET24 GO SET RETURN CODE @V305114 01243000 * 01244000 BADMODE2 TM ADTFLG1,ADTFRO+ADTFRW CMS DISK? @VA02610 01245000 BZ BADMODE3 NO @VA02610 01246000 LA R1,FMODE GET FILEMODE ADDRESS @VA02610 01247000 B BADMODE GIVE ERROR MSG @VA02610 01248000 BADMODE3 LA R2,FMODE GET FILEMODE @VA02610 01249000 DMSERR TEXT='DISK ''........'' NOT ACCESSED', @VA02610*01250000 NUM=069,LET=E,SUB=(CHARA,(R2)) @VA02610 01251000 LA R10,36 GET RETURN CODE @VA02610 01252000 B LEAVE EXIT @VA02610 01253000 * 01254000 BADDSN EQU * @V201101 01255000 DMSERR TEXT='INVALID DATA SET NAME',NUM=221,LET=E @V201101 01256000 B RET24 GO SET RETURN CODE @V305114 01257000 EJECT 1 01258000 * 01259000 NOFMODE EQU * @V201101 01260000 DMSERR TEXT='NO FILEMODE SPECIFIED',NUM=223,LET=E @V201101 01261000 B RET24 GO SET RETURN CODE @V305114 01262000 * 01263000 XTNTERR1 EQU * @V305114 01264000 DMSERR TEXT='INVALID EXTENT FOUND FOR ''......................X01265000 ......................'' ON ''..'' DISK',NUM=227,LET=W,SX01266000 UB=(CHARA,DSNAME,CHARA,(ADTM,1)),RENT=NO @V305114 01267000 LA R10,RCFOUR SAVE RETURN CODE FOR LATER @VM03219 01268000 ST R10,RCSAVE ..... @VM03219 01269000 B XEXIT AND CONTINUE @VM03219 01270000 SPACE 1 01271000 FREERR EQU * @V305114 01272000 DMSERR TEXT='NO DATA SET NAME ALLOWED WITH FREE OPTION',NUM=22X01273000 6,LET=E @V305114 01274000 B RET24 GO SET RETURN CODE @V305114 01275000 SPACE 1 01276000 BADOPT LR R2,R1 GET OPTION ADDRESS @V201101 01277000 DMSERR TEXT='INVALID OPTION ''........''',NUM=003,LET=E, *01278000 SUB=(CHARA,(R2)) @V201101 01279000 SPACE 1 01280000 RET24 EQU * @V305114 01281000 LA R10,TWENTY4 SET RETURN CODE 24 @V305066 01282000 B LEAVE AND USE COMMON EXIT @V305114 01283000 NOMEMS EQU * @V201101 01284000 DMSERR TEXT='NO MEMBERS FOUND',LET=I,NUM=229 @V305114 01285000 B GETNXT RETURN.. @V201101 01286000 SPACE 1 01287000 NOSPACE EQU * @V305114 01288000 DMSERR TEXT='NO FREE SPACE AVAILABLE ON ''..'' DISK',NUM=233,LX01289000 ET=I,SUB=(CHARA,(ADTM,1)) @V305114 01290000 B FEXIT NOW FREE UP STORAGE @V305114 01291000 EJECT 1 01292000 * 01293000 IOERROR EQU * @V201101 01294000 DMSERR NUM=222,LET=E,SUB=(CHARA,DSNAME,CHARA,(ADTM,1)), X01295000 TEXT='I/O ERROR READING ''..............................*01296000 ..............'' FROM ''..'' DISK',RENT=NO @V305114 01297000 LA R10,28 GET RETURN CODE @VA13586 01298000 B LEAVE RETURN.. @VA13586 01298300 * 01299000 VTOCERR EQU * @V201101 01300000 DMSERR NUM=231,LET=E,SUB=(CHARA,FMODE), @V201101*01301000 TEXT='I/O ERROR READING VTOC FROM ''....'' DISK' 01302000 LA R10,28 GET RETURN CODE @V201101 01303000 B LEAVE RETURN.. @V201101 01304000 EJECT 1 01305000 * 01306000 DSNMSG EQU * @V201101 01307000 DMSERR TEXT='ENTER DATA SET NAME:',LET=R,NUM=220,DOT=NO 01308000 BR R14 @V201101 01309000 * 01310000 TSTDSNF TM LVSW,DSFND WAS ANY DATA SET FOUND ? @VA05780 01311000 BO EXIT YES, NOT AN ERROR, JUST EOF @VA04298 01316200 DMSERR TEXT='DATA SET NOT FOUND',NUM=002,LET=E @V201101 01317000 LA R10,28 GET RETURN CODE @V201101 01318000 B LEAVE RETURN.. @V201101 01319000 SPACE 1 01320000 PREEXIT TM LVSW,ALLOS ALL DISKS REQUESTED ? @V305114 01321000 BNO EXIT NO, WE'RE ALL THROUGH @V305614 01322000 TM LVSW,FREESW FREE SPECIFIED ? @V305614 01323000 BO SRCHADTS YES, BACK TO LOOP @V305614 01324000 TM LVSW,DSN DATA SET NAME SPECIFIED ? @V305614 01325000 BNO SRCHADTS NO, BACK TO LOOP @V305614 01326000 * 01327000 EXIT L R10,RCSAVE GET RETURN CODE @VM03219 01328000 * 01329000 LEAVE EQU * @V201101 01330000 MVC DOSFLAGS(1),SAVDOS RESTORE DOSFLAGS @V305114 01331000 DMSKEY RESET ENABLE NUCLEUS PROTECT @V201101 01332000 * 01333000 LA R1,FINDCLR GET FILEDEF CLEAR LIST ADDR @V201101 01334000 SVC 202 CLEAR $LISTDS$ FILEDEF @V201101 01335000 DC AL4(*+4) ... @V201101 01336000 LR R15,R10 GET RETURN CODE @V201101 01337000 L R14,SAVR14 GET RETURN ADDR @V201101 01338000 BR R14 RETURN TO CALLER @V201101 01339000 EJECT 1 01340000 *************************************************************** 01341000 * 01342000 * CONSTANTS AND STORAGE AREAS 01343000 * 01344000 *************************************************************** 01345000 SPACE 1 01346000 DS 0D @V305114 01347000 CVDWK DS 1F CONVERT TO DECIMAL WORK AREA @V305114 01348000 HALF DS 1F EDIT FROM HERE @V305114 01349000 UNPKWK DS 1D UNPACK WORK AREA @V201101 01350000 CCHHR DC 2H'0',X'02',X'00' DISK SEARCH ADDRESS @V201101 01351000 NEXTSEEK DS 2F DISK ADDRESS FOR NEXT SEEK @V201101 01352000 SNSEDATA DC 6X'00' SENSE INFO. FOR DISK ERRORS @V201101 01353000 H45 DC H'45' CONSTANT TO CONTROL DSNAME LE@V201101 01354000 H8 DC H'8' CONSTANT TO CONTROL I/O ERROR@V201101 01355000 SEEK DC H'0' DISK SEEK ADDRESS @V201101 01356000 DS 1F DITTO @V201101 01357000 SAVR14 DS 1F RETURN REGISTER SAVE AREA @V201101 01358000 SAVADT DS 1F ADDRESS OF CURRENT ADT @V305114 01359000 CHNPROG DS 1F ADDRESS OF CURRENT CHAN PROG @V201101 01360000 MAPAD DS 1F TRACK MAP ADDRESS @V305114 01361000 MAPNUM DS 1H TRACK MAP BYTE COUNT @V305114 01362000 TRKTOTAL DS 1H TOTAL TRACKS THIS DISK @V305114 01363000 TRKCYL DS 1H TRACKS PER CYLINDER @V305114 01364000 STRKCYL DS 1H SPLIT TRACKS PER CYLINDER @V305114 01365000 XTNUM DS 1X NUMBER OF EXTENTS FOR A DS @V305114 01366000 TCCHHR DS 5X SAVE AREA FOR NEXT FMT1 SEARCH @V305114 01367000 SAVDOS DS 1X SAVE AREA FOR DOSFLAGS @V305114 01368000 SPACE 1 01369000 T2314 EQU X'08' 2314 DEVICE TYPE @V305114 01370000 T3330 EQU X'09' 3330 DEVICE TYPE @V305114 01371000 T333B EQU X'05' 3330-11 DEVICE TYPE @V505098 01371500 T3380 EQU X'0E' 3380 DEVICE TYPE HRC004DS 01371700 DSCB DS 0D @V305114 01372000 DSNAME DC 44C' ' FORMAT 1 DSCB KEY @V201101 01373000 DSCB1 DS 24F REST OF DSCB @V201101 01374000 RETSAVE DC F'0' SAVE AREA FOR A RETURN ADDRESS @V305114 01375000 RCSAVE DC F'0' RETURN CODE SAVE AREA @VM03219 01376000 PATTERN DC X'4020202020202021' PATTERN FOR EDIT @V305114 01377000 MASK DC B'01010000' SET FILE MASK CONTROL @V201101 01378000 SNSEBYTE DC X'00' SENSE INFO. FOR DISK ERRORS @V201101 01379000 MEMBER DC CL13'MEMBER NAMES:' TYPED MSG FOR MEMBERS @V201101 01380000 FORMAT DC CL8'FORMAT' OPTION FOR EXTENDED INFO. @V201101 01381000 FO DC CL8'FO' ABBREV. OF ABOVE @V201101 01382000 PDS DC CL4'PDS' OPTION TO TYPE MEMBERS OF PO @V201101 01383000 FREE DC CL5'FREE' OPTION FOR FREE SPACE DISPLAY @V305114 01384000 XTNT DC CL7'EXTENT' OPTION FOR DSN EXTENT DISPLAY @V305114 01385000 EX DC CL4'EX' EXTENT ABBREVIATION @V305114 01386000 VTOC DC C'VTOC ' DSNAME FOR VTOC EXTENT @V305114 01387000 DCONST DC C'DATA ' FOR EXTENT DATA LINE @V305114 01388000 SCONST DC C'SPLIT' FOR EXTENT DATA LINE @V305114 01389000 LCONST DC C'LABEL' FOR EXTENT DATA LINE @V305114 01390000 ICONST DC C'INDEX' FOR EXTENT DATA LINE @V305114 01391000 OCONST DC C'OVFLO' FOR EXTENT DATA LINE @V305114 01392000 MCONST DC C'MODEL' FOR EXTENT DATA LINE @VA06034 01392500 SPACE 1 01393000 *************************************************************** 01394000 * 01395000 * SOME COMMONLY USED EQUATES 01396000 * 01397000 *************************************************************** 01398000 SPACE 1 01399000 ABLE EQU C'A' @V201101 01400000 ZEBRA EQU C'Z' @V201101 01401000 BLANK EQU C' ' @V201101 01402000 LPAR EQU C'(' @V201101 01403000 RPAR EQU C')' @V201101 01404000 DOT EQU C'.' @V201101 01405000 STAR EQU C'*' @V201101 01406000 SLASH EQU C'/' @V201101 01407000 FENCE EQU X'FF' @V201101 01408000 * 01409000 F EQU X'80' FIXED @V201101 01410000 V EQU X'40' VARIABLE @V201101 01411000 U EQU X'C0' UNDEFINED @V201101 01412000 B EQU X'10' BLOCKED @V201101 01413000 S EQU X'08' SPANNED @V201101 01414000 T EQU X'20' TRACK OVERFLOW @V201101 01415000 A EQU X'04' ASA CONTROL CHAR. @V201101 01416000 M EQU X'02' MACHINE CONTROL CHAR. @V201101 01417000 EJECT 1 01418000 * 01419000 DSORGS DC X'8000',CL4'IS' INDEX SEQUENTIAL @V305114 01420000 DC X'4000',CL4'PS' PHYSICAL SEQUENTIAL @V305114 01421000 DC X'2000',CL4'DA' DIRECT ACCESS @V305114 01422000 DC X'0300',CL4'POU' PARTITIONED UNMOVEABLE @VA06395 01422500 DC X'0200',CL4'PO' PARTITIONED ORGANIZATION @V305114 01423000 DC X'0100',CL4'U' UNMOVABLE @V305114 01424000 DC X'0008',CL4'VSAM' VSAM @V305114 01425000 * 01426000 LVHEAD DC C'RECFM LRECL BLKSI DSORG DATE LABEL FM ' @V201101 01427000 DC C'DATA SET NAME ' @V201101 01428000 * 01429000 LVBUF EQU * DATA SET INFO. TO BE TYPED @V201101 01430000 LVREC DC CL6' ' RECORD FORMAT @V201101 01431000 LVLRL DC CL6' ' RECORD LENGTH @V201101 01432000 LVBLK DC CL6' ' BLOCK SIZE @V201101 01433000 LVDSO DC CL6' ' DATA SET ORGANIZATION @V201101 01434000 LVMM DC CL2' ' DATE - MONTH @V201101 01435000 LVSL1 DC CL1' ' @V201101 01436000 LVDD DC CL2' ' DATE - DAY @V201101 01437000 LVSL2 DC CL1' ' @V201101 01438000 LVYY DC CL3' ' DATE - YEAR @V201101 01439000 LVLAB DC CL7' ' DISK LABEL @V201101 01440000 LVMOD DC CL3' ' DISK FILE MODE @V201101 01441000 LVDSN DC CL44' ' DATA SET NAME @V201101 01442000 LVEND EQU * END OF INFO. @V201101 01443000 * 01444000 JAN DC H'31' DAYS IN JANUARY @V201101 01445000 FEB DC H'29' DAYS IN FEBRARY @V201101 01446000 DC H'31',H'30',H'31',H'30',H'31' MARCH - JULY @V201101 01447000 DC H'31',H'30',H'31',H'30',H'31' AUGUST - DECEM@V201101 01448000 * 01449000 HDTEMP DC H'0' RELATIVE TRACK SAVE AREA @V305114 01450000 CYLTEMP DC H'0' RELATIVE TRACK SAVE AREA @V305114 01451000 FHEAD DC C'CYL-HD(RELTRK) TO CYL-HD(RELTRK) TRACKS' @V305114 01452000 XHEAD DC C'SEQ TYPE CYL-HD(RELTRK) TO CYL-HD(RELTRK) TRACKS' 01453000 LVSW DC X'00' LIST VTOC SWITCH @V201101 01454000 DSHDNG EQU X'80' DATA SET HEADING TYPED @V201101 01455000 DSN EQU X'40' SEARCH BY DSNAME KEY @V201101 01456000 ALLOS EQU X'20' SEARCH ALL ADTS @V201101 01457000 MEM EQU X'10' PDS OPTION SPECIFIED @V201101 01458000 MEMHDG EQU X'08' MEMBER HEADING TYPED @V201101 01459000 RTPAREN EQU C')' PARENTHESES @V305066 01460000 LTPAREN EQU C'(' LEFT PAREN @V305066 01461000 LEN70 EQU 70 OUTPUT LENGTH @V305066 01462000 LEN30 EQU 30 OUTPUT LENGTH @V305066 01463000 DSCBONE EQU C'1' FORMAT 1 DSCB @V305066 01464000 POSEXT EQU 3 POSSIBLE EXTENTS WITH DSCB @V305066 01465000 BIN0001 EQU B'0001' MASK @V305066 01466000 BIN0011 EQU B'0011' MASK @V305066 01467000 BIN0111 EQU B'0111' MASK @V305066 01468000 FORM3 EQU C'3' FORMAT 3 DSCB @V305066 01469000 FORM2 EQU C'2' FORMAT 2 DSCB NOT SUPPORTED @VA09881 01469500 MAXEXT3 EQU 3 MAX EXTENTS - 3 @V305066 01470000 MAXEXT13 EQU 13 MAX EXTENTS - 13 @V305066 01471000 CHAR3 EQU C'3' ... @V305066 01472000 SPLITCYL EQU X'80' SPLIT CYLINDER EXTENT @V305066 01473000 EIGHT EQU 8 INITIALIZE BIT COUNTER @V305066 01474000 RCFOUR EQU 4 WARNING RETURN CODE @VM03219 01475000 CON128 EQU 128 INITIALIZE BIT COMPARE REG @V305066 01476000 CON41 EQU 41 HEADING LINE LEN @V305066 01477000 HEX00 EQU X'00' ... @V305066 01478000 CON51 EQU 51 LINE LENGTH - PERMANENT @V305066 01479000 HEXF3 EQU X'F3' ... @V305066 01480000 CON8 EQU 8 CONSTANT FOR DIVIDE @V305066 01481000 SIGN EQU X'F0' PRINTABLE CHAR @V305066 01482000 TWENTY4 EQU 24 RETURN CODE @V305066 01483000 TWENTY8 EQU 28 RETURN CODE @V305066 01484000 CON20 EQU 20 TRKS/CYL - 2314 @V305066 01485000 CON19 EQU 19 TRKS/CYL - 3330 @V305066 01486000 CON15 EQU 15 TRKS/CYL - 3380 HRC004DS 01486500 CON12 EQU 12 TRKS/CYL - 3340 @V305066 01487000 CON30 EQU 30 3350 TRK/CYL @VA06168 01487300 T3350 EQU X'0B' 3350 DEVICE TYPE CODE @VA06168 01487400 SEQ0 EQU X'0' ZERO EXT SEQ NUMBER @V305066 01488000 EXT1 EQU X'1' ONE EXTENT @V305066 01489000 HEX80 EQU X'80' ... @V305066 01490000 LOOP7 EQU 7 LOOP COUNTER @VA06395 01491100 DSFND EQU X'04' DATA SET FOUND @V201101 01492000 XTNTSW EQU X'02' EXTENT OPTION SPECIFIED @V305114 01493000 FREESW EQU X'01' FREE SPACE OPTION SPECIFIED @V305114 01494000 CHAR0 EQU C'0' ZERO CHARACTER @VA06034 01494500 SPACE 1 01495000 FREEFLG DC X'00' FREE OPTION FLAGS @V305114 01496000 ON EQU X'80' LAST BIT TESTED WAS ALLOCATED @V305114 01497000 SPACE EQU X'40' FREE SPACE DETECTED THIS DISK @V305114 01498000 HDG EQU X'20' HEADING WAS TYPED @V305114 01499000 SPLIT EQU X'10' SPLIT CYLINDER ALLOCATION @V305114 01500000 ANY EQU X'08' SOME FREE SPACE AVAILABLE @V305114 01501000 SPACE 1 01502000 XTNTFLG DC X'00' EXTENT OPTION FLAGS @V305114 01503000 FM3SW EQU X'80' FORMAT 3 DSCB EXPECTED @V305114 01504000 VTOCFLG EQU X'40' VTOC EXTENT BEING TYPED @V305114 01505000 EJECT 1 01506000 * 01507000 DS 0D @V201101 01508000 LVLINE DC CL8'TYPLIN' TYPE DATA SET INFO. @V201101 01509000 LVBUFF DC AL1(1),AL3(0) @V201101 01510000 LVLNTH DC CL1'B',AL3(0) @V201101 01511000 * 01512000 DS 0D @V201101 01513000 MEMLINE DC CL8'TYPLIN' TYPE MEMBERS OF PO @V201101 01514000 MEMBUFF DC AL1(1),AL3(0) @V201101 01515000 MEMLNTH DC CL1'B',AL3(0) @V201101 01516000 * 01517000 DS 0D @V201101 01518000 CONRD DC CL8'CONREAD' READ DSNAME FROM CONSOLE @V201101 01519000 DC AL1(1),AL3(DSNAME) @V201101 01520000 CONCNT DC CL1'U',AL3(0) @V201101 01521000 * 01522000 DS 0D @V201101 01523000 FINDFDF DC CL8'FILEDEF' FILEDEF FOR MEMBERS @V201101 01524000 DC CL8'$LISTDS$' @V201101 01525000 DC CL8'DISK' @V201101 01526000 DC CL8'$LISTDS$' @V201101 01527000 DC CL8'CMSUT1' @V201101 01528000 FMODE DC CL8' ' @V201101 01529000 DC 8X'FF' @V201101 01530000 * 01531000 DS 0D @V201101 01532000 FINDCLR DC CL8'FILEDEF' FILEDEF CLEAR FOR ABOVE @V201101 01533000 DC CL8'$LISTDS$' @V201101 01534000 DC CL8'CLEAR' @V201101 01535000 DC 8X'FF' @V201101 01536000 * 01537000 DS 0D @V201101 01538000 FINDSTT DC CL8'STATE' STATE TO TIE UP FST @V201101 01539000 DC CL8'$LISTDS$' @V201101 01540000 DC CL8'CMSUT1' @V201101 01541000 STTFM DC CL4' ' @V201101 01542000 DC A(0) @V201101 01543000 * 01544000 MNAMES DC CL72' ' MEMBER NAMES BUFFER @V201101 01545000 EJECT 1 01546000 LTORG @V201101 01547000 SPACE 1 01548000 CD EQU X'80' CHAIN DATA @V201101 01549000 CC EQU X'40' CHAIN COMMAND @V201101 01550000 SLI EQU X'20' SUPPRESS LENGTH IND. @V201101 01551000 SKIP EQU X'10' SKIP COMMAND @V201101 01552000 SPACE 1 01553000 DATX EQU X'01' DATA FLAG IN EXTENT TYPE @V305114 01554000 SPLITX EQU X'80' SPLIT CYL FLAG IN EXTENT TYPE @V305114 01555000 LABX EQU X'40' LABEL FLAG IN EXTENT TYPE @V305114 01556000 INDX EQU X'04' INDEX FLAG IN EXTENT TYPE @V305114 01557000 MODL EQU X'00' MODEL DSCB FLAG @VA06034 01557500 SPACE 1 01558000 FMT1 DSECT @V305114 01559000 DS CL51 @V305114 01560000 VOLSEQ1 DS 2X NUMBER OF VOL IN MULTIVOL FILE @V305114 01561000 DS CL6 @V305114 01562000 F1XNUM DS X NUMBER OF EXTENTS FOR THIS FILE @V305114 01563000 DS CL45 @V305114 01564000 X1TYP DS X TYPE OF EXTENT @V305114 01565000 X1SEQ DS X EXTENT SEQUENCE NUMBER @V305114 01566000 X1LCC DS 2X LO CYL LIMIT @V305114 01567000 X1LHH DS 2X LO HEAD LIMIT @V305114 01568000 X1HCC DS 2X HI CYL LIMIT @V305114 01569000 X1HHH DS 2X HI HEAD LIMIT @V305114 01570000 X2TYP DS X TYPE OF EXTENT @V305114 01571000 X2SEQ DS X SEQUENCE NUMBER OF EXTENT @V305114 01572000 X2LCC DS 2X LO CYL LIMIT @V305114 01573000 X2LHH DS 2X LO HEAD LIMIT @V305114 01574000 X2HCC DS 2X HI CYL LIMIT @V305114 01575000 X2HHH DS 2X HI HEAD LIMIT @V305114 01576000 X3TYP DS X TYPE OF EXTENT @V305114 01577000 X3SEQ DS X SEQUENCE NUMBER OF EXTENT @V305114 01578000 X3LCC DS 2X LO CYL LIMIT @V305114 01579000 X3LHH DS 2X LO HEAD LIMIT @V305114 01580000 X3HCC DS 2X HI CYL LIMIT @V305114 01581000 X3HHH DS 2X HI HEAD LIMIT @V305114 01582000 F1PTR DS 5X CCHHR NEXT LABEL OF THIS FILE @V305114 01583000 SPACE 1 01584000 FMT3 DSECT @V305114 01585000 DS CL4 @V305114 01586000 X4TYP DS X TYPE OF EXTENT @V305114 01587000 X4SEQ DS X SEQUENCE NUMBER FO THIS EXTENT @V305114 01588000 X4LCC DS 2X LO CYL LIMIT @V305114 01589000 X4LHH DS 2X LO HEAD LIMIT @V305114 01590000 X4HCC DS 2X HI CYL LIMIT @V305114 01591000 X4HHH DS 2X HI HEAD LIMIT @V305114 01592000 DS CL121 @V305114 01593000 F3PTR DS 5X CCHHR OF FOLLOWING FMT 3 @V305114 01594000 SPACE 1 01595000 FDATA DSECT @V305114 01596000 LCYL DS 3C LOW CYLINDER NUMBER @V305114 01597000 DS 1C @V305114 01598000 LHD DS 2C LOW HEAD NUMBER @V305114 01599000 DS 2C @V305114 01600000 RELTRK1 DS 5C RELATIVE TRACK @V305114 01601000 DS 5C @V305114 01602000 HCYL DS 3C HIGH CYLINDER NUMBER @V305114 01603000 DS 1C @V305114 01604000 HHD DS 2C HIGH HEAD NUMBER @V305114 01605000 DS 2C @V305114 01606000 RELTRK2 DS 5C RELATIVE TRACKS @V305114 01607000 DS 5C @V305114 01608000 FTRKS DS 5C NUMBER OF EXTENT TRACKS @V305114 01609000 SPACE 1 01610000 XDATA DSECT @V305114 01611000 XSEQ DS 3C SEQUENCE NUMBER @V305114 01612000 DS 1C @V305114 01613000 XTYPE DS 4C EXTENT TYPE @V305114 01614000 DS 2C @V305114 01615000 XLCYL DS 3C LOW CYLINDER @V305114 01616000 DS 1C @V305114 01617000 XLHD DS 2C LOW HEAD @V305114 01618000 DS 2C @V305114 01619000 XRTRK1 DS 5C RELATIVE TRACK NUMBER @V305114 01620000 DS 5C @V305114 01621000 XHCYL DS 3C HIGH CYLINDER @V305114 01622000 DS 1C @V305114 01623000 XHHD DS 2C HIGH HEAD @V305114 01624000 DS 2C @V305114 01625000 XRTRK2 DS 5C RELATIVE TRACK NUMBER @V305114 01626000 DS 5C @V305114 01627000 XTRKS DS 5C NUMBER OF TRACKS @V305114 01628000 SPACE 1 01629000 EXTNT DSECT @V305114 01630000 TYPX DS X EXTENT TYPE @V305114 01631000 SEQX DS X EXTENT SEQUENCE NUMBER @V305114 01632000 LCYLX DS 2X LOW CYLINDER @V305114 01633000 LHDX DS 2X LOW HEAD @V305114 01634000 HCYLX DS 2X HIGH CYLINDER @V305114 01635000 HHDX DS 2X HIGH HEAD @V305114 01636000 EJECT 01637000 NUCON @V201101 01638000 ADT @V201101 01639000 CMSCB @V201101 01640000 REGEQU @V201101 01641000 END 01642000