1 Assembler C9208 DISKTOTAPE -- Offline Disk to Tape Backup 28-Sep-93 11:12 PAGE 1 ($$$LOGO.) F 2 2 INPUT $$$LOGO. 1 2 3 4 5 6 7 8 9 10 * ......... BBBBBBBBBBBBBBBBBB TTTTTTTTTTTTTTTTTTTTTTTT IIIIIIIIIIII 11 * ................. BBBBBBBBBBBBBBBBBBBBB TTTTTTTTTTTTTTTTTTTTTTTT IIIIIIIIIIII 12 * ..........##......... BBBBBBBBBBBBBBBBBBBBBB TTTTTTTTTTTTTTTTTTTTTTTT IIIIIIIIIIII 13 * ............##........... BBBBBB BBBBBB TTTTTT TTTTTT TTTTTT IIIIII 14 * .............##............ BBBBBB BBBBBB TTTTT TTTTTT TTTTT IIIIII 15 * .............##............ BBBBBB BBBBBBB TTTT TTTTTT TTTT IIIIII 16 * ..............##............. BBBBBBBBBBBBBBBBBBB TTTTTT IIIIII 17 * ..............##............. BBBBBBBBBBBBBBBBB TTTTTT IIIIII 18 * ..............##............. BBBBBBBBBBBBBBBBBBB TTTTTT IIIIII 19 * .............##.............. BBBBBB BBBBBB TTTTTT IIIIII 20 * ...........##.............. BBBBBB BBBBBB TTTTTT IIIIII 21 * ..........##............... BBBBBB BBBBBB TTTTTT IIIIII 22 * ........##............... BBBBBB BBBBBBB TTTTTT IIIIII 23 * .....##.............. BBBBBBBBBBBBBBBBBBBBBBBB TTTTTTTTTTTT IIIIIIIIIIII 24 * ................. BBBBBBBBBBBBBBBBBBBBBBB TTTTTTTTTTTT IIIIIIIIIIII 25 * ......... BBBBBBBBBBBBBBBBBBBB TTTTTTTTTTTT IIIIIIIIIIII 26 * 27 * 28 * ****** Copyright 1982, 1983, 1984, 1985, 1986, 1987, 1988, 29 * 1989, 1990, 1991, 1992 BTI Computer Systems ****** 30 * 31 * This document and the program it describes are the exclusive property 32 * of and proprietary to BTI Computer Systems. No use, reproduction, or 33 * disclosure of this document or its contents, either in full or in part, 34 * by any means whatsoever regardless of purpose may be made without the 35 * prior written consent of BTI Computer Systems. 36 * 37 * BTI Computer Systems 38 * Sunnyvale, California 94086 3 4 5 * DDDD III SSS K K TTTTT OOO TTTTT A PPPP EEEEE 6 * D D I S S K K T O O T A A P P E 7 * D D I S K K T O O T A A P P E 8 * D D I SSS KK T O O T AAAAA PPPP EEEE 9 * D D I S K K T O O T A A P E 10 * D D I S S K K T O O T A A P E 11 * DDDD III SSS K K T OOO T A A P EEEEE 12 13 14 DISKTOTAPE BLOCK entire DISKTOTAPE 15 16 INPUT DISKTOTAPE.OPSYS:REVISIONS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 2 (REVISIONS) F 3 Revisions 4 5 ********************************************************************************** 6 * * 7 * revisions date * 8 * --------- ---- * 9 * A8506 30 Jun 85 * 10 * Original release. * 11 * A8601 21 Jan 86 * 12 * Modifications for tiny RAFs. * 13 * A8603 11 Mar 86 * 14 * Changes for new FDE field FDRAFTYPE. * 15 * A8607 11 Jul 86 * 16 * Multiple fixes to prevent dying on * 17 * residual parity errors. Fix to WRITEGAP * 18 * routine to make variable length gaps * 19 * work correctly. Correction to MERRTAB * 20 * to reflect controller microcode rev 5 * 21 * error codes. Fix in tape driver to * 22 * recognize data path parity error during * 23 * writes to CT. Other minor changes. * 24 * A8608 29 Aug 86 * 25 * Re-assembly to include new TALON. * 26 * Change to IOR protect bit with CPP in * 27 * OSHEADER. RC * 28 * A8611 30 Nov 86 * 29 * Mods to pass TBMNONE element clear * 30 * through to tape write process. * 31 * HALT codes individualized and moved to * 32 * HALTDEFS. RC * 33 * A8612 03 Dec 86 * 34 * Physical record size determined separately * 35 * for 9 track and cartridge drives now. RC * 36 * A8703 31 Mar 87 * 37 * Reassembled with slightly different support * 38 * routines. RC * 39 * A8712 17 Dec 87 * 40 * Checksums added to physical tape records. RC * 41 * A8803 04 Mar 88 * 42 * Mods to FBI flag check in PageIn. RC * 43 * A8803a 07 Mar 88 * 44 * Mods to traverse IDX in ascending order. RC * 45 * A8805 27 May 88 * 46 * Added entries to OPENERRTAB (VOPENDISK). DH * 47 * A8901 20 Jan 89 * 48 * Mods to work with VT, including re-assembly * 49 * to pick up new TALON. RC * 50 * A8902 01 Feb 89 * 51 * Fixes to VOLLOGREC to include the BKUPHDRW2 * 52 * lengths. RC * 53 * A8905 23 May 89 * 54 * Changes so that variables are initialized when * 55 * program is run. Allows multiple runs without * 56 * reloading program, primarily for test purposes. RC * 57 * A8907 18 Jul 89 * 58 * Fix to not set SSU alarm bit with front panel * 59 * messages. JB * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 3 (REVISIONS) F 3 Revisions 60 * A8907a 20 Jul 89 * 61 * Fix to print proper error message on disk or tape * 62 * open error. Includes new tape driver. RC * 63 * A8907b 23 Jul 89 * 64 * Reassembled to get new tape driver. RC * 65 * A8911 01 Nov 89 * 66 * Fix to READFILE to not copy a file if either the * 67 * no-backup or file-being-destroyed indicators are * 68 * set. * 69 * A9003 14 Mar 90 * 70 * Changed PAGEIN to check FBIDEFFLAGS instead of * 71 * FBIFLAGS. CG * 72 * A9108 02 Aug 91 * 73 * Changes made to work with SCSI disk drives. * 74 * * 75 ********************************************************************************** 76 41393130 ABS 77 REVHIGH EQU "A910" 38202020 ABS 78 REVLOW EQU "8 " 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 4 F 0 19 20 ********************************************************************************** 21 * * 22 * DISKTOTAPE * 23 * * 24 * This program runs offline under OPL. It does a dump of * 25 * the contents of a disk to mag tape (9 track, cartridge, or VT). * 26 * The resulting dump is compatible with +BACKUP. It can be * 27 * recovered using the TAPERECOVER program and, if it is a dump * 28 * of a system volume, can be booted from. * 29 * * 30 * DISKTOTAPE is divided into four processes: Disk Reading, * 31 * Physical Record Packing, Encryption, and Tape Writing. * 32 * * 33 ********************************************************************************** 34 35 36 ********************************************************************************** 37 * * 38 * MEMORY MANAGEMENT * 39 * * 40 * Memory is managed on a page by page basis. For each page * 41 * of physical memory used there is a memory control block (MCB). * 42 * This is a 16 word block which contains the page map value for * 43 * its physical page and will contain a disk block's FBI and * 44 * other pertinent information about the page's contents. * 45 * DISKTOTAPE initializes up to 500 MCBs for use. If any of * 46 * the processes need a page of memory it takes an MCB from the * 47 * free page queue. Similarly, when a process is finished with a * 48 * page it replaces that MCB in the free page queue. Each process * 49 * is responsible for allowing enough free pages within the * 50 * system to prevent deadlock from occurring. A counter is kept * 51 * of the number of free pages available and is incremented and * 52 * decremented when appropriate. This may be used by a process * 53 * to determine if there is enough memory to continue. * 54 * * 55 ********************************************************************************** 56 57 58 ********************************************************************************** 59 * * 60 * TAPEBOOTMAKE * 61 * * 62 * If the volume being backed up is a system pack we * 63 * must put some special files on the beginning of the tape * 64 * to allow the tape to be booted from. Online backup chains * 65 * to a program called TAPEBOOTMAKE which performs this task. * 66 * Since we cannot chain to this program we must instead simulate * 67 * it. The first thing the read process does is determine if * 68 * there is an Offline.!!! account on the volume being backed * 69 * up. If so then the necessary files are read and passed * 70 * onward. Once the last file is read a special MCB is * 71 * linked into the PRPQ indicating the tapebootmake stuff is * 72 * finished. This record is linked in immediately if there is * 73 * no Offline.!!! account. A special packing is done of these * 74 * pages and also a different encryption is used. After * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 5 F 0 75 * TAPEBOOTMAKE is finished then we run in normal mode. * 76 * * 77 ********************************************************************************** 78 79 80 ********************************************************************************** 81 * * 82 * DISK READING * 83 * * 84 * The disk is read by following the tree structure set up * 85 * by the operating system. Since RAF and code data may be * 86 * written to tape in any order RAF Minor Access Blocks and Code * 87 * Control Blocks are sorted into the optimal order for speed * 88 * reading of the disk. * 89 * Since only one CPU may be reading from the disk at any * 90 * time, a lock is held by the CPU currently doing the disk * 91 * reading. This CPU continues reading from the disk as long as * 92 * there is a minimum number of free pages of memory available to * 93 * read into (RMINPAGES). * 94 * Pages read are placed on the end of the physical record * 95 * packing queue (PRPQ) with the exception of the Operating * 96 * System control structures. Most of these control structures * 97 * are not placed onto the backup tape except for the first * 98 * identifying portions. Since the control structures are * 99 * necessary for the disk reading process, it keeps the block * 100 * containing the control structures and moves the necessary * 101 * information required by the packing process into a new page * 102 * and puts the new (abbreviated) page into the PRPQ. * 103 * Each file directory entry is placed in a physical * 104 * record element (PREL) by the reading process and linked * 105 * onto the PRPQ before data associated with that FDE is read * 106 * and linked onto the PRPQ. * 107 * * 108 ********************************************************************************** 109 110 111 ********************************************************************************** 112 * * 113 * PHYSICAL RECORD PACKING * 114 * * 115 * The blocks in the PRPQ are packed into physical records, * 116 * encrypted if necessary, and written onto tape. The blocks * 117 * are always taken from the head of the PRPQ to be packed. * 118 * Each physical record must go onto the tape in the order * 119 * that the physical records are created. When a physical record * 120 * is packed it is marked either "encrypt" or "don't encrypt". All * 121 * physical records when packed are placed, in order, on the end * 122 * of the encrypt queue. The encrypt process then encrypts them * 123 * if necessary and moves them to the tape write queue in order. * 124 * Each physical record has a physical record element * 125 * (PREL) associated with it. A PREL is a 25 word structure that * 126 * contains the physical record sequence number, a pointer to the * 127 * next PREL, and pointers to the MCBs that control the blocks of * 128 * memory used by its physical record. The PREL is what is put * 129 * into the encryption and tape write queues. * 130 * PRELS are also used to contain file directory entries * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 6 F 0 131 * which are placed in the PRPQ. This is used by the packing * 132 * process to determine when a new file is starting and to * 133 * construct the header for the file logical record. * 134 * Physical records may be of varying size dependent upon * 135 * the type of tape medium being used. The absolute limits of * 136 * size for the physical records are set by the operating system. * 137 * Those limits are: * 138 * for DEI, 4.5 blocks minus 2 words. * 139 * for 9 track and VT, 12 blocks. * 140 * However, the actual sizes used here are determined by several * 141 * factors, including (for DEI) the length of tape between the * 142 * EOT warning and the hard EOT. The sizes used are: * 143 * 9 track, 3 pages + 080 words * 144 * VT, 3 pages + 0100 words * 145 * DEI, 2 pages + 080 words * 146 * Physical records contain a variable number of logical * 147 * records. If blocks requiring encryption are being packed into * 148 * physical records and the next block to be packed does not * 149 * require encryption, or vice versa then the current physical * 150 * record is ended and a new one started. Otherwise physical * 151 * records are packed to contain the maximum number of actual * 152 * data blocks, plus all relevant header trash, that will fit in * 153 * the actual physical record. * 154 * * 155 ********************************************************************************** 156 157 ********************************************************************************** 158 * * 159 * ENCRYPTION * 160 * * 161 * For security purposes all BTI furnished software, * 162 * Operating System control structures, and specified customer * 163 * data are encrypted. This is a time consuming and independent * 164 * process so multiple CPUs may be encrypting concurrently. * 165 * Physical records are encrypted in chunks up to 4 pages long, * 166 * and all but the first few words of header information * 167 * is encrypted. * 168 * A CPU doing encryption starts at the head of the * 169 * encryption queue and continues downward until a physical * 170 * record is found that is not currently being encrypted. * 171 * Once a record is found that is not being encrypted it is * 172 * marked "encrypt in progress", is encrypted if necessary, * 173 * and then marked "encrypt done". * 174 * If the physical record just marked done is at the head * 175 * of the encrypt queue it is moved to the end of the tape write * 176 * queue. All queue entries directly following it are checked * 177 * to see if they are finished being encrypted and, if so, are * 178 * also moved to the tape write queue, until an entry is found * 179 * that is not encrypted yet. * 180 * * 181 ********************************************************************************** 182 183 ********************************************************************************** 184 * * 185 * TAPE WRITING * 186 * * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 7 F 0 187 * Physical records are placed into the tape write queue in * 188 * the order that they should be written to the tape. Whenever * 189 * there is an entry in the tape write queue it can be written. * 190 * Only one CPU may be writing to tape at a time so it must * 191 * hold a lock. The goal is to keep this CPU constantly writing * 192 * once it starts. This CPU will not look for another process to * 193 * perform until all entries in the tape write queue have been * 194 * written to tape and their memory is added to the free page list. * 195 * * 196 ********************************************************************************** 197 198 ********************************************************************************** 199 * * 200 * SCHEDULING * 201 * * 202 * The goal in scheduling optimally is to keep one CPU * 203 * constantly reading blocks from the disk, and one CPU * 204 * constantly writing physical records to tape. All other * 205 * available CPUs should be packing or encrypting physical * 206 * records. * 207 * * 208 * Algorithm For a Free CPU * 209 * * 210 * 1. If no one is reading the disk and there is enough free * 211 * memory (and the disk has not been exhausted) then read * 212 * the disk. * 213 * 2. If no one is packing physical records and there is something * 214 * available to pack, then pack physical records. * 215 * 3. Encrypt if something exists and is ready to be encrypted. * 216 * After each physical record is encrypted check the ratio of * 217 * encrypt queue entries to tape write queue entries. If this * 218 * is less than a 1 to 10 ratio, and no CPU is writing to tape * 219 * or reading from disk then return to the scheduler. * 220 * 4. If no one is writing to tape and there is at least one PREL * 221 * in the write queue then run the tape writer. * 222 * * 223 * Except for the encrypt process, when a CPU starts a process * 224 * it remains in that process until some necessary resource is * 225 * exhausted, then continues with the next step in the algorithm. * 226 * Note that the minimum number of pages allowed for a process * 227 * to continue is initially set higher for the extra pages required * 228 * for tapebootmake encryption. Once the tapebootmake stuff is * 229 * done we change the minimum page variables to reflect this. * 230 * * 231 ********************************************************************************** 232 233 START2 DISKTOTAPE 234 235 NOLIST CREF 236 INPUT $$$MACROS 1 * Including MACROS.ASSEM Version A8607. 237 INPUT SOURCE.OPSYS:MACHDEFS 238 INPUT SOURCE.OPSYS:IODEFS 239 INPUT OPSYS.SCSIDR:SCSIDEFS 240 INPUT SOURCE.OPSYS:DISKDEFS 241 INPUT SOURCE.OPSYS:PAGEDEFS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 8 (IBLOCK) F 10 242 INPUT SOURCE.OPSYS:IBLOCK 243 INPUT SOURCE.OPSYS:HALTDEFS 244 INPUT SOURCE.OPSYS:OPRQINFOMACS 245 LIST CREF 246 INPUT BOOT.OPSYS:OPLVECTORS 247 INPUT BOOT.OPSYS:DISKCB 248 INPUT BOOT.OPSYS:TAPECB 249 INPUT TAPERECOVER.OPSYS:TRTAPEDEFS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 9 (TRTAPEDEFS) F 16 Backup Format Definitions 3 4 ********************************************************************************** 5 * * 6 * This file defines the format for the backup tapes. * 7 * Note that the +BACKUP program uses its own definitions * 8 * file and these definitions must match. * 9 * The backup program is written so that it is * 10 * independant of the internal format of the data manipulated * 11 * by the operating system backup/recover requests. In order * 12 * to keep order among the various accounts and things, it * 13 * adds a considerable amount of format, identifying, and * 14 * other header information to each logical record that the * 15 * system returns. This information is pretty much duplicated * 16 * within the OS created logical records, so much of what the * 17 * backup program adds is ignored by TAPERECOVER. However * 18 * DISKTOTAPE must put in all the same information that * 19 * +BACKUP does in order to keep compatibility. * 20 * TAPERECOVER does need to know what 'type' of logical * 21 * record it is recovering, so it uses the record type * 22 * (RTYPExxx) that the backup program added. This is the * 23 * only datum, available for each logical record, that * 24 * determines how much header information needs to be skipped * 25 * before getting to the actual data contained in the logical * 26 * record. There is a record type provided with the OS * 27 * information but we must know what type of backup record we * 28 * have before we can find the OS record. * 29 * * 30 ********************************************************************************** 31 32 ********************************************************************************** 33 * * 34 * This is the format for the physical record header. * 35 * Each physical record is made up of a header followed by * 36 * logical record(s). There is no limit to the number of * 37 * logical records contained by a physical record and a * 38 * logical record may stretch over many physical records. * 39 * The physical record is encrypted as a whole (except for * 40 * the first part of the header) if any of the logical * 41 * record(s) contained within must be encrypted. The * 42 * physical record is assigned a sequence number and is * 43 * written on the tape as a single record in the proper * 44 * sequence. * 45 * * 46 ********************************************************************************** 47 00000400 48 PHSRECHDR BASE R0 00160800 0 BASE 49 PHSSEQNUM BSS 1 sequence number in this "file set" 00160801 0 BASE 50 OPHSREQCNT BSS 1 PHSREQCNT in versions 5 and below... 51 * unused in versions 6 and above 00160802 0 BASE 52 PHSFLAGWRD BSS 1 00080012 0 ZBM 53 PHSNCRYPTD EQU PHSFLAGWRD/BIT 0 on sez physical record encrypted 00080212 0 ZBM 54 PHSFILEDO EQU PHSFLAGWRD/BIT 1 on sez no critical info here 55 * (just file data) 00000003 ABS 56 PHSNOESIZE EQU DISPW PHSSEQNUM size of part never encrypted 57 * ****** record beyond here may be encrypted 00001000 ABS 58 MAXENCRSIZ EQU 4*WPP maximum block size that can be encrypted 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 10 (TRTAPEDEFS) F 16 Backup Format Definitions 00160803 0 BASE 59 PHSENCSTRT BSS 0 beginning of encrypted area 00160803 0 BASE 60 PHSDSEQNUM BSS 1 duplicate sequence number 61 * (used to verify decrypt) 00160804 0 BASE 62 PHSCKSUM BSS 1 checksum of physical record, before 63 * encrypt and after decrypt 00160805 0 BASE 64 PHSREQCNT BSS 1 number of words at the beginning of ... 65 * ... this physical record continued ... 66 * ... from last logical record 00000001 ABS 67 PHSFILLSIZ EQU 1 size of filler in physical record 00160806 0 BASE 68 PHSFILLER BSS PHSFILLSIZ filler to ensure minimum encrypt size 69 * (must be zero filled) 00000004 ABS 70 PHSEHDRSIZ EQU DISPW PHSDSEQNUM size of encrypted header 00160807 0 BASE 71 PHSLOGDATA BSS 0 start of logical data 72 DRCT 00000007 ABS 73 PHSHDRLEN EQU DISPW PHSRECHDR length of physical record header 74 ORG PHSRECHDR 75 76 77 ********************************************************************************** 78 * This is the format of the header for each logical * 79 * record. Other information is appended to this header for * 80 * different types of logical records. * 81 ********************************************************************************** 82 00000400 83 LOGRECHDR BASE R0 00160800 0 BASE 84 LOGRECCWD BSS 1 +BACKUP made logical record header word 00080010 0 ZBM 85 LOGRECOSQ EQU LOGRECCWD/BIT 0 flag to say that backup info. is out of order 00080210 0 ZBM 86 LOGRECBZY EQU LOGRECCWD/BIT 1 flag to say backup info. missing 00081650 0 ZBM 87 LOGRECTYP EQU LOGRECCWD/BITS 11:15 logical record type 00000000 ABS 88 RTYPESET EQU 0 file set header 00000001 ABS 89 RTYPEESET EQU 1 end of file set 00000002 ABS 90 RTYPESWCH EQU 2 end of tape or tape track 00000003 ABS 91 RTYPEVOL EQU 3 volume information record 00000004 ABS 92 RTYPEACC EQU 4 account information record 00000005 ABS 93 RTYPEFIL EQU 5 file information record 00000006 ABS 94 RTYPEFP EQU 6 file data information record 00000007 ABS 95 RTYPEERR EQU 7 error was encountered in backup 00000008 ABS 96 RTYPEFLR EQU 8 filler record type 00000008 ABS 97 MAXRECTYP EQU 8 maximum for logical record types 00082100 0 ZBM 98 LOGRECIFL EQU LOGRECCWD/BITS 16:31 length of this logical record 99 DRCT 00000001 ABS 100 LOGHDRLEN EQU DISPW LOGRECHDR length of logical record header 101 ORG LOGRECHDR 102 103 104 105 ********************************************************************************** 106 * * 107 * 'Tape Strings' are used to record character strings in * 108 * logical record headers. They are variable length thus making * 109 * any logical record header containing them variable and adding * 110 * a degree of complexity to our record unpacking algorithms. * 111 * Tape Strings are used to aid in recovering from errors when a * 112 * file name or account name is needed. * 113 * Tape strings are variable length but will always be an * 114 * integral number of words. The length of a tape string is * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 11 (TRTAPEDEFS) F 16 Backup Format Definitions 115 * found in its first character. * 116 * * 117 ********************************************************************************** 118 00000000 ABS 119 TS EQU 0 marker used in logical record 120 headers for a tapestring 121 00000400 122 TAPSTRDEF BASE R0 00160000 0 CACH 123 TAPSTRCHS BSSC 1 the first character is the length 124 DRCT 125 ORG TAPSTRDEF 126 127 128 ********************************************************************************** 129 * * 130 * Following the rest of a logical record header is the * 131 * actual data that was returned to BACKUP by the relevant * 132 * operating system backup request. This buffer is preceeded * 133 * by a single word that indicates its length. * 134 * * 135 ********************************************************************************** 136 00000400 137 TAPHDR1000 BASE R0 00160800 0 BASE 138 OSINFOSIZ BSS 1 length of OS returned information 00160801 0 BASE 139 OSINFO BSS 0 where this stuff starts 140 DRCT 00000001 ABS 141 TAPHDR1000L EQU DISPW TAPHDR1000 142 ORG TAPHDR1000 143 144 145 ********************************************************************************** 146 * * 147 * This is the format for the "file set" logical record. * 148 * AKA the 'tape label'. It is the first record to appear at * 149 * the beginning of the BACKUP info, and also is the first * 150 * record on each continued tape of BACKUP. * 151 * This record is really a special case in several ways. * 152 * It always appears alone in a physical record. Two copies of * 153 * this always appear together on separate physical records. It * 154 * is never encrypted. The sequence number of the physical * 155 * record is a duplicate of the immediately following physical * 156 * record. This is because the EOT status is not known at the * 157 * time that a record is constructed and encrypted. Therefore, * 158 * a tape header may need to be inserted at an arbitrary place. * 159 * We borrow the next expected sequence number and don't * 160 * increment the expected number. * 161 * Some misc notes.. Note that the time stamp for this * 162 * file set, while not secret, is used as an indicator in the * 163 * encryption (i.e. makes up part of the key). Backup can * 164 * get the maximum required buffer size from PHYSRECSZ. * 165 * * 166 ********************************************************************************** 167 00000400 168 HDRTYP0 BASE R0 169 BSS LOGHDRLEN logical record header 00160801 0 BASE 170 HDRTYPWRD1 BSS 1 holds revision numbers 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 12 (TRTAPEDEFS) F 16 Backup Format Definitions 00080101 0 ZBM 171 ENCTYP EQU HDRTYPWRD1/BITS 0:15 encryption algorithm used 00000001 ABS 172 SSENCRFN EQU 1 current encrypt format number 00082101 0 ZBM 173 SAVSETFMT EQU HDRTYPWRD1/BITS 16:31 tape format used 00000005 ABS 174 SSTAPEFN5 EQU 5 earliest format for DTT type seq num 00000006 ABS 175 SSTAPEFN6 EQU 6 earliest format with checksums 00000006 ABS 176 SSTAPEFN EQU 6 current form for writers 00160802 0 BASE 177 SETTAPNUM BSS 1 current tape number 00160803 0 BASE 178 SETTIMSTP BSS2 1 time stamp for this "file set" 00160805 0 BASE 179 BOOTINFO BSS 1 1 if boot info on this tape 00160806 0 BASE 180 PHYSRECSZ BSS 1 maximum words in a physical record 00160807 0 BASE 181 WHODONE BSS 1 1 sez DISKTOTAPE did this backup 182 * 0 sez +BACKUP is guilty 00160808 0 BASE 183 SSSSN BSS 1 fileset system's serial number 00160809 0 BASE 184 SSOWNER BSS2 1 account serial number of owner of this fileset 00000005 ABS 185 SSFILLEN EQU 5 length of filler 0016080B 0 BASE 186 SAVESETFIL BSS SSFILLEN filler (must always be zero) 00160810 0 BASE 187 SAVSETNAME BSS TS tape string - contains fileset's name 188 DRCT 00000010 ABS 189 SVSRECLEN EQU DISPW HDRTYP0 length of "file set" header 190 ORG HDRTYP0 191 192 193 ********************************************************************************** 194 * This is the format for the "end file set" logical * 195 * record. It indicates the end of the BACKUP info. A tape * 196 * mark appears before and after it, and it is not encrypted. * 197 ********************************************************************************** 198 00000400 199 HDRTYP1 BASE R0 00160800 0 BASE 200 ENDHEADER BSS LOGHDRLEN logical record header 00160801 0 BASE 201 ENDTIME BSS 2 copy of the beginning time stamp 00000004 ABS 202 ENDFILLEN EQU 4 length of this filler 00160803 0 BASE 203 ENDFILLER BSS ENDFILLEN filler 204 DRCT 00000007 ABS 205 SVERECLEN EQU DISPW HDRTYP1 length of "end file set" header 206 ORG HDRTYP1 207 208 209 ********************************************************************************** 210 * This is the format for the "tape end" logical record. * 211 * A tape mark appears before and after it, and it is * 212 * unencrypted. * 213 * As soon as the tape writing process detects the EOT, * 214 * it writes out a file mark, this record, and another file * 215 * mark. Note that the reading process must not use the EOT * 216 * status to substitute for this record... the EOT is * 217 * mechanically detected and might not appear in the same * 218 * relative position when the tape is read, especially on * 219 * another drive. * 220 ********************************************************************************** 221 00000400 222 HDRTYP2 BASE R0 00160800 0 BASE 223 TAPENDHDR BSS LOGHDRLEN logical record header 00160801 0 BASE 224 TAPENDNUM BSS 1 current tape number 00160802 0 BASE 225 TAPENDTIME BSS 2 beginning time stamp 00000004 ABS 226 TPENDFILLN EQU 4 length of this filler 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 13 (TRTAPEDEFS) F 16 Backup Format Definitions 00160804 0 BASE 227 TAPENDFIL BSS TPENDFILLN must be zero 228 DRCT 00000008 ABS 229 TPERECLEN EQU DISPW HDRTYP2 length of "tape end" header 230 ORG HDRTYP2 231 232 233 ********************************************************************************** 234 * This is the format for the "volume" logical record * 235 * header. The tapestring containing the volume name is * 236 * followed by the OS defined backup information block. * 237 ********************************************************************************** 238 00000400 239 HDRTYP3 BASE R0 240 BSS LOGHDRLEN logical record header 00000004 ABS 241 VOLFILLEN EQU 4 this record's filler length 00160801 0 BASE 242 VOLRECFILL BSS VOLFILLEN filler - must be zero 00160805 0 BASE 243 VOLRECNAME BSS TS tape string - volume name 244 DRCT 00000005 ABS 245 VOLRECLEN EQU DISPW HDRTYP3 length of "volume" header 246 ORG HDRTYP3 247 248 249 ********************************************************************************** 250 * This is the format for the "account" logical record * 251 * header. The account name tapestring is followed by the OS * 252 * defined backup information block. * 253 ********************************************************************************** 254 00000400 255 HDRTYP4 BASE R0 00160800 0 BASE 256 ACTHDR BSS LOGHDRLEN logical record header 00160801 0 BASE 257 ACTHDRSER BSS 2 account serial number 00160803 0 BASE 258 ACTHDRNOSL BSS 1 1 sez dump the account share list 00160804 0 BASE 259 ACTHDRFAST BSS 1 1 sez used fast encryption 00000004 ABS 260 ACTFILLEN EQU 4 this header's filler length 00160805 0 BASE 261 ACTHDRFILL BSS ACTFILLEN filler - must be zero 00160809 0 BASE 262 ACTHDRNAME BSS TS tapestring - full account name (including volume name) 263 DRCT 00000009 ABS 264 ACTRECLEN EQU DISPW HDRTYP4 length of "account" header 265 ORG HDRTYP4 266 267 268 ********************************************************************************** 269 * This is the format for the "file" logical record * 270 * header. The file name tapestring is followed by the OS * 271 * defined backup information block. * 272 ********************************************************************************** 273 00000400 274 HDRTYP5 BASE R0 00160800 0 BASE 275 FILHDR BSS LOGHDRLEN logical record header 00160801 0 BASE 276 FILHDRASER BSS 2 owner account serial number 00160803 0 BASE 277 FILHDRNOSL BSS 1 1 sez dump share list 00160804 0 BASE 278 FILHDRTYPE BSS 1 file hardware type 00160805 0 BASE 279 FILHDRSIZE BSS 1 size of file in blocks 00160806 0 BASE 280 FILHDRRDAT BSS 2 last read date 00160808 0 BASE 281 FILHDRWDAT BSS 2 last write date 0016080A 0 BASE 282 FILHDRCDAT BSS 2 create date 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 14 (TRTAPEDEFS) F 16 Backup Format Definitions 0016080C 0 BASE 283 FILHDRBDAT BSS 2 backup date 0016080E 0 BASE 284 FILHDRGOST BSS 1 1 sez ghost file 00000004 ABS 285 FILEFILLEN EQU 4 this filler length 0016080F 0 BASE 286 FILHDRFILL BSS FILEFILLEN filler - must be zero 00160813 0 BASE 287 FILHDRNAME BSS TS tapestring - ::) 288 DRCT 00000013 ABS 289 FILRECLEN EQU DISPW HDRTYP5 length of "file" header 290 ORG HDRTYP5 291 292 293 ********************************************************************************** 294 * * 295 * This is the format for the "file page" logical record * 296 * header. It is followed by the OS defined backup info * 297 * block. * 298 * Any number of file blocks may appear in this record. * 299 * When more than one is present the format is: * 300 * header * 301 * block 1 * 302 * block 2 * 303 * ... * 304 * block n * 305 * FBI 1 * 306 * ... * 307 * FBI n * 308 * * 309 * Note that to keep compatibility with older backups a * 310 * count of zero data blocks really means one. * 311 * Note that the file page logical records for a RAF or * 312 * code file may appear in any order. * 313 * * 314 ********************************************************************************** 315 00000400 316 HDRTYP6 BASE R0 00160800 0 BASE 317 DATAHDR BSS LOGHDRLEN logical record header 00160801 0 BASE 318 DATAACTSER BSS 2 account serial number 00160803 0 BASE 319 DATASEQNUM BSS 1 sequence number of this record in file 00160804 0 BASE 320 NUMBERWORD BSS 1 word for various sequence numbers 00080084 0 ZBM 321 NUMBPAGES EQU NUMBERWORD/CH0 number of file pages in this record 00081184 0 ZBM 322 DATAPAGESN EQU NUMBERWORD/BITS 8:31 sequence number of first file page 323 * within this logical record 00000003 ABS 324 DATAFILLEN EQU 3 this filler length 00160805 0 BASE 325 DATAFILL BSS DATAFILLEN filler - must be zero 326 DRCT 00000008 ABS 327 FIPRECLEN EQU DISPW HDRTYP6 length of "file page" header 328 ORG HDRTYP6 329 330 331 ********************************************************************************** 332 * This is the format for the "error" logical record * 333 * header. This record will occur at any spot in the BACKUP * 334 * that an error has occurred. It is assumed that it was a * 335 * non-fatal error, but if it was a fatal error the BACKUP * 336 * will end immediately. * 337 ********************************************************************************** 338 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 15 (TRTAPEDEFS) F 16 Backup Format Definitions 00000400 339 HDRTYP7 BASE R0 00160800 0 BASE 340 ERRHDR BSS LOGHDRLEN logical record header 341 DRCT 00000001 ABS 342 ERRRECLEN EQU DISPW HDRTYP7 length of "error" header 343 ORG HDRTYP7 344 345 ********************************************************************************** 346 * Backup has a filler record type which is just to take * 347 * up space. We only need to get the size from the header and * 348 * skip that many words to the next record. * 349 ********************************************************************************** 350 00000400 351 HDRTYP8 BASE R0 00160800 0 BASE 352 FILLERHDR BSS LOGHDRLEN logical record header 353 DRCT 00000001 ABS 354 FILLERRECL EQU DISPW HDRTYP8 length of "filler" header 355 ORG HDRTYP8 250 BKUPINFORD LIST 250 ********************************************************************************** 250 * * 250 * Definition of system header made in backup. * 250 * * 250 ********************************************************************************** 250 00000400 250 HDRPROTO BASE R0 00160800 0 BASE 250 BKUPHDRW1 BSS 1 first word of header 000000F0 BYTE 250 FILEINFOT EQU BITS 0:14 type of backup information 00000000 ABS 250 FILEINFOTV EQU 0 volume information 00000001 ABS 250 FILEINFOTA EQU 1 account information 00000002 ABS 250 FILEINFOTF EQU 2 file information 00000003 ABS 250 FILEINFOTD EQU 3 file page information 00000004 ABS 250 FILEINFOTM EQU 4 mapped file page information 00001F10 BYTE 250 BKUPREV EQU BITS 15:31 revision number 00160801 0 BASE 250 BKUPHDRW2 BSS 1 second word of header 000000F0 BYTE 250 FSTBKUPLEN EQU BITS 0:14 first optional length 00001F10 BYTE 250 SNDBKUPLEN EQU BITS 15:31 second optional length 250 DRCT 00000002 ABS 250 BKUPHDRLEN EQU DISPW HDRPROTO length of header 250 ORG HDRPROTO reclaim space 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 16 F 0 Memory Usage 253 254 ********************************************************************************** 255 * * 256 * MEMORY MAP * 257 * ---------- * 258 * * 259 * page address usage (all in monitor memory) * 260 * ---- ------- ----- * 261 * 000:00B 0000:2FFF Bootstrap routine and OPL * 262 * 00C:011 3000:47FF DISKTOTAPE code * 263 * 012 4800:4BFF variables * 264 * 013:01A 4C00:6BFF MCBs * 265 * 01B:023 6C00:8BFF PRELs * 266 * 024:07F 8C00:1FFFF unmapped * 267 * * 268 ********************************************************************************** 269 270 00003000 ABS 271 PROGPLACE EQU 03000 start code here 00004800 ABS 272 VARPLACE EQU PROGPLACE+(6*WPP) variables go here 00004C00 ABS 273 MCBPLACE EQU VARPLACE+WPP where we will build MCBs 274 PRELPLACE EQU MCBPLACE+NUMMCBPAG*WPP with the PRELS following 275 PROCPAGE EQU PRELPLACE+NUMPRELPAG*WPP first free page address for processes 276 * to map in their own pages 277 PROCPN EQU (PROCPAGE/WPP)+MONPF page number for first process' page 278 279 INPUT DISKTOTAPE.OPSYS:DTTDEFS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 17 (DTTDEFS) F 17 Global and Stucture Definitions 3 00000400 4 TRASHPOINT LABEL to recover this space 5 6 ********************************************************************************** 7 * * 8 * MCB -- Memory Control Blocks * 9 * * 10 * Every page of memory used by DISKTOTAPE has a memory * 11 * control block (MCB) associated with it. The MCB contains * 12 * information about the block and is the main source of * 13 * memory management for DISKTOTAPE. * 14 * A free block list is created at the beginning of * 15 * DISKTOTAPE by building an MCB for each page of physical * 16 * memory available (up to a limit of 500 pages). Any process * 17 * then needing a page of memory takes an MCB from the list, * 18 * and any process done with a page of memory returns the MCB * 19 * to the list. * 20 * Since MCBs and PRELs can appear in the same list, the * 21 * first word of both elements must be defined the same. * 22 * * 23 ********************************************************************************** 24 00000000 ABS 25 TPREL EQU 0 code for use as PREL 00000001 ABS 26 TFDE EQU 1 code for use as FDE 00000002 ABS 27 TMCB EQU 2 code for MCB block 00000003 ABS 28 TTBM EQU 3 code for tape boot make info marker 00000004 ABS 29 TEOV EQU 4 code for end of volume 00000005 ABS 30 TVOLNAM EQU 5 code for volume name 00000006 ABS 31 TUDIR EQU 6 code for UDIR 00000007 ABS 32 TERROR EQU 7 code for error 33 00000010 ABS 34 MCBLNTH EQU 010 memory control block size 00000008 ABS 35 NUMMCBPAG EQU 8 number of pages used for MCBs 36 37 BASE R4 00170800 4 BASE 38 MCBWORDA BSS 1 00091F10 4 ZBM 39 MCBLINK EQU MCBWORDA/FLDADRS pointer to next MCB 00090040 4 ZBM 40 MCBTYPE EQU MCBWORDA/BITS 0:3 bits describing use 00090810 4 ZBM 41 MCBWPRT EQU MCBWORDA/BIT 4 bit indicating write protected page 00170801 4 BASE 42 MCBPMV BSS 1 page map value for this block 00170802 4 BASE 43 MCBFBI BSS FBILNTH FBI for this block 44 BSS MCBLNTH-(DISPW MCBWORDA) ensure we have MCBLNTH words 45 DRCT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 18 (DTTDEFS) F 17 Global and Stucture Definitions 47 48 ********************************************************************************** 49 * * 50 * PRELs -- physical record elements (FDE) * 51 * * 52 * DISKTOTAPE picks up information from the disk, packs * 53 * it into physical records, encrypts the physical records if * 54 * necessary, and writes the physical records onto tape. * 55 * These physical records can consist of 1 to 5 actual pages * 56 * of data, but must be dealt with as one entity. For this * 57 * purpose we have Physical Record ELements (PREL). * 58 * PRELs contain the information necessary to describe * 59 * each physical record. DISKTOTAPE creates the PRELs at the * 60 * start and keeps the free ones in a linked list. When the * 61 * packing process needs a new PREL it removes it from the * 62 * list, and when the tapewriting process is finished with a * 63 * PREL it returns it to the list. * 64 * The same memory chunks used for PRELs are also used to * 65 * pass file directory entries between the reading and packing * 66 * process. These elements are linked into the PRPQ before * 67 * the data blocks making up the file. The MCBs following an * 68 * FDE, up to the next FDE, are blocks belonging to the file * 69 * described by the first FDE. * 70 * * 71 * * 72 ********************************************************************************** 73 00000019 ABS 74 PRELLNTH EQU 25 physical record element size 0000012C ABS 75 MAXPRELS EQU 300 maximum PRELS we will build 00000008 ABS 76 NUMPRELPAG EQU 8 number of pages used for PRELs 77 78 BASE R3 0016C800 3 BASE 79 PRELWORDA BSS 1 0008DF10 3 ZBM 80 PRELLINK EQU PRELWORDA/FLDADRS link to next PREL 0008C040 3 ZBM 81 PRELTYPE EQU PRELWORDA/BITS 0:3 what this PREL is used for 0008C820 3 ZBM 82 PRELFLAGS EQU PRELWORDA/BITS 4:5 so we can check them both at once 0008C810 3 ZBM 83 PRELBUSY EQU PRELWORDA/BIT 4 flag indicating PREL is busy 0008CA10 3 ZBM 84 PRELDONE EQU PRELWORDA/BIT 5 flag sez PREL is encrypted 0008CC20 3 ZBM 85 PRELENCRY EQU PRELWORDA/BITS 6:7 encrypt code for this physical record 0016C801 3 BASE 86 PRELWORDB BSS 1 0016C801 3 BASE 87 PRELFDE EQU PRELWORDB beginning of FDE 0016C801 3 BASE 88 PRELVOLNAM EQU PRELWORDB where to put the volume name 89 0016C801 3 BASE 90 PRELTBM EQU PRELWORDB code for this TBM type 00000000 ABS 91 TBMNONE EQU 0 no tape boot info on tape 00000001 ABS 92 TBMBEGIN EQU 1 begin tapeboot make 00000002 ABS 93 TBMEND EQU 2 end tapeboot make 94 0008C041 3 ZBM 95 PRELMCBCNT EQU PRELWORDB/BITS 0:3 count of MCB pointers in PREL 0008E101 3 ZBM 96 PRELPRLEN EQU PRELWORDB/BITS 16:31 number of words in physical record 0016C802 3 BASE 97 PRELPRINX BSS 1 index to starting position of physical record 0016C803 3 BASE 98 PRELMCBPTR BSS 1 beginning of pointers to MCBs 99 BSS PRELLNTH-(DISPW PRELWORDA) space for FDE or MCB pointers 100 DRCT 101 102 * codes for physical record encryption, 0 indicates not set yet 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 19 (DTTDEFS) F 17 Global and Stucture Definitions 00000001 ABS 103 ENCRTBM EQU 1 tape boot make special encrypt 00000002 ABS 104 ENCRNORM EQU 2 normal encrypt 00000003 ABS 105 ENCRNONE EQU 3 no encrypt 106 107 ********************************************************************************** 108 * * 109 * This is the template for the header that is put on * 110 * file data blocks used for the TAPEBOOTMAKE process. It is * 111 * an 11 word header (same as FBI) which is not encrypted. * 112 * This header contains the checksum for the data part (before * 113 * encryption) and is itself checksummed. The header is * 114 * followed by a page of data (encrypted). We make the full * 115 * page of data fall on a page boundary. * 116 * * 117 ********************************************************************************** 118 119 BASE R2 00168800 2 BASE 120 TBMNAME BSS 2 place for identifying marker 00168802 2 BASE 121 TBMIND BSS 1 place for encryption indicator 00168803 2 BASE 122 TBMDATE BSS 2 place where date goes 00168805 2 BASE 123 TBMFIL1 BSS 2 filler 00168807 2 BASE 124 TBMFIL2 BSS 2 filler 00168809 2 BASE 125 TBMDCS BSS 1 data checksum 0016880A 2 BASE 126 TBMHCS BSS 1 header checksum 127 DRCT 128 FFC00000 ABS 129 HCSMASK EQU -1/BITS 0:(FBILNTH-2)*BITS 0:(FBILNTH-2) 130 ORG TRASHPOINT recover wasted space 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 20 (DTTDEFS) F 17 Global and Stucture Definitions 132 133 ********************************************************************************** 134 * * 135 * List locking macro. * 136 * Call: * 137 * LLOCK lockword * 138 * * 139 ********************************************************************************** 140 141 LLOCK MACRO 142 NOLIST 143 $L SETT $P 144 JNE MA(3+DISPW MA 0) 145 WAIT LOCKWAIT 146 JMP MA((DISPW MA 0)-3) 147 * --- 148 149 LIST 150 EMAC 151 152 ********************************************************************************** 153 * * 154 * The following macro is just like BEGFRAME except that * 155 * it does NOT generate a BSS 1 for the return link word. * 156 * * 157 ********************************************************************************** 158 159 BEGFRAME2 MACRO 160 NOLIST 161 NOLIST CREF 162 NOSYMS 163 FRAME! BASE SP beginning of stack frame 164 SYMS 165 LIST CREF 166 LIST 167 EMAC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 21 (DTTDEFS) F 17 Global and Stucture Definitions 169 170 ********************************************************************************** 171 * Global definitions. * 172 ********************************************************************************** 173 174 ORG VARPLACE start variables here 175 00000002 ABS 176 LOCKWAIT EQU 02 how long to wait for a lock (* 10 us) 177 178 ********************************************************************************** 179 * This area is initialized to zeros just after the parameters * 180 * are processed. * 181 ********************************************************************************** 182 00004800 183 CLEARAREA LABEL start of area to clear during init. 184 00004800 185 READLOCK BSS 1 read process lock 00004801 186 PACKLOCK BSS 1 physical record packing process lock 00004802 187 WRITELOCK BSS 1 tape write process lock 188 00004803 189 READDONE BSS 1 0 sez more disk left to read 190 * 1 sez done reading disk 191 00004804 192 PAGEQ BSS 1 pointer to list of free pages 00004805 193 PAGEQLOCK BSS 1 lock for this queue 00004806 194 FREEPGCNT BSS 1 free page count 195 00004807 196 PRELQ BSS 1 pointer to list of free physical record 197 * elements (PREL) 00004808 198 PRELQLOCK BSS 1 lock for this queue 00004809 199 FREEPRELCT BSS 1 start with the maximum number of PRELs 200 0000480A 201 PRPQHEAD BSS 1 head of the physical record packing queue 0000480B 202 PRPQTAIL BSS 1 tail of same queue 0000480C 203 PRPQLOCK BSS 1 lock for this queue 204 0000480D 205 ENCRYQHD BSS 1 head of encrypt queue 0000480E 206 ENCRYQTL BSS 1 tail of encrypt queue 0000480F 207 ENCRQCNT BSS 1 count of entries in encryption queue 00004810 208 ENCRYLOCK BSS 1 lock for this queue 209 00004811 210 TAPEQHEAD BSS 1 head of tape write queue 00004812 211 TAPEQTAIL BSS 1 tail of tape write queue 00004813 212 TAPEQCNT BSS 1 count of entries in tape write queue 00004814 213 TAPEQLOCK BSS 1 lock for tape write queue 214 00004815 215 CPUCOUNT BSS 1 count of the CPUs 216 00000016 ABS 217 CLEARLEN EQU DISPW CLEARAREA length of variable area initialized to 0 218 219 ********************************************************************************** 220 * End of area initialized to zeros. * 221 * The following variables are initialized in other ways. * 222 ********************************************************************************** 223 00004816 224 SPINADDR BSS 1 address in OPL that CPUs loop on 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 22 (DTTDEFS) F 17 Global and Stucture Definitions 225 00004817 226 FREESPACE BSS 1 pointer to available memory for 227 * allocating MCBs 00004818 228 READMINPAG BSS 1 current minimum read page limit 00004819 229 PACKMINPAG BSS 1 current minimum pack page limit 230 231 * Variables set up by GETPARAMS 232 0000481A 233 OPTKEY BSS2 1 optional encryption key 0000481C 234 ENCRFASTFL BSS 1 0 sez encrypt everything 235 * 1 sez check account encrypt flag 0000481D 236 GOFLAG BSS 1 flag used when picking up parameters 237 0000481E 238 TAPENAME BSS 2 tape name 00004820 239 DISKNAME BSS 2 disk name 240 241 * variables set by GETENCPARM 242 00004822 243 STARTTIME BSS2 1 starting time 244 00004824 245 SYSSN BSS 1 system's serial number 00004825 246 SYSPWD BSS2 1 system's password 247 248 * buffer used for terminal communications 249 00000050 ABS 250 BUFL EQU 80 Buffer length 00004827 251 BUF LABEL 02004827 252 BUFC BSSC BUFL The buffer itself 253 0000483B 254 PHYSRECSIZ BSS 1 size limit for tape records 255 0000483C 256 TAPECB BSS TPCBLEN tape control block 00004844 257 DISKCB BSS DCBLEN disk control block 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 23 (DTTDEFS) F 17 Read Process Variables 260 261 ********************************************************************************** 262 * * 263 * The following variables are used by the disk reading * 264 * process. * 265 * * 266 ********************************************************************************** 267 0000484C 268 READR2 BSS 1 save read's R2 here 0000484D 269 READSPR7 BSS 2 stack pointer and R7 are saved here 0000484F 270 READPC BSS 1 where to start up in the read process 271 00004850 272 FDEPTR BSS 1 pointer to current FDE 273 00004851 274 READFBI BSS FBILNTH place for read to put FBIs 275 0000485C 276 SECPTRAK BSS 1 sectors per track 0000485D 277 SECPCYL BSS 1 sectors per cylinder 0000485E 278 VOLSIZE BSS 1 volume size 0000485F 279 VOLMCB BSS 1 holds a pointer to volume label's MCB 280 00004860 281 SECTORSW LABEL 00404860 282 SECTORS BSSB 1:32 bit array for sector ordering 283 00004861 284 RELBLOCK BSS 1 relative block number 00004862 285 SECDA BSS 1 disk address of security block 00004863 286 SEC2DA BSS 1 disk address of second security block 00004864 287 CURBLK BSS 1 disk address 00004865 288 ERRORCODE BSS 1 numeric error code 00004866 289 READASN BSS2 1 account serial number of current account 00004868 290 READSERIAL BSS 2 serial number of current file 0000486A 291 PREVBLOCK BSS 1 previous block in a saf 0000486B 292 UDIRTYPE BSS 1 UDIR FBI type 0000486C 293 UDIRBLOCK BSS 1 UDIR block number 294 0000486D 295 ERRORBLOCK LABEL 0000486D 296 READVOL BSS 2 0000486F 297 READSYS BSS 1 00004870 298 READSYSPW BSS 2 00004872 299 READACCT BSS 2 00004874 300 READPROJ BSS 1 00004875 301 READACCTPW BSS 2 00004877 302 READNAME BSS 2 00004879 303 READEXT BSS 1 0000487A 304 READFILEPW BSS 2 0000000F ABS 305 ERRBLKLEN EQU DISPW ERRORBLOCK 306 0000487C 307 CHEKFBIFLG BSS 1 flag indicating if we should check FBIs 0000487D 308 READKEY BSS 1 hold key that read process puts into 309 * tapeboot FBIs 310 311 * Prototype for equipping the code files. 0000487E 312 EQPBLK LABEL 0487E 9B17AC90 313 PAK12 OFFLINE account file is on 04880 E79DF200 314 PAK6 !!! account extension 04882 00000000 315 VFD 0,0 password for account 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 24 (DTTDEFS) F 17 Read Process Variables 00004883 316 EQPFILNAM BSS2 1 file name 04885 533719C0 317 PAKCODE PAK6 CODE extension for filename 04887 00000000 318 VFD 0,0 password for file 319 320 BSS 64 000048C8 321 READSTACK LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 25 (DTTDEFS) F 17 Constant Definition 324 325 * Global definitions. 326 000001F4 ABS 327 MAXMEMRY EQU 500 most pages of memory we will use 0000000A ABS 328 RMINPAGES EQU 0A minimum free pages for Read proceess 00000002 ABS 329 PMINPAGES EQU 02 minimum free pages for Pack process 330 00000018 ABS 331 TPBTPAGES EQU 24 extra pages needed for tapebootmake encryptor 00000005 ABS 332 MINPCKPREL EQU 5 pack needs to leave some PRELs for 333 * encrypt and tapewrite stack usage 00000019 ABS 334 MINPRELS EQU MINPCKPREL+20 minimum number of available free PRELs 335 * for the read process to continue. 336 00000001 ABS 337 MEMDEVICE EQU 01 WRU device number for memory 048C8 0F000FFF 338 PFCLNMASK VFD ONEBITS/PFSLOT*PFSLOT+ONEBITS/PFPAGENUM*PFPAGENUM 048C9 00FFFFFF 339 MSMASK VFD 0FFFFFF mask for MS addresses 340 048CA A0084822 341 CURDATE PTR STARTTIME/DATEHORD pointer to the single word version 048CB 020C4827 342 BUFP PTR BUFC pointer to the buffer 343 048CC 964C9000 344 PACKNO PAK6 NO 048CD 927C0000 345 PACKN PAK6 N 048CE D805C200 346 PACKYES PAK6 YES 048CF D59F8000 347 PACKY PAK6 Y 048D0 9BCAD000 348 PACKOK PAK6 OK 349 350 ********************************************************************************** 351 * * 352 * The maximum tape record sizes are determined separately * 353 * for 9 track, video, and cartridge tape. The appropriate value * 354 * is set up during initialization and is used thereafter by the * 355 * modules concerned. * 356 * The 9 track record size is limited by errors in the * 357 * microcode timout values. When the controllers are fixed, * 358 * this value can be increased. The originally determined * 359 * limit was 3 pages less 080 words. Here we press our luck * 360 * in the interest of a better packing density on the tapes. * 361 * The video tape unit gathers data into its RAM buffer * 362 * in units of 1024 bytes (padding any record not a multiple * 363 * of 1024 bytes) and proceeds to lay down on the tape stripes * 364 * of 8192 bytes. IRGs as such do not exist. Therefore, the * 365 * video tape record size is rather uncritical, except that * 366 * all records should be a multiple of 1024 bytes (256 words). * 367 * We use 3 pages plus a little grace so that we can use the * 368 * more efficient file page writing for up to three pages at * 369 * a time. * 370 * The cartridge tape record size is limited to just * 371 * under 4.5 pages by the operating system. In addition, the * 372 * distance between the early warning and the hard EOT is only * 373 * 48 inches. This means that this 18kb record (about 23 * 374 * inches) is in serious danger of hitting the hard EOT if one * 375 * or two write errors happen in the region after the early * 376 * warning. This record size was therefore cut down to * 377 * a little more than two pages. * 378 * * 379 * * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 26 (DTTDEFS) F 17 Constant Definition 380 ********************************************************************************** 381 382 * record size for 9 track 048D1 00000C80 383 PHYSRECSIZ9 VFD (3*WPP)+080 a little longer than 3 pages 384 * record size for video tape 048D2 00000D00 385 PHYSRECSIZV VFD (3*WPP)+0100 a little longer than 3 pages 386 * record size for Cartridge Tape 048D3 00000880 387 PHYSRECSIZC VFD (2*WPP)+080 a little longer than 2 pages 388 0000000D ABS 389 CR EQU 0D carriage return 0000000A ABS 390 LF EQU 0A line feed 000001E0 BYTE 391 DIVBY4BITS EQU BITS 0:29 load from these bits is equivalent to 392 * dividing by 4 393 000003FF ABS 394 PAGEMASK EQU ONEBITS/DISPFIELD mask for offset in page 00000060 ABS 395 UDIRKEEPL EQU (UDFDLIST DISPW UD) how much of the UDIR to keep 396 048D4 00484860 397 SECPTR PTR SECTORS pointer into the bit array 398 048D5 379EFD4E 399 OLDDATE VFD 0379EFD4E oldest date we will allow on a disk 400 * 01-Jan-80 0:00 401 048D7 00000000 402 EMPTY2 VFD 0,0 two words of nothingness 000048D7 403 EMPTY EQU EMPTY2(1) just what it says 404 405 * Table of files that we will copy to the tape in the 406 * TAPEEBOOT encrypted format. Note that this encryption 407 * format is massively different than that of the normal 408 * data. 000048D8 409 NAMTAB LABEL 048D8 B8E273B9 410 PAK12 TAPEBOOT must be first! 048DA BB057D80 411 PAK12 TOPL 048DC B8E2762F 412 PAK12 TAPERECOVER 048DE A3146E3C 413 PAK12 PRTERRLOG 048E0 A10A1F4A 414 PAK12 PEEK&POKE 048E2 58760850 415 PAK12 DISKINIT 048E4 AD3C6CCE 416 PAK12 REBUILD 048E6 58760761 417 PAK12 DISKCOPY 048E8 5876078F 418 PAK12 DISKDUP 00000009 ABS 419 TABMAX EQU DISPW NAMTAB/2 420 BSS2 4 room to patch in more 421 048F2 E79EDF2D 422 GOOFNAME PAK12 !!!!!!!!!!!! very off-the-wall name 423 048F4 020C490D 424 NAMEBUFLCH PTR NAMEBUF(0) points to string length byte 048F5 420C490D 425 NAMEBUFPTR PTR NAMEBUF(1) points to beginning of string 426 048F6 7208492E 427 FFPNPTR PTR FASTFBIPTR/PAGEFIELD pointer into the page number field 428 00000004 ABS 429 VOLMAXTS EQU 16/CPW maximum volume tapestring size 0000000A ABS 430 ACCTMAXTS EQU 40/CPW maximum account tapestring size 0000000F ABS 431 FILEMAXTS EQU 60/CPW maximum file tapestring size 432 433 * The following definitions are maximum logical record sizes 434 * for the various logical records. 435 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 27 (DTTDEFS) F 17 Constant Definition 00000876 ABS 436 ACCTRECSIZ EQU 2*WPP+ACCTMAXTS+ACTRECLEN+UDIRKEEPL+BKUPHDRLEN+TAPHDR1000L 00000076 ABS 437 ACCTNOALSL EQU ACCTRECSIZ-(2*WPP) account with no share or auth list 438 00000467 ABS 439 VOLRECSIZ EQU BKUPHDRLEN+WPP+FBILNTH+VLBKUPE+(SECBKUPE DISPW SECTZONE) 440 0000001A ABS 441 FILEOSSIZE EQU BKUPHDRLEN+FDLNTH 0000043D ABS 442 FILERECSIZ EQU FILRECLEN+FILEMAXTS+FILEOSSIZE+WPP+TAPHDR1000L 0000003D ABS 443 FILENOSL EQU FILERECSIZ-WPP 444 0000040D ABS 445 FASTRECLEN EQU WPP+FBILNTH+BKUPHDRLEN file block record with no header 00000416 ABS 446 FILBLKRECL EQU FIPRECLEN+FASTRECLEN+TAPHDR1000L file block record with header 447 0000040B ABS 448 TBMRECSIZ EQU WPP+TPHDRLNTH length of each tapebootmake record 449 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 28 (DTTDEFS) F 17 Read Process Definitions 452 453 ********************************************************************************** 454 * Read process page definitions. These must appear in * 455 * the same order as the pages defined in READPMV table. * 456 ********************************************************************************** 457 000048F7 458 BEFORE LABEL 459 ORG PROCPAGE 460 00008C00 461 RDSECLOC BSS WPP security block 00009000 462 RDIDXLOC BSS WPP IDX block 00009400 463 RDUDIR1LOC BSS WPP UDIR1 00009800 464 RDUDIR2LOC BSS WPP UDIR2 00009C00 465 RDMINLOC BSS WPP RAF minor access block 0000A000 466 RDMAJLOC BSS WPP RAF major access block 0000A400 467 RDSORTLOC BSS WPP sorting block 0000A800 468 RDMERGELOC BSS WPP merging block 469 000000AB ABS 470 RDDATAPN EQU MONPF+((DISPW MA 0)/WPP) virtual page number of following block 0000AC00 471 READDATA BSS WPP where to map in data page to read into 472 473 ORG BEFORE continue where we left off 474 000048F7 475 READPMV LABEL 048F7 00000023 476 VFD (RDSECLOC DISPW MA 0)/WPP security block page map value 048F8 00000024 477 VFD (RDIDXLOC DISPW MA 0)/WPP IDX block page map value 048F9 00000025 478 VFD (RDUDIR1LOC DISPW MA 0)/WPP UDIR1 page map value 048FA 00000026 479 VFD (RDUDIR2LOC DISPW MA 0)/WPP UDIR2 page map value 048FB 00000027 480 VFD (RDMINLOC DISPW MA 0)/WPP Raf minor access block page map value 048FC 00000028 481 VFD (RDMAJLOC DISPW MA 0)/WPP Raf major access block page map value 048FD 00000029 482 VFD (RDSORTLOC DISPW MA 0)/WPP sorting block page map value 048FE 0000002A 483 VFD (RDMERGELOC DISPW MA 0)/WPP merging block page map value 00000008 ABS 484 READPMVL EQU DISPW READPMV 000048FF 485 RDDATAPMV BSS 1 word to hold data page's PMV 486 0000002B ABS 487 LASTPN EQU ((RDMERGELOC DISPW MA 0)/WPP)+1 reserve previous pages 488 * for read process 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 29 (DTTDEFS) F 17 Packing Process Definitions 491 492 ********************************************************************************** 493 * * 494 * The following definitions and variables are used by * 495 * the physical record packing process. * 496 * * 497 ********************************************************************************** 498 00004900 499 PACKPC BSS 1 place to save packing process's PC 00004901 500 PACKSPR7 BSS 2 place to save packing process's SP and R7 00004903 501 PACKR4R5 BSS 2 place to save packing process's R4 and R5 502 00004905 503 PACKSEQNUM BSS 1 physical record sequence number used by 504 * the packing process 00004906 505 FPSEQNUM BSS 1 file page sequence number 00004907 506 FPLRSEQNUM BSS 1 file page record sequence number 00004908 507 CPRFORM BSS 1 current physical record format 00000000 ABS 508 NOFORM EQU 0 no current format 00000001 ABS 509 NORMFORM EQU 1 normal format 00000002 ABS 510 FASTFORM EQU 2 format for multiple data blocks 00004909 511 CPRPN BSS 1 current physical record page number 0000490A 512 ACCTENCR BSS 1 current accounts fast encrypt flag 513 0000490B 514 PACKACCTSN BSS2 1 account serial number 515 0000490D 516 NAMEBUFW BSS 0 word label for buffer 0200490D 517 NAMEBUF BSSC 120 lots of space for tape string name 0000492B 518 ACCTINDEX BSS 1 position in NAMEBUF to start account name 0000492C 519 FILEINDEX BSS 1 position in NAMEBUF to start file name 520 0000492D 521 FASTFBIMCB BSS 1 MCB that points to page containing FBIs 0000492E 522 FASTFBIPTR BSS 1 pointer to current position in FBI page 523 0000000E ABS 524 PACKPMVTABL EQU 14 0000492F 525 PACKPMVTAB BSS PACKPMVTABL Table for holding page map values 526 * for the packing process. Initialized 527 * to all entries being excluded pages. 528 529 BSS 64 stack area for packing process 0000497D 530 PACKSTACK LABEL 531 0000497D 532 PACKDEFEND LABEL to use to recover space 533 534 ORG PROCPAGE define pack process's pages starting here 535 00008C00 536 PACKWNDO1 BSS WPP working window for packing process 00009000 537 PACKWNDO2 BSS WPP working window for packing process 00009400 538 PACKPRPAGE BSS WPP first page to start building physical 539 * record on 540 541 000000A3 ABS 542 PKPNWNDO1 EQU PROCPN page number of PACKWNDO1 000000A4 ABS 543 PKPNWNDO2 EQU PKPNWNDO1+1 page number of PACKWNDO2 000000A5 ABS 544 PACKPRPN EQU PKPNWNDO2+1 page number for PACKPRPAGE 545 000097F0 ABS 546 FASTPHSHDR EQU (PROCPAGE+2*WPP)+WPP-PHSHDRLEN-FIPRECLEN-TAPHDR1000L 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 30 (DTTDEFS) F 17 Packing Process Definitions 547 * start address for fast file page record 548 ORG FASTPHSHDR 000097F0 549 FASTHDRLOC BSS 0 550 000093F5 ABS 551 TBMFBIPOS EQU PROCPAGE+WPP+(WPP-FBILNTH) where to start TBM's FBI 552 ORG TBMFBIPOS define pack process's pages starting here 553 000093F5 554 TPHDRLOC BSS TPHDRLNTH define actual space for the tape header 02009400 555 PROGBC BSSC 0 00009400 556 PROGB BSS WPP page for tapebootmake code block 00009800 557 PRNTABLE BSS ROUNDS*L table to hold all of the random numbers 000000A4 ABS 558 TBMPN1 EQU PROCPN+1 start this on second of process page 000000A5 ABS 559 TBMPN2 EQU TBMPN1+1 000000A6 ABS 560 PRNTABPN EQU TBMPN1+2 page number to start PRN table 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 31 (DTTDEFS) F 17 Packing Process Definitions 562 563 ********************************************************************************** 564 * * 565 * Variables used by the TAPEBOOTMAKE encryptor for key * 566 * and data manipulation. We ORG to PROCPAGE since the * 567 * encryptor's stack is on PROCPAGE and each encryptor needs * 568 * its own copy of these global variables too. The stack * 569 * starts around 165 words down on this page so we have plenty * 570 * of room at the beginning. * 571 * * 572 ********************************************************************************** 573 574 ORG PROCPAGE 04008C00 575 KEYHALF BSS 16:0 00008C00 576 KEYINDIC BSS 1 holds the indicator (read from tape) 00008C01 577 KEYPWDDAT BSS2 1 holds the xor of pw and backup date 578 00008C03 579 TABLEINDEX BSS 1 holds index to PRNTABLE 580 581 ORG PACKDEFEND resume where we left off 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 32 (DTTDEFS) F 17 Encryption Process Definitions 584 00000009 ABS 585 QUITRATIO EQU 9 tape to encrypt ratio to quit encrypting 586 0000497D 587 ENCRSTKPTR BSS NUMSLOTS table of pointers to PRELs used for 588 * stacks by the encrypt process 0000498D 589 ENCRDEFEND LABEL 590 591 ORG PROCPAGE 00008C00 592 ENCRVARPAG BSS WPP page for encryptors variables and stack 00009000 593 ENCRPRPAGE BSS WPP physical record starting page 594 595 ORG ENCRDEFEND 596 000000A3 ABS 597 ENCRVARPN EQU PROCPN page number for ENCRVARPAG 000000A4 ABS 598 ENCRPRPN EQU ENCRVARPN+1 page number for ENCRPRPAGE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 33 (DTTDEFS) F 17 Tape Write Process Definitions 601 0000498D 602 WRITEPC BSS 1 to save write process's PC 0000498E 603 WRITESPR7 BSS 2 to save write process's SP and R7 00004990 604 WRTFSLRPREL BSS 1 write's file set logical record's PREL 605 00004991 606 TAPENUM BSS 1 tape number 607 608 BSS 64 some stack space 000049D2 609 WRITESTACK LABEL 610 000049D2 611 WRITEBUF BSS (VARPLACE+WPP-(DISPW MA 0)) buffer space to build records on 0000022E ABS 612 WRITEBUFL EQU DISPW WRITEBUF 613 614 ORG PROCPAGE 00008C00 615 WRITEPRLOC BSS WPP page for writer to start mapping in physical record 000000A3 ABS 616 WRITEPRPN EQU PROCPN page number where the write process maps 617 * in the physical record 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 34 F 0 Main Control 282 283 MC BLOCK main control 284 285 ENTRY DISKTOTAPE 286 ENTRY DUMPDONE 287 ENTRY UNLINKPAGE 288 ENTRY UNLINKPREL 289 ENTRY FINDTEXTZ 290 ENTRY SCHEDULER 291 ENTRY DONEREAD 292 ENTRY CHEKPACK 293 ENTRY DONEPACK 294 ENTRY CHEKENCR 295 ENTRY CHEKTAPE 296 ENTRY CHEKIFDONE 297 ENTRY DONETAPE 298 ENTRY PAGERETURN 299 ENTRY PRELRETURN 300 ENTRY FREEALL 301 ENTRY MAPINPR 302 303 ORG PROGPLACE offline program start 304 00003000 305 DISKTOTAPE LABEL 03000 FE0E300F 306 JMP OVERVERS don't execute the version number 307 * --- 308 03003 00000000 309 VERSION VFD REVHIGH,REVLOW,0 03004 20444953 310 TITLELINE TEXTZ " DISKTOTAPE - Disk to Tape Backup v\C1\" 311 0000300F 312 OVERVERS LABEL 0300F DC5013E3 @ 313 CALLNP @VDISPLAY put our name in lights 03010 4449534B 314 ASCII 2,DISKTOTA 03012 10050000 315 VFD "PE " AND 03F3F0000 316 03013 DC1013F9 @ 317 CALL @VPREPOUT tell terminal who we are 03014 41003001 318 PAR VERSION let them know the version 03015 40003004 319 PARL TITLELINE 320 03016 DC4031A4 321 CALLNP GETPARAMS fetch the disk and tape to use 03017 FE0E3047 322 JMP DONTDUMP operator chickened out 323 03018 DC403159 324 CALLNP INITIALIZE set up all of the tables 325 03019 6104483C 4 IMM 326 LD R4 ADR TAPECB point to our tape control block 0301A 6000481E 0 327 LD R0 TAPENAME get the tape's name 0301B DC404261 328 CALLNP OPENTAPE try to open the sucker 0301C FA0C3055 0 329 JNEZ R0 NOGOTAPE if error on open, tattle and die 330 0301D 600048D1 0 331 LD R0 PHYSRECSIZ9 get record size limit for 9 track 0301E 60570802 1 4 BASE 332 LD R1 R4,TPCBTRACK pick up track number 0301F FA6C3023 1 333 JEQMW R1 STORERSIZ -1 means 9 track 03020 600048D2 0 334 LD R0 PHYSRECSIZV otherwise, get limit for video tape 03021 FA483023 1 335 JLTZ R1 STORERSIZ -2 means VT 03022 600048D3 0 336 LD R0 PHYSRECSIZC otherwise, get limit for cartridge tape 00003023 337 STORERSIZ LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 35 F 0 Main Control 03023 E400483B 0 338 ST R0 PHYSRECSIZ set up record size limit 339 03024 61044844 4 IMM 340 LD R4 ADR DISKCB point to disk control block 03025 60004820 0 341 LD R0 DISKNAME the disk to open 03026 60440000 1 IMM 342 LD R1 0 say to use system's sub list 03027 DC5013EB @ 343 CALLNP @VOPENDISK open the disk 03028 FA0C30D0 0 344 JNEZ R0 NOGODISK if error on open, then die 345 03029 60170805 0 4 BASE 346 LD R0 R4,DCBVOLSIZE get the volume size 0302A E400485E 0 347 ST R0 VOLSIZE and save it for PAGEIN 0302B 60170802 0 4 BASE 348 LD R0 R4,DCBSECPTRK get the sectors per track 0302C E400485C 0 349 ST R0 SECPTRAK and save 'em 0302D 60570803 1 4 BASE 350 LD R1 R4,DCBTRKPCYL get the tracks per cylinder 0302E 1C124000 0 1 REG 351 MUL R0 R1 turn into sectors per cylinder 0302F E400485D 0 352 ST R0 SECPCYL and save for sort routines 353 03030 DC4033CF 354 CALLNP GETENCPARM get parameters for encryption routines 355 03031 DC4033F4 356 CALLNP BUILDMCBS build our memory control blocks 03032 DC40343E 357 CALLNP BUILDPRELS build the physical record elements 358 03033 600013FC 0 359 LD R0 VEXTRACPUS get address from here 03034 E4004816 0 360 ST R0 SPINADDR remember where they were spinning at 03035 60043178 0 IMM 361 LD R0 ADR SCHEDULER get place to start the other CPUs 03036 E40013FC 0 362 ST R0 VEXTRACPUS let them know where to go 03037 5C8013FC 363 LDPC VEXTRACPUS race them for the start 364 * --- 365 00003038 366 DUMPDONE LABEL 03038 6104483C 4 IMM 367 LD R4 ADR TAPECB R4 -> tape control block 03039 DC4043D5 368 CALLNP REWIND rewind the last tape 0303A DC1013F9 @ 369 CALL @VPREPOUT tell the operator we are stopping 0303B 4000303D 370 PARL DUMPDONEM 0303C 5C8013F0 371 LDPC VDONEEXIT quit this mess 372 * --- 373 0303D 20074469 374 DUMPDONEM TEXTZ " Disk to tape backup has completed." 375 376 00003047 377 DONTDUMP LABEL 03047 DC1013F9 @ 378 CALL @VPREPOUT tell the operator we are stopping 03048 4000304A 379 PARL CHICKENMS 03049 5C8013F0 380 LDPC VDONEEXIT quit this mess 381 * --- 382 0304A 20446973 383 CHICKENMS TEXTZ " DiskToTape aborted at operator's request." 384 00003055 385 NOGOTAPE LABEL 03055 60920000 2 0 REG 386 LD R2 R0 copy the error code 03056 DC1013F9 @ 387 CALL @VPREPOUT tell about problem 03057 4100481E 388 PAR TAPENAME the tape that caused problems 03058 40003061 389 PARL NOGOTAPEM 03059 DC00348B 390 CALL FINDTEXTZ find right error message 0305A 41528000 2 REG 391 PARV R2 pass the error code 0305B 4000306D 392 PARL TAPERRTAB 0305C 60520000 1 0 REG 393 LD R1 R0 R1 -> error message 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 36 F 0 Main Control 0305D DC1013F9 @ 394 CALL @VPREPOUT tell user about our troubles 0305E 4100481E 395 PAR TAPENAME 0305F 40164400 1 @R 396 PARL @R1 03060 5C8013F0 397 LDPC VDONEEXIT quit this mess 398 * --- 399 03061 20446973 400 NOGOTAPEM TEXTZ " DiskToTape aborted. Unable to open tape \S1\." 401 0000306D 402 TAPERRTAB LABEL tape error codes 0306D 20457272 403 TEXTZ " Error code zero." 03072 20426164 404 TEXTZ " Bad unit number." 03077 20426164 405 TEXTZ " Bad channel number." 0307D 20426164 406 TEXTZ " Bad slot number." 03082 205C5231 407 TEXTZ " \R1\ is not a tape drive." 03089 20546170 408 TEXTZ " Tape drive not on-line." (no longer used) 03090 20546170 409 TEXTZ " Tape \R1\ is not ready." 410 * (the following errors should not come back from OPENTAPE) 03097 20497272 411 TEXTZ " Irrecoverable tape error." 0309E 2046696C 412 TEXTZ " File mark on read." 030A3 2046696C 413 TEXTZ " File name not found on tape." 030AB 20486561 414 TEXTZ " Header checksum error (from TAPELOAD)." 030B5 20446174 415 TEXTZ " Data checksum error (from TAPELOAD)." 030BF 20447269 416 TEXTZ " Drive is write protected." 030C6 20746869 417 TEXTZ " this tape is not a bootable tape." 030CF 00000000 418 VFD 0 419 420 000030D0 421 NOGODISK LABEL 030D0 60920000 2 0 REG 422 LD R2 R0 copy the error code 030D1 DC1013F9 @ 423 CALL @VPREPOUT tell about problem 030D2 41004820 424 PAR DISKNAME the disk that caused problems 030D3 400030DC 425 PARL NOGODISKM 030D4 DC00348B 426 CALL FINDTEXTZ find right error message 030D5 41528000 2 REG 427 PARV R2 pass the error code 030D6 400030E8 428 PARL OPENERRTAB 030D7 60520000 1 0 REG 429 LD R1 R0 R1 -> error message 030D8 DC1013F9 @ 430 CALL @VPREPOUT tell user about our troubles 030D9 41004820 431 PAR DISKNAME 030DA 40164400 1 @R 432 PARL @R1 030DB 5C8013F0 433 LDPC VDONEEXIT quit this mess 434 * --- 435 030DC 20446973 436 NOGODISKM TEXTZ " DiskToTape aborted. Unable to open disk \R1\." 437 000030E8 438 OPENERRTAB LABEL errors from OPENDISK 030E8 20457272 439 TEXTZ " Error code zero." 030ED 20496E76 440 TEXTZ " Invalid disk name, \R1\." 030F4 205C5231 441 TEXTZ " \R1\ is not a disk." 030FA 20446973 442 TEXTZ " Disk \R1\ is not online." 03101 20457272 443 TEXTZ " Error reading pack label on \R1\." 0310A 20457272 444 TEXTZ " Error reading volume label on \R1\." 03114 20457272 445 TEXTZ " Error reading substitution block on \R1\." 0311F 20496E73 446 TEXTZ " Insufficient memory for substitution list for \R1\." 0312D 20496E74 447 TEXTZ " Internal error attempting to mount \R1\." 03138 20536F6D 448 TEXTZ " Someone else already has \R1\ maintenance mounted." 03145 205C5231 449 TEXTZ " \R1\ is writeprotected." 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 37 F 0 Main Control 0314C 20496E73 450 TEXTZ " Insufficient system resources to mount \R1\." 03158 00000000 451 VFD 0 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 38 F 0 Initializer 454 455 ********************************************************************************** 456 * * 457 * Initializer * 458 * * 459 * This is the initializing code for DISKTOTAPE. * 460 * * 461 ********************************************************************************** 462 463 INITIALIZE BLOCK INITIALIZE 464 465 ENTRY INITIALIZE 466 467 BEGFRAME 468 ENDFRAME 469 03159 DD5F8001 6 STAK 470 INITIALIZE ENTRNP PUSH 471 0315A 60044800 0 IMM 472 LD R0 ADR CLEARAREA get address of area to set to zeros 0315B 60440058 1 IMM 473 LD R1 CLEARLEN*CPW and its length 0315C DA000800 0 1 474 FILLI R0 R1 000 and do it 475 0315D 60044C00 0 IMM 476 LD R0 MCBPLACE get address for MCB build 0315E E4004817 0 477 ST R0 FREESPACE and set for builder 478 0315F 60040022 0 IMM 479 LD R0 RMINPAGES+TPBTPAGES get value for reader 03160 E4004818 0 480 ST R0 READMINPAG minimum starting value 03161 6004001A 0 IMM 481 LD R0 PMINPAGES+TPBTPAGES get value for packer 03162 E4004819 0 482 ST R0 PACKMINPAG minimum starting value 483 03163 6004012C 0 IMM 484 LD R0 MAXPRELS start with maximum PREL count 03164 E4004809 0 485 ST R0 FREEPRELCT 486 03165 6047FFF2 1 IMM 487 LD R1 -PACKPMVTABL set up page map value table 03166 6002000C 0 IMM 488 LD R0 1*PFROBIT+1*PFALTBIT for packing process 03167 60C400A3 3 IMM 489 LD PFPTR PROCPN 00003168 490 INITPPTF LABEL 03168 E422493D 0 1 491 ST R0 PACKPMVTAB(PACKPMVTABL)(R1) hit table entry 03169 18C40001 3 IMM 492 ADD PFPTR 1 advance to next entry 0316A FA603168 1 493 IRJ R1 INITPPTF and check the counter 494 0316B 600434E3 0 IMM 495 LD R0 ADR READINIT initialize read process 0316C E400484F 0 496 ST R0 READPC where to start the read process 0316D 60043A92 0 IMM 497 LD R0 ADR PACKINIT where to start packing process 0316E E4004900 0 498 ST R0 PACKPC so we can have a normal start 0316F 60044170 0 IMM 499 LD R0 ADR WRITEINIT where to start tape write process 03170 E400498D 0 500 ST R0 WRITEPC so we can have a normal start 501 03171 6004480A 0 IMM 502 LD R0 ADR PRPQHEAD initialize queue pointer 03172 E400480B 0 503 ST R0 PRPQTAIL 03173 6004480D 0 IMM 504 LD R0 ADR ENCRYQHD initialize encrypt queue pointer 03174 E400480E 0 505 ST R0 ENCRYQTL 03175 60044811 0 IMM 506 LD R0 ADR TAPEQHEAD initialize tape queue 03176 E4004812 0 507 ST R0 TAPEQTAIL 508 03177 5D1F8001 6 STAK 509 LEAVE POP 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 39 F 0 Initializer 510 * --- 511 512 END INITIALIZE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 40 F 0 Process Scheduler 515 516 ********************************************************************************** 517 * * 518 * SCHEDULER * 519 * * 520 * This is the main scheduling routine for DISKTOTAPE. * 521 * * 522 ********************************************************************************** 523 524 SCHEDULER BLOCK SCHEDULER 525 526 ENTRY SCHEDULER 527 ENTRY DONEREAD 528 ENTRY CHEKPACK 529 ENTRY DONEPACK 530 ENTRY CHEKENCR 531 ENTRY CHEKTAPE 532 ENTRY CHEKIFDONE 533 ENTRY DONETAPE 534 535 536 ********************************************************************************** 537 * Clear unused page file locations that were loaded by OPL * 538 ********************************************************************************** 539 00003178 540 SCHEDULER LABEL main entrance 03178 60C400A3 3 IMM 541 LD PFPTR PROCPN where to start the clearing 00003179 542 CLEARLOOP LABEL 03179 80D20000 0 REG 543 PFRC R0 clear and throw away contents 0317A 18C40001 3 IMM 544 ADD PFPTR 1 move to next page file location 0317B 64C40100 3 IMM 545 CPR PFPTR PFSIZE see if we have reached the end 0317C FE083179 546 JLT CLEARLOOP if not then clear the next location 547 * \ / 548 0317D D0004815 549 INC CPUCOUNT keep track of how many are working 550 * \ / 551 0000317E 552 CHEKREAD LABEL 0317E D1C04800 553 SETT READLOCK get the read lock if possible 0317F FE023187 554 JEQ CHEKPACK if we could not get the lock, try to pack 555 * \ / 556 03180 60004818 0 557 LD R0 READMINPAG get the minimum number of pages 03181 64004806 0 558 CPR R0 FREEPGCNT see if there are enough around 03182 FE043186 559 JGT DONEREAD jump if not, skipping read process 03183 60040019 0 IMM 560 LD R0 MINPRELS get the minimum number of PRELs 03184 64004809 0 561 CPR R0 FREEPRELCT see if there are enough PRELs 03185 FE0A34D5 562 JLE READSTART jump if enough, go to read process 563 * \ / 564 00003186 565 DONEREAD LABEL entrance from read process 03186 EC004800 566 STZ READLOCK say the reading process is open 00003187 567 CHEKPACK LABEL packing process check 03187 D1C04801 568 SETT PACKLOCK get pack process lock if possible 03188 FE023190 569 JEQ CHEKENCR if can't pack, try encrypting 03189 60004819 0 570 LD R0 PACKMINPAG minimum number of pages for pack 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 41 F 0 Process Scheduler 0318A 64004806 0 571 CPR R0 FREEPGCNT see if there are any pages to work with 0318B FE04318F 572 JGT DONEPACK jump if not, skipping pack process 0318C 60040005 0 IMM 573 LD R0 MINPCKPREL minimum number of PRELs for packing 0318D 64004809 0 574 CPR R0 FREEPRELCT see if we have enough free PRELs 0318E FE083A88 575 JLT PACKSTART jump if so, starting pack process 576 * \ / 577 0000318F 578 DONEPACK LABEL 0318F EC004801 579 STZ PACKLOCK indicate pack process not running 00003190 580 CHEKENCR LABEL 03190 FE0E3E16 581 JMP ENCRYPT encrypt can almost always run 582 * --- 583 00003191 584 CHEKTAPE LABEL 03191 D1C04802 585 SETT WRITELOCK see if we can get this first 03192 FE023195 586 JEQ CHEKIFDONE if not see what is next 03193 FE0E416E 587 JMP TAPEWRITE go write on the tape 588 * --- 589 00003194 590 DONETAPE LABEL 03194 EC004802 591 STZ WRITELOCK done with the writing process 592 * \ / 593 594 ********************************************************************************** 595 * * 596 * The following checks are to see if we are done. They * 597 * must be done in the same order as the above scheduler * 598 * checks for free processes. Otherwise we could jump back * 599 * into the scheduler at the wrong place, shutting out a * 600 * process. * 601 * * 602 ********************************************************************************** 603 00003195 604 CHEKIFDONE LABEL 03195 5C004803 605 CMZ READDONE see if finished reading disk 03196 FE02317E 606 JEQ CHEKREAD if not, go try to start reader 03197 5C00480A 607 CMZ PRPQHEAD see if anything left to pack 03198 FE0C3187 608 JNE CHEKPACK if so go check the packing process 03199 5C00480D 609 CMZ ENCRYQHD see if anything left to encrypt 0319A FE0C3190 610 JNE CHEKENCR if so go encrypt it 611 * \ / 612 0319B D0404815 613 DEC CPUCOUNT one less CPU in the running 0319C FE023038 614 JEQ DUMPDONE last one through finishes things up 0319D 60004816 0 615 LD R0 SPINADDR get original address from VEXTRACPUS 0319E E40013FC 0 616 ST R0 VEXTRACPUS replace it into the vector 0319F 5C8013FC 617 LDPC VEXTRACPUS go there 618 * --- 619 620 END SCHEDULER 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 42 F 0 Initialization Subroutines 623 624 ********************************************************************************** 625 * * 626 * GETPARAMS -- parameter fetcher * 627 * * 628 * This subroutine gets the disk drive name and tape * 629 * drive name for DISKTOTAPE. They are returned in DISKNAME * 630 * and TAPENAME. Also we see if the user requested fast * 631 * encryption and set the flag accordingly. * 632 * When DISKTOTAPE is invoked by OPL, R4 points to the * 633 * input buffer used by OPL. Any parameters passed on the * 634 * invocation line are in this buffer. We check this buffer * 635 * first, and if nothing is there prompt the user for the * 636 * parameters. * 637 * Call: * 638 * R4 -> OPL's input buffer * 639 * CALLNP GETPARAMS * 640 * JMP * 641 * Eats R0:R4 * 642 * * 643 ********************************************************************************** 644 645 GETPARAMS BLOCK 646 647 ENTRY GETPARAMS 648 ENTRY COMMTAB 649 ENTRY COMMTABL 650 651 BEGFRAME 652 ENDFRAME 653 031A0 2A444953 654 KICKMSG TEXTZ "*DISKTOTAPE: " 655 031A4 DD5F8001 6 STAK 656 GETPARAMS ENTRNP PUSH 031A5 EDC0481C 657 STW ENCRFASTFL assume fast encryption 031A6 EE00481A 658 STZ2 OPTKEY in case we don't get an optional key 031A7 EE004820 659 STZ2 DISKNAME 031A8 EE00481E 660 STZ2 TAPENAME 031A9 EDC0481D 661 STW GOFLAG assume parameters on invocation line 031AA DC5013F5 @ 662 CALLNP @VFETCHITEM get parameter 031AB F27831B7 1 663 JBF R1/TEOL PROCPARMS skip if something was found 664 * \ / 000031AC 665 KICKUSER LABEL nothing on invocation line 031AC EC00481D 666 STZ GOFLAG don't go until told to 031AD DC1013F9 @ 667 CALL @VPREPOUT tell 'em what we want 031AE 400031A0 668 PARL KICKMSG 669 031AF 60440050 1 IMM 670 LD R1 BUFL Buffer length 031B0 60844827 2 IMM 671 LD R2 ADR BUF Start of the thing 031B1 DC5013F3 @ 672 CALLNP @VREADLINE Read a line 031B2 30440050 1 IMM 673 RSB R1 BUFL See what's left 031B3 FA4A31AC 1 674 JLEZ R1 KICKUSER Ask again if we didn't get anything 675 * \ / 676 677 * We got something. Terminate the buffer and take it from the top 678 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 43 F 0 Initialization Subroutines 679 * \ / 031B4 EC3248CB 1 @ 680 STZ @BUFP(R1) 031B5 610048CB 4 681 LD R4 BUFP R4 -> beginning of input buffer 031B6 DC5013F5 @ 682 CALLNP @VFETCHITEM get parameter 000031B7 683 PROCPARMS LABEL 031B7 F27C31BC 1 684 JBF R1/TALPH PARMERROR jump if didn't get symbol 685 031B8 60040008 0 IMM 686 LD R0 COMMTABL-1 number of commands 000031B9 687 COMMLOOP LABEL 031B9 66A031C9 23 0 688 CPR2 R2 COMMTAB(R0) see if this is what was found 031BA FE0231C8 689 JEQ FOUNDIT if so stop looking 031BB FA2631B9 0 690 JDR R0 COMMLOOP 691 * \ / 692 000031BC 693 PARMERROR LABEL errors in parameters 031BC DC1013F9 @ 694 CALL @VPREPOUT write help line 031BD 400031BF 695 PARL HELPMSG 031BE FE0E31AC 696 JMP KICKUSER Try to get stuff from the console 697 * --- 698 031BF 20074261 699 HELPMSG TEXTZ " Bad parms. Try help or commands." 700 000031C8 701 FOUNDIT LABEL 031C8 5CA031DD 0 702 LDPC COMJTAB(R0) go process command 703 * --- 704 000031C9 705 COMMTAB BSS2 0 031C9 60D0E980 706 PAK12 EXIT 031CB 5F446692 707 PAK12 ENCRYPTALL 031CD 5F43B200 708 PAK12 ENC 031CF 53401790 709 PAK12 COMMANDS 031D1 703D0E80 710 PAK12 HELP 031D3 6B931000 711 PAK12 GO 031D5 82989E00 712 PAK12 KEY 031D7 761A6000 713 PAK12 ID 031D9 9D2A6000 714 PAK12 OT 00000009 ABS 715 COMMTABL EQU DISP2 COMMTAB 716 * We need a multiple of 5 PAK12 names for the commands command, 717 * so we pad this table. 031DB 00000000 718 PAK12 719 000031DD 720 COMJTAB LABEL 031DD 00003211 721 VFD ADR NOGO user wants out 031DE 000031E8 722 VFD ADR SETFLAG encrypt all flag 031DF 000031E8 723 VFD ADR SETFLAG encrypt all flag 031E0 0000322B 724 VFD ADR COMMANDS list commands 031E1 000031E6 725 VFD ADR HELP give help 031E2 000031F7 726 VFD ADR SAYGO set go flag 031E3 000031EA 727 VFD ADR SETKEY set encryption key 031E4 000031EF 728 VFD ADR SETID set input disk 031E5 000031F3 729 VFD ADR SETOT set output tape 730 000031E6 731 HELP LABEL 031E6 DC403246 732 CALLNP GIVEHELP give the user help information 031E7 FE0E31F8 733 JMP NEXTCOMM go do next command 734 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 44 F 0 Initialization Subroutines 735 000031E8 736 SETFLAG LABEL 031E8 EC00481C 737 STZ ENCRFASTFL set flag to encrypt all 031E9 FE0E31F8 738 JMP NEXTCOMM go do next command 739 * --- 740 000031EA 741 SETKEY LABEL 031EA DC40323A 742 CALLNP SKIPEQUAL skip past the equal sign and get a symbol 031EB FE0E31BC 743 JMP PARMERROR 031EC F480481A 2 744 XORM R2 OPTKEY(0) mix in the first half of the key 031ED F4C0481B 3 745 XORM R3 OPTKEY(1) mix in the second half of the key 031EE FE0E31F8 746 JMP NEXTCOMM 747 * --- 748 000031EF 749 SETID LABEL 031EF DC40323A 750 CALLNP SKIPEQUAL skip past the equal sign and get a symbol 031F0 FE0E31BC 751 JMP PARMERROR 031F1 E6804820 23 752 ST2 R2 DISKNAME set the disk's name 031F2 FE0E31F8 753 JMP NEXTCOMM 754 * --- 755 000031F3 756 SETOT LABEL 031F3 DC40323A 757 CALLNP SKIPEQUAL skip past the equal sign and get a symbol 031F4 FE0E31BC 758 JMP PARMERROR 031F5 E680481E 23 759 ST2 R2 TAPENAME set the disk's name 031F6 FE0E31F8 760 JMP NEXTCOMM 761 * --- 762 000031F7 763 SAYGO LABEL 031F7 EDC0481D 764 STW GOFLAG say it is time to go 765 * \ / 766 000031F8 767 NEXTCOMM LABEL 031F8 DC5013F5 @ 768 CALLNP @VFETCHITEM get the next thing on the line 031F9 F27831B7 1 769 JBF R1/TEOL PROCPARMS continuing processing parameters 031FA 5C00481D 770 CMZ GOFLAG see if we should go 031FB FE0231AC 771 JEQ KICKUSER if not prompt for more input 772 * \ / 773 774 ********************************************************************************** 775 * We have the tape and disk drives, now let's double * 776 * check. * 777 ********************************************************************************** 778 779 * \ / 000031FC 780 ASKIFOK LABEL 031FC DC1013F9 @ 781 CALL @VPREPOUT print the verification question 031FD 41004820 782 PAR DISKNAME the disk drive 031FE 4100481E 783 PAR TAPENAME the tape drive 031FF 40003212 784 PARL ASKMESS the question 785 03200 60440050 1 IMM 786 LD R1 BUFL length of buffer 03201 60844827 2 IMM 787 LD R2 ADR BUF where the buffer is 03202 DC5013F3 @ 788 CALLNP @VREADLINE read the answer 03203 30440050 1 IMM 789 RSB R1 BUFL get the length of the response 03204 FA4A31FC 1 790 JLEZ R1 ASKIFOK ask again if we didn't get anything 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 45 F 0 Initialization Subroutines 791 * \ / 03205 EC3248CB 1 @ 792 STZ @BUFP(R1) mark the end 03206 610048CB 4 793 LD R4 BUFP R4 -> first char of buffer 03207 DC5013F5 @ 794 CALLNP @VFETCHITEM get the response 03208 648048CC 2 795 CPR R2 PACKNO see if the response is negative 03209 FE0231AC 796 JEQ KICKUSER jump if can't do this 0320A 648048CD 2 797 CPR R2 PACKN see if the response is negative 0320B FE0231AC 798 JEQ KICKUSER jump if can't do this 0320C 648048CE 2 799 CPR R2 PACKYES is it a yes? 0320D FE023210 800 JEQ ITSOK he wants to do it 0320E 648048CF 2 801 CPR R2 PACKY then how about a y? 0320F FE0C31FC 802 JNE ASKIFOK if not then make 'em give a vaild answer 803 * \ / 804 00003210 805 ITSOK LABEL 03210 19C40001 7 IMM 806 ADD R7 1 normal return 00003211 807 NOGO LABEL abort return 03211 5D1F8001 6 STAK 808 LEAVE POP 809 * --- 810 03212 2A436F70 811 ASKMESS TEXTZ "*Copying volume from \S1\ to \S2\. Proceed? (Y|N): " 812 03220 205C5331 813 COMMES TEXTZ " \S1,12\ \S2,12\ \S3,12\ \S4,12\ \S5,12\" 814 0000322B 815 COMMANDS LABEL 0322B DC1013F9 @ 816 CALL @VPREPOUT 0322C 410031C9 817 PAR COMMTAB(0) 0322D 410031CB 818 PAR COMMTAB(2) 0322E 410031CD 819 PAR COMMTAB(4) 0322F 410031CF 820 PAR COMMTAB(6) 03230 410031D1 821 PAR COMMTAB(8) 03231 40003220 822 PARL COMMES 823 03232 DC1013F9 @ 824 CALL @VPREPOUT 03233 410031D3 825 PAR COMMTAB(10) 03234 410031D5 826 PAR COMMTAB(12) 03235 410031D7 827 PAR COMMTAB(14) 03236 410031D9 828 PAR COMMTAB(16) 03237 410031DB 829 PAR COMMTAB(18) 03238 40003220 830 PARL COMMES 831 03239 FE0E31AC 832 JMP KICKUSER 833 * --- 834 835 END GETPARAMS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 46 F 0 Initialization Subroutines 837 838 ********************************************************************************** 839 * * 840 * SKIPEQUAL * 841 * * 842 * This routine skips past the equal sign on the input * 843 * line and picks up the next item on the line. * 844 * * 845 * Call: * 846 * CALLNP SKIPEQUAL * 847 * JMP garbage on line * 848 * * 849 * Returns R2,R3 with PAK12 symbol, R1 with FETCHITEM code * 850 * Eats R0:R3 * 851 * * 852 ********************************************************************************** 853 854 SKIPEQUAL BLOCK 855 856 ENTRY SKIPEQUAL 857 858 BEGFRAME 859 ENDFRAME 860 0323A DD5F8001 6 STAK 861 SKIPEQUAL ENTRNP PUSH 0323B 60130000 0 4 REG 862 LD R0 R4 R0 -> position in input buffer 0323C 60440050 1 IMM 863 LD R1 BUFL how far to search 0323D 6084003D 2 IMM 864 LD R2 "=" what to look for 0323E FE560000 865 CSRCH 0323F FE0C3245 866 JNE ERRETURN jump if we did not find it 03240 D0920000 0 REG 867 INCP R0 move beyond equal sign 03241 61120000 4 0 REG 868 LD R4 R0 R4 -> equal sign 03242 DC5013F5 @ 869 CALLNP @VFETCHITEM pick up next item on line 03243 F27C3245 1 870 JBF R1/TALPH ERRETURN if we did not get a symbol 03244 19C40001 7 IMM 871 ADD R7 1 good return 00003245 872 ERRETURN LABEL 03245 5D1F8001 6 STAK 873 LEAVE POP 874 * --- 875 876 END SKIPEQUAL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 47 F 0 Initialization Subroutines 878 879 ********************************************************************************** 880 * * 881 * GIVEHELP * 882 * * 883 * This subroutine gives help information to the user * 884 * about individual commands or about this program. * 885 * Call: * 886 * CALLNP GIVEHELP * 887 * * 888 * Eats R0:R4 * 889 * * 890 ********************************************************************************** 891 892 GIVEHELP BLOCK 893 894 ENTRY GIVEHELP 895 896 BEGFRAME 00178801 6 BASE 897 MESPTR BSS 1 holds pointer to current line of help output 898 ENDFRAME 899 03246 DD5F8002 6 STAK 900 GIVEHELP ENTRNP PUSH 03247 DC5013F5 @ 901 CALLNP @VFETCHITEM fetch the next item (command name) 03248 F678324E 1 902 JBT R1/TEOL GENERAL give general help if no command name 03249 F27C324E 1 903 JBF R1/TALPH GENERAL must be symbol if a valid command name 0324A 60040008 0 IMM 904 LD R0 COMMTABL-1 get number of commands in table 0000324B 905 HELPCOMLP LABEL 0324B 66A031C9 23 0 906 CPR2 R2 COMMTAB(R0) look for this command 0324C FE023250 907 JEQ HELPCOMFND jump if found 0324D FA26324B 0 908 JDR R0 HELPCOMLP go back until done 909 * \ / sorry, no such command 910 0000324E 911 GENERAL LABEL 0324E 60043272 0 IMM 912 LD R0 ADR HIGENHELP get pointer to general help 0324F FE0E3251 913 JMP HELPWPTR and go to general printer 914 * --- 915 00003250 916 HELPCOMFND LABEL 03250 60203269 0 0 917 LD R0 COMMHELPT(R0) get pointer to the appropriate text 00003251 918 HELPWPTR LABEL 03251 E4178801 0 6 BASE 919 ST R0 SP,MESPTR and save for following code 00003252 920 HELPNXTLIN LABEL 03252 60178801 0 6 BASE 921 LD R0 SP,MESPTR pick up the message pointer 03253 60440064 1 IMM 922 LD R1 100 all lines are shorter than this 03254 60840000 2 IMM 923 LD R2 0 we will look for the terminator (null) 03255 FE560000 924 CSRCH look for its end 03256 FE0C325E 925 JNE HELPERR must find terminator 03257 30440064 1 IMM 926 RSB R1 100 make line length 03258 FA42325D 1 927 JEQZ R1 HELPDONE if another null, done with help 03259 38960801 2 0 BASE 928 LEA R2 R0,1 make word address of next word 0325A E0978801 2 6 BASE 929 EXCH R2 SP,MESPTR put this away for next search, and get last to print 0325B DC5013F4 @ 930 CALLNP @VWRITELINE print out the line 0325C FE0E3252 931 JMP HELPNXTLIN and go for the next line 932 * --- 933 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 48 F 0 Initialization Subroutines 0000325D 934 HELPDONE LABEL 0325D 5D1F8002 6 STAK 935 LEAVE POP 936 * --- 937 0000325E 938 HELPERR LABEL 0325E DC1013F9 @ 939 CALL @VPREPOUT call to output desperation message 0325F 40003261 940 PARL HELPBUG must be bug in internal messages 03260 FE0E325D 941 JMP HELPDONE and back to main control 942 * --- 943 03261 202A2A2A 944 HELPBUG TEXTZ " *** bug in help routine ***" 945 00003269 946 COMMHELPT LABEL pointers to the help messages 03269 000032E4 947 VFD ADR HIEXIT 0326A 0000330B 948 VFD ADR HIENC 0326B 0000330B 949 VFD ADR HIENC 0326C 000032D6 950 VFD ADR HICOMMAND 0326D 000032B8 951 VFD ADR HIHELP 0326E 000032F7 952 VFD ADR HIGO 0326F 00003391 953 VFD ADR HIKEY 03270 00003368 954 VFD ADR HIID 03271 0000332F 955 VFD ADR HIOT 956 00003272 957 HIGENHELP LABEL 03272 2020464F 958 TEXTZ " FORMAT: DISKTOTAPE ID=DSKscu, OT=TAPscu [,KEY=] [,ENCRYPTALL|ENC]" 03285 20202020 959 TEXTZ " This program performs an offline disk to tape backup. The" 03295 20207265 960 TEXTZ " resulting tape is of the same format as used by online BACKUP." 032A6 20205061 961 TEXTZ " Parameters may be given on the invocation line, or interactively." 032B7 20000000 962 TEXTZ " " 963 * don't zero terminate so we also give help message 000032B8 964 HIHELP LABEL 032B8 2020466F 965 TEXTZ " For a list of valid commands, type 'Commands'. For help with" 032C8 20206120 966 TEXTZ " a specific command, type 'help '." 032D5 00000000 967 VFD 0 000032D6 968 HICOMMAND LABEL 032D6 20205468 969 TEXTZ " This command prints a list of the valid commands." 032E3 00000000 970 VFD 0 000032E4 971 HIEXIT LABEL 032E4 20205468 972 TEXTZ " This command returns control to OPL without performing" 032F3 20206120 973 TEXTZ " a backup." 032F6 00000000 974 VFD 0 000032F7 975 HIGO LABEL 032F7 20205468 976 TEXTZ " This command starts the backup with the previously" 03305 20206769 977 TEXTZ " given parameters." 0330A 00000000 978 VFD 0 0000330B 979 HIENC LABEL 0330B 2020464F 980 TEXTZ " FORMAT: [ENCRYPTALL|ENC]" 03312 20202020 981 TEXTZ " This parameter causes DISKTOTAPE to encrypt all" 03320 20206163 982 TEXTZ " accounts even if they have the no encrypt flag set." 0332E 00000000 983 VFD 0 0000332F 984 HIOT LABEL 0332F 2020464F 985 TEXTZ " FORMAT: OT=TAPscu (s=slot, c=channel, u=unit)" 0333C 20202020 986 TEXTZ " This command is used to specify the output tape drive" 0334B 20207768 987 TEXTZ " which is being used for this backup operation. There" 03359 20206D75 988 TEXTZ " must be a tape, ready to use, in the specified drive." 03367 00000000 989 VFD 0 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 49 F 0 Initialization Subroutines 00003368 990 HIID LABEL 03368 2020464F 991 TEXTZ " FORMAT: ID=DSKscu (s=slot, c=channel, u=unit)" 03375 20202020 992 TEXTZ " This command is used to specify the input disk drive" 03384 20207768 993 TEXTZ " which contains the volume being backed up." 03390 00000000 994 VFD 0 00003391 995 HIKEY LABEL 03391 2020464F 996 TEXTZ " FORMAT: [KEY=]" 0339B 20202020 997 TEXTZ " This command is used to specify an optional extra" 033A9 2020656E 998 TEXTZ " encryption key. This key has the same restriction as" 033B7 20206669 999 TEXTZ " file names. Multiple keys may be used by specifying" 033C5 20207468 1000 TEXTZ " this parameter multiple times." 033CE 00000000 1001 VFD 0 1002 1003 END GIVEHELP 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 50 F 0 Initialization Subroutines 1005 1006 ********************************************************************************** 1007 * * 1008 * GETENCPARM -- Get Encryption Parameters * 1009 * * 1010 * Here we get the parameters necessary for the * 1011 * encryption routine which are also used for other purposes * 1012 * by different processes. These parameters are STARTTIME, * 1013 * SYSSN, and SYSPWD. * 1014 * Call: * 1015 * CALLNP GETENCPARM * 1016 * * 1017 * Eats R0:R3 * 1018 * * 1019 ********************************************************************************** 1020 1021 GETENCPARM BLOCK 1022 1023 ENTRY GETENCPARM 1024 1025 BEGFRAME 1026 ENDFRAME 1027 033CF DD5F8001 6 STAK 1028 GETENCPARM ENTRNP PUSH 033D0 DC5013FB @ 1029 CALLNP @VGETDATE get our time stamp 033D1 E6804822 23 1030 ST2 R2 STARTTIME save the starting time 033D2 60C40086 3 IMM 1031 LD PFPTR PNCIX page number reserved for I/O 033D3 601013E5 0 @ 1032 LD R0 @VPF4SSU page map value for SSU 033D4 18040001 0 IMM 1033 ADD R0 (SSUNVM-SSUCOFFSET)/WPP move to NVM location 033D5 00D20000 0 REG 1034 LDPF R0 map SSU into CIX 033D6 DC0033E7 1035 CALL READNVM get system serial number 033D7 4144003C IMM 1036 PARV NVMSSN its address 033D8 40440004 IMM 1037 PARVL 4 number of bytes to read 033D9 E4004824 0 1038 ST R0 SYSSN save the result 033DA DC0033E7 1039 CALL READNVM get system password 033DB 41440022 IMM 1040 PARV NVMTAPEPW its address 033DC 40440008 IMM 1041 PARVL 8 number of bytes to read 033DD E6004825 01 1042 ST2 R0 SYSPWD save result 033DE 7600481A 01 1043 XOR2 R0 OPTKEY mix with optional key 033DF E600481A 01 1044 ST2 R0 OPTKEY save this for encryption key 033E0 80D20000 0 REG 1045 PFRC R0 clear i/o page 033E1 60449400 1 IMM 1046 LD R1 ADR PROGB R1 -> program buffer (used by TBM) 033E2 38084080 0 1 ZBM 1047 LEA R0 R1,0/CH0 make a pointer to program buffer by chars 033E3 E400032D 0 1048 ST R0 APROGBC put it in the pointer 033E4 38084050 0 1 ZBM 1049 LEA R0 R1,0/BITS 0:4 and one to program buffer by 5 bits 033E5 E400032E 0 1050 ST R0 APROGB5S put it in the pointer 033E6 5D1F8001 6 STAK 1051 LEAVE POP 1052 * --- 1053 1054 END GETENCPARM 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 51 F 0 Initialization Subroutines 1056 1057 ********************************************************************************** 1058 * * 1059 * READNVM * 1060 * This routine is provided to read a specific datum * 1061 * from the NVM. * 1062 * Call: * 1063 * SSU NVM mapped into CIX * 1064 * CALL READNVM eats R2 during parameter passing * 1065 * PARV
* 1066 * PARVL * 1067 * * 1068 * Eats R0:R3 * 1069 * * 1070 ********************************************************************************** 1071 1072 READNVM BLOCK 1073 1074 ENTRY READNVM read a complete value from the NVM 1075 1076 BEGFRAME 00178801 6 BASE 1077 NUMBYTES BSS 1 number of bytes to read 00178802 6 BASE 1078 BILDSPOTW BSS2 0 word address for following 00178008 6 CACH 1079 BILDSPOT BSSC 8 allow for up to 8 byte length 1080 ENDFRAME 1081 033E7 DD1F8004 6 STAK 1082 READNVM ENTR PUSH 033E8 C1524000 1 REG 1083 STPV R1 save the address 033E9 C0578801 6 BASE 1084 STPVL SP,NUMBYTES and the byte count 033EA 38978008 2 6 CACH 1085 LEA R2 SP,BILDSPOT make pointer to build area on stack 033EB EE178802 6 BASE 1086 STZ2 SP,BILDSPOTW initialize for some callers 000033EC 1087 NEXTBYTE LABEL 033EC 60221800 0 1 1088 LD R0 CIX(R1) read a byte from the NVM 033ED E4168400 0 2 @R 1089 ST R0 @R2 and store that byte 033EE 18440001 1 IMM 1090 ADD R1 1 advance the NVM address 033EF D0928000 2 REG 1091 INCP R2 and advance the build pointer 033F0 D0578801 6 BASE 1092 DEC SP,NUMBYTES decrement the count 033F1 FE0433EC 1093 JGT NEXTBYTE jump if still more bytes to go 033F2 62178802 016 BASE 1094 LD2 R0 SP,BILDSPOTW load the data picked up 033F3 5D1F8004 6 STAK 1095 LEAVE POP Return 1096 * --- 1097 1098 END READNVM 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 52 F 0 Initialization Subroutines 1100 1101 ********************************************************************************** 1102 * * 1103 * BUILDMCBS * 1104 * * 1105 * Search the slot table for memory and initialize MCBs * 1106 * using found memory. For safety, we will fill the pages * 1107 * where we are going to build MCBs with zeroes. * 1108 * Eats R0:R4 * 1109 * * 1110 ********************************************************************************** 1111 1112 BUILDMCBS BLOCK 1113 1114 ENTRY BUILDMCBS 1115 1116 BEGFRAME 1117 ENDFRAME 1118 033F4 DD5F8001 6 STAK 1119 BUILDMCBS ENTRNP PUSH 033F5 60844C00 2 IMM 1120 LD R2 MCBPLACE so we can zero out before building MCBs 033F6 60448000 1 IMM 1121 LD R1 NUMMCBPAG*CPP how many pages to clean out for them 033F7 FE580000 1122 CFILL 00 lots and lots of zeroes 1123 033F8 61040000 4 IMM 1124 LD R4 0 load slot to look at 033F9 60440001 1 IMM 1125 LD R1 MEMDEVICE what we are looking for 000033FA 1126 NEXTMEM LABEL 033FA 60280370 0 4 1127 LD R0 IBSLOTS(R4) get this slots data word 033FB 644A0040 1 0 CBM 1128 CPR R1 R0/WRU0TYPE see if we have found some memory 033FC FE0C3400 1129 JNE EMPTYSLOT if not try next slot 033FD DC403404 1130 CALLNP HAVEMEMORY call the memory initializer 033FE FE0E3403 1131 JMP MCBSDONE enough MCBs, time to leave 1132 * \ / 1133 033FF 60440001 1 IMM 1134 LD R1 MEMDEVICE what we are looking for 00003400 1135 EMPTYSLOT LABEL 03400 19040001 4 IMM 1136 ADD R4 1 advance to next slot 03401 65040010 4 IMM 1137 CPR R4 NUMSLOTS see if we're done 03402 FE0833FA 1138 JLT NEXTMEM jump if not, on to next device 1139 * \ / 1140 00003403 1141 MCBSDONE LABEL 03403 5D1F8001 6 STAK 1142 LEAVE POP 1143 * --- 1144 1145 END BUILDMCBS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 53 F 0 Initialization Subroutines 1147 1148 ********************************************************************************** 1149 * * 1150 * HAVEMEMORY - Generate MCB Elements for a Memory * 1151 * * 1152 * Scanning through the slot table we have found an MCU. * 1153 * This memory is carved into pages and an MCB is generated * 1154 * for each page. The MCBs are linked together in the free * 1155 * memory list. We use the 8 pages allocated for MCBs and * 1156 * take 16 word chunks for each new MCB. This allows up to 512 * 1157 * MCBs so we limit our usable memory to 500 pages, which is * 1158 * plenty for our job. * 1159 * * 1160 * Several pages are taken by the boot routine to read * 1161 * OPL into. Additional pages are taken by OPL to read us * 1162 * (DISKTOTAPE) into. If the memory box being configured here * 1163 * is the memory that was booted into (known by comparing * 1164 * against the slot number in the PHPNAV), we do not generate * 1165 * MCB's for those pages up to LASTPN. * 1166 * * 1167 * LD R0 WRU response from memory * 1168 * LD R4 slot number * 1169 * CALLNP HAVEMEMORY * 1170 * JMP * 1171 * * 1172 * Eats R0:R3. * 1173 * * 1174 ********************************************************************************** 1175 1176 HAVEMEMORY BLOCK 1177 ENTRY HAVEMEMORY 1178 1179 BEGFRAME 00178801 6 BASE 1180 MEMMASK BSS 1 number of pages described by each bit 1181 * of WRUMEMHERE, less one. 00178802 6 BASE 1182 MEMBITS BSS 1 bits for memory addresses present, 1183 * from WRUMEMHERE. 00178803 6 BASE 1184 MEMPFILE BSS 1 running page file value. 00178804 6 BASE 1185 LASTSYS BSS 1 last page in memory used by us, 1186 * or -1 if none 1187 ENDFRAME 1188 03404 DD5F8005 6 STAK 1189 HAVEMEMORY ENTRNP PUSH 03405 EC178803 6 BASE 1190 STZ SP,MEMPFILE clean out page file 03406 D1578804 6 BASE 1191 STMW SP,LASTSYS assume we didn't boot from this mem 03407 E5098843 4 6 ZBM 1192 ST R4 SP,MEMPFILE/PFSLOT save slot number in page file 03408 605013E6 1 @ 1193 LD R1 @VMEMPF get page file for some page in our memory 03409 650A4840 4 1 CBM 1194 CPR R4 R1/PFSLOT did we use this memory? 0340A FE0C340F 1195 JNE NOTBOOTMEM jump if not 0340B 6044002B 1 IMM 1196 LD R1 LASTPN last page used by boot routine and OPL 0340C 784048C8 1 1197 AND R1 PFCLNMASK clean out garbage bits in page file 0340D E50A4840 4 1 CBM 1198 ST R4 R1/PFSLOT put in the slot part 0340E E4578804 1 6 BASE 1199 ST R1 SP,LASTSYS last used system page 1200 0000340F 1201 NOTBOOTMEM LABEL 0340F 600A2040 0 0 CBM 1202 LD R0 R0/WRUMEMINC description of size of blocks of mem 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 54 F 0 Initialization Subroutines 03410 60440010 1 IMM 1203 LD R1 16 00003411 1204 MEMDOUBLE LABEL 03411 18524000 1 1 REG 1205 ADD R1 R1 03412 FA263411 0 1206 JDR R0 MEMDOUBLE 1207 * \ / 1208 * Now, R1 has the number of pages that are described by 1209 * each bit of the memory's WRU4 response. 1210 * \ / 03413 10440001 1 IMM 1211 SUB R1 1 turn into mask of lower bits 03414 E4578801 1 6 BASE 1212 ST R1 SP,MEMMASK save it 03415 60130000 0 4 REG 1213 LD R0 R4 slot number 03416 1C040010 0 IMM 1214 MUL R0 WRUIMAX index for array 03417 60200204 0 0 1215 LD R0 WRUIPROTO/WRU4(R0) get WRU4 response 03418 F62C3432 0 1216 JBT R0/WRUMEMNONE RETURN jump if no memory connected 03419 F22E341E 0 1217 JBF R0/WRUMEMBAD SETUPBLOCK jump if memory is useable 1218 * \ / 1219 * This memory is not useable. Let's say so. 1220 * \ / 0341A 18C0341D 3 1221 ADD R3 STOPINST build a stop instruction 0341B 5D52C000 3 REG 1222 XCT R3 do it. 0341C FE0E3432 1223 JMP RETURN if he wants to RUN, skip this MCU 1224 * --- 1225 0341D 00826000 1226 STOPINST STOP STOPB600X memory cabled wrong to MCU 1227 0000341E 1228 SETUPBLOCK LABEL 0341E 60840002 2 IMM 1229 LD R2 TMCB keep this code in R2 for call to GENMCB 0341F 600A3080 0 0 CBM 1230 LD R0 R0/WRUMEMHERE get bits for addresses present 1231 * \ / 1232 * Each time through the following loop builds the MCB's for 1233 * one contiguous chunk of memory (MEMMASK+1 pages). 1234 * \ / 00003420 1235 BUILDBLOCK LABEL 03420 E4178802 0 6 BASE 1236 ST R0 SP,MEMBITS save the bits 03421 F63E3426 0 1237 JBT R0/BIT 31 BUILDPAGE jump if the memory is really here 1238 * \ / 1239 * Here, the block doesn't exist. Just increment the page number. 1240 * \ / 03422 60178801 0 6 BASE 1241 LD R0 SP,MEMMASK 03423 60161001 0 0 REG 1242 LD R0 R0+1 number of pages per chunk 03424 98178803 0 6 BASE 1243 ADDM R0 SP,MEMPFILE increment counter 03425 FE0E3430 1244 JMP NEXTBLOCK 1245 * --- 1246 00003426 1247 BUILDPAGE LABEL 03426 60D78803 3 6 BASE 1248 LD R3 SP,MEMPFILE page file value for first page 03427 64D78804 3 6 BASE 1249 CPR R3 SP,LASTSYS page used by boot? 03428 FE0A342D 1250 JLE NOREGENSYS if so, no MCB wanted 03429 DC403434 1251 CALLNP GENMCB build an MCB for it 0342A BC004806 0 1252 INCL R0 FREEPGCNT say one more free page exists 0342B 640401F4 0 IMM 1253 CPR R0 MAXMEMRY see if we have all the pages we need 0342C FE043433 1254 JGT ALLDONE if so we can quit 0000342D 1255 NOREGENSYS LABEL 0342D BC178803 0 6 BASE 1256 INCL R0 SP,MEMPFILE increment to next page 0342E 78178801 0 6 BASE 1257 AND R0 SP,MEMMASK are we done with one block? 0342F FA0C3426 0 1258 JNEZ R0 BUILDPAGE jump if not 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 55 F 0 Initialization Subroutines 1259 * \ / 00003430 1260 NEXTBLOCK LABEL 03430 600981F2 0 6 ZBM 1261 LD R0 SP,MEMBITS/BITS 0:30 remove bit for work done 03431 FA0C3420 0 1262 JNEZ R0 BUILDBLOCK jump if more to do 1263 * \ / 1264 00003432 1265 RETURN LABEL 03432 19C40001 7 IMM 1266 ADD R7 1 advance for normal return 00003433 1267 ALLDONE LABEL max pages found 03433 5D1F8005 6 STAK 1268 LEAVE POP all done 1269 * --- 1270 1271 END HAVEMEMORY 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 56 F 0 Initialization Subroutines 1273 1274 ********************************************************************************** 1275 * * 1276 * GENMCB -- generate an MCB * 1277 * * 1278 * We have a page of memory so now we build a control * 1279 * block for it. The first time here we set up the free page * 1280 * list pointer. We always leave FREESPACE pointing to the * 1281 * next available word after the MCB we have constructed. * 1282 * Next time through we back up MCBLNTH to get to the previous * 1283 * MCB so that we may set the forward link. * 1284 * Call: * 1285 * LD R3 page map value for new page * 1286 * CALLNP GENMCB * 1287 * Eats R0,R1 * 1288 * * 1289 ********************************************************************************** 1290 1291 GENMCB BLOCK 1292 1293 ENTRY GENMCB 1294 1295 BEGFRAME 1296 ENDFRAME 1297 03434 DD5F8001 6 STAK 1298 GENMCB ENTRNP PUSH 03435 60004817 0 1299 LD R0 FREESPACE available place to put an MCB 03436 E4D60801 3 0 BASE 1300 ST R3 R0,MCBPMV put in the page map value 03437 E4880040 2 0 ZBM 1301 ST R2 R0,MCBTYPE set the type into this MCB 03438 60404804 1 1302 LD R1 PAGEQ pointer to MCB list 03439 E4481F10 1 0 ZBM 1303 ST R1 R0,MCBLINK add this element to head of list 0343A E4004804 0 1304 ST R0 PAGEQ this is the new list head 0343B 60040010 0 IMM 1305 LD R0 MCBLNTH get the length of an element 0343C 98004817 0 1306 ADDM R0 FREESPACE to move freeplace accordingly 0343D 5D1F8001 6 STAK 1307 LEAVE POP 1308 * --- 1309 1310 END GENMCB 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 57 F 0 Initialization Subroutines 1312 1313 ********************************************************************************** 1314 * * 1315 * BUILDPRELS * 1316 * * 1317 * We loop dividing memory into a bunch of PRELLNTH * 1318 * chunks and linking them together to form the list of free * 1319 * physical record elements. * 1320 * Call: * 1321 * CALLNP BUILDPRELS * 1322 * Eats R0:R2 * 1323 * * 1324 ********************************************************************************** 1325 1326 BUILDPRELS BLOCK 1327 1328 ENTRY BUILDPRELS 1329 1330 BEGFRAME 1331 ENDFRAME 1332 0343E DD5F8001 6 STAK 1333 BUILDPRELS ENTRNP PUSH 0343F 60846C00 2 IMM 1334 LD R2 PRELPLACE first clean up the pages 03440 60447530 1 IMM 1335 LD R1 MAXPRELS*PRELLNTH*CPW how much to clear out 03441 FE580000 1336 CFILL 00 make them clean pages 1337 03442 60046C00 0 IMM 1338 LD R0 PRELPLACE where we will put the PRELS 03443 E4004807 0 1339 ST R0 PRELQ set up pointer to free PREL list 03444 6084012C 2 IMM 1340 LD R2 MAXPRELS the number of PRELS we will build 00003445 1341 PRELLOOP LABEL 03445 60520000 1 0 REG 1342 LD R1 R0 R0 -> this PREL 03446 18440019 1 IMM 1343 ADD R1 PRELLNTH R1 -> next PREL 03447 E4481F10 1 0 ZBM 1344 ST R1 R0,PRELLINK put in forward link 03448 60124000 0 1 REG 1345 LD R0 R1 R0 -> next PREL 03449 FAA23445 2 1346 DRJ R2 PRELLOOP do the next PREL 1347 * \ / 0344A EC160800 0 BASE 1348 STZ R0,PRELWORDA make sure we point nowhere 1349 * (use whole word to fix parity) 0344B 5D1F8001 6 STAK 1350 LEAVE POP 1351 * --- 1352 1353 END BUILDPRELS 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 58 F 0 Queue Manipulation Subroutines 1356 1357 ********************************************************************************** 1358 * * 1359 * UNLINKPAGE -- remove a page from the free page list * 1360 * * 1361 * This subroutine simply removes an MCB from the free * 1362 * page list and returns a pointer to the MCB. The caller must * 1363 * have the list locked and be sure there are enough pages in * 1364 * the list. * 1365 * * 1366 * Returns R4 -> MCB and free page list unlocked. * 1367 * Eats R0 * 1368 * * 1369 ********************************************************************************** 1370 1371 UNLINKPAGE BLOCK 1372 1373 ENTRY UNLINKPAGE 1374 1375 BEGFRAME 1376 ENDFRAME 1377 0344C DD5F8001 6 STAK 1378 UNLINKPAGE ENTRNP PUSH 0344D D0404806 1379 DEC FREEPGCNT say we are taking a page 0344E 61004804 4 1380 LD R4 PAGEQ get pointer to first free MCB 0344F 60091F10 0 4 ZBM 1381 LD R0 R4,MCBLINK get pointer to next MCB on the list 03450 E4004804 0 1382 ST R0 PAGEQ and call it the first free MCB 03451 EC004805 1383 STZ PAGEQLOCK free up list for others use 03452 EC091F10 4 ZBM 1384 STZ R4,MCBLINK wipe out any link 03453 5D1F8001 6 STAK 1385 LEAVE POP return to caller 1386 * --- 1387 1388 END UNLINKPAGE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 59 F 0 Queue Manipulation Subroutines 1390 1391 ********************************************************************************** 1392 * * 1393 * UNLINKPREL -- remove a page from the free page list * 1394 * * 1395 * This subroutine simply removes a PREL from the free * 1396 * PREL list and returns a pointer to the PREL. The caller * 1397 * must have the list locked and be sure there are enough * 1398 * PRELs in the list. We also clean out the information * 1399 * fields of the PREL. * 1400 * Returns R5 -> PREL and the free PREL list unlocked. * 1401 * Eats R0 * 1402 * * 1403 ********************************************************************************** 1404 1405 UNLINKPREL BLOCK 1406 1407 ENTRY UNLINKPREL 1408 1409 BEGFRAME 1410 ENDFRAME 1411 03454 DD5F8001 6 STAK 1412 UNLINKPREL ENTRNP PUSH 03455 D0404809 1413 DEC FREEPRELCT say we are taking a PREL 03456 61404807 5 1414 LD R5 PRELQ get pointer to first free PREL 03457 60095F10 0 5 ZBM 1415 LD R0 R5,PRELLINK get pointer to next PREL on the list 03458 E4004807 0 1416 ST R0 PRELQ and call it the first free PREL 03459 EC004808 1417 STZ PRELQLOCK free up list for others use 0345A EE174800 5 BASE 1418 STZ2 R5,PRELWORDA clean out the link, type, encrypt, flag 1419 * MCB count, and physical record length 1420 * fields in one clean swoop 0345B 5D1F8001 6 STAK 1421 LEAVE POP return to caller 1422 * --- 1423 1424 END UNLINKPREL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 60 F 0 Queue Manipulation Subroutines 1426 1427 ********************************************************************************** 1428 * * 1429 * MAPINPR -- Map in a physical record * 1430 * * 1431 * This subroutine maps a physical record into a CPUs * 1432 * virtual space. * 1433 * * 1434 * Call: * 1435 * R5 -> PREL * 1436 * CALL MAPINPR * 1437 * PARVL * 1438 * * 1439 * Eats R0:R3 * 1440 * * 1441 ********************************************************************************** 1442 1443 MAPINPR BLOCK 1444 1445 ENTRY MAPINPR 1446 1447 BEGFRAME 1448 ENDFRAME 1449 0345C DD1F8001 6 STAK 1450 MAPINPR ENTR PUSH 0345D C052C000 3 REG 1451 STPVL PFPTR virtual page number to start mapin at 0345E 60494041 1 5 ZBM 1452 LD R1 R5,PRELMCBCNT how many pages to map in 0345F 18D24000 3 1 REG 1453 ADD PFPTR R1 map in high ones first 03460 FE0E3463 1454 JMP INTOLOOP 1455 * --- 1456 00003461 1457 MAPLOOP LABEL 03461 609D4803 2 51 BASE 1458 LD R2 R5,PRELMCBPTR(R1) R2 -> an MCB 03462 00D68801 2 BASE 1459 LDPF R2,MCBPMV map in the page 00003463 1460 INTOLOOP LABEL 03463 10C40001 3 IMM 1461 SUB PFPTR 1 move back one page file location 03464 FA663461 1 1462 JDR R1 MAPLOOP do the next one 1463 * \ / 1464 03465 5D1F8001 6 STAK 1465 LEAVE POP 1466 * --- 1467 1468 END MAPINPR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 61 F 0 Queue Manipulation Subroutines 1470 1471 ********************************************************************************** 1472 * * 1473 * PAGERETURN * 1474 * * 1475 * This subroutine returns a page to the free page list. * 1476 * Call: * 1477 * LD R4 ADR MCB * 1478 * CALLNP PAGERETURN * 1479 * * 1480 * Eats R0 * 1481 * * 1482 ********************************************************************************** 1483 1484 PAGERETURN BLOCK 1485 1486 ENTRY PAGERETURN 1487 1488 BEGFRAME 1489 ENDFRAME 1490 03466 DD5F8001 6 STAK 1491 PAGERETURN ENTRNP PUSH 1492 LLOCK PAGEQLOCK lock the list 0346B 60004804 0 1493 LD R0 PAGEQ get pointer to first element 0346C E4091F10 0 4 ZBM 1494 ST R0 R4,MCBLINK make the returning MCB point to it 0346D E5004804 4 1495 ST R4 PAGEQ returning MCB is at first of list 0346E D0004806 1496 INC FREEPGCNT say another page is in list 0346F EC004805 1497 STZ PAGEQLOCK free the list 03470 5D1F8001 6 STAK 1498 LEAVE POP 1499 * --- 1500 1501 END PAGERETURN 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 62 F 0 Queue Manipulation Subroutines 1503 1504 ********************************************************************************** 1505 * * 1506 * PRELRETURN * 1507 * * 1508 * This subroutine returns a PREL to the free PREL list. * 1509 * Call: * 1510 * LD R5 ADR PREL * 1511 * CALLNP PRELRETURN * 1512 * * 1513 * Eats R0 * 1514 * * 1515 ********************************************************************************** 1516 1517 PRELRETURN BLOCK 1518 1519 ENTRY PRELRETURN 1520 1521 BEGFRAME 1522 ENDFRAME 1523 03471 DD5F8001 6 STAK 1524 PRELRETURN ENTRNP PUSH 1525 LLOCK PRELQLOCK lock the list 03476 60004807 0 1526 LD R0 PRELQ get pointer to first element 03477 E4095F10 0 5 ZBM 1527 ST R0 R5,MCBLINK make the returning MCB point to it 03478 E5404807 5 1528 ST R5 PRELQ returning PREL is at first of list 03479 D0004809 1529 INC FREEPRELCT say another PREL is in list 0347A EC004808 1530 STZ PRELQLOCK free the list 0347B 5D1F8001 6 STAK 1531 LEAVE POP 1532 * --- 1533 1534 END PRELRETURN 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 63 F 0 Queue Manipulation Subroutines 1536 1537 ********************************************************************************** 1538 * * 1539 * FREEALL -- Free a PREL and all its associated pages * 1540 * * 1541 * This simple little subroutine returns all the pages * 1542 * associated with a PREL to the free page list and then * 1543 * returns the PREL to the free PREL list. * 1544 * Call: * 1545 * R5 -> PREL * 1546 * CALLNP FREEALL * 1547 * * 1548 * Eats R0:R5 * 1549 * * 1550 ********************************************************************************** 1551 1552 FREEALL BLOCK 1553 1554 ENTRY FREEALL 1555 1556 BEGFRAME 1557 ENDFRAME 1558 0347C DD5F8001 6 STAK 1559 FREEALL ENTRNP PUSH 0347D 60494041 1 5 ZBM 1560 LD R1 R5,PRELMCBCNT how many pages to return 0347E FE0E3481 1561 JMP INTOLOOP 1562 * --- 1563 0000347F 1564 FREELOOP LABEL 0347F 611D4803 4 51 BASE 1565 LD R4 R5,PRELMCBPTR(R1) R4 -> an MCB 03480 DC403466 1566 CALLNP PAGERETURN return the page 00003481 1567 INTOLOOP LABEL 03481 FA66347F 1 1568 JDR R1 FREELOOP 1569 * \ / 1570 03482 DC403471 1571 CALLNP PRELRETURN return the PREL to the free PREL list 03483 5D1F8001 6 STAK 1572 LEAVE POP 1573 * --- 1574 1575 END FREEALL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 64 F 0 FINDTEXTZ - Find a String by Index 1578 1579 ********************************************************************************** 1580 * * 1581 * FINDTEXTZ - Find a String by Index * 1582 * * 1583 * This routine will search an array of zero-terminated (TEXTZ) * 1584 * strings, for a particular one. * 1585 * * 1586 * Usage: * 1587 * TABLE TEXTZ " string 0 " * 1588 * TEXTZ " string 1 " * 1589 * TEXTZ " string 2 " * 1590 * ... * 1591 * TEXTZ " string n " * 1592 * VFD 0 * 1593 * * 1594 * CALL FINDTEXTZ * 1595 * PARV index into table * 1596 * PARL table address * 1597 * ST R0 address of string * 1598 * * 1599 * Value returned in R0, kills R1-R2. * 1600 * * 1601 ********************************************************************************** 1602 1603 FINDTEXTZ BLOCK 1604 ENTRY FINDTEXTZ 1605 1606 BEGFRAME 00178801 6 BASE 1607 INDEX BSS 1 1608 ENDFRAME 1609 03484 20457272 1610 ERRSTRING TEXTZ " Error code out of range." 1611 0348B DD1F8002 6 STAK 1612 FINDTEXTZ ENTR PUSH 0348C C1578801 6 BASE 1613 STPV SP,INDEX 0348D C0120000 0 REG 1614 STPL R0 R0 -> string zero 1615 0000348E 1616 LOOP LABEL 0348E 5C160800 0 BASE 1617 CMZ R0,0 beyond end of table? 0348F FE023499 1618 JEQ GIVEERR jump if yes 03490 5C178801 6 BASE 1619 CMZ SP,INDEX 03491 FE083499 1620 JLT GIVEERR jump if index too small 03492 FE02349A 1621 JEQ RETURN jump if found right string 03493 604400FF 1 IMM 1622 LD R1 0FF reasonable max length for string 03494 60840000 2 IMM 1623 LD R2 0 look for zero byte at end 03495 FE560000 1624 CSRCH R0 = cach addr of zero byte 03496 38160801 0 0 BASE 1625 LEA R0 R0,1 R0 = word addr of next string 03497 D0578801 6 BASE 1626 DEC SP,INDEX 03498 FE0E348E 1627 JMP LOOP try next string 1628 * --- 1629 00003499 1630 GIVEERR LABEL index out of range 03499 60043484 0 IMM 1631 LD R0 ADR ERRSTRING return pointer to error string 1632 * \ / 1633 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 65 F 0 FINDTEXTZ - Find a String by Index 0000349A 1634 RETURN LABEL R0 = addr of string 0349A 5D1F8002 6 STAK 1635 LEAVE POP 1636 * --- 1637 1638 END FINDTEXTZ 1639 1640 END MC of main control 1641 1642 INPUT DISKTOTAPE.OPSYS:DTTREAD 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 66 (DTTREAD) F 18 DISKTOTAPE Read Disk Process 3 4 ********************************************************************************** 5 * * 6 * The disk reading process follows the disk control * 7 * structures set up by the Operating System. When a CPU * 8 * starts this process it must map in the pages reserved for * 9 * holding these structures. The page map values for these * 10 * pages are kept in a table which is in memory mapped by all * 11 * CPUs (READPMV). * 12 * A CPU starting this process must be sure there are * 13 * enough free pages and free PRELs available before jumping * 14 * to READSTART. READSTART then maps in the pages reserved for * 15 * the reading process, restores the stack pointer, R7, and R2 * 16 * and loads the CPU's PC with READPC, which will continue the * 17 * reading process where it left off. * 18 * The order of the elements put into the PRPQ by the * 19 * reading process is: * 20 * quantity element use * 21 * -------- ------- --- * 22 * 1 PREL volume name * 23 * 0 or many MCB tape boot info * 24 * 1 PREL end of tape boot info marker * 25 * 1 MCB boot strap block * 26 * 1 MCB volume label * 27 * * 28 * 1 MCB UDIR1 * 29 * 1 PREL FDE * 30 * 0 to many MCB file data blocks * 31 * 1 PREL FDE * 32 * 0 to many MCB file data blocks * 33 * ..... * 34 * * 35 * 1 MCB UDIR1 * 36 * 1 PREL FDE * 37 * 0 to many MCB file data blocks * 38 * 1 PREL FDE * 39 * 0 to many MCB file data blocks * 40 * ..... * 41 * * 42 * ..... * 43 * 1 PREL end of volume marker * 44 * * 45 ********************************************************************************** 46 47 READDISK BLOCK disk reading process 48 49 ENTRY GETAPAGE 50 ENTRY READINIT 51 ENTRY READSTART 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 67 (DTTREAD) F 18 Get a Free Page 54 55 ********************************************************************************** 56 * * 57 * GETAPAGE checks the free page count and if enough free * 58 * pages exist, gets the MCB for one and returns to the * 59 * calling process. If there are not enough pages available * 60 * we save the information necessary for restarting the * 61 * reading process and go to the scheduler. * 62 * The free page is mapped into READDATA. * 63 * Call: * 64 * CALLNP GETAPAGE * 65 * returns with R4 pointing to an available page's MCB * 66 * * 67 * Eats R0:R1, R3:R5 (since we might not return immediately) * 68 * Returns R4 -> MCB * 69 * * 70 ********************************************************************************** 71 72 GETAPAGE BLOCK 73 74 ENTRY GETAPAGE 75 ENTRY GETAPAGEL 76 77 BEGFRAME 78 ENDFRAME 79 0349B DD5F8001 6 STAK 80 GETAPAGE ENTRNP PUSH 0000349C 81 GETAPAGEL LABEL label for GETAPAGE subroutine 82 LLOCK PAGEQLOCK need exclusive use of this list 034A0 60004818 0 83 LD R0 READMINPAG minimum number of free pages allowed 034A1 64004806 0 84 CPR R0 FREEPGCNT see if we have enough free pages 034A2 FE0434A7 85 JGT TOOFEWPAG if not save state and switch processes 86 * \ / 87 034A3 DC40344C 88 CALLNP UNLINKPAGE get the page from the queue 034A4 60C400AB 3 IMM 89 LD PFPTR RDDATAPN set up to map in data page 034A5 00D70801 4 BASE 90 LDPF R4,MCBPMV do it 034A6 5D1F8001 6 STAK 91 LEAVE POP return to caller 92 * --- 93 000034A7 94 TOOFEWPAG LABEL 034A7 EC004805 95 STZ PAGEQLOCK release the lock 034A8 FA2834B7 0 96 JSR R0 SAVESTATE save our present state 034A9 0000349C 97 VFD ADR GETAPAGEL address to start over at 98 * --- 99 100 END GETAPAGE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 68 (DTTREAD) F 18 Get a free PREL routine 103 104 ********************************************************************************** 105 * * 106 * GETAPREL * 107 * * 108 * This routine checks for enough free PRELs and if there * 109 * are enough it removes one from the list and returns to the * 110 * caller. If not enough it saves the current state and jumps * 111 * to the scheduler. We need to allow more free PRELS than * 112 * free pages since these are used heavily by the next process * 113 * (packing). * 114 * Call: * 115 * CALLNP GETAPREL * 116 * returns with R5 -> to PREL * 117 * Eats R0:R1,R3:R5 since we might not return for awhile. * 118 * * 119 ********************************************************************************** 120 121 GETAPREL BLOCK 122 123 ENTRY GETAPREL 124 125 BEGFRAME 126 ENDFRAME 127 034AA DD5F8001 6 STAK 128 GETAPREL ENTRNP PUSH 000034AB 129 ONCEAGAIN LABEL 130 LLOCK PRELQLOCK need exclusive use of this list 034AF 60040019 0 IMM 131 LD R0 MINPRELS minimum number of free PRELs allowed 034B0 64004809 0 132 CPR R0 FREEPRELCT see if we have enough free pages 034B1 FE0434B4 133 JGT TOOFEWPREL if not save state and switch processes 134 * \ / 135 034B2 DC403454 136 CALLNP UNLINKPREL get the PREL from the list 034B3 5D1F8001 6 STAK 137 LEAVE POP return to caller 138 * --- 139 000034B4 140 TOOFEWPREL LABEL 034B4 EC004808 141 STZ PRELQLOCK release the lock 034B5 FA2834B7 0 142 JSR R0 SAVESTATE save the process state 034B6 000034AB 143 VFD ADR ONCEAGAIN where to restart the process 144 * --- 145 146 END GETAPREL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 69 (DTTREAD) F 18 Save State Routine 149 150 ********************************************************************************** 151 * * 152 * SAVESTATE * 153 * * 154 * This routine saves the information needed to restore * 155 * the read process. * 156 * Call: * 157 * JSR R0 SAVESTATE * 158 * VFD ADR * 159 * * 160 ********************************************************************************** 161 162 SAVESTATE BLOCK 163 164 ENTRY SAVESTATE 165 000034B7 166 SAVESTATE LABEL 034B7 60160400 0 0 @R 167 LD R0 @R0 get the return address 034B8 E400484F 0 168 ST R0 READPC and save for start up 034B9 E780484D 67 169 ST2 SP READSPR7 save the stack pointer and R7 034BA E480484C 2 170 ST R2 READR2 save R2 171 034BB 60C400AB 3 IMM 172 LD PFPTR RDDATAPN data page's number 034BC 80C048FF 173 PFRC RDDATAPMV clear and save the page map value 174 034BD 60040008 0 IMM 175 LD R0 READPMVL number of pages used by read process 034BE 60C400A3 3 IMM 176 LD PFPTR PROCPN page number of first page 000034BF 177 UNMAPLOOP LABEL 034BF 80D24000 1 REG 178 PFRC R1 034C0 18C40001 3 IMM 179 ADD PFPTR 1 move to the next page 034C1 FA2634BF 0 180 JDR R0 UNMAPLOOP do the next page 181 * \ / 182 034C2 FE0E3186 183 JMP DONEREAD return to scheduler 184 * --- 185 186 END SAVESTATE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 70 (DTTREAD) F 18 PRPQ linker 189 190 ********************************************************************************** 191 * * 192 * Subroutine to link an MCB onto the PRPQ. * 193 * Call: * 194 * LD R4 ADR MCB * 195 * CALL LINKINPRPQ * 196 * PARVL * 197 * Eats R0. * 198 * * 199 ********************************************************************************** 200 201 LINKINPRPQ BLOCK 202 203 ENTRY LINKINPRPQ 204 205 BEGFRAME 206 ENDFRAME 207 034C3 DD1F8001 6 STAK 208 LINKINPRPQ ENTR PUSH 034C4 C0490040 4 ZBM 209 STPVL R4,MCBTYPE set the type field 034C5 EC091F10 4 ZBM 210 STZ R4,MCBLINK new MCB doesn't point anywhere 211 LLOCK PRPQLOCK get the list locked 034CA 6000480B 0 212 LD R0 PRPQTAIL want to link this on the tail 034CB E5081F10 4 0 ZBM 213 ST R4 R0,MCBLINK make the old tail point to the new MCB 034CC E500480B 4 214 ST R4 PRPQTAIL now the new MCB is the tail 034CD EC00480C 215 STZ PRPQLOCK release the lock 034CE 5D1F8001 6 STAK 216 LEAVE POP 217 * --- 218 219 END LINKINPRPQ 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 71 (DTTREAD) F 18 PRPQ linker 221 222 ********************************************************************************** 223 * * 224 * GIVEERROR * 225 * * 226 * This subroutine puts an error element onto the PRPQ to * 227 * let the packer know a problem has happened. * 228 * Call: * 229 * CALLNP GIVEERROR * 230 * * 231 * Eats R0, R4:R5 * 232 * * 233 ********************************************************************************** 234 235 GIVEERROR BLOCK 236 237 ENTRY GIVEERROR 238 239 BEGFRAME 240 ENDFRAME 241 034CF DD5F8001 6 STAK 242 GIVEERROR ENTRNP PUSH 034D0 DC4034AA 243 CALLNP GETAPREL 034D1 61134000 4 5 REG 244 LD R4 R5 R4 -> PREL 034D2 DC0034C3 245 CALL LINKINPRPQ put it in the queue 034D3 40440007 IMM 246 PARVL TERROR what type of element this is 034D4 5D1F8001 6 STAK 247 LEAVE POP 248 * --- 249 250 END GIVEERROR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 72 (DTTREAD) F 18 Read Process Start-up 253 254 ********************************************************************************** 255 * * 256 * This is where a CPU comes to start the disk reading * 257 * process. We initialize what we must and then jump to where * 258 * we left off. * 259 * * 260 ********************************************************************************** 261 000034D5 262 READSTART LABEL 034D5 609013E6 2 @ 263 LD R2 @VMEMPF page file for our memory 034D6 6047FFF8 1 IMM 264 LD R1 -(READPMVL) number of page map values to load 034D7 60C400A3 3 IMM 265 LD PFPTR PROCPN starting page map location 000034D8 266 RDLOADPMV LABEL 034D8 602248FF 0 1 267 LD R0 READPMV(READPMVL)(R1) get a page map value 034D9 E40AA8C0 0 2 CBM 268 ST R0 R2/PFPAGENUM make page file for this page 034DA 00D28000 2 REG 269 LDPF R2 load it 034DB 18C40001 3 IMM 270 ADD PFPTR 1 move to next page file location 034DC FA6034D8 1 271 IRJ R1 RDLOADPMV load the next one 272 * \ / 034DD 5C0048FF 273 CMZ RDDATAPMV page map value for data page 034DE FE0234E0 274 JEQ NODATA jump if no page to map in 034DF 00C048FF 275 LDPF RDDATAPMV map in data page 000034E0 276 NODATA LABEL 034E0 6380484D 67 277 LD2 SP READSPR7 set up our stack and restore R7 034E1 6080484C 2 278 LD R2 READR2 restore R2 034E2 5C80484F 279 LDPC READPC and off we go 280 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 73 (DTTREAD) F 18 Read Process Start-up 282 283 ********************************************************************************** 284 * * 285 * The read process is initialized to start here. We * 286 * read the volume information necessary to write the fileset * 287 * header, then read the control structures necessary to start * 288 * reading files from accounts, then away we go reading data * 289 * blocks and shipping them off to be packed into physical * 290 * records. * 291 * Since we get here through READSTART, R4 points to the * 292 * MCB of an available page. * 293 * * 294 ********************************************************************************** 295 000034E3 296 READINIT LABEL 034E3 618448C8 6 IMM 297 LD SP ADR READSTACK initialize read process stack 034E4 EDC0487C 298 STW CHEKFBIFLG say check FBIs on page reads 299 034E5 6044003C 1 IMM 300 LD R1 ERRBLKLEN*CPW load size of file name block 034E6 6084486D 2 IMM 301 LD R2 ADR ERRORBLOCK its address 034E7 FE580000 302 CFILL 000 and clear it out 303 034E8 DC40349B 304 CALLNP GETAPAGE get a free page 034E9 EC004861 305 STZ RELBLOCK no relative block number for these blocks 034EA DC00382C 306 CALL PAGEIN get the volume label off the disk 034EB 41440004 IMM 307 PARV FBITVL volume label FBI type 034EC 41440001 IMM 308 PARV VOLLABELDA pass volume label address 034ED 4100AC00 309 PAR READDATA where we want it 034EE 40170802 4 BASE 310 PARL R4,MCBFBI and its FBI 034EF FE0E3535 311 JMP VOLLBAD jump if it didn't work 312 * \ / 313 034F0 E500485F 4 314 ST R4 VOLMCB save pointer to volume label's MCB 034F1 DC4034AA 315 CALLNP GETAPREL get a free PREL 034F2 6200AC04 01 316 LD2 R0 READDATA(VLVNAME) get the volume name 034F3 E600486D 01 317 ST2 R0 READVOL and save it 034F4 E6174801 015 BASE 318 ST2 R0 R5,PRELVOLNAM put the volume name in a PREL 034F5 61134000 4 5 REG 319 LD R4 R5 034F6 DC0034C3 320 CALL LINKINPRPQ link it into the PRPQ 034F7 40440005 IMM 321 PARVL TVOLNAM type is volume name 322 034F8 6000AC12 0 323 LD R0 READDATA(VLSECBDA) get the security block address 034F9 E4004862 0 324 ST R0 SECDA save address of the security block 034FA 6000AC13 0 325 LD R0 READDATA(VLSECB2DA) get the second sec block address 034FB E4004863 0 326 ST R0 SEC2DA and save it 327 * \ / 328 034FC DC403553 329 CALLNP TAPEBOOTMA put in tape boot info 330 034FD DC40349B 331 CALLNP GETAPAGE get a free page 034FE EC004861 332 STZ RELBLOCK no relative block number for these blocks 034FF DC00382C 333 CALL PAGEIN read the boot block 03500 41440003 IMM 334 PARV FBITBOOT indicate FBI type 03501 41440002 IMM 335 PARV BOOTDA disk address 03502 4100AC00 336 PAR READDATA buffer address 03503 40170802 4 BASE 337 PARL R4,MCBFBI and FBI address 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 74 (DTTREAD) F 18 Read Process Start-up 03504 FE0E3528 338 JMP BOOTBAD disk error 339 03505 DC0034C3 340 CALL LINKINPRPQ put the bootstrap block in the PRPQ 03506 40440002 IMM 341 PARVL TMCB 342 03507 6100485F 4 343 LD R4 VOLMCB get pointer to volume label's MCB 03508 DC0034C3 344 CALL LINKINPRPQ put the volume label in the PRPQ 03509 40440002 IMM 345 PARVL TMCB 346 0350A DC40349B 347 CALLNP GETAPAGE get a free page 0350B DC00382C 348 CALL PAGEIN get the block resident 0350C 41440006 IMM 349 PARV FBITSEC expecting security block 0350D 41004862 350 PAR SECDA indicate where it is 0350E 41008C00 351 PAR RDSECLOC and where to put it 0350F 40170802 4 BASE 352 PARL R4,MCBFBI and its FBI 03510 FE0E3521 353 JMP SECBAD go here if trouble 354 * \ / 355 * Move part of security block into free page and add to PRPQ. 356 00003511 357 GOTSEC LABEL 03511 60048E26 0 IMM 358 LD R0 ADR RDSECLOC(SECTZONE) source address for move 03512 60440068 1 IMM 359 LD R1 (SECBKUPE DISPW SECTZONE)*CPW how much to move 03513 6084AC00 2 IMM 360 LD R2 ADR READDATA where to move to 03514 FE400000 361 CMOVE move them 03515 DC0034C3 362 CALL LINKINPRPQ put page into the PRPQ 03516 40440002 IMM 363 PARVL TMCB 364 * \ / 365 03517 DC4035B1 366 CALLNP READIDX now read the entire volume 03518 FE0E354F 367 JMP READDEATH if problem reading disk 368 03519 DC4034AA 369 CALLNP GETAPREL get a free PREL 0351A 61134000 4 5 REG 370 LD R4 R5 need R4 -> PREL 0351B DC0034C3 371 CALL LINKINPRPQ put it in the PRPQ 0351C 40440004 IMM 372 PARVL TEOV to say we are through with the volume 373 0000351D 374 CLEANUP LABEL 0351D 61044844 4 IMM 375 LD R4 ADR DISKCB R4 -> disk control block 0351E DC5013EC @ 376 CALLNP @VCLOSEDISK we are through with it 377 0351F EDC04803 378 STW READDONE say we are finished reading the disk 03520 FE0E3187 379 JMP CHEKPACK see if you can help with the next process 380 * --- 381 382 00003521 383 SECBAD LABEL 03521 DC00382C 384 CALL PAGEIN get the block resident 03522 41440006 IMM 385 PARV FBITSEC expecting security block 03523 41004863 386 PAR SEC2DA indicate where it is 03524 41008C00 387 PAR RDSECLOC and where to put it 03525 40170802 4 BASE 388 PARL R4,MCBFBI and its FBI 03526 FE0E3542 389 JMP SEC2BAD go here if trouble 03527 FE0E3511 390 JMP GOTSEC 391 * --- 392 00003528 393 BOOTBAD LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 75 (DTTREAD) F 18 Read Process Start-up 03528 DC1013F9 @ 394 CALL @VPREPOUT tell the problem 03529 4000352B 395 PARL BOOTBADM 0352A FE0E354F 396 JMP READDEATH 397 * --- 398 0352B 20436F75 399 BOOTBADM TEXTZ " Could not read the boot strap block" 400 00003535 401 VOLLBAD LABEL 03535 DC1013F9 @ 402 CALL @VPREPOUT tell the problem 03536 40003538 403 PARL VOLBADM 03537 FE0E351D 404 JMP CLEANUP and quit 405 * --- 406 03538 20436F75 407 VOLBADM TEXTZ " Could not read the volume label block" 408 00003542 409 SEC2BAD LABEL 03542 DC1013F9 @ 410 CALL @VPREPOUT tell the problem 03543 40003545 411 PARL SECBADM 03544 FE0E354F 412 JMP READDEATH 413 * --- 414 03545 20436F75 415 SECBADM TEXTZ " Could not read either security block" 416 0000354F 417 READDEATH LABEL 0354F DC4034AA 418 CALLNP GETAPREL get a PREL 03550 61134000 4 5 REG 419 LD R4 R5 03551 DC4034C3 420 CALLNP LINKINPRPQ put into the packing queue 03552 FE0E351D 421 JMP CLEANUP and quit this madness 422 * --- traversing the disk 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 76 (DTTREAD) F 18 TAPEBOOTMAKE 425 426 ********************************************************************************** 427 * * 428 * TAPEBOOTMA * 429 * * 430 * This subroutine determines if the volume being copied * 431 * is a system disk and if so reads the necessary files to * 432 * create the TAPEBOOTMAKE information. * 433 * * 434 * Call: * 435 * CALLNP TAPEBOOTMA * 436 * * 437 * Eats R0:R5 * 438 * * 439 ********************************************************************************** 440 441 TAPEBOOTMA BLOCK 442 443 ENTRY TAPEBOOTMA 444 445 BEGFRAME 00178801 6 BASE 446 TABINDX BSS 1 index into file name table 447 ENDFRAME 448 03553 DD5F8002 6 STAK 449 TAPEBOOTMA ENTRNP PUSH 03554 620048F2 01 450 LD2 R0 GOOFNAME some goofy pack12 name 03555 E6004883 01 451 ST2 R0 EQPFILNAM put in equip block 03556 6144487E 5 IMM 452 LD R5 ADR EQPBLK R5 -> file equip block 03557 61044844 4 IMM 453 LD R4 ADR DISKCB R4 -> disk control block 03558 DC5013E2 @ 454 CALLNP @VSRCHDIR see if we have an offline.!!! account 03559 FAF2355C 3 455 JNZA R3 HAVEOFFL oops, GOOFNAME exists on Offline.!!! 0355A 64040006 0 IMM 456 CPR R0 6 see if the error was just a missing file 0355B FE0C3579 457 JNE NOOFF if not then we have no Offline.!!! account 458 * \ / 0000355C 459 HAVEOFFL LABEL 0355C DC4034AA 460 CALLNP GETAPREL get a free PREL 0355D 60040001 0 IMM 461 LD R0 TBMBEGIN code for begin TBM 0355E E4174801 0 5 BASE 462 ST R0 R5,PRELTBM put in the PREL 0355F 61134000 4 5 REG 463 LD R4 R5 need R4 -> PREL 03560 DC0034C3 464 CALL LINKINPRPQ put it in the PRPQ 03561 40440003 IMM 465 PARVL TTBM to say we have tape boot make info 466 * \ / 467 03562 60004885 0 468 LD R0 PAKCODE get code extension 03563 E4004879 0 469 ST R0 READEXT and set up for any error reporting 03564 EC00487C 470 STZ CHEKFBIFLG say don't check FBIs on page reads 03565 EC178801 6 BASE 471 STZ SP,TABINDX start at beginning of table 03566 60040000 0 IMM 472 LD R0 0 initial index into the table 00003567 473 NEXTFILE LABEL 03567 626048D8 12 0 474 LD2 R1 NAMTAB(R0) get the name from the table 03568 E6404883 12 475 ST2 R1 EQPFILNAM and remember it for SRCHDIR 03569 E6404877 12 476 ST2 R1 READNAME and save for the file block's FBIs 0356A 74528000 1 2 REG 477 XOR R1 R2 cook up a good indicator 0356B E440487D 1 478 ST R1 READKEY and save for COPYFILE 479 0356C DC40358E 480 CALLNP COPYFILE read the file 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 77 (DTTREAD) F 18 TAPEBOOTMAKE 0356D FE0E357D 481 JMP BADFIL jump on any error 482 * \ / 0000356E 483 NXTINDX LABEL 0356E BC178801 0 6 BASE 484 INCL R0 SP,TABINDX get index to next file 0356F 64040009 0 IMM 485 CPR R0 TABMAX have we done all of the files? 03570 FE083567 486 JLT NEXTFILE jump if more to do 487 * \ / 488 03571 EDC0487C 489 STW CHEKFBIFLG say check FBIs on page reads 03572 DC4034AA 490 CALLNP GETAPREL get a free PREL 03573 60040002 0 IMM 491 LD R0 TBMEND code for done 03574 E4174801 0 5 BASE 492 ST R0 R5,PRELTBM put in the PREL 00003575 493 LINKTBM LABEL 03575 61134000 4 5 REG 494 LD R4 R5 need R4 -> PREL 03576 DC0034C3 495 CALL LINKINPRPQ put it in the PRPQ 03577 40440003 IMM 496 PARVL TTBM type of PREL 03578 5D1F8002 6 STAK 497 LEAVE POP 498 * --- 499 00003579 500 NOOFF LABEL 03579 DC4034AA 501 CALLNP GETAPREL get a free PREL 0357A 60040000 0 IMM 502 LD R0 TBMNONE code for no TBM 0357B E4174801 0 5 BASE 503 ST R0 R5,PRELTBM put in the PREL 0357C FE0E3575 504 JMP LINKTBM 505 * --- 506 507 * If we get an error copying one of the files we will come here. 0000357D 508 BADFIL LABEL 0357D DC1013F9 @ 509 CALL @VPREPOUT tell the guy 0357E 41004883 510 PAR EQPFILNAM name of file 0357F 40003581 511 PARL BADFILMSG 03580 FE0E356E 512 JMP NXTINDX try for next one 513 * --- 514 03581 20574152 515 BADFILMSG TEXTZ " WARNING !!! Offline file \S1\ not written on tape." 516 517 END TAPEBOOTMA 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 78 (DTTREAD) F 18 TAPEBOOTMAKE 519 520 ********************************************************************************** 521 * * 522 * COPYFILE * 523 * * 524 * Read all of the CODE file's pages and link them onto * 525 * the PRPQ. Note that the code file that we are writing must * 526 * be contiguous after the first page found. This is a * 527 * requirement of TAPEBOOT. * 528 * * 529 * Calling sequence: * 530 * CALLNP COPYFILE * 531 * JMP * 532 * Eats R0:R5 * 533 * * 534 ********************************************************************************** 535 536 COPYFILE BLOCK 537 ENTRY COPYFILE 538 539 BEGFRAME 00178801 6 BASE 540 PLACE BSS 1 current position in code file 541 ENDFRAME 542 0358E DD5F8002 6 STAK 543 COPYFILE ENTRNP PUSH 0358F 6144487E 5 IMM 544 LD R5 ADR EQPBLK R5 -> file equip block 03590 61044844 4 IMM 545 LD R4 ADR DISKCB R4 -> disk control block 03591 DC5013E2 @ 546 CALLNP @VSRCHDIR find the file on disk 03592 FAF035B0 3 547 JZA R3 BADRTN jump if file can't be found 548 * \ / 549 03593 DC00382C 550 CALL PAGEIN read in the CCB 03594 41440013 IMM 551 PARV FBITCCB FBI type 03595 4148D185 3 ZBM 552 PARV R3,FDDA disk address 03596 41009C00 553 PAR RDMINLOC where to put it 03597 40004851 554 PARL READFBI place for the FBI 03598 FE0E35B0 555 JMP BADRTN go here if error getting block 556 * \ / 557 558 * There is always at least one page of code in these files so we 559 * search for the first one. 03599 60840000 2 IMM 560 LD R2 0 0000359A 561 NXTPAG LABEL 0359A 5C249C00 2 562 CMZ RDMINLOC(R2) see if it's a hole 0359B FE0C359D 563 JNE NOHOLE jump if data here 0359C FAA0359A 2 564 IRJ R2 NXTPAG else try the next location 565 * --- 566 0000359D 567 NOHOLE LABEL 0359D E4978801 2 6 BASE 568 ST R2 SP,PLACE save our starting place 0000359E 569 NOHOLE1 LABEL 0359E DC40349B 570 CALLNP GETAPAGE get a free page 0359F DC00382C 571 CALL PAGEIN read in the data block 035A0 41440014 IMM 572 PARV FBITCODED FBI type 035A1 41649C00 2 573 PARV RDMINLOC(R2) disk address 035A2 4100AC00 574 PAR READDATA where to put it 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 79 (DTTREAD) F 18 TAPEBOOTMAKE 035A3 40170802 4 BASE 575 PARL R4,MCBFBI and its FBI 035A4 FE0E35B0 576 JMP BADRTN if trouble 577 * \ / 578 035A5 38970802 2 4 BASE 579 LEA R2 R4,MCBFBI R2 -> FBI 035A6 62004877 01 580 LD2 R0 READNAME get the file name 035A7 E6168800 012 BASE 581 ST2 R0 R2,TBMNAME put into the FBI block 035A8 BC00487D 0 582 INCL R0 READKEY get the indicator 035A9 E4168802 0 2 BASE 583 ST R0 R2,TBMIND put in for encryptor 584 035AA DC0034C3 585 CALL LINKINPRPQ add to packing queue 035AB 40440002 IMM 586 PARVL TMCB 587 035AC BC978801 2 6 BASE 588 INCL R2 SP,PLACE our place in CCB 035AD 5C249C00 2 589 CMZ RDMINLOC(R2) anything here? 035AE FE0C359E 590 JNE NOHOLE1 if so, go do next page 591 * \ / 592 593 * We are through at the first hole since we are guaranteed to have 594 * contiguous blocks in these code files. 035AF 19C40001 7 IMM 595 ADD R7 1 good return 000035B0 596 BADRTN LABEL 035B0 5D1F8002 6 STAK 597 LEAVE POP 598 * --- 599 600 END COPYFILE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 80 (DTTREAD) F 18 Read User Index Table 603 604 ********************************************************************************** 605 * * 606 * Routine to read all the IDXs and the structures * 607 * pointed to by them. This has the effect of reading all * 608 * accounts and their files. * 609 * Call: * 610 * * 611 * RDSECLOC contains security block * 612 * CALLNP READIDX * 613 * JMP fatal error * 614 * * 615 * Gets R0:R5. * 616 * * 617 ********************************************************************************** 618 619 READIDX BLOCK 620 621 ENTRY READIDX 622 623 BEGFRAME 00178801 6 BASE 624 INDEX BSS 1 pointer into current IDX block 00178802 6 BASE 625 BUCKET BSS 1 index to bucket being processed 626 ENDFRAME 627 035B1 DD5F8003 6 STAK 628 READIDX ENTRNP PUSH 035B2 D1578802 6 BASE 629 STMW SP,BUCKET save bucket index 035B3 FE0E35CC 630 JMP ENDOFBUKT start with count and test 631 * --- 632 000035B4 633 NEXTBUKT LABEL 035B4 60608C2C 1 0 634 LD R1 RDSECLOC/SECIDXPTR(R0) get DA of current IDX block 035B5 FA4235CC 1 635 JEQZ R1 ENDOFBUKT zero addr says end of bucket 035B6 E4004861 0 636 ST R0 RELBLOCK to check against when read in 035B7 DC00382C 637 CALL PAGEIN read in this IDX block 035B8 41440008 IMM 638 PARV FBITIDX FBI type 035B9 41524000 1 REG 639 PARV R1 block number 035BA 41009000 640 PAR RDIDXLOC where to put it 035BB 40004851 641 PARL READFBI we want the FBI put here 035BC FE0E35D1 642 JMP BADIDX go here if trouble 643 * \ / 644 035BD 61449000 5 IMM 645 LD R5 ADR RDIDXLOC pointer to first element 035BE E5578801 5 6 BASE 646 ST R5 SP,INDEX save the index 000035BF 647 NEXTENT LABEL 035BF 62174800 015 BASE 648 LD2 R0 R5,IDXACNO get the account number 035C0 FA2C35C8 0 649 JEQMW R0 BFILLER jump if deleted entry filler 035C1 FA1C35C4 01 650 JNEZ2 R0 THISPLACE jump if an account is here 035C2 5C174802 5 BASE 651 CMZ R5,IDXACNOP check the extension 035C3 FE0235CC 652 JEQ ENDOFBUKT jump if nothing here 000035C4 653 THISPLACE LABEL 035C4 60178802 0 6 BASE 654 LD R0 SP,BUCKET bucket number 035C5 DC0035DC 655 CALL READACNT read the account 035C6 41520000 0 REG 656 PARV R0 bucket number 035C7 40174400 5 @R 657 PARL @R5 pointer to IDX entry 658 * \ / 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 81 (DTTREAD) F 18 Read User Index Table 659 000035C8 660 BFILLER LABEL 035C8 61440005 5 IMM 661 LD R5 IDXLNTH length of entry 035C9 B9578801 5 6 BASE 662 ADDB R5 SP,INDEX move to the next entry 035CA 654493FC 5 IMM 663 CPR R5 ADR(RDIDXLOC(IDXECNT*IDXLNTH)) see if more 035CB FE0835BF 664 JLT NEXTENT jump if more 665 * \ / 666 000035CC 667 ENDOFBUKT LABEL 035CC BC178802 0 6 BASE 668 INCL R0 SP,BUCKET advance to next bucket number 035CD 64008C28 0 669 CPR R0 RDSECLOC(SECIDXSIZ) number of blocks in IDX 035CE FE0835B4 670 JLT NEXTBUKT jump if some left 671 * \ / 035CF 19C40001 7 IMM 672 ADD R7 1 good return 000035D0 673 BADBYE LABEL 035D0 5D1F8003 6 STAK 674 LEAVE POP 675 * --- 676 000035D1 677 BADIDX LABEL 035D1 DC1013F9 @ 678 CALL @VPREPOUT tell about our problem 035D2 400035D4 679 PARL BADIDXMES what we will say 035D3 FE0E35D0 680 JMP BADBYE 681 * --- 682 035D4 20436F75 683 BADIDXMES TEXTZ " Could not read an IDX block" 684 685 END READIDX 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 82 (DTTREAD) F 18 Read an Account 688 689 ********************************************************************************** 690 * * 691 * Given a pointer to an IDX entry this routine reads the * 692 * directory and all of the associated files. * 693 * Call: * 694 * CALL READACNT * 695 * PARV * 696 * PARL => IDX entry * 697 * * 698 * Gets R0:R5. * 699 * * 700 ********************************************************************************** 701 702 READACNT BLOCK 703 704 ENTRY READACNT 705 706 BEGFRAME 00178801 6 BASE 707 DIR1INDEX BSS 1 index into primary directory block 00178802 6 BASE 708 DIR2INDEX BSS 1 index into secondary directory block 00178803 6 BASE 709 ACCTINIDX BSS 1 pointer to IDX entry 00178804 6 BASE 710 UDIR1NAME BSS2 1 UDIR1 name index 00178806 6 BASE 711 UDIR1EXT BSS 1 UDIR1 extension index 00178807 6 BASE 712 CURUDIR1 BSS 1 block number of UDIR1 00178808 6 BASE 713 BUCKNUM BSS 1 bucket number 714 ENDFRAME 715 035DC DD1F8009 6 STAK 716 READACNT ENTR PUSH 035DD C1578808 6 BASE 717 STPV SP,BUCKNUM store the bucket number 035DE C0178803 6 BASE 718 STPL SP,ACCTINIDX pointer to IDX 035DF DC40349B 719 CALLNP GETAPAGE get a free page 720 035E0 60178803 0 6 BASE 721 LD R0 SP,ACCTINIDX get pointer to FDE 035E1 62560800 120 BASE 722 LD2 R1 R0,IDXACNO pick up account 035E2 E6404872 12 723 ST2 R1 READACCT and save it 035E3 60560802 1 0 BASE 724 LD R1 R0,IDXACNOP and project 035E4 E4404874 1 725 ST R1 READPROJ 726 * \ / 035E5 EC004861 727 STZ RELBLOCK to compare against when read in 035E6 60560803 1 0 BASE 728 LD R1 R0,IDXDIRDA R1:=disk addr of directory 035E7 E4578807 1 6 BASE 729 ST R1 SP,CURUDIR1 save UDIR1 block number 035E8 E440486C 1 730 ST R1 UDIRBLOCK save block # for error processing 035E9 60040009 0 IMM 731 LD R0 FBITUDIR1 FBI type 035EA E400486B 0 732 ST R0 UDIRTYPE save it for error processing 733 * \ / 035EB DC00382C 734 CALL PAGEIN get the UDIR1 035EC 41440009 IMM 735 PARV FBITUDIR1 FBI type 035ED 41524000 1 REG 736 PARV R1 block number 035EE 41009400 737 PAR RDUDIR1LOC where to put UDIR 035EF 40004851 738 PARL READFBI and its FBI 035F0 FE0E363E 739 JMP BADDIR1 where to go on error 740 * \ / 741 * Verify that the account name in the user directory matches the 742 * account name in the IDX. Horrible things happen otherwise. 743 * \ / 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 83 (DTTREAD) F 18 Read an Account 744 035F1 60978803 2 6 BASE 745 LD R2 SP,ACCTINIDX R2 -> IDX entry 035F2 62168800 012 BASE 746 LD2 R0 R2,IDXACNO R0,R1 = account name 035F3 66009400 01 747 CPR2 R0 RDUDIR1LOC/UDACCT is it right? 035F4 FE0C35F8 748 JNE NAMEBAD jump if not 035F5 60168802 0 2 BASE 749 LD R0 R2,IDXACNOP R0 = project name 035F6 64009402 0 750 CPR R0 RDUDIR1LOC/UDPROJ does it match? 035F7 FE0235FF 751 JEQ NAMEGOOD jump if all is ok 752 * \ / 753 000035F8 754 NAMEBAD LABEL 035F8 DC1013F9 @ 755 CALL @VPREPOUT tell user about mismatch names 035F9 4100486D 756 PAR ERRORBLOCK account from IDX 035FA 41009400 757 PAR RDUDIR1LOC/UDACCT account name from UDIR1 035FB 41009402 758 PAR RDUDIR1LOC/UDPROJ project name from UDIR1 035FC 41004856 759 PAR READFBI/FBIACCT account name from UDIR1 FBI 035FD 41004858 760 PAR READFBI/FBIPROJ project name from UDIR1 FBI 035FE 4000362C 761 PARL NAMEBADMSG message prototype 762 * \ / 763 000035FF 764 NAMEGOOD LABEL 035FF 60049400 0 IMM 765 LD R0 ADR RDUDIR1LOC set up to move part of UDIR to free page 03600 60440180 1 IMM 766 LD R1 UDIRKEEPL*CPW how much to move 03601 6084AC00 2 IMM 767 LD R2 ADR READDATA where to move to 03602 FE400000 768 CMOVE 03603 DC0034C3 769 CALL LINKINPRPQ put it in the PRPQ 03604 40440006 IMM 770 PARVL TUDIR UDIR type 771 * \ / 772 03605 6080943C 2 773 LD R2 RDUDIR1LOC/UDSHLLIST get share list entry 03606 F2803610 2 774 JBF R2/SHLDSKFLGB CONTSHL jump if no shared list block 775 * \ / 776 03607 DC40349B 777 CALLNP GETAPAGE need a new free page 03608 DC00382C 778 CALL PAGEIN to read in the SHL block for check 03609 41440011 IMM 779 PARV FBITASLB type is account share list 0360A 41528000 2 REG 780 PARV R2 pass disk address 0360B 4100AC00 781 PAR READDATA buffer addr 0360C 40170802 4 BASE 782 PARL R4,MCBFBI FBI addr 0360D FE0E3640 783 JMP BADASHL jump if bad read 0360E DC0034C3 784 CALL LINKINPRPQ send it to the packing queue 0360F 40440002 IMM 785 PARVL TMCB 786 * \ / 787 00003610 788 CONTSHL LABEL 03610 60809440 2 789 LD R2 RDUDIR1LOC/UDAUTHLIST get authorization list entry 03611 FA82361B 2 790 JEQZ R2 CONTAUTH jump if no auth list 791 * \ / 792 03612 DC40349B 793 CALLNP GETAPAGE get a free page 03613 DC00382C 794 CALL PAGEIN to read in the AUT block for check 03614 41440015 IMM 795 PARV FBITAUTLB type is account share list 03615 41528000 2 REG 796 PARV R2 pass disk address 03616 4100AC00 797 PAR READDATA buffer addr 03617 40170802 4 BASE 798 PARL R4,MCBFBI FBI addr 03618 FE0E3643 799 JMP BADAUTH jump if bad read 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 84 (DTTREAD) F 18 Read an Account 03619 DC0034C3 800 CALL LINKINPRPQ send it to the packing queue 0361A 40440002 IMM 801 PARVL TMCB 802 * \ / 803 0000361B 804 CONTAUTH LABEL 0361B EC178801 6 BASE 805 STZ SP,DIR1INDEX begin at the begining 0361C EE004877 806 STZ2 READNAME to compare against for order 0361D EC004879 807 STZ READEXT first one will be in order 0361E 60049400 0 IMM 808 LD R0 ADR RDUDIR1LOC point to UDIR1 block 0361F 5C08001A 0 ZBM 809 CMZ R0,UDTYPE is this a big directory? 03620 FE0C3646 810 JNE BIGDIR jump if big 811 * \ / 812 03621 60D78801 3 6 BASE 813 LD R3 SP,DIR1INDEX get our place in UDIR 00003622 814 NEXTFDE LABEL 03622 39269460 4 3 815 LEA R4 RDUDIR1LOC/UDFDLIST(R3) get pointer to FD entry 03623 5C170800 4 BASE 816 CMZ R4,0 is there an entry? 03624 FE02362B 817 JEQ ACCTEND if not then we are done 03625 E5004850 4 818 ST R4 FDEPTR set pointer to FDE 03626 DC403691 819 CALLNP READFILE call to read this file 820 * \ / 821 822 * Move to the next entry 03627 60C40018 3 IMM 823 LD R3 FDLNTH length of entry 03628 B8D78801 3 6 BASE 824 ADDB R3 SP,DIR1INDEX move over the last entry 03629 64C40390 3 IMM 825 CPR R3 UDFDECNT*FDLNTH the end? 0362A FE083622 826 JLT NEXTFDE jump if possibly more entries 827 * \ / 828 0000362B 829 ACCTEND LABEL 0362B 5D1F8009 6 STAK 830 LEAVE POP 831 * --- 832 0362C 20416363 833 NAMEBADMSG TEXT " Account name mismatch. " 03632 20494458 834 TEXTZ " IDX=\A1\, UDIR1=\S2\.\R3\, UDIR1 FBI=\S4\.\R5\" 835 0000363E 836 BADDIR1 LABEL 0363E DC4034CF 837 CALLNP GIVEERROR put an error element into the queue 0363F FE0E362B 838 JMP ACCTEND get out of here 839 * --- 840 00003640 841 BADASHL LABEL 03640 DC403466 842 CALLNP PAGERETURN give back the page we could not read into 03641 DC4034CF 843 CALLNP GIVEERROR put an error element into the queue 03642 FE0E3610 844 JMP CONTSHL keep on going 845 * --- 846 00003643 847 BADAUTH LABEL 03643 DC403466 848 CALLNP PAGERETURN give back the page we could not read into 03644 DC4034CF 849 CALLNP GIVEERROR put an error element into the queue 03645 FE0E3610 850 JMP CONTSHL keep on going 851 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 85 (DTTREAD) F 18 Read an Account 853 854 ********************************************************************************** 855 * * 856 * The directory is a big one so we scan through the * 857 * major block, read in each of the minor blocks, and read the * 858 * files in them. * 859 * * 860 ********************************************************************************** 861 00003646 862 BIGDIR LABEL 03646 60D78801 3 6 BASE 863 LD R3 SP,DIR1INDEX where we are in UDIR1 00003647 864 NEXTDIR2 LABEL 03647 38A69460 2 3 865 LEA R2 RDUDIR1LOC/UDFDLIST(R3) pointer to entry 03648 62168800 012 BASE 866 LD2 R0 R2,UDINDXNAM get the first name in UDIR2 03649 FA02366E 0 867 JEQZ R0 DIR1IDEMP jump if no more 0364A E6178804 016 BASE 868 ST2 R0 SP,UDIR1NAME 0364B 60168802 0 2 BASE 869 LD R0 R2,UDINDXEXT get the extension, too 0364C E4178806 0 6 BASE 870 ST R0 SP,UDIR1EXT 871 * \ / 872 0364D EC004861 873 STZ RELBLOCK to compare against when read in 0364E 6004000A 0 IMM 874 LD R0 FBITUDIR2 FBI type 0364F E400486B 0 875 ST R0 UDIRTYPE save it for error processing 03650 60089183 0 2 ZBM 876 LD R0 R2,UDINDXADR get block number now 03651 E400486C 0 877 ST R0 UDIRBLOCK and save it for error processing 878 * \ / 879 03652 DC00382C 880 CALL PAGEIN get the pointer page in 03653 4144000A IMM 881 PARV FBITUDIR2 FBI type 03654 41489183 2 ZBM 882 PARV R2,UDINDXADR disk address 03655 41009800 883 PAR RDUDIR2LOC where we want it put 03656 40004851 884 PARL READFBI where to put the FBI 03657 FE0E366F 885 JMP BADDIR2 what to do when problems 886 * \ / 887 03658 EC178802 6 BASE 888 STZ SP,DIR2INDEX begin at the beginning 03659 60C40000 3 IMM 889 LD R3 0 use R3 for index 890 891 * check the first UDIR2 entry's name for a match against UDIR1 892 0365A 39269800 4 3 893 LEA R4 RDUDIR2LOC(R3) get pointer to entry 0365B 62170802 014 BASE 894 LD2 R0 R4,FDNAME get the name from UDIR2 0365C 6A178804 016 BASE 895 UCPR2 R0 SP,UDIR1NAME compare against UDIR1 0365D FE0C3671 896 JNE BADUDIRNAM report any problems 0365E 60170804 0 4 BASE 897 LD R0 R4,FDEXTEN get the extension 0365F 68178806 0 6 BASE 898 UCPR R0 SP,UDIR1EXT see if it matches 03660 FE0C3671 899 JNE BADUDIRNAM report any problem 900 * \ / 901 00003661 902 NEXTFDEX LABEL 03661 39269800 4 3 903 LEA R4 RDUDIR2LOC(R3) get pointer to entry 03662 5C170800 4 BASE 904 CMZ R4,0 is there another entry? 03663 FE02366A 905 JEQ DIR2FDEMP jump if not 03664 E5004850 4 906 ST R4 FDEPTR set pointer to FDE 03665 DC403691 907 CALLNP READFILE call to read this file 908 * \ / 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 86 (DTTREAD) F 18 Read an Account 909 910 * Move to the next entry 03666 60C40018 3 IMM 911 LD R3 FDLNTH size of entry 03667 B8D78802 3 6 BASE 912 ADDB R3 SP,DIR2INDEX move over the entry 03668 64C403F0 3 IMM 913 CPR R3 UD2FDECNT*FDLNTH past the end? 03669 FE083661 914 JLT NEXTFDEX jump if possibly more 915 * \ / 916 917 * Move to next secondary directory block 0000366A 918 DIR2FDEMP LABEL 0366A 60C40005 3 IMM 919 LD R3 UDINDXLEN length of index 0366B B8D78801 3 6 BASE 920 ADDB R3 SP,DIR1INDEX move to the next block pointer 0366C 64C4039D 3 IMM 921 CPR R3 UDINDCNT*UDINDXLEN past the end? 0366D FE083647 922 JLT NEXTDIR2 jump if possibly more 923 * \ / 924 0000366E 925 DIR1IDEMP LABEL 0366E FE0E362B 926 JMP ACCTEND all done, get out of here 927 * --- 928 0000366F 929 BADDIR2 LABEL 0366F DC4034CF 930 CALLNP GIVEERROR put an error element into the queue 03670 FE0E366A 931 JMP DIR2FDEMP get out of here 932 * --- 933 00003671 934 BADUDIRNAM LABEL 03671 61538000 5 6 REG 935 LD R5 SP 03672 DC1013F9 @ 936 CALL @VPREPOUT complain a bit 03673 4100486C 937 PAR UDIRBLOCK UDIR2 block number 03674 41170802 4 BASE 938 PAR R4,FDNAME first entry's name 03675 41170804 4 BASE 939 PAR R4,FDEXTEN and its extension 03676 41174807 5 BASE 940 PAR R5,CURUDIR1 UDIR1 block number 03677 41174804 5 BASE 941 PAR R5,UDIR1NAME UDIR1 index file name 03678 41174806 5 BASE 942 PAR R5,UDIR1EXT and its extension 03679 4000367C 943 PARL BADNAMEM 0367A EC12C000 3 REG 944 STZ R3 restore for loop 0367B FE0E3661 945 JMP NEXTFDEX 946 * --- 947 0367C 20074572 948 BADNAMEM TEXT " Error UDIR2 #\H1,6\ FDE=\S2\.\R3\ " 03685 646F6573 949 TEXTZ "doesn't match UDIR1 #\H4,6\ index=\S5\.\R6\." 950 951 END READACNT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 87 (DTTREAD) F 18 Read a file 954 955 ********************************************************************************** 956 * * 957 * This routine reads the file share list if it exists, * 958 * moves the FDE into a PREL and links it onto the PRPQ, then * 959 * calls the appropriate file reader to finish reading the * 960 * file. * 961 * Call: * 962 * CALLNP READFILE * 963 * Eats R0:R5 * 964 * * 965 ********************************************************************************** 966 967 READFILE BLOCK 968 969 ENTRY READFILE 970 971 BEGFRAME 972 ENDFRAME 973 03691 DD5F8001 6 STAK 974 READFILE ENTRNP PUSH 03692 60804850 2 975 LD R2 FDEPTR get pointer to FDE 03693 6008A010 0 2 ZBM 976 LD R0 R2,FDNBU no backup flag set? 03694 7C089E10 0 2 ZBM 977 IOR R0 R2,FDFBD file being destroyed? 03695 FA0C36B3 0 978 JNEZ R0 DONTREAD jump to ignore this file 979 * \ / 03696 62168802 012 BASE 980 LD2 R0 R2,FDNAME fetch up file name 03697 6A004877 01 981 UCPR2 R0 READNAME are we in ascending order 03698 E6004877 01 982 ST2 R0 READNAME and save for error printer 03699 FE0836B7 983 JLT NOORDER complain if out of order 0369A 60168804 0 2 BASE 984 LD R0 R2,FDEXTEN fetch up file name extension 0369B FE0C369E 985 JNE NOCHEKEXT don't check extension for order 986 * \ / 0369C 68004879 0 987 UCPR R0 READEXT names matched so check extensions 0369D FE0836B7 988 JLT NOORDER report the error 989 * \ / 0000369E 990 NOCHEKEXT LABEL 0369E E4004879 0 991 ST R0 READEXT and likewise save 0000369F 992 RETERROR LABEL 0369F DC403822 993 CALLNP MOVEFDE put the file directory entry in PRPQ 036A0 60804850 2 994 LD R2 FDEPTR R2 -> FDE 995 036A1 6216880A 012 BASE 996 LD2 R0 R2,FDSERNO pick up file serial number 036A2 E6004868 01 997 ST2 R0 READSERIAL and save for checker 036A3 60968814 2 2 BASE 998 LD R2 R2,FDSHL get key to shared list 036A4 F28036AF 2 999 JBF R2/SHLDSKFLGB NOSHL jump if no disk shared list 1000 * \ / 1001 036A5 EC004861 1002 STZ RELBLOCK to compare against when read in 036A6 DC40349B 1003 CALLNP GETAPAGE go get a free page 036A7 DC00382C 1004 CALL PAGEIN to read in the SHL block for check 036A8 41440012 IMM 1005 PARV FBITFSLB type is account share list 036A9 41528000 2 REG 1006 PARV R2 pass disk address 036AA 4100AC00 1007 PAR READDATA buffer addr 036AB 40170802 4 BASE 1008 PARL R4,MCBFBI FBI addr 036AC FE0E36B4 1009 JMP BADFSHL jump if bad read 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 88 (DTTREAD) F 18 Read a file 036AD DC0034C3 1010 CALL LINKINPRPQ add to the packing queue 036AE 40440002 IMM 1011 PARVL TMCB 1012 000036AF 1013 NOSHL LABEL 036AF 60804850 2 1014 LD R2 FDEPTR => file dir entry 036B0 6008AA60 0 2 ZBM 1015 LD R0 R2,FDET get the type of the device 036B1 50040010 0 IMM 1016 MIN R0 TYPELAST make it within bounds 036B2 5D6036C8 0 1017 XCT TYPETAB(R0) execute a subroutine call to read 1018 * the file. 000036B3 1019 DONTREAD LABEL 036B3 5D1F8001 6 STAK 1020 LEAVE POP return 1021 * --- 1022 000036B4 1023 BADFSHL LABEL 036B4 DC403466 1024 CALLNP PAGERETURN give back the unused page 036B5 DC4034CF 1025 CALLNP GIVEERROR put an error element into the queue 036B6 FE0E36AF 1026 JMP NOSHL continue on 1027 * --- 1028 1029 000036B7 1030 NOORDER LABEL 036B7 60168804 0 2 BASE 1031 LD R0 R2,FDEXTEN fetch up file name extension 036B8 E4004879 0 1032 ST R0 READEXT and likewise save 036B9 DC003A64 1033 CALL RPTERROR complain about order (like MacDonalds) 036BA 4144001A IMM 1034 PARV ECUDIRORD error code "UDIR entries out of order" 036BB 4140486C 1035 PARV UDIRBLOCK block number 036BC 4040486B 1036 PARVL UDIRTYPE FBI type 1037 * \ / 036BD DC1013F9 @ 1038 CALL @VPREPOUT tell them the file name 036BE 41004877 1039 PAR READNAME file name 036BF 41004879 1040 PAR READEXT and extention 036C0 400036C3 1041 PARL FILELINE 036C1 60804850 2 1042 LD R2 FDEPTR need to point to FDE 036C2 FE0E369F 1043 JMP RETERROR return to processing UDIR 1044 * --- 1045 036C3 20202020 1046 FILELINE TEXTZ " file \S1\.\R2\ " 1047 1048 ********************************************************************************** 1049 * * 1050 * Calls to subroutines to do the different disk * 1051 * structures indexed by structure code. * 1052 * * 1053 ********************************************************************************** 1054 000036C8 1055 TYPETAB LABEL 036C8 FEC00000 1056 NOP 0 0 - illegal 036C9 DC4036D9 1057 CALLNP READSAF 1 - SAF 036CA DC4036F1 1058 CALLNP READRAF 2 - RAF 036CB DC403756 1059 CALLNP READCODE 3 - CODE 036CC FEC00000 1060 NOP 0 4 - PATH 036CD FEC00000 1061 NOP 0 5 - DIR 036CE FEC00000 1062 NOP 0 6 - NULL 036CF FEC00000 1063 NOP 0 7 - TERM 036D0 FEC00000 1064 NOP 0 8 - LOCK 036D1 FEC00000 1065 NOP 0 9 - TASK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 89 (DTTREAD) F 18 Read a file 036D2 FEC00000 1066 NOP 0 10 - CDR 036D3 FEC00000 1067 NOP 0 11 - LP 036D4 FEC00000 1068 NOP 0 12 - MT 036D5 FEC00000 1069 NOP 0 13 - CT 036D6 FEC00000 1070 NOP 0 14 - VOL 036D7 FEC00000 1071 NOP 0 15 - VT 00000010 ABS 1072 TYPELAST EQU DISPW TYPETAB 036D8 FEC00000 1073 NOP 0 anything bigger than above 1074 1075 END READFILE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 90 (DTTREAD) F 18 Read a SAF 1078 1079 ********************************************************************************** 1080 * * 1081 * Routine to read a SAF. * 1082 * Call: * 1083 * CALLNP READSAF * 1084 * * 1085 * Eats R0:R5. * 1086 * * 1087 ********************************************************************************** 1088 1089 READSAF BLOCK 1090 1091 ENTRY READSAF 1092 1093 BEGFRAME 1094 ENDFRAME 1095 036D9 DD5F8001 6 STAK 1096 READSAF ENTRNP PUSH 036DA EC00486A 1097 STZ PREVBLOCK say no previous block 036DB EC004861 1098 STZ RELBLOCK start with no previous blocks 036DC 60004850 0 1099 LD R0 FDEPTR => file dir entry 036DD 60881185 2 0 ZBM 1100 LD R2 R0,FDDA get the root address of the file 1101 * \ / 1102 000036DE 1103 NEXTSAF LABEL 036DE DC40349B 1104 CALLNP GETAPAGE get a free page 036DF DC00382C 1105 CALL PAGEIN get the file page in 036E0 4144000C IMM 1106 PARV FBITSAF FBI type 036E1 41528000 2 REG 1107 PARV R2 disk address 036E2 4100AC00 1108 PAR READDATA where the block should go 036E3 40170802 4 BASE 1109 PARL R4,MCBFBI where to put FBI 036E4 FE0E36EE 1110 JMP BADSAF where to go if trouble 036E5 D0004861 1111 INC RELBLOCK next block should be one greater 036E6 EC090810 4 ZBM 1112 STZ R4,MCBWPRT not a write protected page 036E7 DC0034C3 1113 CALL LINKINPRPQ add to the packing queue 036E8 40440002 IMM 1114 PARVL TMCB 1115 * \ / 1116 036E9 60891183 2 4 ZBM 1117 LD R2 R4,MCBFBI/FBIDA get the blocks disk address 036EA E480486A 2 1118 ST R2 PREVBLOCK remember this as the last one 036EB 60891182 2 4 ZBM 1119 LD R2 R4,MCBFBI/FBIFLINK get the addr of the next block 036EC FA8C36DE 2 1120 JNEZ R2 NEXTSAF read another if not the end 1121 * \ / 1122 000036ED 1123 SAFDONE LABEL 036ED 5D1F8001 6 STAK 1124 LEAVE POP 1125 * --- 1126 000036EE 1127 BADSAF LABEL 036EE DC403466 1128 CALLNP PAGERETURN give back the unused page 036EF DC4034CF 1129 CALLNP GIVEERROR link in an error element 036F0 FE0E36ED 1130 JMP SAFDONE and quit 1131 * --- 1132 1133 END READSAF 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 91 (DTTREAD) F 18 Read a RAF 1136 1137 ********************************************************************************** 1138 * * 1139 * Routine to read a RAF. * 1140 * Call: * 1141 * CALLNP READRAF * 1142 * * 1143 * Gets R0:R5. * 1144 * * 1145 ********************************************************************************** 1146 1147 READRAF BLOCK 1148 1149 ENTRY READRAF read a RAF 1150 1151 BEGFRAME 00178801 6 BASE 1152 MAJINDEX BSS 1 index into major access block 1153 ENDFRAME 1154 036F1 DD5F8002 6 STAK 1155 READRAF ENTRNP PUSH 036F2 60C04850 3 1156 LD R3 FDEPTR => File dir entry 036F3 6088D185 2 3 ZBM 1157 LD R2 R3,FDDA get the root of the file 036F4 EC004861 1158 STZ RELBLOCK no block number for minor or major RAFs 036F5 6008FC20 0 3 ZBM 1159 LD R0 R3,FDRAFTYPE pick up the RAF type from the FDE 036F6 5CA036F7 0 1160 LDPC RAFJTAB(R0) act accordingly 1161 * --- 1162 000036F7 1163 RAFJTAB LABEL 036F7 000036FB 1164 VFD ADR CHEKTYPE empty RAF 036F8 0000370A 1165 VFD ADR TINYRAF tiny RAF 036F9 000036FE 1166 VFD ADR SMALLRAF small RAF 036FA 00003716 1167 VFD ADR LARGERAF large RAF 1168 000036FB 1169 CHEKTYPE LABEL 036FB FA823707 2 1170 JEQZ R2 OKEXIT done, if reading an empty RAF 1171 * \ / 1172 1173 * The RAF type is invalid. Decide what is the correct type 036FC 5C08E810 3 ZBM 1174 CMZ R3,FDLRAF is it a large RAF? 036FD FE0C3716 1175 JNE LARGERAF jump if so 1176 * \ / 1177 000036FE 1178 SMALLRAF LABEL 036FE DC00382C 1179 CALL PAGEIN get the small raf index 036FF 4144000E IMM 1180 PARV FBITSRAF FBI type 03700 41528000 2 REG 1181 PARV R2 block address 03701 41009C00 1182 PAR RDMINLOC where to put it 03702 40004851 1183 PARL READFBI and its FBI 03703 FE0E3708 1184 JMP BAILOUT if problems 1185 * \ / 1186 03704 DC003730 1187 CALL READMINOR read all those pointed to 03705 4144000F IMM 1188 PARV FBITRAFD FBI type 03706 40440400 IMM 1189 PARVL WPP number of words to scan 1190 * \ / 1191 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 92 (DTTREAD) F 18 Read a RAF 00003707 1192 OKEXIT LABEL 03707 5D1F8002 6 STAK 1193 LEAVE POP 1194 * --- 1195 00003708 1196 BAILOUT LABEL 03708 DC4034CF 1197 CALLNP GIVEERROR put in an error element 03709 FE0E3707 1198 JMP OKEXIT and get out of here 1199 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 93 (DTTREAD) F 18 Read a RAF 1201 1202 ********************************************************************************** 1203 * * 1204 * Tiny RAF -- read the single block (if any). * 1205 * * 1206 ********************************************************************************** 1207 0000370A 1208 TINYRAF LABEL 0370A DC40349B 1209 CALLNP GETAPAGE pick up a page to read into 0370B E4809C00 2 1210 ST R2 RDMINLOC(0) fake a minor access block so relative 1211 * block checking will work 0370C DC00382C 1212 CALL PAGEIN read the page 0370D 4144000F IMM 1213 PARV FBITRAFD RAF data page 0370E 41528000 2 REG 1214 PARV R2 disk address 0370F 4100AC00 1215 PAR READDATA where to read it into 03710 40170802 4 BASE 1216 PARL R4,MCBFBI put the FBI here 03711 FE0E3708 1217 JMP BAILOUT if we could not read the block 03712 EC090810 4 ZBM 1218 STZ R4,MCBWPRT not a write protected block 03713 DC0034C3 1219 CALL LINKINPRPQ link it in to be packed 03714 40440002 IMM 1220 PARVL TMCB type is MCB 03715 FE0E3707 1221 JMP OKEXIT 1222 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 94 (DTTREAD) F 18 Read a RAF 1224 1225 ********************************************************************************** 1226 * * 1227 * Large RAF -- read everything. * 1228 * * 1229 ********************************************************************************** 1230 00003716 1231 LARGERAF LABEL 03716 DC00382C 1232 CALL PAGEIN read in the major access block 03717 4144000D IMM 1233 PARV FBITLRAF FBI type 03718 41528000 2 REG 1234 PARV R2 disk address 03719 4100A000 1235 PAR RDMAJLOC where we want block 0371A 40004851 1236 PARL READFBI and FBI 0371B FE0E3708 1237 JMP BAILOUT if problems 1238 * \ / 1239 0371C 60C7FC00 3 IMM 1240 LD R3 -(WPP) number of locations to search 0000371D 1241 NEXTMAJB LABEL 0371D 60A6A400 2 3 1242 LD R2 RDMAJLOC(R3)(WPP) get address of block 0371E FA82372C 2 1243 JEQZ R2 MAJHOLE jump if zero and try next one 0371F E4D78801 3 6 BASE 1244 ST R3 SP,MAJINDEX save index 03720 18C40400 3 IMM 1245 ADD R3 WPP make into a positive index 03721 E4C04861 3 1246 ST R3 RELBLOCK relative block number for minor 03722 DC00382C 1247 CALL PAGEIN read the minor access block in 03723 4144000E IMM 1248 PARV FBITSRAF FBI type 03724 41528000 2 REG 1249 PARV R2 disk address 03725 41009C00 1250 PAR RDMINLOC where we want it 03726 40004851 1251 PARL READFBI and its FBI 03727 FE0E372E 1252 JMP BADMIN if problems 1253 * \ / 1254 03728 DC003730 1255 CALL READMINOR read those pointed to 03729 4144000F IMM 1256 PARV FBITRAFD FBI type 0372A 40440400 IMM 1257 PARVL WPP number of words to scan 0000372B 1258 KEEPGOIN LABEL 0372B 60D78801 3 6 BASE 1259 LD R3 SP,MAJINDEX where we are in major block 1260 * \ / 1261 0000372C 1262 MAJHOLE LABEL 0372C FAE0371D 3 1263 IRJ R3 NEXTMAJB count and jump if more 0372D FE0E3707 1264 JMP OKEXIT go to good exit 1265 * --- 1266 0000372E 1267 BADMIN LABEL 0372E DC4034CF 1268 CALLNP GIVEERROR tell the packer about the error 0372F FE0E372B 1269 JMP KEEPGOIN 1270 * --- 1271 1272 END READRAF 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 95 (DTTREAD) F 18 Read a RAF 1274 1275 ********************************************************************************** 1276 * * 1277 * Routine that reads the pages pointed to by a minor * 1278 * access block. * 1279 * Call: * 1280 * CALL READMINOR * 1281 * PARV FBI type of data pages * 1282 * PARVL number of words to scan in the block * 1283 * * 1284 * Gets R0:R5. * 1285 * * 1286 ********************************************************************************** 1287 1288 READMINOR BLOCK 1289 1290 ENTRY READMINOR 1291 1292 BEGFRAME 00178801 6 BASE 1293 TYPEFBI BSS 1 type of data page FBIs 00178802 6 BASE 1294 MINORSIZE BSS 1 number of entries in minor access block 00178803 6 BASE 1295 MINEND BSS 1 location of last entry in ordered minor block 00178804 6 BASE 1296 MININDEX BSS 1 our current index into ordered minor block 1297 ENDFRAME 1298 0008ACA4 2 ZBM 1299 FBIMINBITS EQU FBIWORDE/BITS 22:31 minor access relative block number 1300 03730 DD1F8005 6 STAK 1301 READMINOR ENTR PUSH 03731 C1578801 6 BASE 1302 STPV SP,TYPEFBI FBI type 03732 C0524000 1 REG 1303 STPVL R1 number of words to scan in block 1304 * \ / 03733 DC40376D 1305 CALLNP SORT sort the minor access block 03734 E4578802 1 6 BASE 1306 ST R1 SP,MINORSIZE save the size of the block 03735 60044844 0 IMM 1307 LD R0 ADR DISKCB address disk control block 03736 5C080816 0 ZBM 1308 CMZ R0,DCBSCSI SCSI disk drive? 03737 FE0C373C 1309 JNE NOTSCSIDSK jump if not 03738 DC4037E2 1310 CALLNP DIVSECTOR get the sector of each one 03739 60578802 1 6 BASE 1311 LD R1 SP,MINORSIZE get the size of the block 0373A DC4037EF 1312 CALLNP ORDERCYL order the cylinders 0373B 60578802 1 6 BASE 1313 LD R1 SP,MINORSIZE get the size of the block 1314 * \ / 0000373C 1315 NOTSCSIDSK LABEL 0373C 391B0C00 4 41 @R 1316 LEA R4 @R4(R1) R4 -> end of data 0373D E5178803 4 6 BASE 1317 ST R4 SP,MINEND save it 0373E 70D24000 3 1 REG 1318 LDN R3 R1 use R3 for a loop counter 0373F FAC63753 3 1319 JGEZ R3 EMPTYMIN if nothing in this block skip reading 03740 E4D78804 3 6 BASE 1320 ST R3 SP,MININDEX our location in the minor access block 1321 * \ / 00003741 1322 NEXTMINE LABEL 03741 60978803 2 6 BASE 1323 LD R2 SP,MINEND R2 -> end of ordered minor block 03742 609C9800 2 23 BASE 1324 LD R2 R2,0(R3) get the address of the next block 03743 DC40349B 1325 CALLNP GETAPAGE get a free page 03744 60578801 1 6 BASE 1326 LD R1 SP,TYPEFBI FBI type 03745 DC00382C 1327 CALL PAGEIN read in the data block 03746 41524000 1 REG 1328 PARV R1 FBI type 03747 41528000 2 REG 1329 PARV R2 disk address 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 96 (DTTREAD) F 18 Read a RAF 03748 4100AC00 1330 PAR READDATA where to put it 03749 40170802 4 BASE 1331 PARL R4,MCBFBI and its FBI 0374A FE0E3754 1332 JMP DATABAD if trouble 0374B 60092CA6 0 4 ZBM 1333 LD R0 R4,MCBFBI/FBIMINBITS get the minor access block index 0374C 60209C00 0 0 1334 LD R0 RDMINLOC(R0) pick up the pointing word in minor access 0374D 600A0010 0 0 CBM 1335 LD R0 R0/CCBPROTECT get the write protect bit 0374E E4090810 0 4 ZBM 1336 ST R0 R4,MCBWPRT so the packer will know 0374F DC0034C3 1337 CALL LINKINPRPQ add to packing queue 03750 40440002 IMM 1338 PARVL TMCB 1339 * \ / 00003751 1340 NEXTEND LABEL 03751 BCD78804 3 6 BASE 1341 INCL R3 SP,MININDEX 03752 FAC83741 3 1342 JLTZ R3 NEXTMINE restore the index 1343 * \ / 00003753 1344 EMPTYMIN LABEL 03753 5D1F8005 6 STAK 1345 LEAVE POP 1346 * --- 1347 00003754 1348 DATABAD LABEL 03754 DC4034CF 1349 CALLNP GIVEERROR let the packer know there is an error 03755 FE0E3751 1350 JMP NEXTEND keep on going 1351 * --- 1352 1353 END READMINOR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 97 (DTTREAD) F 18 Read a CODE 1356 1357 ********************************************************************************** 1358 * * 1359 * Routine to read a CODE. * 1360 * Call: * 1361 * CALLNP readcode * 1362 * * 1363 * Eats R0:R5. * 1364 * * 1365 ********************************************************************************** 1366 1367 READCODE BLOCK 1368 1369 ENTRY READCODE 1370 1371 BEGFRAME 1372 ENDFRAME 1373 03756 DD5F8001 6 STAK 1374 READCODE ENTRNP PUSH 03757 60C04850 3 1375 LD R3 FDEPTR => file dir entry 03758 EC004861 1376 STZ RELBLOCK no block number for CCBs 03759 6088D185 2 3 ZBM 1377 LD R2 R3,FDDA get root address of the file 0375A DC40349B 1378 CALLNP GETAPAGE need a page to move CCBINFO into 0375B DC00382C 1379 CALL PAGEIN get the root block in 0375C 41440013 IMM 1380 PARV FBITCCB FBI type 0375D 41528000 2 REG 1381 PARV R2 disk address 0375E 41009C00 1382 PAR RDMINLOC where we want the block 0375F 40170802 4 BASE 1383 PARL R4,MCBFBI FBI goes with the CCBINFO in new page 03760 FE0E376B 1384 JMP BAILOUT only if trouble with read 1385 * \ / 1386 1387 * Move first part of CCB into the page we got and send to the packer. 03761 38009FE8 0 1388 LEA R0 RDMINLOC(CCBINFO) where to start the move at 03762 60440060 1 IMM 1389 LD R1 CCBINFOL*CPW how much there is to move 03763 6084AC00 2 IMM 1390 LD R2 ADR READDATA where to move it to 03764 FE400000 1391 CMOVE and move the stuff 03765 DC0034C3 1392 CALL LINKINPRPQ time to queue the mother up 03766 40440002 IMM 1393 PARVL TMCB it is an MCB 1394 03767 DC003730 1395 CALL READMINOR read pointed to blocks 03768 41440014 IMM 1396 PARV FBITCODED FBI type 03769 404403E8 IMM 1397 PARVL CCBMAXPAGE how much to scan 1398 * \ / 0000376A 1399 BADLEAVE LABEL 0376A 5D1F8001 6 STAK 1400 LEAVE POP 1401 * --- 1402 0000376B 1403 BAILOUT LABEL 0376B DC4034CF 1404 CALLNP GIVEERROR tell the packer about the error 0376C FE0E376A 1405 JMP BADLEAVE 1406 * --- 1407 1408 END READCODE 1409 1410 INPUT DISKTOTAPE.OPSYS:DTTSORT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 98 (DTTSORT) F 19 Sort Minor Access Block 3 4 ********************************************************************************** 5 * * 6 * SORT removes all zero elements from RDMINLOC * 7 * and sorts the remaining elements in ascending order using * 8 * either a merge or bubble sort. There is more overhead in * 9 * setting up for a merge sort so if there is a small number * 10 * of elements to be sorted we just do a quick and sleazy * 11 * bubble sort. * 12 * Call: * 13 * LD R1 * 14 * CALLNP SORT * 15 * * 16 * Eats R0:R4 * 17 * Leaves R1 = number of non-zero elements, R4 -> sorted data * 18 * R3 -> free page * 19 * * 20 ********************************************************************************** 21 22 BLOCK 23 24 ENTRY SORT 25 26 BEGFRAME 00178801 6 BASE 27 NUMELEM BSS 1 number of elements 28 ENDFRAME 29 0000000F ABS 30 MINELEMS EQU 15 minimum number to merge sort 31 0376D DD5F8002 6 STAK 32 SORT ENTRNP PUSH 0376E DC4037D8 33 CALLNP MOVESTUFF move data into working area and 34 * get rid of zero entries 0376F E4578801 1 6 BASE 35 ST R1 SP,NUMELEM save the number of good data words 03770 6444000F 1 IMM 36 CPR R1 MINELEMS see if enough elements 03771 FE083775 37 JLT BUBSORT if not then bubble sort them 38 * \ / 39 03772 DC40377B 40 CALLNP MSORT merge sort the suckers 41 * \ / 42 00003773 43 SORTEND LABEL 03773 60578801 1 6 BASE 44 LD R1 SP,NUMELEM get the number of elements 03774 5D1F8002 6 STAK 45 LEAVE POP 46 * --- 47 00003775 48 BUBSORT LABEL 03775 64440001 1 IMM 49 CPR R1 1 see if there are any elements to sort 03776 FE0A3778 50 JLE BUBSEND if not then don't bother 51 * \ / 52 03777 DC4037C9 53 CALLNP BSORT bubble sort 54 * \ / 55 00003778 56 BUBSEND LABEL 03778 6104A400 4 IMM 57 LD R4 ADR RDSORTLOC R4 -> sorted stuff 03779 60C4A800 3 IMM 58 LD R3 ADR RDMERGELOC R3 -> free page 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 99 (DTTSORT) F 19 Sort Minor Access Block 0377A FE0E3773 59 JMP SORTEND 60 * --- 61 62 END of SORT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 100 (DTTSORT) F 19 Sort Minor Access Block 64 65 ********************************************************************************** 66 * * 67 * MSORT sorts the contents of RDSORTLOC using a mergesort. * 68 * Call: * 69 * LD R1 * 70 * CALLNP MSORT * 71 * * 72 * Eats R0:R4 * 73 * Leaves R4 -> sorted block * 74 * R3 -> free page * 75 * * 76 ********************************************************************************** 77 78 BLOCK 79 80 ENTRY MSORT 81 82 BEGFRAME 00178801 6 BASE 83 PASSSIZE BSS 1 size of blocks in the current pass 00178802 6 BASE 84 HICOUNT BSS 1 counter for words left in high block 00178803 6 BASE 85 LOCOUNT BSS 1 counter for words left in low block 00178804 6 BASE 86 HIBLOCK BSS 1 pointer to the high block 00178805 6 BASE 87 BLOCKEND BSS 1 address of end of current block 00178806 6 BASE 88 CURBLOCK BSS 1 address of current block 00178807 6 BASE 89 DESTBLOCK BSS 1 address of destination block 00178808 6 BASE 90 NUMELEM BSS 1 number of elements 91 ENDFRAME 92 0377B DD5F8009 6 STAK 93 MSORT ENTRNP PUSH 0377C E4578808 1 6 BASE 94 ST R1 SP,NUMELEM save the number of elements 0377D 60C40001 3 IMM 95 LD R3 1 size of first pass 0377E E4D78801 3 6 BASE 96 ST R3 SP,PASSSIZE 0377F E4D78803 3 6 BASE 97 ST R3 SP,LOCOUNT set the count for the low block 03780 E4D78802 3 6 BASE 98 ST R3 SP,HICOUNT set the count for the high block 99 03781 6104A800 4 IMM 100 LD R4 ADR RDMERGELOC R4 -> destination block 03782 6084A400 2 IMM 101 LD R2 ADR RDSORTLOC pointer to first of data 102 * \ / 103 104 * R2 -> source, R4 -> destination, R1 = number of elements, R3 = PASSSIZE 00003783 105 PASSLOOP LABEL 03783 E4978806 2 6 BASE 106 ST R2 SP,CURBLOCK call our current block 03784 E5178807 4 6 BASE 107 ST R4 SP,DESTBLOCK save our destination block address 03785 18528000 1 2 REG 108 ADD R1 R2 create address of end of block 03786 E4578805 1 6 BASE 109 ST R1 SP,BLOCKEND and save it 110 * \ / 111 112 * R2 -> low block, R3 = PASSSIZE = size of block = LOCOUNT, 00003787 113 OUTLOOP LABEL 03787 18D28000 3 2 REG 114 ADD R3 R2 set pointer to high block 03788 64D78805 3 6 BASE 115 CPR R3 SP,BLOCKEND see if there is any data this far out 03789 FE0637B5 116 JGE PASSEND if beyond end then quit 0378A E4D78804 3 6 BASE 117 ST R3 SP,HIBLOCK save pointer to high block 118 0378B 30D78805 3 6 BASE 119 RSB R3 SP,BLOCKEND get number of words left in block 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 101 (DTTSORT) F 19 Sort Minor Access Block 0378C 50D78801 3 6 BASE 120 MIN R3 SP,PASSSIZE keep if smaller than size of block 0378D E4D78802 3 6 BASE 121 ST R3 SP,HICOUNT number of words in high block 0378E 60D78804 3 6 BASE 122 LD R3 SP,HIBLOCK restore high block pointer 123 0378F 60168400 0 2 @R 124 LD R0 @R2 get first word of data 03790 6056C400 1 3 @R 125 LD R1 @R3 from both blocks 126 * \ / 127 128 ********************************************************************************** 129 * * 130 * This is the central loop of the merge sort. It uses R2 * 131 * and R3 to point to the current position within the blocks * 132 * being merged, and R0 and R1 contain the current words * 133 * pointed at by these. When all of one block is merged the * 134 * remaining elements are moved using a CMOVE. * 135 * * 136 ********************************************************************************** 137 * \ / 138 00003791 139 LOOP LABEL 03791 64124000 0 1 REG 140 CPR R0 R1 see which is less 03792 FE04379A 141 JGT PUTINR1 and put the lessor in the buffer 142 * \ / 143 03793 E4170400 0 4 @R 144 ST R0 @R4 put R0 in buffer 03794 19040001 4 IMM 145 ADD R4 1 move up the buffer pointer 03795 D0578803 6 BASE 146 DEC SP,LOCOUNT one less in the lower block 03796 FE0237A1 147 JEQ LODONE done with the lower block? 03797 18840001 2 IMM 148 ADD R2 1 move up within the block 03798 60168400 0 2 @R 149 LD R0 @R2 get the next word 03799 FE0E3791 150 JMP LOOP 151 * --- 152 0000379A 153 PUTINR1 LABEL 0379A E4570400 1 4 @R 154 ST R1 @R4 put R1 in the buffer 0379B 19040001 4 IMM 155 ADD R4 1 move up the buffer pointer 0379C D0578802 6 BASE 156 DEC SP,HICOUNT one less word in the high block 0379D FE0237A8 157 JEQ HIDONE done with lower block if zero 0379E 18C40001 3 IMM 158 ADD R3 1 move up within high block 0379F 6056C400 1 3 @R 159 LD R1 @R3 get the next word 037A0 FE0E3791 160 JMP LOOP and go around again 161 * --- 162 000037A1 163 LODONE LABEL 037A1 6012C000 0 3 REG 164 LD R0 R3 R0 -> remaining words 037A2 60578802 1 6 BASE 165 LD R1 SP,HICOUNT number of words remaining 037A3 1C440004 1 IMM 166 MUL R1 CPW convert to characters 037A4 60930000 2 4 REG 167 LD R2 R4 R2 -> destination 037A5 FE400000 168 CMOVE finish moving them 037A6 19178802 4 6 BASE 169 ADD R4 SP,HICOUNT move up the destination pointer 037A7 FE0E37AE 170 JMP LOOPEND through with inner loop 171 * --- 172 000037A8 173 HIDONE LABEL 037A8 60128000 0 2 REG 174 LD R0 R2 R0 -> remaining words 037A9 60578803 1 6 BASE 175 LD R1 SP,LOCOUNT get number of words left to move 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 102 (DTTSORT) F 19 Sort Minor Access Block 037AA 1C440004 1 IMM 176 MUL R1 CPW convert to character count 037AB 60930000 2 4 REG 177 LD R2 R4 R2 -> destination 037AC FE400000 178 CMOVE and finish moving them 037AD 19178803 4 6 BASE 179 ADD R4 SP,LOCOUNT move up the destination pointer 180 * \ / 181 000037AE 182 LOOPEND LABEL 037AE 60978804 2 6 BASE 183 LD R2 SP,HIBLOCK get address of last high block 037AF 18978801 2 6 BASE 184 ADD R2 SP,PASSSIZE move to beginning of next block 037B0 64978805 2 6 BASE 185 CPR R2 SP,BLOCKEND are we beyond the data 037B1 FE0637BB 186 JGE PASSEND1 done with pass and nothing to move 037B2 60D78801 3 6 BASE 187 LD R3 SP,PASSSIZE get the pass block size 037B3 E4D78803 3 6 BASE 188 ST R3 SP,LOCOUNT and call it the low block word count 037B4 FE0E3787 189 JMP OUTLOOP 190 * --- 191 192 193 * We get here when there is no high block to merge with 194 * the low block so we just move the low block to the 195 * destination and do another pass. 000037B5 196 PASSEND LABEL 037B5 60128000 0 2 REG 197 LD R0 R2 set up for CMOVE, R0 -> source 037B6 60578805 1 6 BASE 198 LD R1 SP,BLOCKEND get end of block's address 037B7 10528000 1 2 REG 199 SUB R1 R2 get number of words left in block 037B8 1C440004 1 IMM 200 MUL R1 CPW convert to a character count 037B9 60930000 2 4 REG 201 LD R2 R4 R2 -> destination 037BA FE400000 202 CMOVE move the remaining words 203 * \ / 204 000037BB 205 PASSEND1 LABEL 037BB 60D78801 3 6 BASE 206 LD R3 SP,PASSSIZE get the size of the last pass 037BC 18D2C000 3 3 REG 207 ADD R3 R3 double the size for this pass 037BD 64D78808 3 6 BASE 208 CPR R3 SP,NUMELEM see if we are done 037BE FE0637C5 209 JGE MERGEDONE 210 * \ / 211 037BF E4D78801 3 6 BASE 212 ST R3 SP,PASSSIZE save the size of this pass 037C0 E4D78803 3 6 BASE 213 ST R3 SP,LOCOUNT set the low block count 037C1 60578808 1 6 BASE 214 LD R1 SP,NUMELEM get the number of elements 037C2 61178806 4 6 BASE 215 LD R4 SP,CURBLOCK R4 -> new destination block 037C3 60978807 2 6 BASE 216 LD R2 SP,DESTBLOCK R2 -> new source block 037C4 FE0E3783 217 JMP PASSLOOP do another pass 218 * --- 219 000037C5 220 MERGEDONE LABEL 037C5 60578808 1 6 BASE 221 LD R1 SP,NUMELEM get the number of elements 037C6 61178807 4 6 BASE 222 LD R4 SP,DESTBLOCK R4 -> destination 037C7 60D78806 3 6 BASE 223 LD R3 SP,CURBLOCK R3 -> free block 037C8 5D1F8009 6 STAK 224 LEAVE POP 225 * --- 226 227 END 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 103 (DTTSORT) F 19 Sort Minor Access Block 229 230 ********************************************************************************** 231 * * 232 * BSORT performs a bubble sort on the words in RDSORTLOC. * 233 * Call: * 234 * LD R1 * 235 * CALLNP BSORT * 236 * * 237 * Eats R0:R4 * 238 * * 239 ********************************************************************************** 240 241 BLOCK 242 243 ENTRY BSORT 244 245 BEGFRAME 246 ENDFRAME 247 037C9 DD5F8001 6 STAK 248 BSORT ENTRNP PUSH 037CA E4571002 1 4 REG 249 ST R1 R4+2 set up outer loop counter 250 000037CB 251 LOOP LABEL 037CB 60D30000 3 4 REG 252 LD R3 R4 037CC 62440000 12 IMM 253 LD2 R1 0 set our index into the data (R1) 254 * and clear our change flag (R2) 000037CD 255 INNRLOOP LABEL 037CD 6022A400 0 1 256 LD R0 RDSORTLOC(R1) get first data word 037CE 6422A401 0 1 257 CPR R0 RDSORTLOC(R1+1) see if in order 037CF FE0A37D3 258 JLE INEND if so go to end of inner loop 037D0 E022A401 0 1 259 EXCH R0 RDSORTLOC(R1+1) exchange the two words 037D1 E422A400 0 1 260 ST R0 RDSORTLOC(R1) finish up the exchange 037D2 60840001 2 IMM 261 LD R2 1 say an exchange happened 000037D3 262 INEND LABEL 037D3 18440001 1 IMM 263 ADD R1 1 move to the next word 037D4 FAE637CD 3 264 JDR R3 INNRLOOP go around again 265 * \ / 266 037D5 FA8237D7 2 267 JEQZ R2 BUBEND if no changes quit 037D6 FB2637CB 4 268 JDR R4 LOOP go around again 269 * \ / 270 000037D7 271 BUBEND LABEL 037D7 5D1F8001 6 STAK 272 LEAVE POP 273 * --- 274 275 END BSORT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 104 (DTTSORT) F 19 Sort Minor Access Block 277 278 ********************************************************************************** 279 * * 280 * MOVESTUFF moves the words in RDMINLOC to RDSORTLOC * 281 * and eliminates all zero elements. * 282 * Call: * 283 * LD R1 * 284 * CALLNP MOVESTUFF * 285 * ST R1 * 286 * * 287 * Eats R0:R3 * 288 * * 289 ********************************************************************************** 290 291 BLOCK 292 293 ENTRY MOVESTUFF 294 295 BEGFRAME 296 ENDFRAME 297 037D8 DD5F8001 6 STAK 298 MOVESTUFF ENTRNP PUSH 037D9 38E29C00 3 1 299 LEA R3 RDMINLOC(R1) set R2 -> end of source 037DA 70924000 2 1 REG 300 LDN R2 R1 initialize index into RDMINLOC 037DB 60440000 1 IMM 301 LD R1 0 initialize word count 302 000037DC 303 MOVELOOP LABEL 037DC 601CD000 0 32 BASE 304 LD R0 R3,0(R2) get a word 037DD FA0237E0 0 305 JEQZ R0 MOVELPEND if it is zero skip it 037DE E422A400 0 1 306 ST R0 RDSORTLOC(R1) put the word in place 037DF 18440001 1 IMM 307 ADD R1 1 say another word has been found 308 * \ / 309 000037E0 310 MOVELPEND LABEL 037E0 FAA037DC 2 311 IRJ R2 MOVELOOP and get the next word 312 * \ / 037E1 5D1F8001 6 STAK 313 LEAVE POP 314 * --- 315 316 END of MOVESTUFF 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 105 (DTTSORT) F 19 Sort Minor Access Block 318 319 ********************************************************************************** 320 * * 321 * DIVSECTOR determines the sector number of each block * 322 * in the sorted page pointed to by R4, and stores the sector * 323 * number in BITS 0:3 of the word containing the block number. * 324 * Call: * 325 * LD R1 number of entries in block * 326 * LD R4 ADR * 327 * SECPTRAK = sectors per track of disk being rebuilt * 328 * CALLNP DIVSECTOR * 329 * * 330 * Leaves R4 -> sorted block * 331 * Eats R0:R2 * 332 * * 333 ********************************************************************************** 334 00000040 BYTE 335 SECTBITS EQU BITS 0:3 bits containing sector number 336 337 BLOCK 338 339 ENTRY DIVSECTOR 340 341 BEGFRAME 342 ENDFRAME 343 037E2 DD5F8001 6 STAK 344 DIVSECTOR ENTRNP PUSH 037E3 FA4237EE 1 345 JEQZ R1 DIVEND don't do this if there aren't any 037E4 58C40010 IMM 346 IORPSR PSRMODIF set funky arithmetic 037E5 E4569001 1 2 REG 347 ST R1 R2+1 initialize our index 348 000037E6 349 DIVLOOP LABEL 037E6 605D1000 1 42 BASE 350 LD R1 R4,0(R2) get a word 037E7 60040000 0 IMM 351 LD R0 0 for funny math 037E8 1400485C 0 352 DIV R0 SECPTRAK figure out the sector number 037E9 601D1000 0 42 BASE 353 LD R0 R4,0(R2) get the word back 037EA E44A0040 1 0 CBM 354 ST R1 R0/SECTBITS put the sector in the high bits 037EB E41D1000 0 42 BASE 355 ST R0 R4,0(R2) put the word back 037EC FAA637E6 2 356 JDR R2 DIVLOOP go around again 357 * \ / 358 037ED 58840010 IMM 359 CLBPSR PSRMODIF clear bizarre mathematics 000037EE 360 DIVEND LABEL 037EE 5D1F8001 6 STAK 361 LEAVE POP 362 * --- 363 364 END 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 106 (DTTSORT) F 19 Sort Minor Access Block 366 367 ********************************************************************************** 368 * * 369 * ORDERCYL orders the sorted minor access block to optimize * 370 * disk reads. * 371 * Call: * 372 * LD R1 number of entries * 373 * LD R3 ADR * 374 * LD R4 ADR * 375 * CALLNP ORDERCYL * 376 * * 377 * Leaves R4 -> destination block * 378 * Eats R0:R5 * 379 * * 380 ********************************************************************************** 381 382 BLOCK 383 384 ENTRY ORDERCYL 385 386 BEGFRAME 00178801 6 BASE 387 FOUNDFLAG BSS 1 counter used to determine when cylinder is done 00178802 6 BASE 388 DESTBLOCK BSS 1 destination for ordered stuff 00178803 6 BASE 389 NEXTCYL BSS 1 index to the next cylinder 00178804 6 BASE 390 THISCYL BSS 1 index to beginning of current cylinder 391 ENDFRAME 392 037EF DD5F8005 6 STAK 393 ORDERCYL ENTRNP PUSH 037F0 64440001 1 IMM 394 CPR R1 1 see if it makes sense to optimize 037F1 FE0A381D 395 JLE ONLYONE if not then don't 037F2 E4D78802 3 6 BASE 396 ST R3 SP,DESTBLOCK destination address 037F3 19124000 4 1 REG 397 ADD R4 R1 R4 -> end of block 037F4 70524000 1 1 REG 398 LDN R1 R1 make into a negative index 037F5 E4578803 1 6 BASE 399 ST R1 SP,NEXTCYL where to start next cylinder at 400 * \ / 401 000037F6 402 ORDLOOP LABEL 037F6 60578803 1 6 BASE 403 LD R1 SP,NEXTCYL start at the beginning of the next cylinder 037F7 E4578804 1 6 BASE 404 ST R1 SP,THISCYL so we know where we are 037F8 615D0800 5 41 BASE 405 LD R5 R4,0(R1) get the first block number 037F9 794048C9 5 406 AND R5 MSMASK remove sector bits 037FA 1540485D 5 407 DIV R5 SECPCYL determine the cylinder of this block 037FB 19440001 5 IMM 408 ADD R5 1 we want the next cylinder 037FC 1D40485D 5 409 MUL R5 SECPCYL get to the beginning of next cylinder 410 037FD 6000485C 0 411 LD R0 SECPTRAK sectors per track 037FE E4178801 0 6 BASE 412 ST R0 SP,FOUNDFLAG will decrement each time around that a 413 * sector is not found. 414 * 0 indicates through with this cylinder 037FF EC004860 415 STZ SECTORSW zero out the sector bit array 03800 60840000 2 IMM 416 LD R2 0 first sector to look for 417 * \ / 418 00003801 419 SECTLOOP LABEL 03801 601D0800 0 41 BASE 420 LD R0 R4,0(R1) get the block's address 03802 FA023807 0 421 JEQZ R0 SECTLEND 0 indicates word already is used 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 107 (DTTSORT) F 19 Sort Minor Access Block 03803 654A1180 5 0 CBM 422 CPR R5 R0/MSBLKFIELD see if block is on the cylinder 03804 FE0A3817 423 JLE CYLEND 03805 648A0040 2 0 CBM 424 CPR R2 R0/SECTBITS just check bits indicating the sector 03806 FE02380B 425 JEQ FOUNDSEC 00003807 426 SECTLEND LABEL 03807 FA603801 1 427 IRJ R1 SECTLOOP go around again until end of cylinder 428 * \ / 429 430 * end of block has been reached 03808 D0578801 6 BASE 431 DEC SP,FOUNDFLAG a round done with no success 03809 FE023820 432 JEQ ORDEND if zero, done with last cylinder 0380A FE0E381A 433 JMP NEXTSEC do the next sector 434 * --- 435 436 0000380B 437 FOUNDSEC LABEL 0380B EC1D0800 41 BASE 438 STZ R4,0(R1) this entry is now used 0380C 780048C9 0 439 AND R0 MSMASK get rid of misc bits 0380D E416C400 0 3 @R 440 ST R0 @R3 move this entry into our new ordered list 0380E 18C40001 3 IMM 441 ADD R3 1 move up for next word 0380F 18840002 2 IMM 442 ADD R2 2 move to the next wanted sector 443 * \ / 444 00003810 445 SECTMOD LABEL 03810 60578804 1 6 BASE 446 LD R1 SP,THISCYL initialize for SECTLOOP 03811 6480485C 2 447 CPR R2 SECPTRAK see if valid sector number 03812 FE083814 448 JLT CHEKSECT see if this sector exists still 03813 1080485C 2 449 SUB R2 SECPTRAK adjust to a valid sector 00003814 450 CHEKSECT LABEL 03814 5C3448D4 2 @ 451 CMZ @SECPTR(R2) is this sector exhausted? 03815 FE023801 452 JEQ SECTLOOP if zero then some still left 03816 FAA03810 2 453 IRJ R2 SECTMOD move to next sector and check 454 * --- 455 00003817 456 CYLEND LABEL 03817 E4578803 1 6 BASE 457 ST R1 SP,NEXTCYL and save for end of cylinder processing 03818 D0578801 6 BASE 458 DEC SP,FOUNDFLAG a round done with no success 03819 FE0237F6 459 JEQ ORDLOOP if zero then start the next cylinder 460 * \ / 461 0000381A 462 NEXTSEC LABEL 0381A EDF448D4 2 @ 463 STW @SECPTR(R2) say none of this sector left 0381B 18840001 2 IMM 464 ADD R2 1 try for the next sector 0381C FE0E3810 465 JMP SECTMOD share sector modulo code 466 * --- 467 0000381D 468 ONLYONE LABEL 0381D E5178802 4 6 BASE 469 ST R4 SP,DESTBLOCK 0381E 600048C9 0 470 LD R0 MSMASK get mask for block numbers 0381F F8170400 0 4 @R 471 ANDM R0 @R4 get rid of sector number of block 472 * \ / 473 00003820 474 ORDEND LABEL 03820 61178802 4 6 BASE 475 LD R4 SP,DESTBLOCK destination address 03821 5D1F8005 6 STAK 476 LEAVE POP 477 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 108 (DTTSORT) F 19 Sort Minor Access Block 478 479 END 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 109 (DTTREAD) F 18 FDE mover 1413 1414 ********************************************************************************** 1415 * * 1416 * MOVEFDE -- FDE mover * 1417 * * 1418 * This routine copies a file directory entry into a PREL * 1419 * and links it into the PRPQ. This is used by the packer to * 1420 * determine the start of a new file. * 1421 * Call: * 1422 * FDEPTR -> FDE entry * 1423 * CALLNP MOVEFDE * 1424 * Eats R0:R4 * 1425 * * 1426 ********************************************************************************** 1427 1428 MOVEFDE BLOCK 1429 1430 ENTRY MOVEFDE 1431 1432 BEGFRAME 1433 ENDFRAME 1434 03822 DD5F8001 6 STAK 1435 MOVEFDE ENTRNP PUSH 03823 DC4034AA 1436 CALLNP GETAPREL get a chunk of memory to put the FDE in 03824 60004850 0 1437 LD R0 FDEPTR set up for the move 03825 60440060 1 IMM 1438 LD R1 FDLNTH*CPW length of move 03826 38974801 2 5 BASE 1439 LEA R2 R5,PRELFDE where to move the FDE to 03827 FE400000 1440 CMOVE 03828 61134000 4 5 REG 1441 LD R4 R5 need R4 -> PREL 03829 DC0034C3 1442 CALL LINKINPRPQ link in a FDE 0382A 40440001 IMM 1443 PARVL TFDE 0382B 5D1F8001 6 STAK 1444 LEAVE POP 1445 * --- 1446 1447 END MOVEFDE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 110 (DTTREAD) F 18 Page Input 1450 1451 ********************************************************************************** 1452 * * 1453 * Routine to read in the specified page. * 1454 * Call: * 1455 * CALL PAGEIN * 1456 * PARV fbi type (zero will cause no check) * 1457 * PARV disk address * 1458 * PAR page to put the block in * 1459 * PARL place to put the FBI * 1460 * JMP error * 1461 * * 1462 * Gets R0:R2,R5. * 1463 * * 1464 ********************************************************************************** 1465 1466 PAGEIN BLOCK 1467 1468 ENTRY PAGEIN 1469 1470 BEGFRAME 00178801 6 BASE 1471 FBITYPEX BSS 1 00178802 6 BASE 1472 PAGEINBL BSS 1 block location 00178803 6 BASE 1473 FBIADR BSS 1 fbi location 00178804 6 BASE 1474 PAGEINR34 BSS 2 save for R3,R4 00178806 6 BASE 1475 PAGEERROR BSS 1 temporary storage 1476 ENDFRAME 1477 0382C DD1F8007 6 STAK 1478 PAGEIN ENTR PUSH 0382D C1578801 6 BASE 1479 STPV SP,FBITYPEX FBI type expected 0382E C1404864 1480 STPV CURBLK block to get 0382F C1178802 6 BASE 1481 STP SP,PAGEINBL where to put it 03830 C0178803 6 BASE 1482 STPL SP,FBIADR and its FBI 03831 E6D78804 346 BASE 1483 ST2 R3 SP,PAGEINR34 save R3,R4 03832 600048C9 0 1484 LD R0 MSMASK mask for disk addresses 03833 78004864 0 1485 AND R0 CURBLK remove extra bits from disk address 03834 E4004864 0 1486 ST R0 CURBLK remember given addr 03835 6400485E 0 1487 CPR R0 VOLSIZE check for beyond volume end 03836 FE063890 1488 JGE PASTVOLEND jump if so 1489 * \ / 1490 03837 60C99E72 3 6 ZBM 1491 LD PFPTR SP,PAGEINBL/FLDPAGE get the block location 03838 18C40080 3 IMM 1492 ADD PFPTR MONPF make it in the monitor 03839 8092C000 3 REG 1493 PFRD R3 get the page file for the page 0383A 61044844 4 IMM 1494 LD R4 ADR DISKCB get the control block addr 0383B 61538000 5 6 REG 1495 LD R5 SP 0383C DC1013E0 @ 1496 CALL @VREAD read in the page 0383D 41404864 1497 PARV CURBLK the block desired 0383E 4152C000 3 REG 1498 PARV R3 where we want it 0383F 41174C03 5 FPVR 1499 PAR @(R5,FBIADR) put the FBI here 03840 41440000 IMM 1500 PARV 0 just check CS and FBIDA 03841 40003891 1501 PARL READERROR go here if problems 1502 * \ / 1503 * READ thought it was successful. Here, we check to see 1504 * if we really got the block we wanted. 1505 * \ / 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 111 (DTTREAD) F 18 Page Input 03842 60978803 2 6 BASE 1506 LD R2 SP,FBIADR for the following tests 03843 60578801 1 6 BASE 1507 LD R1 SP,FBITYPEX get the FBI type expected 03844 FA423848 1 1508 JEQZ R1 ANYTYPE don't check the FBI type if zero 03845 64488080 1 2 ZBM 1509 CPR R1 R2,FBITYPE verify it's the right kind of block 03846 60040008 0 IMM 1510 LD R0 ECFBITYPE error code 03847 FE0C3891 1511 JNE READERROR jump if wrong type of block 1512 * \ / 1513 00003848 1514 ANYTYPE LABEL 03848 5C00487C 1515 CMZ CHEKFBIFLG should we check the FBI? 03849 FE02388D 1516 JEQ READOK if not then give an OK exit 1517 * \ / 0384A 64440009 1 IMM 1518 CPR R1 FBITUDIR1 see if we have read in a UDIR1 0384B FE0C384F 1519 JNE NOTUDIR1 if not then continue on 0384C 62009420 01 1520 LD2 R0 RDUDIR1LOC/UDSERNO get the account serial number 0384D E6004866 01 1521 ST2 R0 READASN save it for other checks 0384E 60578801 1 6 BASE 1522 LD R1 SP,FBITYPEX get FBI type back 1523 * \ / 1524 1525 ********************************************************************************** 1526 * * 1527 * Now all the FBI fields are checked for validity. * 1528 * * 1529 ********************************************************************************** 1530 0000384F 1531 NOTUDIR1 LABEL 0384F 603238B1 0 1 @ 1532 LD R0 @TYPETAB(R1) get word indicating what to check for 03850 F6303855 0 1533 JBT R0/FLINKBIT CHEKFLAG if set then don't check now 03851 DC0038F4 1534 CALL FBIFLDCHEK check for a zero field 03852 4144000E IMM 1535 PARV ECFBIFLNK error code 03853 414048D7 1536 PARV EMPTY check for nothing 03854 40089180 2 ZBM 1537 PARL R2,FBIFLINK what to check 1538 * \ / 1539 00003855 1540 CHEKFLAG LABEL 03855 60578801 1 6 BASE 1541 LD R1 SP,FBITYPEX get the FBI type back 03856 DC0038F4 1542 CALL FBIFLDCHEK check flag field value 03857 4144000F IMM 1543 PARV ECFBIFLAG error code 03858 417238B5 1 @ 1544 PARV @FBIFLAGPTR(R1) value depends on the FBI type 03859 40088221 2 ZBM 1545 PARL R2,FBIDEFFLAGS what to check 1546 * \ / 0385A DC4038D9 1547 CALLNP CDCHEK go check the last change date 1548 * \ / 1549 0385B 603238B1 0 1 @ 1550 LD R0 @TYPETAB(R1) get word indicating what to check for 0385C F6343862 0 1551 JBT R0/BLINKBIT BLINKIN what to do about backward link 0385D DC0038F4 1552 CALL FBIFLDCHEK check for no backward link 0385E 41440011 IMM 1553 PARV ECFBIBLNE error code 0385F 414048D7 1554 PARV EMPTY should be nothing there 03860 40089182 2 ZBM 1555 PARL R2,FBIBLINK check back link 03861 FE0E3866 1556 JMP CHEKRELBLK continue on 1557 * --- 1558 00003862 1559 BLINKIN LABEL 03862 DC0038F4 1560 CALL FBIFLDCHEK check for backward link 03863 4144000B IMM 1561 PARV ECFBIBLNK error code 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 112 (DTTREAD) F 18 Page Input 03864 4140486A 1562 PARV PREVBLOCK should match previous block # 03865 40089182 2 ZBM 1563 PARL R2,FBIBLINK check back link 1564 * \ / 1565 00003866 1566 CHEKRELBLK LABEL 03866 DC4038B6 1567 CALLNP RELBLKCHEK check the relative block number 1568 * \ / 1569 03867 603238B1 0 1 @ 1570 LD R0 @TYPETAB(R1) get word indicating what to check for 03868 60D24000 3 1 REG 1571 LD R3 R1 need FBI type in R3 03869 F63A386F 0 1572 JBT R0/ACCTBIT ACCTIN what to do about the account name 0386A DC003907 1573 CALL FBI2FLDCHEK check for no account name 0386B 41440015 IMM 1574 PARV ECFBINBAN error code 0386C 434048D6 1575 PARV2 EMPTY2 nothing there 0386D 40168805 2 BASE 1576 PARL R2,FBIACCT what to check 0386E FE0E3873 1577 JMP CHEKPROJ continue on 1578 * --- 1579 0000386F 1580 ACCTIN LABEL 0386F DC003907 1581 CALL FBI2FLDCHEK check for account name 03870 41440009 IMM 1582 PARV ECFBIACCT error code 03871 43404872 1583 PARV2 READACCT check against this 03872 40168805 2 BASE 1584 PARL R2,FBIACCT what to check 1585 * \ / 1586 00003873 1587 CHEKPROJ LABEL 03873 603238B1 0 1 @ 1588 LD R0 @TYPETAB(R1) get word indicating what to check for 03874 F63C387A 0 1589 JBT R0/PROJBIT PROJIN what to do about the project name 03875 DC0038F4 1590 CALL FBIFLDCHEK check for no project 03876 41440016 IMM 1591 PARV ECFBINBPJ error code 03877 414048D7 1592 PARV EMPTY should be nothing there 03878 40168807 2 BASE 1593 PARL R2,FBIPROJ what to check 03879 FE0E387E 1594 JMP CHEKFSN continue on 1595 * --- 1596 0000387A 1597 PROJIN LABEL 0387A DC0038F4 1598 CALL FBIFLDCHEK check for project 0387B 41440017 IMM 1599 PARV ECFBIPROJ error code 0387C 41404874 1600 PARV READPROJ what should be there 0387D 40168807 2 BASE 1601 PARL R2,FBIPROJ what to check 1602 * \ / 1603 0000387E 1604 CHEKFSN LABEL 0387E 603238B1 0 1 @ 1605 LD R0 @TYPETAB(R1) get word indicating what to check for 0387F 60D24000 3 1 REG 1606 LD R3 R1 need FBI type in R3 03880 F23E3889 0 1607 JBF R0/FSNBIT NOFSN jump if FSN should be empty 03881 F2363884 0 1608 JBF R0/ASNBIT HAVESN jump if don't need to get ASN 1609 03882 62004866 01 1610 LD2 R0 READASN 03883 E6004868 01 1611 ST2 R0 READSERIAL put account serial # here 1612 * \ / 1613 00003884 1614 HAVESN LABEL 03884 DC003907 1615 CALL FBI2FLDCHEK check for no file serial number 03885 4144000A IMM 1616 PARV ECFBIFSN error code "FSN/ASN wrong" 03886 43404868 1617 PARV2 READSERIAL what to check for 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 113 (DTTREAD) F 18 Page Input 03887 40168808 2 BASE 1618 PARL R2,FBISERNO what to check 03888 FE0E388D 1619 JMP READOK continue on 1620 * --- 1621 00003889 1622 NOFSN LABEL 03889 DC003907 1623 CALL FBI2FLDCHEK check for file serial number 0388A 41440018 IMM 1624 PARV ECFBINBFS error code 0388B 434048D6 1625 PARV2 EMPTY2 what to check for 0388C 40168808 2 BASE 1626 PARL R2,FBISERNO what to check 1627 * \ / 1628 0000388D 1629 READOK LABEL 0388D 19C40001 7 IMM 1630 ADD R7 1 0000388E 1631 ERROREXIT LABEL 0388E 62D78804 346 BASE 1632 LD2 R3 SP,PAGEINR34 restore R3,R4 0388F 5D1F8007 6 STAK 1633 LEAVE POP 1634 * --- 1635 00003890 1636 PASTVOLEND LABEL 03890 6004000C 0 IMM 1637 LD R0 ECDA code for beyond volume end 1638 00003891 1639 READERROR LABEL R0 has error code 03891 E4178806 0 6 BASE 1640 ST R0 SP,PAGEERROR 03892 DC003A64 1641 CALL RPTERROR tell the world about the error 03893 41574806 5 BASE 1642 PARV R5,PAGEERROR the error code 03894 41404864 1643 PARV CURBLK the block number 03895 40574801 5 BASE 1644 PARVL R5,FBITYPEX the block type 1645 * \ / 03896 60178806 0 6 BASE 1646 LD R0 SP,PAGEERROR get the errorcode again 03897 64040008 0 IMM 1647 CPR R0 8 was it wrong FBI type 03898 FE0C388E 1648 JNE ERROREXIT just leave 1649 * \ / 03899 60978803 2 6 BASE 1650 LD R2 SP,FBIADR get pointer to FBI 0389A 60888080 2 2 ZBM 1651 LD R2 R2,FBITYPE and extract the FBI type 0389B 60443A07 1 IMM 1652 LD R1 ADR FREEMESS R1 -> free block message 0389C 6444007F 1 IMM 1653 CPR R1 FBITFREE see if it is a free block 0389D FE0238A2 1654 JEQ SENDMESS if so then just send message 1655 * \ / 0389E DC00348B 1656 CALL FINDTEXTZ find the type message 0389F 41528000 2 REG 1657 PARV R2 FBI type 038A0 400039B8 1658 PARL FBITYPETAB what table to look in 038A1 60520000 1 0 REG 1659 LD R1 R0 R1 -> message 1660 * \ / 1661 000038A2 1662 SENDMESS LABEL 038A2 DC1013F9 @ 1663 CALL @VPREPOUT report the wrong type 038A3 41164400 1 @R 1664 PAR @R1 pointer to FBI type message 038A4 400038A6 1665 PARL WRONGMES our message prototype 038A5 FE0E388E 1666 JMP ERROREXIT then leave 1667 * --- 1668 038A6 2020466F 1669 WRONGMES TEXTZ " Found \C1\ block." 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 114 (DTTREAD) F 18 Page Input 1671 1672 ********************************************************************************** 1673 * * 1674 * The following tables and definitions are used to * 1675 * determine what to check for in each field of the FBI. * 1676 * TYPETABLE is indexed by FBITYPE and has bits set in each * 1677 * word to indicate whether a field should be empty. * 1678 * * 1679 ********************************************************************************** 1680 00003010 BYTE 1681 FLINKBIT EQU BIT 24 forward link 1682 * EQU BIT 25 (was flags, now always checked) 00003410 BYTE 1683 BLINKBIT EQU BIT 26 backward link 00003610 BYTE 1684 ASNBIT EQU BIT 27 account serial number 1685 * EQU BIT 28 (was create date) 00003A10 BYTE 1686 ACCTBIT EQU BIT 29 account name 00003C10 BYTE 1687 PROJBIT EQU BIT 30 project name 00003E10 BYTE 1688 FSNBIT EQU BIT 31 file serial number 1689 00000080 ABS 1690 FLNKB EQU 1*FLINKBIT 00000020 ABS 1691 BLNKB EQU 1*BLINKBIT 00000004 ABS 1692 ACTB EQU 1*ACCTBIT 00000002 ABS 1693 PRJB EQU 1*PROJBIT 00000010 ABS 1694 ASNB EQU 1*ASNBIT 00000001 ABS 1695 FSNB EQU 1*FSNBIT 1696 038AA 00000000 1697 TYPETABLE VFDB 8:0 038AA 00000000 1698 VFDB 8:0 1 - pack label 038AA 00000000 1699 VFDB 8:0 2 - bad trax block 038AB 00000000 1700 VFDB 8:0 3 - bootstrap code 038AB 00000000 1701 VFDB 8:0 4 - volume label 038AB 00000000 1702 VFDB 8:0 5 - substitution list 038AB 00000000 1703 VFDB 8:0 6 - security block 038AC 000000A0 1704 VFDB 8:FLNKB+BLNKB 7 - ADT block 038AC 00000000 1705 VFDB 8:0 8 - IDX block 038AC 00000017 1706 VFDB 8:ACTB+PRJB+ASNB+FSNB 9 - UDIR primary block 038AC 00000017 1707 VFDB 8:ACTB+PRJB+ASNB+FSNB A - UDIR secondary block 038AD 00000000 1708 VFDB 8:0 B - system use misc 038AD 000000A7 1709 VFDB 8:FLNKB+BLNKB+ACTB+PRJB+FSNB C - SAF 038AD 00000007 1710 VFDB 8:ACTB+PRJB+FSNB D - RAF major block 038AD 00000007 1711 VFDB 8:ACTB+PRJB+FSNB E - RAF minor block 038AE 00000007 1712 VFDB 8:ACTB+PRJB+FSNB F - RAF data block 038AE 00000000 1713 VFDB 8:0 10 - AFT 038AE 00000017 1714 VFDB 8:ACTB+PRJB+ASNB+FSNB 11 - account shared list block 038AE 00000007 1715 VFDB 8:ACTB+PRJB+FSNB 12 - file shared list block 038AF 00000007 1716 VFDB 8:ACTB+PRJB+FSNB 13 - code control block 038AF 00000007 1717 VFDB 8:ACTB+PRJB+FSNB 14 - code block 038AF 00000017 1718 VFDB 8:ACTB+PRJB+ASNB+FSNB 15 - authorization list block 038B1 020C38AB 1719 TYPETAB PTR TYPETABLE 1720 1721 ********************************************************************************** 1722 * * 1723 * This table contains the FBI flag values depending on * 1724 * the type of block (FBI type) we are checking. * 1725 * The 002 bit indicates that a write check should be * 1726 * done. This is not yet implemented in the system due to * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 115 (DTTREAD) F 18 Page Input 1727 * the difficulties involved in preventing alterations before * 1728 * the write check can be done. * 1729 * The 001 bit indicates that substitutions are prohibited. * 1730 * * 1731 ********************************************************************************** 038B1 00000000 1732 FBIFLAGVAL VFDB 3:0 038B1 00000003 1733 VFDB 3:3,3,3,3,3 pack, bad tracks, boot, volume, substitution 038B1 00000003 1734 VFDB 3:3 security block 038B2 00000000 1735 VFDB 3:0,0,0,0,0,0,0,0 038B3 00000000 1736 VFDB 3:0,0,0,0,0,0,0 and the rest 038B5 00C838B2 1737 FBIFLAGPTR PTR FBIFLAGVAL 1738 1739 END PAGEIN 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 116 (DTTREAD) F 18 Page Input 1741 1742 ********************************************************************************** 1743 * * 1744 * RELBKLCHEK checks the relative block number in FBIs. * 1745 * The procedure for checking a RAF data block or code data * 1746 * block is to use the relative block number found in the FBI * 1747 * as an index into the minor access block (or code control * 1748 * block). Then compare the block number found there against * 1749 * the block number of the read in block. * 1750 * Call: * 1751 * R1 = FBI type * 1752 * R2 -> FBI * 1753 * CALLNP RELBLKCHEK * 1754 * * 1755 * Eats R0,R3,R4 * 1756 * * 1757 ********************************************************************************** 1758 1759 RELBLKCHEK BLOCK 1760 1761 ENTRY RELBLKCHEK 1762 1763 BEGFRAME 00178801 6 BASE 1764 RELBLKR12 BSS2 1 save R1, R2 1765 ENDFRAME 1766 0008ACA4 2 ZBM 1767 FBIMINBITS EQU FBIWORDE/BITS 22:31 minor access relative block number 000898A4 2 ZBM 1768 FBIMAJBITS EQU FBIWORDE/BITS 12:21 major access relative block number 1769 038B6 DD5F8003 6 STAK 1770 RELBLKCHEK ENTRNP PUSH 038B7 64440014 1 IMM 1771 CPR R1 FBITCODED is it a code data block? 038B8 FE0238C0 1772 JEQ RAFCHECK if so, treat it like a RAF data block 038B9 6444000F 1 IMM 1773 CPR R1 FBITRAFD is it a RAF data block? 038BA FE0238C0 1774 JEQ RAFCHECK these get checked special 1775 * \ / 1776 038BB DC0038F4 1777 CALL FBIFLDCHEK go check the relative block number 038BC 41440014 IMM 1778 PARV ECFBIRBN error code 038BD 41404861 1779 PARV RELBLOCK what it should be 038BE 40089184 2 ZBM 1780 PARL R2,FBIRELBLK relative block 000038BF 1781 RELBLKEND LABEL 038BF 5D1F8003 6 STAK 1782 LEAVE POP 1783 * --- 1784 000038C0 1785 RAFCHECK LABEL 038C0 6008ACA4 0 2 ZBM 1786 LD R0 R2,FBIMINBITS the relative block number 038C1 60209C00 0 0 1787 LD R0 RDMINLOC(R0) get block number of associated block 038C2 780048C9 0 1788 AND R0 MSMASK just want the block number 038C3 64004864 0 1789 CPR R0 CURBLK see if we have the correct block 038C4 FE0C38C8 1790 JNE BADRELNUM if not then fix it 038C5 600898A4 0 2 ZBM 1791 LD R0 R2,FBIMAJBITS get the major access bits 038C6 64004861 0 1792 CPR R0 RELBLOCK the relative block number of our minor 038C7 FE0238BF 1793 JEQ RELBLKEND if all matches then go home 1794 * \ / 1795 000038C8 1796 BADRELNUM LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 117 (DTTREAD) F 18 Page Input 038C8 E6578801 126 BASE 1797 ST2 R1 SP,RELBLKR12 save R1,R2 038C9 DC003A64 1798 CALL RPTERROR tell about the bad relative block number 038CA 41440014 IMM 1799 PARV ECFBIRBN error code 038CB 41404864 1800 PARV CURBLK block number 038CC 40524000 1 REG 1801 PARVL R1 FBI type 1802 038CD 600403FF 0 IMM 1803 LD R0 WPP-1 index into RDMINLOC 000038CE 1804 FINDLOOP LABEL 038CE 60609C00 1 0 1805 LD R1 RDMINLOC(R0) get the entry 038CF 784048C9 1 1806 AND R1 MSMASK clear off extra crud 038D0 64404864 1 1807 CPR R1 CURBLK see if this is the block 038D1 FE0238D4 1808 JEQ FOUNDIT 038D2 FA2638CE 0 1809 JDR R0 FINDLOOP if not then try the next place 1810 * \ / 1811 * should not ever fall through. What to do here if it does? 038D3 FE0E38BF 1812 JMP RELBLKEND 1813 * --- 1814 000038D4 1815 FOUNDIT LABEL 038D4 62578801 126 BASE 1816 LD2 R1 SP,RELBLKR12 get these registers back 038D5 E408ACA4 0 2 ZBM 1817 ST R0 R2,FBIMINBITS put the correct relative block # in FBI 038D6 60004861 0 1818 LD R0 RELBLOCK get the minor access block index 038D7 E40898A4 0 2 ZBM 1819 ST R0 R2,FBIMAJBITS make sure the major bits are correct 038D8 FE0E38BF 1820 JMP RELBLKEND 1821 * --- 1822 1823 END RELBLKCHEK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 118 (DTTREAD) F 18 Page Input 1825 1826 ********************************************************************************** 1827 * * 1828 * CDCHEK checks the creation date in the FBI for a valid * 1829 * date. The comparison is between Jan 1, 1980 0:00 and the * 1830 * start up time of this program. * 1831 * Call: * 1832 * LD R2 ADR * 1833 * CALLNP CDCHEK * 1834 * * 1835 * Leaves R2 => FBI * 1836 * Restores R1 * 1837 * Eats R0,R3:R4 * 1838 * * 1839 ********************************************************************************** 1840 1841 CDCHEK BLOCK 1842 1843 ENTRY CDCHEK 1844 1845 BEGFRAME 00178801 6 BASE 1846 CDCHEKR1 BSS 1 00178802 6 BASE 1847 CDCHEKR2 BSS 1 1848 ENDFRAME 1849 038D9 DD5F8003 6 STAK 1850 CDCHEK ENTRNP PUSH 038DA E4578801 1 6 BASE 1851 ST R1 SP,CDCHEKR1 save R1 1852 038DB 60168803 0 2 BASE 1853 LD R0 R2,FBILCD get the last changed date from FBI 038DC 5C120000 0 REG 1854 CMZ R0 has the block been changed? 038DD FE0238E6 1855 JEQ CDZERO see if valid to be blank 038DE 640048D5 0 1856 CPR R0 OLDDATE is it newer than oldest possible date? 038DF 60440012 1 IMM 1857 LD R1 ECFBIODAT error code for date too old 038E0 FE0838EA 1858 JLT CDERR 038E1 641048CA 0 @ 1859 CPR R0 @CURDATE is it a date in the future? 038E2 60440013 1 IMM 1860 LD R1 ECFBIFDAT error code for future date 038E3 FE0438EA 1861 JGT CDERR jump if illegal 1862 * \ / 1863 000038E4 1864 CDEXIT LABEL 038E4 60578801 1 6 BASE 1865 LD R1 SP,CDCHEKR1 restore R1 038E5 5D1F8003 6 STAK 1866 LEAVE POP 1867 * --- 1868 000038E6 1869 CDZERO LABEL 038E6 60178801 0 6 BASE 1870 LD R0 SP,CDCHEKR1 get FBI type 038E7 64040004 0 IMM 1871 CPR R0 FBITVL see if it is volume or less 038E8 FE0A38E4 1872 JLE CDEXIT if so then ok so leave 038E9 60440019 1 IMM 1873 LD R1 ECFBIBDAT get the error code 1874 * \ / 1875 000038EA 1876 CDERR LABEL 038EA E4978802 2 6 BASE 1877 ST R2 SP,CDCHEKR2 save R2 038EB 61138000 4 6 REG 1878 LD R4 SP 038EC DC003A64 1879 CALL RPTERROR tell about the problem 038ED 41524000 1 REG 1880 PARV R1 error code 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 119 (DTTREAD) F 18 Page Input 038EE 41404864 1881 PARV CURBLK block number 038EF 40570801 4 BASE 1882 PARVL R4,CDCHEKR1 FBI type 038F0 60978802 2 6 BASE 1883 LD R2 SP,CDCHEKR2 restore R2 1884 * \ / 038F1 601048CA 0 @ 1885 LD R0 @CURDATE get the current date 038F2 E4168803 0 2 BASE 1886 ST R0 R2,FBILCD put it in as last change date 038F3 FE0E38E4 1887 JMP CDEXIT 1888 * --- 1889 1890 END CDCHEK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 120 (DTTREAD) F 18 Page Input 1892 1893 ********************************************************************************** 1894 * * 1895 * FBIFLDCHEK checks the FBI location passed to it to * 1896 * verify that it matches the value passed. If not an error * 1897 * message is printed and the problem is fixed. * 1898 * Call: * 1899 * R1 = FBI type * 1900 * R2 => FBI * 1901 * CALL FBIFLDCHEK * 1902 * PARV * 1903 * PARV * 1904 * PARL * 1905 * * 1906 * Leaves R2 => FBI * 1907 * Restores R1 * 1908 * Eats R0,R3:R4 * 1909 * * 1910 ********************************************************************************** 1911 1912 FBIFLDCHEK BLOCK 1913 1914 ENTRY FBIFLDCHEK 1915 1916 BEGFRAME 00178801 6 BASE 1917 FLDCHKR1 BSS 1 00178802 6 BASE 1918 FLDCHKR2 BSS 1 00178803 6 BASE 1919 ERRCODE BSS 1 00178804 6 BASE 1920 VALUE BSS 1 00178805 6 BASE 1921 FBILOC BSS 1 1922 ENDFRAME 1923 038F4 DD1F8006 6 STAK 1924 FBIFLDCHEK ENTR PUSH 038F5 C1578803 6 BASE 1925 STPV SP,ERRCODE 038F6 C1578804 6 BASE 1926 STPV SP,VALUE correct value 038F7 C0178805 6 BASE 1927 STPL SP,FBILOC address of FBI location to check 038F8 E4578801 1 6 BASE 1928 ST R1 SP,FLDCHKR1 save R1 038F9 60178C05 0 6 FPVR 1929 LD R0 @(SP,FBILOC) get FBI value to compare 038FA 64178804 0 6 BASE 1930 CPR R0 SP,VALUE is it correct? 038FB FE023905 1931 JEQ FLDCHKEND if so then done 1932 * \ / 1933 038FC E4978802 2 6 BASE 1934 ST R2 SP,FLDCHKR2 save FBI pointer 038FD 61138000 4 6 REG 1935 LD R4 SP 038FE DC003A64 1936 CALL RPTERROR report the error 038FF 41570803 4 BASE 1937 PARV R4,ERRCODE error code 03900 41404864 1938 PARV CURBLK block number 03901 40570801 4 BASE 1939 PARVL R4,FLDCHKR1 FBI type 03902 60978802 2 6 BASE 1940 LD R2 SP,FLDCHKR2 restore FBI pointer 1941 03903 60178804 0 6 BASE 1942 LD R0 SP,VALUE get the correct value 03904 E4178C05 0 6 FPVR 1943 ST R0 @(SP,FBILOC) and put it where it belongs 1944 * \ / 1945 00003905 1946 FLDCHKEND LABEL 03905 60578801 1 6 BASE 1947 LD R1 SP,FLDCHKR1 restore R1 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 121 (DTTREAD) F 18 Page Input 03906 5D1F8006 6 STAK 1948 LEAVE POP 1949 * --- 1950 1951 END FBIFLDCHEK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 122 (DTTREAD) F 18 Page Input 1953 1954 ********************************************************************************** 1955 * * 1956 * FBI2FLDCHEK checks the FBI location passed to it to * 1957 * verify that it matches the value passed. If not an error * 1958 * message is printed and the problem is fixed. * 1959 * Call: * 1960 * R3 = FBI type * 1961 * R2 => FBI * 1962 * CALL FBI2FLDCHEK * 1963 * PARV * 1964 * PARV2 * 1965 * PARL R2, * 1966 * * 1967 * Leaves R2 => FBI * 1968 * Leaves FBI type in R1 * 1969 * Eats R0,R3:R4 * 1970 * * 1971 ********************************************************************************** 1972 1973 FBI2FLDCHEK BLOCK 1974 1975 ENTRY FBI2FLDCHEK 1976 1977 BEGFRAME 00178801 6 BASE 1978 FLD2CHKR3 BSS 1 00178802 6 BASE 1979 FLD2CHKR2 BSS 1 00178803 6 BASE 1980 ERRCODE BSS 1 00178804 6 BASE 1981 VALUE BSS2 1 00178806 6 BASE 1982 FBILOC BSS 1 1983 ENDFRAME 1984 03907 DD1F8007 6 STAK 1985 FBI2FLDCHEK ENTR PUSH 03908 C1578803 6 BASE 1986 STPV SP,ERRCODE 03909 C3578804 6 BASE 1987 STPV2 SP,VALUE correct value 0390A C0178806 6 BASE 1988 STPL SP,FBILOC address of FBI location to check 0390B E4D78801 3 6 BASE 1989 ST R3 SP,FLD2CHKR3 save R3 0390C 62178C06 016 FPVR 1990 LD2 R0 @(SP,FBILOC) get FBI value to compare 0390D 66178804 016 BASE 1991 CPR2 R0 SP,VALUE is it correct? 0390E FE023918 1992 JEQ FLD2CHKEND if so then done 1993 * \ / 1994 0390F E4978802 2 6 BASE 1995 ST R2 SP,FLD2CHKR2 save FBI pointer 03910 61138000 4 6 REG 1996 LD R4 SP 03911 DC003A64 1997 CALL RPTERROR report the error 03912 41570803 4 BASE 1998 PARV R4,ERRCODE error code 03913 41404864 1999 PARV CURBLK block number 03914 40570801 4 BASE 2000 PARVL R4,FLD2CHKR3 FBI type 03915 60978802 2 6 BASE 2001 LD R2 SP,FLD2CHKR2 restore FBI pointer 2002 03916 62178804 016 BASE 2003 LD2 R0 SP,VALUE get the correct value 03917 E6178C06 016 FPVR 2004 ST2 R0 @(SP,FBILOC) and put it where it belongs 2005 * \ / 2006 00003918 2007 FLD2CHKEND LABEL 03918 60578801 1 6 BASE 2008 LD R1 SP,FLD2CHKR3 put FBI type in R1 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 123 (DTTREAD) F 18 Page Input 03919 5D1F8007 6 STAK 2009 LEAVE POP 2010 * --- 2011 2012 END FBI2FLDCHEK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 124 (DTTREAD) F 18 Report Input Error 2015 2016 ********************************************************************************** 2017 * * 2018 * RPTERROR will report an I/O error encountered by * 2019 * READINDISK. * 2020 * Call: * 2021 * CALL RPTERROR * 2022 * PARV errorcode - see ERRCODETAB below * 2023 * PARV diskaddr - disk block number * 2024 * PARVL fbitype - type of disk block * 2025 * * 2026 * Eats R0:R4. * 2027 * * 2028 ********************************************************************************** 2029 2030 RPTERROR BLOCK 2031 ENTRY RPTERROR 2032 ENTRY FBITYPETAB 2033 ENTRY FREEMESS 2034 2035 BEGFRAME 00178801 6 BASE 2036 BLOCKNUM BSS 1 disk block number 00178802 6 BASE 2037 FBITYPEX BSS 1 fbi type expected 2038 ENDFRAME 2039 2040 * Following is the list of error message codes: 0000391A 2041 ERRCODETAB BSS2 0 0391A 636F6465 2042 TEXTZ "code 0" 0 - should never happen 0391C 64617461 2043 TEXTZ "data error" 1 - data error (from @READ) 0391F 46424920 2044 TEXTZ "FBI checksum or address" 2 - fbi checksum error 03925 6368616E 2045 TEXTZ "channel error" 3 - channel error (from @READ) 03929 7365656B 2046 TEXTZ "seek error" 4 - seek error (from @READ) 0392C 6469736B 2047 TEXTZ "disk not ready" 5 - not ready 03930 6469736B 2048 TEXTZ "disk write protected" 6 - write protected unit 03936 6D656D6F 2049 TEXTZ "memory parity error on write" 7 - channel found MPE 0393E 46424920 2050 TEXTZ "FBI type wrong" 8 - fbi type field is bad 03942 46424920 2051 TEXTZ "FBI account wrong" 9 - wrong account in fbi 03947 46424920 2052 TEXTZ "FBI FSN/ASN wrong" 10 - wrong fsn 0394C 46424920 2053 TEXTZ "FBI backward link wrong" 11 - wrong bLink (SAF) 03952 426C6F63 2054 TEXTZ "Block beyond volume end" 12 - bogus disk address 03958 426C6F63 2055 TEXTZ "Block reuse" 13 - block used twice 0395B 466F7277 2056 TEXTZ "Forward link non-zero" 14 - fLink not empty 03961 46424920 2057 TEXTZ "FBI WORDB flags set" 15 - FBI flags non-zero 03966 4E6F2D53 2058 TEXTZ "No-Sub flag not set" 16 - Expected a no-Sub block 0396B 4261636B 2059 TEXTZ "Backward link non-zero" 17 - bLink not empty 03971 4368616E 2060 TEXTZ "Change date to old" 18 - before 1980 03976 4368616E 2061 TEXTZ "Change date not reached yet" 19 - in the future 0397D 52656C61 2062 TEXTZ "Relative block number bad" 20 - 03984 46424920 2063 TEXTZ "FBI Account name is non-blank" 21 - garbage in acct name 0398C 46424920 2064 TEXTZ "FBI Project name is non-blank" 22 - garbage in proj name 03994 46424920 2065 TEXTZ "FBI project wrong" 23 - incorrect proj 03999 46424920 2066 TEXTZ "FBI file serial # is non-zero" 24 039A1 46424920 2067 TEXTZ "FBI change date unset" 25 - blank FBI LCD field 039A7 55444952 2068 TEXTZ "UDIR entries out of order" 26 - non-ascending order 039AE 426F6775 2069 TEXTZ "Bogus entry in substitution list" 27 - read it 039B7 00000000 2070 VFD 0 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 125 (DTTREAD) F 18 Report Input Error 2071 2072 * Following is the list of fbi types: 000039B8 2073 FBITYPETAB BSS2 0 039B8 756E6B6E 2074 TEXTZ "unknown type" 00 - should never happen 039BC 7061636B 2075 TEXTZ "pack label" 01 - pack label 039BF 62616420 2076 TEXTZ "bad tracks" 02 - bad tracks block 039C2 626F6F74 2077 TEXTZ "bootstrap" 03 - bootstrap block 039C5 766F6C75 2078 TEXTZ "volume label" 04 - volume label 039C9 73756273 2079 TEXTZ "substitution" 05 - substitution block 039CD 73656375 2080 TEXTZ "security" 06 - security block 039D0 41445400 2081 TEXTZ "ADT" 07 - available disk table block 039D1 49445800 2082 TEXTZ "IDX" 08 - IDX block 039D2 55444952 2083 TEXTZ "UDIR1" 09 - primary user directory block 039D4 55444952 2084 TEXTZ "UDIR2" 0A - secondary user directory block 039D6 73776170 2085 TEXTZ "swapping" 0B - miscellaneous system block 039D9 53414620 2086 TEXTZ "SAF data" 0C - SAF data block 039DC 52414620 2087 TEXTZ "RAF major access" 0D - RAF major access block 039E1 52414620 2088 TEXTZ "RAF minor access" 0E - RAF minor access block 039E6 52414620 2089 TEXTZ "RAF data" 0F - RAF data block 039E9 41465400 2090 TEXTZ "AFT" 10 - account finder table 039EA 6163636F 2091 TEXTZ "account share list" 11 - account share list block 039EF 66696C65 2092 TEXTZ "file share list" 12 - file share list block 039F3 636F6465 2093 TEXTZ "code control" 13 - code file code control block 039F7 636F6465 2094 TEXTZ "code data" 14 - code file data block 039FA 61757468 2095 TEXTZ "authorization list" 15 - authorization list block 039FF 61206261 2096 TEXTZ "a bad block" 16 - for blocks from bad list 03A02 756E6B6E 2097 TEXTZ "unknown type" 17 & up 03A06 00000000 2098 VFD 0 marks table end 2099 03A07 41206672 2100 FREEMESS TEXTZ "A free block" 2101 2102 * The following table is indexed by the fbi type and gives 2103 * a pointer to the prototype of the appropriate message. 00003A0B 2104 MESSAGETAB BSS 0 03A0E 00000000 2105 VFD 0,0,0,0 00-03 03A12 00000000 2106 VFD 0,0,0,0 04-07 03A16 00000000 2107 VFD 0,1,1,0 08-0B 03A1A 00000002 2108 VFD 3,2,2,2 0C-0F 03A1E 00000002 2109 VFD 0,1,2,2 10-13 03A21 00000000 2110 VFD 2,1,0 14-16 00000017 ABS 2111 FBITYPEMAX EQU DISPW MESSAGETAB 2112 2113 * Following are the message prototypes. 00003A22 2114 MESSAGES LABEL 03A22 20074572 2115 TEXTZ " Error: \C1\ on \C3\, block #\H2,6\." 03A2C 20074572 2116 TEXT " Error: \C1\ on \C3\, block #\H2,6\." 03A36 4163636F 2117 TEXTZ "Account: \S4\.\R5\" 03A3B 20074572 2118 TEXT " Error: \C1\ on \C3\, block #\H2,6\." 03A45 46696C65 2119 TEXTZ "File: \S4\.\R5\:\S6\.\R7\" 03A4C 20074572 2120 TEXT " Error: \C1\ on \C3\, block #\H2,6\." 03A56 46696C65 2121 TEXTZ "File: \S4\.\R5\:\S6\.\R7\. Previous block #\H8,6\." 2122 2123 03A64 DD1F8003 6 STAK 2124 RPTERROR ENTR PUSH 03A65 C1404865 2125 STPV ERRORCODE 03A66 C1578801 6 BASE 2126 STPV SP,BLOCKNUM 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 126 (DTTREAD) F 18 Report Input Error 03A67 C0578802 6 BASE 2127 STPVL SP,FBITYPEX FBI type code 2128 03A68 DC00348B 2129 CALL FINDTEXTZ translate the error code 03A69 41404865 2130 PARV ERRORCODE index into message table 03A6A 4000391A 2131 PARL ERRCODETAB the message table 03A6B E4004865 0 2132 ST R0 ERRORCODE ERRORCODE -> ascii string 2133 2134 * Check for free block (type 7F) and other illegal types 03A6C 60178802 0 6 BASE 2135 LD R0 SP,FBITYPEX get type code under investigation 03A6D 6404007F 0 IMM 2136 CPR R0 FBITFREE check for free block 03A6E FE0C3A73 2137 JNE NOTFREE jump if not 03A6F 60043A07 0 IMM 2138 LD R0 ADR FREEMESS get address of appropriate text 03A70 E4178802 0 6 BASE 2139 ST R0 SP,FBITYPEX and save pointer 03A71 60040001 0 IMM 2140 LD R0 1 get 'type' of appropriate message 03A72 FE0E3A78 2141 JMP FERM and go process 2142 * --- 2143 00003A73 2144 NOTFREE LABEL 03A73 50040017 0 IMM 2145 MIN R0 FBITYPEMAX convert all illegal to same 03A74 DC00348B 2146 CALL FINDTEXTZ translate the FBI type 03A75 41520000 0 REG 2147 PARV R0 pass manipulated FBI type 03A76 400039B8 2148 PARL FBITYPETAB search this table 03A77 E0178802 0 6 BASE 2149 EXCH R0 SP,FBITYPEX FBITYPEX -> ascii string, R0 = fbi type 2150 00003A78 2151 FERM LABEL 03A78 DC00348B 2152 CALL FINDTEXTZ get pointer to right error message 03A79 41603A0B 0 2153 PARV MESSAGETAB(R0) index of right message 03A7A 40003A22 2154 PARL MESSAGES table with the message 03A7B 60520000 1 0 REG 2155 LD R1 R0 R1 -> message text 2156 03A7C 61138000 4 6 REG 2157 LD R4 SP 03A7D DC1013F9 @ 2158 CALL @VPREPOUT print the message 03A7E 41104865 @ 2159 PAR @ERRORCODE error code (ascii string) 03A7F 41170801 4 BASE 2160 PAR R4,BLOCKNUM disk block number 03A80 41170C02 4 FPVR 2161 PAR @(R4,FBITYPEX) fbi type (ascii string) 03A81 41004872 2162 PAR READACCT account number 03A82 41004874 2163 PAR READPROJ division/project 03A83 41004877 2164 PAR READNAME file name 03A84 41004879 2165 PAR READEXT file extension 03A85 4100486A 2166 PAR PREVBLOCK previous block 03A86 40164400 1 @R 2167 PARL @R1 message prototype 2168 03A87 5D1F8003 6 STAK 2169 LEAVE POP 2170 * --- 2171 2172 END RPTERROR 2173 2174 END READDISK of disk reading process 1643 INPUT DISKTOTAPE.OPSYS:DTTPACK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 127 (DTTPACK) F 20 Physical Record Packing Process 3 4 PHYSRECPCK BLOCK physical record packing process 5 6 ENTRY PACKSTART 7 ENTRY PACKINIT 8 ENTRY PACKLOGREC 9 10 ********************************************************************************** 11 * * 12 * The physical record packing process picks up MCBs and * 13 * FDEs from the physical record packing queue (PRPQ) and * 14 * packs them into physical records that then get sent to the * 15 * encrypt queue. The overall algorithm for this is rather * 16 * simple: * 17 * Get an entry from the PRPQ and process according to * 18 * the type of block (or FDE). * 19 * However, to keep compatibility with BACKUP, lots of * 20 * other crap must be taken into consideration including * 21 * encryption format, headers, tapestrings, file page packing * 22 * formats, etc. So deciding what to do with any given PRPQ * 23 * entry is not as straight forward as one might hope. Also * 24 * some PRPQ entries should appear at fixed places so we pick * 25 * these up directly. * 26 * * 27 ********************************************************************************** 28 29 ********************************************************************************** 30 * * 31 * This is where the pack process is set up. Pages are * 32 * mapped in, registers restored, then off to where we were * 33 * suspended. * 34 * * 35 ********************************************************************************** 36 00003A88 37 PACKSTART LABEL 03A88 6047FFF2 1 IMM 38 LD R1 -PACKPMVTABL number of page map values to load 03A89 60C400A3 3 IMM 39 LD PFPTR PROCPN starting page map location 00003A8A 40 LOADPMV LABEL 03A8A 6022493D 0 1 41 LD R0 PACKPMVTAB(PACKPMVTABL)(R1) get a page map value 03A8B FA023A8D 0 42 JEQZ R0 DONTMAP 03A8C 00D20000 0 REG 43 LDPF R0 load it 00003A8D 44 DONTMAP LABEL 03A8D 18C40001 3 IMM 45 ADD PFPTR 1 move to next page file location 03A8E FA603A8A 1 46 IRJ R1 LOADPMV load the next one 47 * \ / 48 03A8F 63804901 67 49 LD2 SP PACKSPR7 set up our stack and restore R7 03A90 63004903 45 50 LD2 R4 PACKR4R5 restore R4 and R5 03A91 5C804900 51 LDPC PACKPC off we go 52 * --- 53 54 00003A92 55 PACKINIT LABEL 03A92 6184497D 6 IMM 56 LD SP ADR PACKSTACK set stack pointer to point to our stack 03A93 D1404905 57 STMW PACKSEQNUM sequence numbers start at zero, but 58 * an INCL is used to obtain these 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 128 (DTTPACK) F 20 Physical Record Packing Process 03A94 EC004908 59 STZ CPRFORM no current physical record format 03A95 DC403A9A 60 CALLNP FILESETLR build save set logical record 03A96 FE0E3A98 61 JMP NOBOOTINFO skip packing boot info 03A97 DC403AD8 62 CALLNP PACKBOOT go pack boot information 00003A98 63 NOBOOTINFO LABEL 03A98 DC403B0B 64 CALLNP PACKVOL pack up the volume 03A99 FE0E318F 65 JMP DONEPACK all done here 66 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 129 (DTTPACK) F 20 Build a Fileset Logical Record 69 70 ********************************************************************************** 71 * * 72 * FILESETLR * 73 * * 74 * This subroutine builds a fileset logical record that * 75 * then gets sent to the tape write process via the encryption * 76 * process. This logical record gets put in its own physical * 77 * record and is not encrypted. * 78 * Note that this record is expected as the first record * 79 * by the tape write process. It picks it off of the stream * 80 * of records and holds it for use at the beginning and end * 81 * of tape (or track). * 82 * * 83 * Call: * 84 * CALLNP FILESETLR * 85 * JMP * 86 * * 87 * Eats R0:R5 * 88 * * 89 ********************************************************************************** 90 91 FILESETLR BLOCK 92 93 ENTRY FILESETLR 94 95 BEGFRAME 96 ENDFRAME 97 03A9A DD5F8001 6 STAK 98 FILESETLR ENTRNP PUSH 03A9B DC003D64 99 CALL PRELANDPAG get a PREL and page and start a physical record 03A9C 40009400 100 PARL PACKPRPAGE where to start the header 03A9D D1404905 101 STMW PACKSEQNUM set this for next physical record 03A9E 60040003 0 IMM 102 LD R0 ENCRNONE code for no encryption 03A9F E4094C20 0 5 ZBM 103 ST R0 R5,PRELENCRY set encryption code 104 03AA0 60040003 0 IMM 105 LD R0 ENCRNONE code for no encryption of this physical rec 03AA1 E4094C20 0 5 ZBM 106 ST R0 R5,PRELENCRY say not to encrypt this 03AA2 DC003CF7 107 CALL PACKLOGREC build logical record header 03AA3 40440000 IMM 108 PARVL RTYPESET code indicating save set header 109 03AA4 EE16C809 3 BASE 110 STZ2 R3,SSOWNER say this is a system backup 03AA5 EC16C802 3 BASE 111 STZ R3,SETTAPNUM clear parity errors from tape number loc 03AA6 60040006 0 IMM 112 LD R0 SSTAPEFN save set tape format number 03AA7 E408E101 0 3 ZBM 113 ST R0 R3,SAVSETFMT put it in the record 03AA8 60040001 0 IMM 114 LD R0 SSENCRFN encryption format number 03AA9 E408C101 0 3 ZBM 115 ST R0 R3,ENCTYP set the encryption type 03AAA 62004822 01 116 LD2 R0 STARTTIME get the time stamp 03AAB E616C803 013 BASE 117 ST2 R0 R3,SETTIMSTP put in the record 03AAC 6000483B 0 118 LD R0 PHYSRECSIZ get the size of our largest physical records 03AAD E416C806 0 3 BASE 119 ST R0 R3,PHYSRECSZ and set it in the header 03AAE EDD6C807 3 BASE 120 STW R3,WHODONE say offline DISKTOTAPE did this 03AAF 60004824 0 121 LD R0 SYSSN get the system's serial number 03AB0 E416C808 0 3 BASE 122 ST R0 R3,SSSSN put in the header 123 03AB1 3896C80B 2 3 BASE 124 LEA R2 R3,SAVESETFIL need to zero fill the filler 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 130 (DTTPACK) F 20 Build a Fileset Logical Record 03AB2 60440014 1 IMM 125 LD R1 CPW*SSFILLEN how much to fill 03AB3 FE580000 126 CFILL 00 all zeroes 127 03AB4 DC403D81 128 CALLNP GETNEXPRPQ get the volume name from the PRPQ 03AB5 60090040 0 4 ZBM 129 LD R0 R4,MCBTYPE get the type of element 03AB6 64040005 0 IMM 130 CPR R0 TVOLNAM see if it is what we expected 03AB7 FE0C3AD7 131 JNE WRONGTYPE death if incorrect 132 * \ / 133 134 * R4 -> PREL containing the volume name. Build the volume name tape string. 03AB8 38D6C810 3 3 BASE 135 LEA R3 R3,SAVSETNAME R3 -> start of save set tape string name 03AB9 62170801 014 BASE 136 LD2 R0 R4,PRELVOLNAM get the volume name 03ABA DC003DE7 137 CALL TSVOL start the tape string 03ABB 42540000 01 PAIR 138 PARV2L PAIR R0 the volume name 139 03ABC DC003E0B 140 CALL TSMOVE move the tape string into the buffer 03ABD 4040492B 141 PARVL ACCTINDEX number of chars to move 142 03ABE E1134000 4 5 REG 143 EXCH R4 R5 R5 -> PREL containing volume name 03ABF DC403471 144 CALLNP PRELRETURN don't need this PREL anylonger 03AC0 61530000 5 4 REG 145 LD R5 R4 R5 -> PREL for current physical record 146 03AC1 10C49400 3 IMM 147 SUB R3 ADR PACKPRPAGE get word count of this physical record 03AC2 E4C96101 3 5 ZBM 148 ST R3 R5,PRELPRLEN put physical record's length in PREL 03AC3 60849400 2 IMM 149 LD R2 ADR PACKPRPAGE R2 -> beginning of physical record 03AC4 EC088012 2 ZBM 150 STZ R2,PHSNCRYPTD this physical record is not encrypted 03AC5 38968807 2 2 BASE 151 LEA R2 R2,PHSLOGDATA R2 -> beginning of logical record 03AC6 10C40007 3 IMM 152 SUB R3 PHSHDRLEN subtract length of the physical record hdr 03AC7 E4C8A100 3 2 ZBM 153 ST R3 R2,LOGRECIFL set length field in logical record 154 155 * See if the next PRPQ entry is the no tapebootmake marker. 156 * If so then set flag indicating no boot info on this tape. 157 03AC8 38C09407 3 158 LEA R3 PACKPRPAGE/PHSLOGDATA R3 -> beginning of this logical record 03AC9 EC16C805 3 BASE 159 STZ R3,BOOTINFO assume no boot info here 03ACA DC403D81 160 CALLNP GETNEXPRPQ get next element from PRPQ 03ACB 60090040 0 4 ZBM 161 LD R0 R4,PRELTYPE get the type field 03ACC 64040003 0 IMM 162 CPR R0 TTBM is it a TBM marker? 03ACD FE0C3AD7 163 JNE WRONGTYPE if not then croak 03ACE 60170801 0 4 BASE 164 LD R0 R4,PRELTBM extract the type code 03ACF 64040000 0 IMM 165 CPR R0 TBMNONE is there TBM info? 03AD0 FE023AD3 166 JEQ ITSSET if not then we guessed right 03AD1 EDD6C805 3 BASE 167 STW R3,BOOTINFO else say boot info is here 03AD2 19C40001 7 IMM 168 ADD R7 1 advance the return 169 * \ / 170 00003AD3 171 ITSSET LABEL 03AD3 DC403DB1 172 CALLNP LINKINENCR and put this in the queue 03AD4 61530000 5 4 REG 173 LD R5 R4 get the tapeboot marker 03AD5 DC403DB1 174 CALLNP LINKINENCR and put this in the queue 03AD6 5D1F8001 6 STAK 175 LEAVE POP 176 * --- 177 00003AD7 178 WRONGTYPE LABEL 03AD7 00173210 179 HALT HALTW3210 first entry in PRPQ is not volume name 180 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 131 (DTTPACK) F 20 Build a Fileset Logical Record 181 182 END FILESETLR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 132 (DTTPACK) F 20 PACKBOOT -- Pack Bootmake Info 185 186 ********************************************************************************** 187 * * 188 * PACKBOOT -- Pack Bootmake Info * 189 * * 190 * This subroutine gets elements from the PRPQ and packs * 191 * them into records identical to those made by TAPEBOOTMAKE. * 192 * These records consist of one code data block with an * 193 * FBILNTH header. The header contains information used by * 194 * the encryptor/decryptor and the file name of which this * 195 * block belongs. The header is checksummed and the plaintext * 196 * code block is checksummed. Both of these checksums are * 197 * kept in the header. * 198 * This subroutine assumes all blocks in the PRPQ are to * 199 * be packed this way until it finds an end-of-tapebootmake * 200 * indicator in the PRPQ. * 201 * Call: * 202 * CALLNP PACKBOOT * 203 * * 204 * Eats R0:R5 * 205 * * 206 ********************************************************************************** 207 208 PACKBOOT BLOCK 209 210 ENTRY PACKBOOT 211 212 BEGFRAME 00178801 6 BASE 213 MCBPTR BSS 1 pointer to MCB 214 ENDFRAME 215 03AD8 DD5F8002 6 STAK 216 PACKBOOT ENTRNP PUSH 00003AD9 217 BOOTLOOP LABEL 03AD9 DC403D81 218 CALLNP GETNEXPRPQ get an entry from the PRPQ 03ADA 60090040 0 4 ZBM 219 LD R0 R4,MCBTYPE extract the type code 03ADB 64040003 0 IMM 220 CPR R0 TTBM see if it is end of tape boot make 03ADC FE023B07 221 JEQ BOOTDONE if so then finish up 222 * \ / 223 03ADD E5178801 4 6 BASE 224 ST R4 SP,MCBPTR save pointer to MCB 03ADE DC003D44 225 CALL GETPACKPAG get a free page 03ADF 404400A4 IMM 226 PARVL TBMPN1 where to put it 03AE0 DC403D54 227 CALLNP GTPACKPREL get a PREL to build the record with 03AE1 60040001 0 IMM 228 LD R0 ENCRTBM get tapebootmake encryption code 03AE2 E4094C20 0 5 ZBM 229 ST R0 R5,PRELENCRY and put it in the PREL 03AE3 6004040B 0 IMM 230 LD R0 TBMRECSIZ get the size of this record 03AE4 E4096101 0 5 ZBM 231 ST R0 R5,PRELPRLEN put in the PREL 232 03AE5 E5174803 4 5 BASE 233 ST R4 R5,PRELMCBPTR put in our first page pointer 03AE6 60978801 2 6 BASE 234 LD R2 SP,MCBPTR get our other page pointer 03AE7 E4974804 2 5 BASE 235 ST R2 R5,PRELMCBPTR(1) put in the other pointer 03AE8 60440002 1 IMM 236 LD R1 2 number of MCBs 03AE9 E4494041 1 5 ZBM 237 ST R1 R5,PRELMCBCNT set the count 238 03AEA 60C400A5 3 IMM 239 LD PFPTR TBMPN2 want to map in page to PACKWNDO2 03AEB 00D68801 2 BASE 240 LDPF R2,MCBPMV map it in 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 133 (DTTPACK) F 20 PACKBOOT -- Pack Bootmake Info 03AEC 610493F5 4 IMM 241 LD R4 TBMFBIPOS R4 -> where we want the FBI stuff 03AED 600493F5 0 IMM 242 LD R0 TBMFBIPOS R0 -> where we want the FBI stuff 03AEE 780403FF 0 IMM 243 AND R0 PAGEMASK turn into page index 03AEF E4174802 0 5 BASE 244 ST R0 R5,PRELPRINX put the index in the PREL 245 03AF0 38968802 2 2 BASE 246 LEA R2 R2,MCBFBI R2 -> FBI 03AF1 62168800 012 BASE 247 LD2 R0 R2,TBMNAME get the file name 03AF2 E6170800 014 BASE 248 ST2 R0 R4,TBMNAME put in our header 03AF3 60168802 0 2 BASE 249 LD R0 R2,TBMIND get the indicator given us by read process 03AF4 E4170802 0 4 BASE 250 ST R0 R4,TBMIND put in our header 251 03AF5 DC5013FB @ 252 CALLNP @VGETDATE get a date 03AF6 E6970803 234 BASE 253 ST2 R2 R4,TBMDATE put it in the header 03AF7 EE170805 4 BASE 254 STZ2 R4,TBMFIL1 zero out the filler 03AF8 EE170807 4 BASE 255 STZ2 R4,TBMFIL2 finish the zeroing 256 03AF9 604403FF 1 IMM 257 LD R1 L/CPW-1 get size of checksummed block 03AFA 60040000 0 IMM 258 LD R0 0 03AFB 58C40010 IMM 259 IORPSR PSRMODIF set funny arithmetic 00003AFC 260 NEXTWORD LABEL 03AFC 18229400 0 1 261 ADD R0 PROGB(R1) add next word and carry 03AFD FA663AFC 1 262 JDR R1 NEXTWORD count and test index 263 * \ / 03AFE 18040000 0 IMM 264 ADD R0 0 add in last carry 03AFF 58840010 IMM 265 CLBPSR PSRMODIF restore normal arithmetic 03B00 E4170809 0 4 BASE 266 ST R0 R4,TBMDCS and place into sum location 267 03B01 6003FF80 0 IMM 268 LD R0 HCSMASK get header checksum mask 03B02 F00093F5 0 269 PRMUT R0 TPHDRLOC generate header checksum 03B03 7407FFFF 0 IMM 270 XOR R0 0FFFFFFFF make ones complement 03B04 E417080A 0 4 BASE 271 ST R0 R4,TBMHCS save in header checksum spot 03B05 DC403DB1 272 CALLNP LINKINENCR put in to be encrypted 03B06 FE0E3AD9 273 JMP BOOTLOOP do the next entry 274 * --- 275 00003B07 276 BOOTDONE LABEL 03B07 60170801 0 4 BASE 277 LD R0 R4,PRELTBM get the type code 03B08 61530000 5 4 REG 278 LD R5 R4 R5 -> PREL 03B09 DC403DB1 279 CALLNP LINKINENCR and put it in the encrypt queue 03B0A 5D1F8002 6 STAK 280 LEAVE POP tapebootmake is done 281 * --- 282 283 END PACKBOOT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 134 (DTTPACK) F 20 Pack the Volume 286 287 ********************************************************************************** 288 * * 289 * PACKVOL * 290 * * 291 * The read process is traversing the OS disk structures * 292 * and putting entries onto the PRPQ. Now we pick entries from * 293 * the head of the queue, and pack them into physical records. * 294 * Register usage is as follows: * 295 * R3 -> current position within physical record * 296 * R4 -> element from PRPQ * 297 * R5 -> current PREL * 298 * Call: * 299 * CALLNP PACKVOL * 300 * * 301 * Eats R0:R5 * 302 * * 303 ********************************************************************************** 304 305 PACKVOL BLOCK 306 307 ENTRY PACKVOL 308 309 BEGFRAME 310 ENDFRAME 311 03B0B DD5F8001 6 STAK 312 PACKVOL ENTRNP PUSH 03B0C EC004908 313 STZ CPRFORM and no file format 03B0D DC403B3E 314 CALLNP VOLLOGREC build the volume's logical record 315 * \ / 316 00003B0E 317 NEXTENTRY LABEL 03B0E DC403D81 318 CALLNP GETNEXPRPQ get the next queue entry 03B0F 60090040 0 4 ZBM 319 LD R0 R4,PRELTYPE extract the type code 03B10 50040008 0 IMM 320 MIN R0 TYPEJTABL keep it within legal limits 03B11 5CA03B12 0 321 LDPC TYPEJTAB(R0) do the proper action 322 * --- 323 03B12 00003B22 324 TYPEJTAB VFD ADR PACKVOLERR 0 - PREL 03B13 00003B23 325 VFD ADR NEWFILE 1 - File Directory Entry 03B14 00003B25 326 VFD ADR FILEBLOCK 2 - MCB 03B15 00003B22 327 VFD ADR PACKVOLERR 3 - end of tapebootmake information 03B16 00003B1B 328 VFD ADR PACKVOLEND 4 - end of volume marker 03B17 00003B22 329 VFD ADR PACKVOLERR 5 - volume name 03B18 00003B3A 330 VFD ADR NEWACCT 6 - UDIR 03B19 00003B3C 331 VFD ADR READERROR 7 - error element 00000008 ABS 332 TYPEJTABL EQU DISPW TYPEJTAB 03B1A 00003B22 333 VFD ADR PACKVOLERR catch any incorrect type codes 334 335 * End of file set marker has been found. Ship out the 336 * last physical record then quit this madness. 337 00003B1B 338 PACKVOLEND LABEL 03B1B FB423B1D 5 339 JEQZ R5 DONTSEND if nothing to send 03B1C DC403DB1 340 CALLNP LINKINENCR link it onto the encryption queue 341 * \ / 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 135 (DTTPACK) F 20 Pack the Volume 342 00003B1D 343 DONTSEND LABEL 03B1D 61530000 5 4 REG 344 LD R5 R4 R5 -> end of volume PREL 03B1E EDC94A10 5 ZBM 345 STW R5,PRELDONE so encryptor will move this to TWQ 03B1F EC094810 5 ZBM 346 STZ R5,PRELBUSY can't be a busy entry 03B20 DC403DB1 347 CALLNP LINKINENCR link it into the encrypt queue 03B21 5D1F8001 6 STAK 348 LEAVE POP 349 * --- 350 351 * Oops!! An illegal type was found in the PRPQ. 00003B22 352 PACKVOLERR LABEL 03B22 00173211 353 HALT HALTW3211 found the wrong type in PRPQ 354 * R0 contains erroneous type 355 * --- R4 -> element containing wrong type 356 357 * The entry found in the PRPQ is a file directory entry. 358 00003B23 359 NEWFILE LABEL 03B23 DC403C18 360 CALLNP PACKFILE pack up a logical file record 03B24 FE0E3B0E 361 JMP NEXTENTRY 362 * --- 363 364 * R4 points to an MCB. The page is a file data block page. 365 * Determine if we can continue using the current physical record 366 * or if we should ship it out and start a new physical record. 367 00003B25 368 FILEBLOCK LABEL 03B25 FB423B38 5 369 JEQZ R5 CALLFAST no current PREL? Start a fast format PR 03B26 60004908 0 370 LD R0 CPRFORM get current physical record format 03B27 64040001 0 IMM 371 CPR R0 NORMFORM see what routine to call 03B28 FE0C3B38 372 JNE CALLFAST call the fast packing routine 373 * check encryption type 03B29 5C00481C 374 CMZ ENCRFASTFL see if we are encrypting everything 03B2A FE023B31 375 JEQ ENCRYOK if so, encryption type is compatible 03B2B 60040003 0 IMM 376 LD R0 ENCRNONE 03B2C 5C00490A 377 CMZ ACCTENCR is this the same as the account? 03B2D FE023B2F 378 JEQ HAVECODE we have the desired code 03B2E 60040002 0 IMM 379 LD R0 ENCRNORM normal encryption is desired 00003B2F 380 HAVECODE LABEL 03B2F 64094C20 0 5 ZBM 381 CPR R0 R5,PRELENCRY are we using the correct encryption? 03B30 FE0C3B37 382 JNE SENDPREL if not start a new physical record 383 * \ / 384 00003B31 385 ENCRYOK LABEL 03B31 6000483B 0 386 LD R0 PHYSRECSIZ get the maximum size of a physical record 03B32 10096101 0 5 ZBM 387 SUB R0 R5,PRELPRLEN see how much space is left 03B33 64040416 0 IMM 388 CPR R0 FILBLKRECL is there enough for this record? 03B34 FE083B37 389 JLT SENDPREL if not, then end this physical record 390 * \ / 391 03B35 DC403CBA 392 CALLNP PACKNORMBL use the normal file block pack routine 03B36 FE0E3B0E 393 JMP NEXTENTRY 394 * --- 395 00003B37 396 SENDPREL LABEL 03B37 DC403DB1 397 CALLNP LINKINENCR link it into the encrypt queue 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 136 (DTTPACK) F 20 Pack the Volume 398 * \ / 399 00003B38 400 CALLFAST LABEL 03B38 DC403C7C 401 CALLNP PACKFASTBL use the fast pack routine 03B39 FE0E3B0E 402 JMP NEXTENTRY 403 * --- 404 405 * The PRPQ entry is an MCB whose page contains the account 406 * information section of a UDIR1. 407 00003B3A 408 NEWACCT LABEL 03B3A DC403B98 409 CALLNP PACKACCT pack an account logical record 03B3B FE0E3B0E 410 JMP NEXTENTRY 411 * --- 412 413 * An error was encountered reading the disk. Need an error 414 * logical record so recovery will know about it. 415 00003B3C 416 READERROR LABEL 03B3C DC403CEA 417 CALLNP PACKERROR pack an error element 03B3D FE0E3B0E 418 JMP NEXTENTRY 419 * --- 420 421 END PACKVOL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 137 (DTTPACK) F 20 Build a Volume Logical Record 424 425 ********************************************************************************** 426 * * 427 * VOLLOGREC -- Build a Volume Logical Record * 428 * * 429 * This subroutine builds the volume logical record which * 430 * starts the actual volume information in the fileset. This * 431 * record contains the typical header crap, plus the entire * 432 * diskboot block and its FBI, the volume label up through * 433 * VOLBKUPE, and part of a security block. * 434 * Call: * 435 * CALLNP VOLLOGREC * 436 * * 437 * Eats R0:R5 * 438 * * 439 ********************************************************************************** 440 441 VOLLOGREC BLOCK 442 443 ENTRY VOLLOGREC 444 445 BEGFRAME 00178801 6 BASE 446 VOLLOGPTR BSS 1 pointer to first of record 00178802 6 BASE 447 OSRECPTR BSS 1 pointer to first of OS record 00178803 6 BASE 448 RUNRECPTR BSS 1 running buffer pointer 449 ENDFRAME 450 03B3E DD5F8004 6 STAK 451 VOLLOGREC ENTRNP PUSH 03B3F DC003D64 452 CALL PRELANDPAG start a new PREL 03B40 40009400 453 PARL PACKPRPAGE start header at the beginning 03B41 60040002 0 IMM 454 LD R0 ENCRNORM code for normal encryption 03B42 E4094C20 0 5 ZBM 455 ST R0 R5,PRELENCRY set encryption code 456 03B43 DC003CF7 457 CALL PACKLOGREC pack a logical record header 03B44 40440003 IMM 458 PARVL RTYPEVOL type of logical record 03B45 E4D78801 3 6 BASE 459 ST R3 SP,VOLLOGPTR save pointer to first of record 03B46 3896C801 2 3 BASE 460 LEA R2 R3,VOLRECFILL R2 -> filler words 03B47 60440010 1 IMM 461 LD R1 VOLFILLEN*CPW how much there is to fill 03B48 FE580000 462 CFILL 00 zero it 03B49 18C40005 3 IMM 463 ADD R3 VOLRECLEN R3 -> beginning of tapestring 03B4A DC003E0B 464 CALL TSMOVE move in the volume name 03B4B 4040492B 465 PARVL ACCTINDEX how much to move 466 467 * BACKUP's header for OS info 03B4C 60040467 0 IMM 468 LD R0 VOLRECSIZ total size of volume record from OS 03B4D E416C800 0 3 BASE 469 ST R0 R3,OSINFOSIZ put it in the header 03B4E 18C40001 3 IMM 470 ADD R3 TAPHDR1000L move to start of OS header 471 472 * OS header for OS info 03B4F E4D78802 3 6 BASE 473 ST R3 SP,OSRECPTR save pointer to OS record 03B50 DC003CFB 474 CALL MAKEOSHDR make an OS header 03B51 40440000 IMM 475 PARVL FILEINFOTV OS code for volume info 03B52 E4D78803 3 6 BASE 476 ST R3 SP,RUNRECPTR save running pointer 477 478 * Boot block followed by its FBI 03B53 BC404909 1 479 INCL R1 CPRPN get the next available page number 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 138 (DTTPACK) F 20 Build a Volume Logical Record 03B54 DC003D44 480 CALL GETPACKPAG need another page 03B55 40524000 1 REG 481 PARVL R1 virtual page number to map into 03B56 60094041 0 5 ZBM 482 LD R0 R5,PRELMCBCNT get index to space for a MCB pointer 03B57 D0094041 5 ZBM 483 INC R5,PRELMCBCNT move up our count of MCB pointers 03B58 E51D4003 4 50 BASE 484 ST R4 R5,PRELMCBPTR(R0) put in this pointer 485 03B59 DC003D95 486 CALL MAPNEXPRPQ map element from PRPQ 03B5A 414400A3 IMM 487 PARV PKPNWNDO1 virtual page to map into 03B5B 40440003 IMM 488 PARVL FBITBOOT FBI type of expected block 03B5C FE0E3B85 489 JMP PACKDEATH die if we can't pack this 490 03B5D 60978803 2 6 BASE 491 LD R2 SP,RUNRECPTR R2 -> position in record 03B5E 60441000 1 IMM 492 LD R1 CPP move this many characters 03B5F 60048C00 0 IMM 493 LD R0 ADR PACKWNDO1 where the block is 03B60 FE400000 494 CMOVE 03B61 38170802 0 4 BASE 495 LEA R0 R4,MCBFBI R0 -> FBI 03B62 6044002C 1 IMM 496 LD R1 FBILNTH*CPW how many chars to move 03B63 FE400000 497 CMOVE in goes the FBI 03B64 E4978803 2 6 BASE 498 ST R2 SP,RUNRECPTR R2 -> position in OS record 03B65 DC403466 499 CALLNP PAGERETURN return the page to the free page list 500 501 * Get volume label and put into record 502 03B66 DC003D95 503 CALL MAPNEXPRPQ map element from PRPQ 03B67 414400A3 IMM 504 PARV PKPNWNDO1 virtual page to map into 03B68 40440004 IMM 505 PARVL FBITVL FBI type of expected block 03B69 FE0E3B85 506 JMP PACKDEATH die if we can't pack this 507 03B6A 60D78802 3 6 BASE 508 LD R3 SP,OSRECPTR get pointer to OS record 03B6B 60978803 2 6 BASE 509 LD R2 SP,RUNRECPTR R2 -> current position in record 03B6C 60440100 1 IMM 510 LD R1 VLBKUPE*CPW move this many characters 03B6D E448C0F1 1 3 ZBM 511 ST R1 R3,BKUPHDRW2/FSTBKUPLEN and indicate length of vol info 03B6E 60048C00 0 IMM 512 LD R0 ADR PACKWNDO1 where the block is 03B6F FE400000 513 CMOVE 03B70 E4978803 2 6 BASE 514 ST R2 SP,RUNRECPTR R2 -> current position in record 03B71 DC403466 515 CALLNP PAGERETURN return the page to the free page list 516 517 * Get security block and put into record 518 03B72 DC003D95 519 CALL MAPNEXPRPQ map element from PRPQ 03B73 414400A3 IMM 520 PARV PKPNWNDO1 virtual page to map into 03B74 40440006 IMM 521 PARVL FBITSEC FBI type of expected block 03B75 FE0E3B85 522 JMP PACKDEATH die if we can't pack this 523 03B76 60D78802 3 6 BASE 524 LD R3 SP,OSRECPTR get pointer to OS record 03B77 60978803 2 6 BASE 525 LD R2 SP,RUNRECPTR R2 -> current position in record 03B78 60440068 1 IMM 526 LD R1 (SECBKUPE DISPW SECTZONE)*CPW move this many characters 03B79 E448DF11 1 3 ZBM 527 ST R1 R3,BKUPHDRW2/SNDBKUPLEN and tell it sec info length 03B7A 60048C00 0 IMM 528 LD R0 ADR PACKWNDO1 where the block is 03B7B FE400000 529 CMOVE 03B7C DC403466 530 CALLNP PAGERETURN return the page to the free page list 531 532 * Determine record's length in words (Backup only deals with 533 * full words, so this will work) 03B7D 60D28000 3 2 REG 534 LD R3 R2 R3 -> end of the record 03B7E 60578801 1 6 BASE 535 LD R1 SP,VOLLOGPTR get starting address of this record 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 139 (DTTPACK) F 20 Build a Volume Logical Record 03B7F 10924000 2 1 REG 536 SUB R2 R1 determine the length of the record 03B80 E4886100 2 1 ZBM 537 ST R2 R1,LOGRECIFL set length in header 03B81 98896101 2 5 ZBM 538 ADDM R2 R5,PRELPRLEN adjust current physical record size 03B82 60040001 0 IMM 539 LD R0 NORMFORM code for normal record 03B83 E4004908 0 540 ST R0 CPRFORM set current physical record format 03B84 5D1F8004 6 STAK 541 LEAVE POP 542 * --- 543 00003B85 544 PACKDEATH LABEL 03B85 DC1013F9 @ 545 CALL @VPREPOUT say what is happening 03B86 40003B88 546 PARL QUITMESS 03B87 00173212 547 HALT HALTW3212 die with missing vol record data 548 * --- 549 03B88 20444953 550 QUITMESS TEXT " DISKTOTAPE aborted." 03B8D 2020436F 551 TEXTZ " Could not build a Volume Logical Record." 552 553 END VOLLOGREC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 140 (DTTPACK) F 20 Pack an Account Logical Record 556 557 ********************************************************************************** 558 * * 559 * PACKACCT -- Pack an Account Logical Record * 560 * * 561 * We arrive here with an MCB for a block containing * 562 * UDIR1 stuff. We first do any necessary work to set up the * 563 * physical record, then build a logical account record * 564 * header, and finally a logical account record. In the * 565 * course of all this we set the account encryption flag, and * 566 * put the account name into the tapestring. * 567 * If a share list or authorization list exists for this * 568 * account we retrieve its MCB from the PRPQ and put it in * 569 * with the account info. * 570 * Call: * 571 * R3 -> next available word in the physical record and * 572 * R4 -> MCB for UDIR1 info * 573 * R5 -> current PREL. * 574 * CALLNP PACKACCT * 575 * * 576 * Returns R3 -> next available word in the physical record and * 577 * R5 -> current PREL. * 578 * Eats R0:R5 * 579 * * 580 ********************************************************************************** 581 582 PACKACCT BLOCK 583 584 ENTRY PACKACCT 585 586 BEGFRAME 00178801 6 BASE 587 OSRECPTR BSS 1 pointer to position in record 00178802 6 BASE 588 ACCTMCB BSS 1 save original MCB pointer 00178803 6 BASE 589 BEGREC BSS 1 pointer to beginning of the record 590 ENDFRAME 591 03B98 DD5F8004 6 STAK 592 PACKACCT ENTRNP PUSH 03B99 E5178802 4 6 BASE 593 ST R4 SP,ACCTMCB save pointer to our MCB 03B9A DC003D03 594 CALL CHEK4ROOM get enough space in the physical record 03B9B 41440002 IMM 595 PARV ENCRNORM desired encryption type 03B9C 40440876 IMM 596 PARVL ACCTRECSIZ how much space we need 597 03B9D E4D78803 3 6 BASE 598 ST R3 SP,BEGREC save record pointer 03B9E 60C400A3 3 IMM 599 LD PFPTR PKPNWNDO1 page to map UDIR into 03B9F 61178802 4 6 BASE 600 LD R4 SP,ACCTMCB R4 -> MCB containing UDIR 03BA0 00D70801 4 BASE 601 LDPF R4,MCBPMV map in the page with UDIR 602 03BA1 60D78803 3 6 BASE 603 LD R3 SP,BEGREC R3 -> where we are at in the record 03BA2 DC003D31 604 CALL ENUFPAGE make enough room on mapped in page(s) 03BA3 40440076 IMM 605 PARVL ACCTNOALSL how much room we need 606 607 * build header 03BA4 DC003CF7 608 CALL PACKLOGREC build the logical record header 03BA5 40440004 IMM 609 PARVL RTYPEACC account type 610 03BA6 62008C20 01 611 LD2 R0 PACKWNDO1(UDSERNO) get the account serial number 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 141 (DTTPACK) F 20 Pack an Account Logical Record 03BA7 E616C801 013 BASE 612 ST2 R0 R3,ACTHDRSER put in the account header 03BA8 E600490B 01 613 ST2 R0 PACKACCTSN save for account's file packing 03BA9 EC16C803 3 BASE 614 STZ R3,ACTHDRNOSL say we are keeping the share list 615 03BAA 60040000 0 IMM 616 LD R0 0 assume encrypt all 03BAB 5C00481C 617 CMZ ENCRFASTFL are we encrypting everything? 03BAC FE023BAF 618 JEQ ENCRYALL if so then we have the write flag 03BAD 60008C1F 0 619 LD R0 PACKWNDO1(UDSFLAGS) get account flags 03BAE 600A0010 0 0 CBM 620 LD R0 R0/UDENCRFLG get the account encrypt flag 621 * (note: 1 means don't encrypt) 00003BAF 622 ENCRYALL LABEL 03BAF E416C804 0 3 BASE 623 ST R0 R3,ACTHDRFAST set it in the record 03BB0 74040001 0 IMM 624 XOR R0 1 want opposite value 03BB1 E400490A 0 625 ST R0 ACCTENCR so we will know for the following files 626 03BB2 3896C805 2 3 BASE 627 LEA R2 R3,ACTHDRFILL R2 -> header filler 03BB3 60440010 1 IMM 628 LD R1 ACTFILLEN*CPW length of filler 03BB4 FE580000 629 CFILL 00 make sure it is all zero 630 03BB5 18C40009 3 IMM 631 ADD R3 ACTRECLEN move beyond header 03BB6 DC003DF3 632 CALL TSNAME put the account name into the tapestring 03BB7 4140492B 633 PARV ACCTINDEX where to start the name 03BB8 43408C00 634 PARV2 PACKWNDO1(UDACCT) the account name 03BB9 40408C02 635 PARVL PACKWNDO1(UDPROJ) project 03BBA E480492C 2 636 ST R2 FILEINDEX where file names start in the string 03BBB DC003E0B 637 CALL TSMOVE move the tape string into the header 03BBC 40528000 2 REG 638 PARVL R2 how many chars to move 639 03BBD E4D78801 3 6 BASE 640 ST R3 SP,OSRECPTR save the position of OS info header 03BBE 60040062 0 IMM 641 LD R0 UDIRKEEPL+BKUPHDRLEN how much we are putting in 03BBF E416C800 0 3 BASE 642 ST R0 R3,OSINFOSIZ size of info we will put in record 03BC0 18C40001 3 IMM 643 ADD R3 TAPHDR1000L move past this f___ing header 644 645 * now we build the OS returned stuff 03BC1 DC003CFB 646 CALL MAKEOSHDR make an OS header 03BC2 40440001 IMM 647 PARVL FILEINFOTA account info code 648 03BC3 6092C000 2 3 REG 649 LD R2 R3 R2 -> where we want stuff moved to 03BC4 60440180 1 IMM 650 LD R1 UDIRKEEPL*CPW how much we want to move 03BC5 60048C00 0 IMM 651 LD R0 ADR PACKWNDO1 where to find the stuff 03BC6 FE400000 652 CMOVE move it into the record 03BC7 60D28000 3 2 REG 653 LD R3 R2 R3 -> word beyond UDIR info 03BC8 60008C3C 0 654 LD R0 PACKWNDO1(UDSHLLIST) see if there is a share list 03BC9 F2003BD1 0 655 JBF R0/SHLDSKFLG CHEKAUTHL if none, see about the auth list 656 * \ / 657 03BCA DC003BE2 658 CALL MOVEINLIST move in the share list 03BCB 40440011 IMM 659 PARVL FBITASLB type of list 03BCC 60178801 0 6 BASE 660 LD R0 SP,OSRECPTR R0 -> another OS header 03BCD 98560800 1 0 BASE 661 ADDM R1 R0,OSINFOSIZ adjust the OS info size 03BCE 18040001 0 IMM 662 ADD R0 TAPHDR1000L move to start of OS header 03BCF 1C440004 1 IMM 663 MUL R1 CPW because OS count is in chars 03BD0 E44800F1 1 0 ZBM 664 ST R1 R0,BKUPHDRW2/FSTBKUPLEN and tell it how long the SL is 665 * \ / 666 00003BD1 667 CHEKAUTHL LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 142 (DTTPACK) F 20 Pack an Account Logical Record 03BD1 5C008C40 668 CMZ PACKWNDO1(UDAUTHLIST) see if there is an auth list 03BD2 FE023BDA 669 JEQ FINISHUP if not then we are done here 670 * \ / 671 03BD3 DC003BE2 672 CALL MOVEINLIST 03BD4 40440015 IMM 673 PARVL FBITAUTLB type of list we are moving 03BD5 60178801 0 6 BASE 674 LD R0 SP,OSRECPTR R0 -> another OS header 03BD6 98560800 1 0 BASE 675 ADDM R1 R0,OSINFOSIZ adjust the OS info size 03BD7 18040001 0 IMM 676 ADD R0 TAPHDR1000L move to start of OS header 03BD8 1C440004 1 IMM 677 MUL R1 CPW because OS count is in chars 03BD9 E4481F11 1 0 ZBM 678 ST R1 R0,BKUPHDRW2/SNDBKUPLEN and tell it how long the AL is 679 * \ / 680 00003BDA 681 FINISHUP LABEL 03BDA 6012C000 0 3 REG 682 LD R0 R3 copy current address 03BDB 10178803 0 6 BASE 683 SUB R0 SP,BEGREC determine words in record 03BDC 60578803 1 6 BASE 684 LD R1 SP,BEGREC R1 -> beginning of the logical record 03BDD E4086100 0 1 ZBM 685 ST R0 R1,LOGRECIFL set the size field in it 03BDE 98096101 0 5 ZBM 686 ADDM R0 R5,PRELPRLEN update current physical record size 03BDF 61178802 4 6 BASE 687 LD R4 SP,ACCTMCB 03BE0 DC403466 688 CALLNP PAGERETURN return the page to free page list 03BE1 5D1F8004 6 STAK 689 LEAVE POP 690 * --- 691 692 END PACKACCT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 143 (DTTPACK) F 20 Move Share List 695 696 ********************************************************************************** 697 * * 698 * MOVEINLIST -- Move the Share List into the Physical Record * 699 * * 700 * We use this subroutine to move disk block share lists * 701 * into physical records. * 702 * * 703 * Call: * 704 * LD R3 ADR * 705 * CALL MOVEINLIST * 706 * PARVL * 707 * * 708 * Uses PACKWNDO2 * 709 * Returns R0 = number of words in share list * 710 * R3 -> word beyond share list in physical record * 711 * Eats R0:R4 * 712 * * 713 ********************************************************************************** 714 715 MOVEINLIST BLOCK 716 717 ENTRY MOVEINLIST 718 719 BEGFRAME 00178801 6 BASE 720 LISTFBITYP BSS 1 expected FBI type 00178802 6 BASE 721 LISTLEN BSS 1 length of share list entry 00178803 6 BASE 722 LISTR3 BSS 1 temp for R3 723 ENDFRAME 724 03BE2 DD1F8004 6 STAK 725 MOVEINLIST ENTR PUSH 03BE3 C0578801 6 BASE 726 STPVL SP,LISTFBITYP 03BE4 E4D78803 3 6 BASE 727 ST R3 SP,LISTR3 save current R3 728 03BE5 60578801 1 6 BASE 729 LD R1 SP,LISTFBITYP get the desired FBI type 03BE6 DC003D95 730 CALL MAPNEXPRPQ map in the next page from the PRPQ 03BE7 414400A4 IMM 731 PARV PKPNWNDO2 where to map it to 03BE8 40524000 1 REG 732 PARVL R1 expected FBI type 03BE9 FE0E3C00 733 JMP NOLIST oops, no list 734 03BEA 60178801 0 6 BASE 735 LD R0 SP,LISTFBITYP get the list type 03BEB 64040015 0 IMM 736 CPR R0 FBITAUTLB see if it is an auth list 03BEC FE0C3BEF 737 JNE SHARELIST if not it must be a share list 03BED FAE83C02 3 738 JSR R3 GETAUTHLEN get length of auth list 03BEE FE0E3BF0 739 JMP HAVELENGTH 740 * --- 741 00003BEF 742 SHARELIST LABEL 03BEF FAE83C0E 3 743 JSR R3 GETSHLLEN get length of shared list 00003BF0 744 HAVELENGTH LABEL 03BF0 E4578802 1 6 BASE 745 ST R1 SP,LISTLEN save the list's length 03BF1 60D78803 3 6 BASE 746 LD R3 SP,LISTR3 R3 -> position in record 03BF2 DC003D31 747 CALL ENUFPAGE get enough working space 03BF3 40524000 1 REG 748 PARVL R1 how much space we need 749 03BF4 60049000 0 IMM 750 LD R0 ADR PACKWNDO2 where the list is 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 144 (DTTPACK) F 20 Move Share List 03BF5 6092C000 2 3 REG 751 LD R2 R3 get pointer to current end of record 03BF6 60578802 1 6 BASE 752 LD R1 SP,LISTLEN get the list's length 03BF7 98578803 1 6 BASE 753 ADDM R1 SP,LISTR3 bump up pointer to end of record 03BF8 1C440004 1 IMM 754 MUL R1 CPW convert to characters 03BF9 FE400000 755 CMOVE 03BFA 60C400A4 3 IMM 756 LD PFPTR PKPNWNDO2 virtual page number for window 2 03BFB 80D2C000 3 REG 757 PFRC R3 clear the page file location 03BFC DC403466 758 CALLNP PAGERETURN return page to free page list 03BFD 60578802 1 6 BASE 759 LD R1 SP,LISTLEN 00003BFE 760 MOVEDONE LABEL 03BFE 60D78803 3 6 BASE 761 LD R3 SP,LISTR3 restore record pointer 03BFF 5D1F8004 6 STAK 762 LEAVE POP 763 * --- 764 00003C00 765 NOLIST LABEL 03C00 60440000 1 IMM 766 LD R1 0 say no list length 03C01 FE0E3BFE 767 JMP MOVEDONE 768 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 145 (DTTPACK) F 20 Move Share List 770 771 ********************************************************************************** 772 * * 773 * GETAUTHLEN * 774 * * 775 * This routine will find the length of data in the * 776 * accounts auth list. We call this so we won't have to pass * 777 * the whole block. * 778 * Call: * 779 * * 780 * JSR R3 GETAUTHLEN * 781 * Returns R1 = length of authlist * 782 * * 783 ********************************************************************************** 784 00003C02 785 GETAUTHLEN LABEL 03C02 60440004 1 IMM 786 LD R1 AUTHENTBG beginning of authlist 00003C03 787 KPONTRUKIN LABEL 03C03 5E229000 1 788 CMZ2 PACKWNDO2(R1) is there a volume name here? 03C04 FE023C09 789 JEQ FOUNDEND jump if end of list 790 * \ / 03C05 1844000C 1 IMM 791 ADD R1 AUTHLELEN adjust length 03C06 644403FF 1 IMM 792 CPR R1 WPP-1 are we at end of page? 03C07 FE083C03 793 JLT KPONTRUKIN if not, keep on truckin' 794 * \ / 03C08 60440400 1 IMM 795 LD R1 WPP say a whole page long 00003C09 796 FOUNDEND LABEL 03C09 5C92C000 3 REG 797 LDPC R3 back to caller 798 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 146 (DTTPACK) F 20 Move Share List 800 801 ********************************************************************************** 802 * * 803 * GETSHLLEN * 804 * * 805 * This routine will find the length of data in the * 806 * shared list. We call this so we won't have to pass the * 807 * whole block. * 808 * Call: * 809 * * 810 * JSR R3 GETSHLLEN * 811 * Returns R1 = length in chars. * 812 * Sets R1, Eats R2 * 813 * * 814 ********************************************************************************** 815 00003C0A 816 SHLTAB LABEL 03C0A 00000004 817 VFD SHLENTLEN length of simple entry 03C0B 00000006 818 VFD SHLENTPLEN length if password specified 03C0C 00000007 819 VFD SHLENTSLEN length if system specified 03C0D 00000007 820 VFD SHLENTSLEN length if system and password specified 821 00003C0E 822 GETSHLLEN LABEL 03C0E 60440000 1 IMM 823 LD R1 0 set begin pointer 00003C0F 824 KEEPON LABEL 03C0F 60A29000 2 1 825 LD R2 PACKWNDO2(R1) first word of entry 03C10 5C128000 2 REG 826 CMZ R2 if zero no more entries 03C11 FE023C17 827 JEQ FNDEND jump if no more entries 828 * \ / 03C12 608A8220 2 2 CBM 829 LD R2 R2/SHLACTOPT get option bits 03C13 18643C0A 1 2 830 ADD R1 SHLTAB(R2) adjust for size of entry 03C14 64440400 1 IMM 831 CPR R1 WPP are we at end of page 03C15 FE083C0F 832 JLT KEEPON jump if not at end yet 833 * \ / 834 03C16 60440400 1 IMM 835 LD R1 WPP say whole page 00003C17 836 FNDEND LABEL 03C17 5C92C000 3 REG 837 LDPC R3 return 838 * --- 839 840 END MOVEINLIST 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 147 (DTTPACK) F 20 Pack a Logical File Record 843 844 ********************************************************************************** 845 * * 846 * PACKFILE -- Pack a logical file record * 847 * * 848 * This subroutine builds a logical file record. This * 849 * consists of the FDE (which is in the PREL pointed to by * 850 * R4), a share list if existent, and the first part of a * 851 * CCB if the file is a code file. * 852 * Call: * 853 * R3 -> current position in physical record * 854 * R4 -> PREL containing FDE * 855 * R5 -> PREL or zero if no PREL * 856 * CALLNP PACKFILE * 857 * * 858 * Returns R3 -> current position in physical record * 859 * R5 -> PREL or zero if no PREL * 860 * Eats R0:R5 * 861 * * 862 ********************************************************************************** 863 864 PACKFILE BLOCK 865 866 ENTRY PACKFILE 867 868 BEGFRAME 00178801 6 BASE 869 FILEBEGPTR BSS 1 pointer to beginning of file log rec 00178802 6 BASE 870 OSHDRPTR BSS 1 pointer to f___ing header 00178803 6 BASE 871 FILPRELPTR BSS 1 pointer to PREL containing FDE 00178804 6 BASE 872 FILER3 BSS 1 temp for R3 873 ENDFRAME 874 03C18 DD5F8005 6 STAK 875 PACKFILE ENTRNP PUSH 03C19 D1404906 876 STMW FPSEQNUM initialize sequence numbers 03C1A D1404907 877 STMW FPLRSEQNUM this one, too 03C1B E5178803 4 6 BASE 878 ST R4 SP,FILPRELPTR save PREL pointer 03C1C DC003D03 879 CALL CHEK4ROOM make enough room in physical record 03C1D 4147FFFF IMM 880 PARV -1 we don't care whether it is encrypted 03C1E 4044043D IMM 881 PARVL FILERECSIZ size of record 882 03C1F E4D78801 3 6 BASE 883 ST R3 SP,FILEBEGPTR save pointer to beginning of file record 03C20 DC003D31 884 CALL ENUFPAGE get enough working space 03C21 4044003D IMM 885 PARVL FILENOSL how much space we need 886 03C22 DC003CF7 887 CALL PACKLOGREC make our logical record header 03C23 40440005 IMM 888 PARVL RTYPEFIL type of logical record 889 890 * Build the file logical record header. 03C24 6200490B 01 891 LD2 R0 PACKACCTSN get the account serial number 03C25 E616C801 013 BASE 892 ST2 R0 R3,FILHDRASER put in header 03C26 EC16C803 3 BASE 893 STZ R3,FILHDRNOSL say we are keeping any file share list 894 03C27 61178803 4 6 BASE 895 LD R4 SP,FILPRELPTR R4 -> PREL containing FDE 03C28 38170801 0 4 BASE 896 LEA R0 R4,PRELFDE R0 -> FDE 03C29 60482A60 1 0 ZBM 897 LD R1 R0,FDET get entry type 03C2A E456C804 1 3 BASE 898 ST R1 R3,FILHDRTYPE set the file hardware type 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 148 (DTTPACK) F 20 Pack a Logical File Record 03C2B 60481186 1 0 ZBM 899 LD R1 R0,FDLEN get the file's length 03C2C E456C805 1 3 BASE 900 ST R1 R3,FILHDRSIZE put in header 901 03C2D EE16C806 3 BASE 902 STZ2 R3,FILHDRRDAT start with nothing here 03C2E 60560808 1 0 BASE 903 LD R1 R0,FDLACC last access date 03C2F E448E806 1 3 ZBM 904 ST R1 R3,FILHDRRDAT/DATEHORD call it the last read date 03C30 EE16C808 3 BASE 905 STZ2 R3,FILHDRWDAT start with nothing here 03C31 60560807 1 0 BASE 906 LD R1 R0,FDLCD last changed date 03C32 E448E808 1 3 ZBM 907 ST R1 R3,FILHDRWDAT/DATEHORD call this the last write date 03C33 6256080A 120 BASE 908 LD2 R1 R0,FDSERNO file serial number 03C34 E656C80A 123 BASE 909 ST2 R1 R3,FILHDRCDAT same as the create date 03C35 EE16C80C 3 BASE 910 STZ2 R3,FILHDRBDAT clear this out 03C36 60560809 1 0 BASE 911 LD R1 R0,FDLBU last backup date 03C37 E448E80C 1 3 ZBM 912 ST R1 R3,FILHDRBDAT/DATEHORD call this the last backup date 913 03C38 60483610 1 0 ZBM 914 LD R1 R0,FDGHOST get the ghost flag 03C39 E456C80E 1 3 BASE 915 ST R1 R3,FILHDRGOST for the header 03C3A 3896C80F 2 3 BASE 916 LEA R2 R3,FILHDRFILL time to wipe out the filler 03C3B 60440010 1 IMM 917 LD R1 FILEFILLEN*CPW how much there is 03C3C FE580000 918 CFILL 00 what to smear it with 919 920 * Now build and put in the tapestring file name. 03C3D 38D6C813 3 3 BASE 921 LEA R3 R3,FILHDRNAME R3 -> beginning of TS location 03C3E 60920000 2 0 REG 922 LD R2 R0 R2 -> FDE 03C3F DC003DF3 923 CALL TSNAME build the tape string name 03C40 4140492C 924 PARV FILEINDEX where to start the name at 03C41 43568802 2 BASE 925 PARV2 R2,FDNAME the file name 03C42 40568804 2 BASE 926 PARVL R2,FDEXTEN extension 03C43 DC003E0B 927 CALL TSMOVE move the TS into the record 03C44 40528000 2 REG 928 PARVL R2 how many to move 929 930 * Next is the BACKUP header for the OS info 03C45 6004001A 0 IMM 931 LD R0 FILEOSSIZE size of OS stuff with no share list 03C46 E416C800 0 3 BASE 932 ST R0 R3,OSINFOSIZ put in the OS header 03C47 E4D78802 3 6 BASE 933 ST R3 SP,OSHDRPTR keep pointer to OS header header 934 935 * Then the OS header for the OS info 03C48 18C40001 3 IMM 936 ADD R3 TAPHDR1000L move to OS header 03C49 DC003CFB 937 CALL MAKEOSHDR build the OS header 03C4A 40440002 IMM 938 PARVL FILEINFOTF OS code for file info 939 940 * Now the actual file information from the UDIR. 03C4B 6092C000 2 3 REG 941 LD R2 R3 R2 -> beyond header 03C4C 38170801 0 4 BASE 942 LEA R0 R4,PRELFDE R0 -> FDE 03C4D 60440060 1 IMM 943 LD R1 FDLNTH*CPW how much FDE there is 03C4E FE400000 944 CMOVE move into the logical record 03C4F 60D28000 3 2 REG 945 LD R3 R2 R3 -> end of record 946 947 * See if there is a file share list to include in this record. 03C50 38170801 0 4 BASE 948 LEA R0 R4,PRELFDE R0 -> FDE 03C51 60160814 0 0 BASE 949 LD R0 R0,FDSHL get share list info 03C52 F2003C5B 0 950 JBF R0/SHLDSKFLGB NOSHARE jump if no disk share list 951 * \ / 952 03C53 DC003BE2 953 CALL MOVEINLIST move in the file share list 03C54 40440012 IMM 954 PARVL FBITFSLB FBI type 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 149 (DTTPACK) F 20 Pack a Logical File Record 03C55 60178802 0 6 BASE 955 LD R0 SP,OSHDRPTR R0 -> OS header 03C56 98560800 1 0 BASE 956 ADDM R1 R0,OSINFOSIZ since we added more OS info on 03C57 18040001 0 IMM 957 ADD R0 TAPHDR1000L move to OS header 03C58 1C440004 1 IMM 958 MUL R1 CPW since we want length in chars 03C59 E44800F1 1 0 ZBM 959 ST R1 R0,BKUPHDRW2/FSTBKUPLEN set SL length 03C5A 61178803 4 6 BASE 960 LD R4 SP,FILPRELPTR restore PREL pointer 961 * \ / 962 00003C5B 963 NOSHARE LABEL 964 * If we have a code file then we must include the CCB. 03C5B 38170801 0 4 BASE 965 LEA R0 R4,PRELFDE R0 -> FDE 03C5C 60082A60 0 0 ZBM 966 LD R0 R0,FDET get code for file type 03C5D 64040003 0 IMM 967 CPR R0 HTYPECODE see if it is a code file 03C5E FE0C3C70 968 JNE NOCODE jump if not 969 * \ / 970 03C5F E4D78804 3 6 BASE 971 ST R3 SP,FILER3 save R3 from harm 03C60 DC003D95 972 CALL MAPNEXPRPQ map next entry in PRPQ 03C61 414400A3 IMM 973 PARV PKPNWNDO1 virtual page number to map block into 03C62 40440013 IMM 974 PARVL FBITCCB FBI type 03C63 FE0E3C79 975 JMP KILLFILE can't do code file with no CCB 976 03C64 60048C00 0 IMM 977 LD R0 ADR PACKWNDO1 place to start move 03C65 60440060 1 IMM 978 LD R1 CCBINFOL*CPW how much we want moved 03C66 60978804 2 6 BASE 979 LD R2 SP,FILER3 where to move it 03C67 FE400000 980 CMOVE 03C68 60D28000 3 2 REG 981 LD R3 R2 R3 -> end of record 982 03C69 60440018 1 IMM 983 LD R1 CCBINFOL how much we moved in words 03C6A 60178802 0 6 BASE 984 LD R0 SP,OSHDRPTR R0 -> OS header 03C6B 98560800 1 0 BASE 985 ADDM R1 R0,OSINFOSIZ since we added on more OS info 03C6C 18040001 0 IMM 986 ADD R0 TAPHDR1000L move to OS header 03C6D 1C440004 1 IMM 987 MUL R1 CPW we want length in chars 03C6E E4481F11 1 0 ZBM 988 ST R1 R0,BKUPHDRW2/SNDBKUPLEN set CCB length 989 03C6F DC403466 990 CALLNP PAGERETURN return the page 991 * \ / 992 00003C70 993 NOCODE LABEL 994 * Finish up by putting the length in the file header and 995 * returning the PREL which contains the FDE. 03C70 6012C000 0 3 REG 996 LD R0 R3 copy R3 03C71 10178801 0 6 BASE 997 SUB R0 SP,FILEBEGPTR subtract starting address 03C72 60578801 1 6 BASE 998 LD R1 SP,FILEBEGPTR R1 -> beginning of file 03C73 E4086100 0 1 ZBM 999 ST R0 R1,LOGRECIFL put length into header 03C74 98096101 0 5 ZBM 1000 ADDM R0 R5,PRELPRLEN increase our current physical record size 1001 00003C75 1002 CLEANUP LABEL 03C75 E1578803 5 6 BASE 1003 EXCH R5 SP,FILPRELPTR save PREL pointer and get pointer to FDE 03C76 DC403471 1004 CALLNP PRELRETURN return the free PREL 03C77 61578803 5 6 BASE 1005 LD R5 SP,FILPRELPTR restore PREL pointer 03C78 5D1F8005 6 STAK 1006 LEAVE POP 1007 * --- 1008 00003C79 1009 KILLFILE LABEL 03C79 60D78801 3 6 BASE 1010 LD R3 SP,FILEBEGPTR go to the start of this record 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 150 (DTTPACK) F 20 Pack a Logical File Record 03C7A DC403CEA 1011 CALLNP PACKERROR put in an error logical record 03C7B FE0E3C75 1012 JMP CLEANUP then clean up and leave 1013 * --- 1014 1015 END PACKFILE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 151 (DTTPACK) F 20 File Block Packing Subroutines 1018 1019 ********************************************************************************** 1020 * * 1021 * PACKFASTBL -- Pack a fast format file block * 1022 * * 1023 * There are two ways to pack file data pages into * 1024 * physical records. One is to stuff them into existing * 1025 * physical records and the other is to have a physical record * 1026 * of just file data pages and page align the file pages in * 1027 * the physical record. The latter is the "FAST" method and * 1028 * what we do in this subroutine. * 1029 * All of the OS headers and FBIs are placed on a page * 1030 * mapped into PACKWNDO2. FASTFBIPTR points to the next * 1031 * location available in this page for a header/FBI. * 1032 * FASTFBIMCB points to the MCB for this page. When this * 1033 * physical record is full, or is used for another purpose the * 1034 * FBI MCB pointer is placed into the PREL for this physical * 1035 * record. * 1036 * Call: * 1037 * R4 -> MCB of file page * 1038 * R5 -> PREL for current fast format physical record or R5 = 0 * 1039 * if there is no current physical record. * 1040 * CALLNP PACKFASTBL * 1041 * R5 -> PREL for current fast format physical record or R5 = 0 * 1042 * if there is no current physical record. * 1043 * * 1044 * Eats R0:R4 * 1045 * * 1046 ********************************************************************************** 1047 1048 PACKFASTBL BLOCK 1049 1050 ENTRY PACKFASTBL 1051 1052 BEGFRAME 00178801 6 BASE 1053 FASTR4 BSS 1 safety place for R4 1054 ENDFRAME 1055 03C7C DD5F8002 6 STAK 1056 PACKFASTBL ENTRNP PUSH 03C7D D0004906 1057 INC FPSEQNUM another file page is going in 03C7E FB4C3C98 5 1058 JNEZ R5 HAVEPREL record is already started 1059 * \ / 1060 03C7F E5178801 4 6 BASE 1061 ST R4 SP,FASTR4 save pointer to page we are packing 03C80 DC003D64 1062 CALL PRELANDPAG start a new physical record 03C81 400097F0 1063 PARL FASTHDRLOC where we want to start the physical header 03C82 DC003D44 1064 CALL GETPACKPAG get a page to put FBIs on 03C83 404400A4 IMM 1065 PARVL PKPNWNDO2 we will use window 2 03C84 E500492D 4 1066 ST R4 FASTFBIMCB save MCB pointer 03C85 60040002 0 IMM 1067 LD R0 FASTFORM code for fast format 03C86 E4004908 0 1068 ST R0 CPRFORM is now the current record format 1069 1070 * Determine encryption format, set code in PREL, and change in 1071 * physical record header if necessary. 03C87 60040002 0 IMM 1072 LD R0 ENCRNORM normal encryption code 03C88 5C00490A 1073 CMZ ACCTENCR see if we are encrypting this account 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 152 (DTTPACK) F 20 File Block Packing Subroutines 03C89 FE0C3C8D 1074 JNE SETENCR if so set our encryption code 1075 * \ / 03C8A 600497F0 0 IMM 1076 LD R0 FASTPHSHDR R0 -> physical record header 03C8B EC080012 0 ZBM 1077 STZ R0,PHSNCRYPTD set flag in physical record header 03C8C 60040003 0 IMM 1078 LD R0 ENCRNONE else get no encrypting code 00003C8D 1079 SETENCR LABEL 03C8D E4094C20 0 5 ZBM 1080 ST R0 R5,PRELENCRY set the encryption code 1081 03C8E 60049000 0 IMM 1082 LD R0 ADR PACKWNDO2 R0 -> beginning of FBI buffer 03C8F E400492E 0 1083 ST R0 FASTFBIPTR so we will know where to move stuff 03C90 60C497F7 3 IMM 1084 LD R3 FASTPHSHDR+PHSHDRLEN R3 -> start of fast format record header 03C91 DC403CDC 1085 CALLNP FILEBLHDR build the logical record header 03C92 EC168800 2 BASE 1086 STZ R2,OSINFOSIZ no OS information yet 1087 03C93 60040009 0 IMM 1088 LD R0 FIPRECLEN+TAPHDR1000L length of the headers 03C94 E408E100 0 3 ZBM 1089 ST R0 R3,LOGRECIFL put length in record header 03C95 60040010 0 IMM 1090 LD R0 FIPRECLEN+PHSHDRLEN+TAPHDR1000L length of the headers 03C96 E4096101 0 5 ZBM 1091 ST R0 R5,PRELPRLEN start the length counter 03C97 61178801 4 6 BASE 1092 LD R4 SP,FASTR4 R4 -> page we are packing 1093 * \ / 1094 00003C98 1095 HAVEPREL LABEL 1096 * put in file block and increment the count in the header 03C98 D0004909 1097 INC CPRPN in case we switch to normal format 03C99 60C497F7 3 IMM 1098 LD R3 FASTPHSHDR+PHSHDRLEN R3 -> start of fast format record header 03C9A D008C084 3 ZBM 1099 INC R3,NUMBPAGES say we are putting in another page 03C9B 6004040D 0 IMM 1100 LD R0 FASTRECLEN how big a fast file page record is 03C9C 9808E100 0 3 ZBM 1101 ADDM R0 R3,LOGRECIFL increase count in record header 03C9D 18C40008 3 IMM 1102 ADD R3 FIPRECLEN R3 -> beginning of OS header header 03C9E 9816C800 0 3 BASE 1103 ADDM R0 R3,OSINFOSIZ increase this size count, too 03C9F 98096101 0 5 ZBM 1104 ADDM R0 R5,PRELPRLEN increment current physical record size 1105 03CA0 60094041 0 5 ZBM 1106 LD R0 R5,PRELMCBCNT get index to space for a MCB pointer 03CA1 D0094041 5 ZBM 1107 INC R5,PRELMCBCNT move up our count of MCB pointers 03CA2 E51D4003 4 50 BASE 1108 ST R4 R5,PRELMCBPTR(R0) in it goes 1109 1110 * make OS header 03CA3 60C0492E 3 1111 LD R3 FASTFBIPTR where to start the OS header 03CA4 6092C000 2 3 REG 1112 LD R2 R3 keep a copy 03CA5 DC003CFB 1113 CALL MAKEOSHDR 03CA6 40440004 IMM 1114 PARVL FILEINFOTM file page type 03CA7 38170802 0 4 BASE 1115 LEA R0 R4,MCBFBI R0 -> FBI 03CA8 60481184 1 0 ZBM 1116 LD R1 R0,FBIRELBLK get relative block number 03CA9 E4488141 1 2 ZBM 1117 ST R1 R2,BKUPHDRW2/PGNUMFLD put in OS header 03CAA 60490810 1 4 ZBM 1118 LD R1 R4,MCBWPRT get the write protect bit 03CAB FC488011 1 2 ZBM 1119 IORM R1 R2,BKUPHDRW2/CCBPROTECT mix in with the relative block number 1120 1121 * Move in the FBI, R0 -> to it 03CAC 6044002C 1 IMM 1122 LD R1 FBILNTH*CPW how much there is 03CAD 6092C000 2 3 REG 1123 LD R2 R3 R2 points to current place in FBI buffer 03CAE FE400000 1124 CMOVE move the FBI into the record 03CAF E480492E 2 1125 ST R2 FASTFBIPTR keep this current 1126 03CB0 6000483B 0 1127 LD R0 PHYSRECSIZ how big our record can get 03CB1 10096101 0 5 ZBM 1128 SUB R0 R5,PRELPRLEN see how much room is left 03CB2 6404040D 0 IMM 1129 CPR R0 FASTRECLEN is there enough for another block? 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 153 (DTTPACK) F 20 File Block Packing Subroutines 03CB3 FE063CB9 1130 JGE FASTEND if so then don't put PREL in encrypt queue 1131 * \ / 1132 03CB4 60C400A4 3 IMM 1133 LD PFPTR PKPNWNDO2 where the FBIs are hanging out 03CB5 80D20000 0 REG 1134 PFRC R0 clear the page file 03CB6 604497F0 1 IMM 1135 LD R1 FASTPHSHDR R1 -> physical record header 03CB7 EDC84212 1 ZBM 1136 STW R1,PHSFILEDO say just file page data here 03CB8 DC403DB1 1137 CALLNP LINKINENCR put this in the encryption queue 1138 * \ / 1139 00003CB9 1140 FASTEND LABEL 03CB9 5D1F8002 6 STAK 1141 LEAVE POP 1142 * --- 1143 1144 END PACKFASTBL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 154 (DTTPACK) F 20 File Block Packing Subroutines 1146 1147 ********************************************************************************** 1148 * * 1149 * PACKNORMBL -- Pack a file block using normal format * 1150 * * 1151 * We arrive here when there is enough space in the * 1152 * current physical record to pack in a file block, the * 1153 * packing format is normal (i.e. header followed by just * 1154 * one file block), and the encryption type is compatible. * 1155 * * 1156 * Call: * 1157 * R3 -> position in physical record * 1158 * R4 -> MCB of file page * 1159 * R5 -> PREL of current physical record * 1160 * CALLNP PACKNORMBL * 1161 * R3 -> position in physical record * 1162 * R5 -> PREL of current physical record * 1163 * * 1164 * Eats R0:R4 * 1165 * * 1166 ********************************************************************************** 1167 1168 PACKNORMBL BLOCK 1169 1170 ENTRY PACKNORMBL 1171 1172 BEGFRAME 00178801 6 BASE 1173 NORMR4 BSS 1 temp for R4 while we get a working page 1174 ENDFRAME 1175 03CBA DD5F8002 6 STAK 1176 PACKNORMBL ENTRNP PUSH 03CBB E5178801 4 6 BASE 1177 ST R4 SP,NORMR4 save pointer to MCB 03CBC DC003D31 1178 CALL ENUFPAGE get us enough pages mapped 03CBD 40440416 IMM 1179 PARVL FILBLKRECL how much we need 03CBE D0004906 1180 INC FPSEQNUM another file page is going in 03CBF DC403CDC 1181 CALLNP FILEBLHDR build a file block header 03CC0 EDC8C084 3 ZBM 1182 STW R3,NUMBPAGES say one page in this record 03CC1 60040416 0 IMM 1183 LD R0 FILBLKRECL file page record length 03CC2 E408E100 0 3 ZBM 1184 ST R0 R3,LOGRECIFL put length in record header 03CC3 98096101 0 5 ZBM 1185 ADDM R0 R5,PRELPRLEN bump up the size of this physical record 1186 1187 * Build the OS header header 03CC4 6004040D 0 IMM 1188 LD R0 FASTRECLEN size of info put in by the OS 03CC5 E4168800 0 2 BASE 1189 ST R0 R2,OSINFOSIZ put this in OS header header 03CC6 18840001 2 IMM 1190 ADD R2 TAPHDR1000L move beyond this header 1191 1192 * First the block 03CC7 61178801 4 6 BASE 1193 LD R4 SP,NORMR4 restore pointer to MCB 03CC8 60C400A3 3 IMM 1194 LD PFPTR PKPNWNDO1 page number for window 1 03CC9 00D70801 4 BASE 1195 LDPF R4,MCBPMV map in the page 03CCA 60441000 1 IMM 1196 LD R1 CPP how many chars to move 03CCB 60048C00 0 IMM 1197 LD R0 ADR PACKWNDO1 where they are 03CCC FE400000 1198 CMOVE R2 set by FILEBLHDR 03CCD 80D20000 0 REG 1199 PFRC R0 unmap the page 1200 1201 * Now put in the OS header 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 155 (DTTPACK) F 20 File Block Packing Subroutines 03CCE 60D28000 3 2 REG 1202 LD R3 R2 get current position 03CCF DC003CFB 1203 CALL MAKEOSHDR make an OS header 03CD0 40440004 IMM 1204 PARVL FILEINFOTM data page type 03CD1 38170802 0 4 BASE 1205 LEA R0 R4,MCBFBI R0 -> FBI 03CD2 60481184 1 0 ZBM 1206 LD R1 R0,FBIRELBLK get relative block number 03CD3 E4488141 1 2 ZBM 1207 ST R1 R2,BKUPHDRW2/PGNUMFLD put in OS header 03CD4 60490810 1 4 ZBM 1208 LD R1 R4,MCBWPRT get the write protect bit 03CD5 FC488011 1 2 ZBM 1209 IORM R1 R2,BKUPHDRW2/CCBPROTECT mix in with the relative block number 1210 1211 * now the FBI 03CD6 6044002C 1 IMM 1212 LD R1 FBILNTH*CPW number of chars in FBI 03CD7 6092C000 2 3 REG 1213 LD R2 R3 R2 -> where to put FBI 03CD8 FE400000 1214 CMOVE move the suckers in 03CD9 60D28000 3 2 REG 1215 LD R3 R2 R3 -> end of record 03CDA DC403466 1216 CALLNP PAGERETURN return this page to the free list 03CDB 5D1F8002 6 STAK 1217 LEAVE POP 1218 * --- 1219 1220 END PACKNORMBL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 156 (DTTPACK) F 20 File Block Packing Subroutines 1222 1223 ********************************************************************************** 1224 * * 1225 * FILEBLHDR -- Build a File Block Header * 1226 * * 1227 * Builds a file data page header. * 1228 * Call: * 1229 * R3 -> position in record to put the header * 1230 * R4 -> MCB of block being put in * 1231 * CALLNP FILEBLHDR * 1232 * * 1233 * Returns R2 -> word in record beyond header * 1234 * Eats R0:R2 * 1235 * * 1236 ********************************************************************************** 1237 1238 FILEBLHDR BLOCK 1239 1240 ENTRY FILEBLHDR 1241 1242 BEGFRAME 1243 ENDFRAME 1244 03CDC DD5F8001 6 STAK 1245 FILEBLHDR ENTRNP PUSH 03CDD DC003CF7 1246 CALL PACKLOGREC build the logical record header 03CDE 40440006 IMM 1247 PARVL RTYPEFP type is file page 03CDF 6200490B 01 1248 LD2 R0 PACKACCTSN get the account serial number 03CE0 E616C801 013 BASE 1249 ST2 R0 R3,DATAACTSER put in the header 03CE1 BC004907 0 1250 INCL R0 FPLRSEQNUM get this file page logical record's sequence # 03CE2 E416C803 0 3 BASE 1251 ST R0 R3,DATASEQNUM put in the block's sequence number 03CE3 EC16C804 3 BASE 1252 STZ R3,NUMBERWORD clear out this word, includes NUMBPAGES 03CE4 60004906 0 1253 LD R0 FPSEQNUM current file page's sequence number 03CE5 E408D184 0 3 ZBM 1254 ST R0 R3,DATAPAGESN put this in the record 03CE6 3896C805 2 3 BASE 1255 LEA R2 R3,DATAFILL R2 -> start of filler 03CE7 6044000C 1 IMM 1256 LD R1 DATAFILLEN*CPW how many chars of filler 03CE8 FE580000 1257 CFILL 00 make sure it is clean 03CE9 5D1F8001 6 STAK 1258 LEAVE POP 1259 * --- 1260 1261 END FILEBLHDR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 157 (DTTPACK) F 20 File Block Packing Subroutines 1263 1264 ********************************************************************************** 1265 * * 1266 * PACKERROR * 1267 * * 1268 * This subroutine simply builds an error element. * 1269 * Call: * 1270 * CALLNP PACKERROR * 1271 * * 1272 * Returns R3 -> next position in the record * 1273 * Returns R5 -> PREL of current physical record * 1274 * Eats R0:R5 * 1275 * * 1276 ********************************************************************************** 1277 1278 PACKERROR BLOCK 1279 1280 ENTRY PACKERROR 1281 1282 BEGFRAME 1283 ENDFRAME 1284 03CEA DD5F8001 6 STAK 1285 PACKERROR ENTRNP PUSH 03CEB E1134000 4 5 REG 1286 EXCH R4 R5 R5 -> PREL with error indicator 03CEC DC403471 1287 CALLNP PRELRETURN return it to available ones 03CED 61530000 5 4 REG 1288 LD R5 R4 restore R5 03CEE DC003D03 1289 CALL CHEK4ROOM clean up physical record 03CEF 4147FFFF IMM 1290 PARV -1 indicate not to check encryption type 03CF0 40440001 IMM 1291 PARVL ERRRECLEN how much space we need 03CF1 DC003CF7 1292 CALL PACKLOGREC build the logical record header 03CF2 40440007 IMM 1293 PARVL RTYPEERR error record 03CF3 60040001 0 IMM 1294 LD R0 ERRRECLEN length of this record 03CF4 E408E100 0 3 ZBM 1295 ST R0 R3,LOGRECIFL put in the header 03CF5 1812C000 0 3 REG 1296 ADD R0 R3 move current record pointer 03CF6 5D1F8001 6 STAK 1297 LEAVE POP 1298 * --- 1299 1300 END PACKERROR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 158 (DTTPACK) F 20 Header Builders 1303 1304 ********************************************************************************** 1305 * * 1306 * PACKLOGREC -- Build Logical Record Header * 1307 * * 1308 * This subroutine builds a logical record header. It * 1309 * sets the logical record type and sets the out of order and * 1310 * file busy flags to false. We do not set the logical record * 1311 * size here. * 1312 * Call: * 1313 * LD R3 ADR * 1314 * CALL PACKLOGREC * 1315 * PARVL record type * 1316 * * 1317 * Eats R0 * 1318 * * 1319 ********************************************************************************** 1320 1321 PACKLOGREC BLOCK 1322 1323 ENTRY PACKLOGREC 1324 1325 BEGFRAME 1326 ENDFRAME 1327 03CF7 DD1F8001 6 STAK 1328 PACKLOGREC ENTR PUSH 03CF8 EC16C800 3 BASE 1329 STZ R3,LOGRECCWD zero the header word 03CF9 C048D650 3 ZBM 1330 STPVL R3,LOGRECTYP set the record type 03CFA 5D1F8001 6 STAK 1331 LEAVE POP 1332 * --- 1333 1334 END PACKLOGREC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 159 (DTTPACK) F 20 Header Builders 1336 1337 ********************************************************************************** 1338 * * 1339 * MAKEOSHDR * 1340 * * 1341 * This subroutine builds the OS header, fondly referred * 1342 * to in the definitions as "another f___ing header". The * 1343 * header word is packed in R1 then stored as a whole word * 1344 * into memory. This prevents parity error halts when running * 1345 * on uninitialized memory. * 1346 * Call: * 1347 * R3 -> position in record * 1348 * CALL MAKEOSHDR * 1349 * PARVL info type * 1350 * Returns R3 -> position in record beyond OS header. * 1351 * Eats R0, R1 * 1352 * * 1353 ********************************************************************************** 1354 1355 MAKEOSHDR BLOCK 1356 1357 ENTRY MAKEOSHDR 1358 1359 BEGFRAME 1360 ENDFRAME 1361 03CFB DD1F8001 6 STAK 1362 MAKEOSHDR ENTR PUSH 03CFC C04A40F0 1 CBM 1363 STPVL R1/FILEINFOT get the type field 03CFD 60040000 0 IMM 1364 LD R0 REVBACKUP get backup format code 03CFE E40A5F10 0 1 CBM 1365 ST R0 R1/BKUPREV make combined word 03CFF E456C800 1 3 BASE 1366 ST R1 R3,BKUPHDRW1 now place into record 03D00 EC16C801 3 BASE 1367 STZ R3,BKUPHDRW2 no variable length fields here 03D01 18C40002 3 IMM 1368 ADD R3 BKUPHDRLEN R3 -> beyond the header 03D02 5D1F8001 6 STAK 1369 LEAVE POP 1370 * --- 1371 1372 END MAKEOSHDR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 160 (DTTPACK) F 20 Physical Record Space Checkers 1375 1376 ********************************************************************************** 1377 * * 1378 * CHEK4ROOM -- Check for room in CPR * 1379 * * 1380 * CHEK4ROOM makes sure there is enough room in a * 1381 * physical record for logical record to fit and for a * 1382 * compatible encryption format. If either of these does not * 1383 * match then the physical record is shipped to the encrypt * 1384 * queue and a new one is started. * 1385 * We also see if the fast format is being used and if * 1386 * so, convert it to normal format. * 1387 * * 1388 * Call: * 1389 * R5 -> PREL * 1390 * R3 -> current position in physical record * 1391 * CALL CHEK4ROOM * 1392 * PARV (-1 => don't check encryption type) * 1393 * PARVL * 1394 * * 1395 * Returns R5 -> PREL * 1396 * R3 -> current position in physical record * 1397 * Physical record header initialized. * 1398 * Eats R0:R2 * 1399 * * 1400 ********************************************************************************** 1401 1402 CHEK4ROOM BLOCK 1403 1404 ENTRY CHEK4ROOM 1405 1406 BEGFRAME 00178801 6 BASE 1407 CHEKENCRT BSS 1 encrypt type code 1408 ENDFRAME 1409 03D03 DD1F8002 6 STAK 1410 CHEK4ROOM ENTR PUSH 03D04 C1578801 6 BASE 1411 STPV SP,CHEKENCRT desired encryption format 03D05 C0524000 1 REG 1412 STPVL R1 max size of record 03D06 FB423D21 5 1413 JEQZ R5 NOCURPREL R5 = 0 implies no current PREL 03D07 60178801 0 6 BASE 1414 LD R0 SP,CHEKENCRT get encryption type 03D08 FA2C3D0B 0 1415 JEQMW R0 ANYENCR -1 indicates any encryption is ok 03D09 64094C20 0 5 ZBM 1416 CPR R0 R5,PRELENCRY see if we have the proper encryption format 03D0A FE0C3D20 1417 JNE SENDPREL if not then send the PREL 1418 * \ / 1419 00003D0B 1420 ANYENCR LABEL 03D0B 6000483B 0 1421 LD R0 PHYSRECSIZ maximum size of physical record 03D0C 10096101 0 5 ZBM 1422 SUB R0 R5,PRELPRLEN account for current physical record size 03D0D 64124000 0 1 REG 1423 CPR R0 R1 see if an account logical record will fit 03D0E FE083D20 1424 JLT SENDPREL if not send physical record and start anew 1425 * \ / 1426 03D0F 60004908 0 1427 LD R0 CPRFORM get current record format 03D10 64040002 0 IMM 1428 CPR R0 FASTFORM see if fast format 03D11 FE0C3D1F 1429 JNE CHEK4END if not then all done 03D12 6000492D 0 1430 LD R0 FASTFBIMCB get pointer to FBI page's MCB 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 161 (DTTPACK) F 20 Physical Record Space Checkers 03D13 60494041 1 5 ZBM 1431 LD R1 R5,PRELMCBCNT get index to next space for a MCB pointer 03D14 D0094041 5 ZBM 1432 INC R5,PRELMCBCNT bump up our MCB pointer counter 03D15 E41D4803 0 51 BASE 1433 ST R0 R5,PRELMCBPTR(R1) put FBI's MCB into PREL 03D16 60C400A4 3 IMM 1434 LD PFPTR PKPNWNDO2 where the FBIs are hanging out 03D17 80D20000 0 REG 1435 PFRC R0 get the page map value 03D18 BCC04909 3 1436 INCL PFPTR CPRPN get next physical record page number 03D19 00D20000 0 REG 1437 LDPF R0 map in the FBI page 03D1A 10C40080 3 IMM 1438 SUB R3 MONPF get virtual page number 03D1B E4D048F6 3 @ 1439 ST R3 @FFPNPTR make this point to its new page 03D1C 60C0492E 3 1440 LD R3 FASTFBIPTR current position in physical record 03D1D 60040001 0 IMM 1441 LD R0 NORMFORM return to normal format 03D1E E4004908 0 1442 ST R0 CPRFORM 1443 * \ / 1444 00003D1F 1445 CHEK4END LABEL 03D1F 5D1F8002 6 STAK 1446 LEAVE POP 1447 * --- 1448 00003D20 1449 SENDPREL LABEL 03D20 DC403DB1 1450 CALLNP LINKINENCR link onto the encrypt queue 1451 * \ / 1452 00003D21 1453 NOCURPREL LABEL 03D21 DC003D64 1454 CALL PRELANDPAG get a PREL and page 03D22 40009400 1455 PARL PACKPRPAGE start the header here 03D23 60040001 0 IMM 1456 LD R0 NORMFORM normal format 03D24 E4004908 0 1457 ST R0 CPRFORM because that is what they want 03D25 60178801 0 6 BASE 1458 LD R0 SP,CHEKENCRT get encryption type 03D26 FA2E3D2F 0 1459 JNEMW R0 HAVETYPE jump if we have the correct type 03D27 60040002 0 IMM 1460 LD R0 ENCRNORM if they don't care try using normal 03D28 5C00481C 1461 CMZ ENCRFASTFL are we encrypting everything? 03D29 FE023D2F 1462 JEQ HAVETYPE if so then encryption is correct 03D2A 5C00490A 1463 CMZ ACCTENCR is the current account encrypted? 03D2B FE0C3D2F 1464 JNE HAVETYPE if so then keep this record encrypted 1465 * \ / 1466 03D2C 60040003 0 IMM 1467 LD R0 ENCRNONE otherwise don't encrypt 03D2D 60449400 1 IMM 1468 LD R1 ADR PACKPRPAGE R1 -> beginning of physical record 03D2E EC084012 1 ZBM 1469 STZ R1,PHSNCRYPTD say this physical record is not encrypted 1470 * \ / 1471 00003D2F 1472 HAVETYPE LABEL 03D2F E4094C20 0 5 ZBM 1473 ST R0 R5,PRELENCRY set PR's encryption type 03D30 FE0E3D1F 1474 JMP CHEK4END 1475 * --- 1476 1477 END CHEK4ROOM 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 162 (DTTPACK) F 20 Physical Record Space Checkers 1479 1480 ********************************************************************************** 1481 * * 1482 * ENUFPAGE * 1483 * This subroutine makes sure there is enough room on the * 1484 * currently mapped in page for the caller. If there is not * 1485 * enough it will map another page into the physical record * 1486 * buffer. * 1487 * * 1488 * Call: * 1489 * R3 -> current position in file * 1490 * CALL ENUFPAGE * 1491 * PARVL * 1492 * Eats R0:R2,R4 * 1493 * * 1494 ********************************************************************************** 1495 1496 ENUFPAGE BLOCK 1497 1498 ENTRY ENUFPAGE 1499 1500 BEGFRAME 00178801 6 BASE 1501 SPACENEED BSS 1 how much space is needed 00178802 6 BASE 1502 AVAILABLE BSS 1 how space is available 00178803 6 BASE 1503 ENUFR3 BSS 1 temp to save R3 1504 ENDFRAME 1505 03D31 DD1F8004 6 STAK 1506 ENUFPAGE ENTR PUSH 03D32 C0578801 6 BASE 1507 STPVL SP,SPACENEED how much space we need 03D33 E4D78803 3 6 BASE 1508 ST R3 SP,ENUFR3 save R3 03D34 78C403FF 3 IMM 1509 AND R3 PAGEMASK get amount on current page 03D35 30C40400 3 IMM 1510 RSB R3 WPP see what is left 03D36 FE0E3D40 1511 JMP LOOPTEST enter the loop at the test 1512 * --- 1513 00003D37 1514 GETSPACE LABEL 03D37 E4D78802 3 6 BASE 1515 ST R3 SP,AVAILABLE save how much is there 03D38 BC404909 1 1516 INCL R1 CPRPN get next virtual page number 03D39 DC003D44 1517 CALL GETPACKPAG get a new physical page 03D3A 40524000 1 REG 1518 PARVL R1 page to map it into 03D3B 60094041 0 5 ZBM 1519 LD R0 R5,PRELMCBCNT get index to next space for a MCB pointer 03D3C D0094041 5 ZBM 1520 INC R5,PRELMCBCNT bump up our MCB pointer counter 03D3D E51D4003 4 50 BASE 1521 ST R4 R5,PRELMCBPTR(R0) put in new MCB pointer 03D3E 60D78802 3 6 BASE 1522 LD R3 SP,AVAILABLE get amount of available space 03D3F 18C40400 3 IMM 1523 ADD R3 WPP we have another page of words 00003D40 1524 LOOPTEST LABEL 03D40 64D78801 3 6 BASE 1525 CPR R3 SP,SPACENEED see if we have enough 03D41 FE083D37 1526 JLT GETSPACE if not then get some more 1527 * \ / 03D42 60D78803 3 6 BASE 1528 LD R3 SP,ENUFR3 restore R3 03D43 5D1F8004 6 STAK 1529 LEAVE POP 1530 * --- 1531 1532 END ENUFPAGE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 163 (DTTPACK) F 20 Get a Free Page for Packing Process 1535 1536 ********************************************************************************** 1537 * * 1538 * GETPACKPAG checks the free page count and if a free * 1539 * page exists, gets the MCB for it and returns to the calling * 1540 * process. If there is not a free page available we save the * 1541 * information necessary for restarting the packing process * 1542 * and go to the scheduler. * 1543 * Call: * 1544 * CALL GETPACKPAG * 1545 * PARVL page number to map page into * 1546 * returns with R4 pointing to an available page's MCB * 1547 * Eats R0:R3 (since we may not return immediately) * 1548 * Returns R4 -> MCB * 1549 * * 1550 ********************************************************************************** 1551 1552 GETPACKPAG BLOCK 1553 1554 ENTRY GETPACKPAG 1555 ENTRY GETPACKPAGL 1556 1557 BEGFRAME 00178801 6 BASE 1558 PAGENUM BSS 1 page number to map page into 1559 ENDFRAME 1560 03D44 DD1F8002 6 STAK 1561 GETPACKPAG ENTR PUSH 03D45 C0578801 6 BASE 1562 STPVL SP,PAGENUM save the page number to map into 00003D46 1563 GETPACKPAGL LABEL label for the restart 1564 LLOCK PAGEQLOCK need exclusive use of this list 03D4A 60004819 0 1565 LD R0 PACKMINPAG minimum number of pages for pack process 03D4B 64004806 0 1566 CPR R0 FREEPGCNT see if we have enough free pages 03D4C FE063D51 1567 JGE NOPAGES if not save state and switch processes 1568 * \ / 1569 03D4D DC40344C 1570 CALLNP UNLINKPAGE remove the page from the list 03D4E 60D78801 3 6 BASE 1571 LD PFPTR SP,PAGENUM page number to map page into 03D4F 00D70801 4 BASE 1572 LDPF R4,MCBPMV physical page to map in 03D50 5D1F8002 6 STAK 1573 LEAVE POP return to caller 1574 * --- 1575 00003D51 1576 NOPAGES LABEL 03D51 EC004805 1577 STZ PAGEQLOCK release the lock 03D52 FA283DA7 0 1578 JSR R0 SAVEPACKST save our present state 03D53 FE0E3D46 1579 JMP GETPACKPAGL address to start over at 1580 * --- 1581 1582 END GETPACKPAG 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 164 (DTTPACK) F 20 Get a free PREL for packing process 1585 1586 ********************************************************************************** 1587 * * 1588 * GTPACKPREL * 1589 * * 1590 * This routine checks for a free PREL and if there is * 1591 * one removes it from the list and returns to the caller. If * 1592 * there is not one, it saves the current state and jumps to * 1593 * the scheduler. * 1594 * Call: * 1595 * CALLNP GTPACKPREL * 1596 * returns with R5 -> to PREL * 1597 * Eats R0:R3 since we may not return for awhile. * 1598 * * 1599 ********************************************************************************** 1600 1601 GTPACKPREL BLOCK 1602 1603 ENTRY GTPACKPREL 1604 1605 BEGFRAME 1606 ENDFRAME 1607 03D54 DD5F8001 6 STAK 1608 GTPACKPREL ENTRNP PUSH 00003D55 1609 ONCEAGAIN LABEL 03D55 60040005 0 IMM 1610 LD R0 MINPCKPREL minimum number of PRELs for packing 1611 LLOCK PRELQLOCK need exclusive use of this list 03D5A 64004809 0 1612 CPR R0 FREEPRELCT see if we have enough free pages 03D5B FE043D61 1613 JGT NOPRELS if not save state and switch processes 1614 * \ / 1615 03D5C DC403454 1616 CALLNP UNLINKPREL get the PREL from the list 03D5D 60040000 0 IMM 1617 LD R0 TPREL code for use as PREL 03D5E E4094040 0 5 ZBM 1618 ST R0 R5,PRELTYPE code for use as PREL 03D5F EC004908 1619 STZ CPRFORM no current format 03D60 5D1F8001 6 STAK 1620 LEAVE POP return to caller 1621 * --- 1622 00003D61 1623 NOPRELS LABEL 03D61 EC004808 1624 STZ PRELQLOCK release the lock 03D62 FA283DA7 0 1625 JSR R0 SAVEPACKST save the process state 03D63 FE0E3D55 1626 JMP ONCEAGAIN where to restart the process 1627 * --- 1628 1629 END GTPACKPREL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 165 (DTTPACK) F 20 Get a PREL and Page 1632 1633 ********************************************************************************** 1634 * * 1635 * PRELANDPAG * 1636 * * 1637 * This subroutine gets a free PREL and page, maps the * 1638 * page into PACKPRPAGE, builds the physical record header, * 1639 * and sets the current physical record page number (CPRPN). * 1640 * Call: * 1641 * CALL PRELANDPAG * 1642 * PARL * 1643 * * 1644 * Returns R3 pointing to first word past physical record header. * 1645 * Eats R0:R2. * 1646 * * 1647 ********************************************************************************** 1648 1649 PRELANDPAG BLOCK 1650 1651 ENTRY PRELANDPAG 1652 1653 BEGFRAME 00178801 6 BASE 1654 HEADERLOC BSS 1 location to start physical record header 1655 ENDFRAME 1656 03D64 DD1F8002 6 STAK 1657 PRELANDPAG ENTR PUSH 03D65 C0178801 6 BASE 1658 STPL SP,HEADERLOC 03D66 DC003D44 1659 CALL GETPACKPAG get a page to build this record in 03D67 404400A5 IMM 1660 PARVL PACKPRPN put it in our first physical record page 03D68 600400A5 0 IMM 1661 LD R0 PACKPRPN get the page virtual page number 03D69 E4004909 0 1662 ST R0 CPRPN set the current physical record page number 03D6A DC403D54 1663 CALLNP GTPACKPREL get a PREL for this physical record 03D6B E5174803 4 5 BASE 1664 ST R4 R5,PRELMCBPTR put pointer to MCB into the PREL 03D6C EDC94041 5 ZBM 1665 STW R5,PRELMCBCNT one MCB in PREL 03D6D 60178801 0 6 BASE 1666 LD R0 SP,HEADERLOC where to start header 03D6E DC003D75 1667 CALL PHYSHDR build the physical record header 03D6F 40520000 0 REG 1668 PARVL R0 header starting address 03D70 60C40007 3 IMM 1669 LD R3 PHSHDRLEN size of physical record header 03D71 E4C96101 3 5 ZBM 1670 ST R3 R5,PRELPRLEN current size of physical record 03D72 18D78801 3 6 BASE 1671 ADD R3 SP,HEADERLOC R3 -> next word of record 03D73 EC16C801 3 BASE 1672 STZ R3,HDRTYPWRD1 eliminate parity errors 03D74 5D1F8002 6 STAK 1673 LEAVE POP 1674 * --- 1675 1676 END PRELANDPAG 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 166 (DTTPACK) F 20 Physical Record Header Builder 1679 1680 ********************************************************************************** 1681 * * 1682 * PHYSHDR -- Build Physical Record Header * 1683 * * 1684 * This subroutine builds a physical record header * 1685 * starting it at the location passed to it. The physical * 1686 * record header is zeroed then the physical record * 1687 * sequence number is placed in the header. * 1688 * Call: * 1689 * R5 => PREL * 1690 * CALL PHYSHDR * 1691 * PARVL * 1692 * element from PRPQ or zero if queue is empty * 1735 * * 1736 * Eats R0:R2,R4 * 1737 * * 1738 ********************************************************************************** 1739 1740 GETNEXPRPQ BLOCK 1741 1742 ENTRY GETNEXPRPQ 1743 1744 BEGFRAME 00178801 6 BASE 1745 GETNEXR3 BSS 1 temp for saving R3 1746 ENDFRAME 1747 03D81 DD5F8002 6 STAK 1748 GETNEXPRPQ ENTRNP PUSH 00003D82 1749 GETLOCK LABEL 1750 LLOCK PRPQLOCK 03D86 6100480A 4 1751 LD R4 PRPQHEAD get the first element in the list 03D87 FB023D90 4 1752 JEQZ R4 EMPTYQ jump if nothing is there 03D88 60091F10 0 4 ZBM 1753 LD R0 R4,MCBLINK pointer to next element in list 03D89 E400480A 0 1754 ST R0 PRPQHEAD make the next element the head 03D8A FA023D8D 0 1755 JEQZ R0 LASTELEM if last element in the list, change tail 00003D8B 1756 GETPRPQEND LABEL 03D8B EC00480C 1757 STZ PRPQLOCK unlock the list 03D8C 5D1F8002 6 STAK 1758 LEAVE POP 1759 * --- 1760 00003D8D 1761 LASTELEM LABEL 03D8D 6004480A 0 IMM 1762 LD R0 ADR PRPQHEAD RO -> PRPQ's head 03D8E E400480B 0 1763 ST R0 PRPQTAIL make the tail point to the head 03D8F FE0E3D8B 1764 JMP GETPRPQEND 1765 * --- 1766 00003D90 1767 EMPTYQ LABEL 03D90 EC00480C 1768 STZ PRPQLOCK release list 03D91 E4D78801 3 6 BASE 1769 ST R3 SP,GETNEXR3 save R3 03D92 FA283DA7 0 1770 JSR R0 SAVEPACKST off to see the scheduler 03D93 60D78801 3 6 BASE 1771 LD R3 SP,GETNEXR3 restore R3 03D94 FE0E3D82 1772 JMP GETLOCK get the lock again 1773 * --- 1774 1775 END GETNEXPRPQ 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 168 (DTTPACK) F 20 Get Next Element from PRPQ 1777 1778 ********************************************************************************** 1779 * * 1780 * MAPNEXPRPQ * 1781 * This subroutine picks the next element from the PRPQ, * 1782 * makes sure it is the correct element, and maps it into the * 1783 * desired page. * 1784 * Call: * 1785 * CALL MAPNEXPRPQ * 1786 * PARV * 1787 * PARVL * 1788 * JMP error element found * 1789 * * 1790 * Returns R4 -> MCB and page mapped in. * 1791 * Eats R0:R4 * 1792 * * 1793 ********************************************************************************** 1794 1795 MAPNEXPRPQ BLOCK 1796 1797 ENTRY MAPNEXPRPQ 1798 1799 BEGFRAME 00178801 6 BASE 1800 PAGENUM BSS 1 page number to map page into 00178802 6 BASE 1801 MAPFBIT BSS 1 type of FBI expected 1802 ENDFRAME 1803 03D95 DD1F8003 6 STAK 1804 MAPNEXPRPQ ENTR PUSH 03D96 C1578801 6 BASE 1805 STPV SP,PAGENUM 03D97 C0578802 6 BASE 1806 STPVL SP,MAPFBIT 1807 03D98 DC403D81 1808 CALLNP GETNEXPRPQ get the next element from the PRPQ 03D99 60090040 0 4 ZBM 1809 LD R0 R4,MCBTYPE make sure we have the right entry 03D9A 64040002 0 IMM 1810 CPR R0 TMCB code for MCB 03D9B FE0C3DA4 1811 JNE BADENTRY 03D9C 38170802 0 4 BASE 1812 LEA R0 R4,MCBFBI R3 -> FBI 03D9D 60080080 0 0 ZBM 1813 LD R0 R0,FBITYPE extract the type 03D9E 64178802 0 6 BASE 1814 CPR R0 SP,MAPFBIT make sure it is the right block 03D9F FE0C3DA6 1815 JNE BADBLOCK 03DA0 60D78801 3 6 BASE 1816 LD PFPTR SP,PAGENUM page number to map block into 03DA1 00D70801 4 BASE 1817 LDPF R4,MCBPMV map it in 1818 * \ / 03DA2 19C40001 7 IMM 1819 ADD R7 1 good return 00003DA3 1820 ERRETURN LABEL 03DA3 5D1F8003 6 STAK 1821 LEAVE POP 1822 * --- 1823 00003DA4 1824 BADENTRY LABEL 03DA4 64040007 0 IMM 1825 CPR R0 TERROR see if it is an error element 03DA5 FE023DA3 1826 JEQ ERRETURN ok (sort of) if it is 1827 * \ / 00003DA6 1828 BADBLOCK LABEL 03DA6 00173213 1829 HALT HALTW3213 bad entry in PRPQ, wrong FBI type 1830 * --- 1831 1832 END MAPNEXPRPQ 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 169 (DTTPACK) F 20 Save State Routine for Packing Process 1835 1836 ********************************************************************************** 1837 * * 1838 * SAVEPACKST * 1839 * * 1840 * This routine saves the information needed to restore * 1841 * the packing process then exits to the scheduler. * 1842 * Call: * 1843 * JSR R0 SAVEPACKST * 1844 * Eats R0:R3. * 1845 * * 1846 ********************************************************************************** 1847 1848 SAVEPACKST BLOCK 1849 1850 ENTRY SAVEPACKST 1851 00003DA7 1852 SAVEPACKST LABEL 03DA7 E4004900 0 1853 ST R0 PACKPC and save for start up 03DA8 E7804901 67 1854 ST2 SP PACKSPR7 save the stack pointer and R7 03DA9 E7004903 45 1855 ST2 R4 PACKR4R5 save R4 and R5 1856 * \ / 1857 03DAA 6047FFF2 1 IMM 1858 LD R1 -PACKPMVTABL number of page map values to unload 03DAB 60C400A3 3 IMM 1859 LD PFPTR PROCPN starting page map location 00003DAC 1860 UNLOADPMV LABEL 03DAC 80D20000 0 REG 1861 PFRC R0 unload it 03DAD E422493D 0 1 1862 ST R0 PACKPMVTAB(PACKPMVTABL)(R1) save a page map value 03DAE 18C40001 3 IMM 1863 ADD PFPTR 1 move to next page file location 03DAF FA603DAC 1 1864 IRJ R1 UNLOADPMV unload the next one 1865 * \ / 1866 03DB0 FE0E318F 1867 JMP DONEPACK return to scheduler 1868 * --- 1869 1870 END SAVEPACKST 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 170 (DTTPACK) F 20 Encrypt Queue Linker 1873 1874 ********************************************************************************** 1875 * * 1876 * Subroutine to link a PREL onto the encryption queue. * 1877 * If the physical record is "fast" format we put the pointer * 1878 * to the MCB into the PREL before linking the PREL into the * 1879 * encryption queue. * 1880 * Call: * 1881 * LD R5 ADR PREL * 1882 * CALLNP LINKINENCR * 1883 * Returns R5 = 0 * 1884 * Eats R0:R1. * 1885 * * 1886 ********************************************************************************** 1887 1888 LINKINENCR BLOCK 1889 1890 ENTRY LINKINENCR 1891 1892 BEGFRAME 1893 ENDFRAME 1894 03DB1 DD5F8001 6 STAK 1895 LINKINENCR ENTRNP PUSH 03DB2 60004908 0 1896 LD R0 CPRFORM see if we need to finish up a fast format 03DB3 64040002 0 IMM 1897 CPR R0 FASTFORM well, do we? 03DB4 FE0C3DB9 1898 JNE NOTFAST jump if not 1899 * \ / 03DB5 6000492D 0 1900 LD R0 FASTFBIMCB get pointer to FBI page's MCB 03DB6 60494041 1 5 ZBM 1901 LD R1 R5,PRELMCBCNT get index to space for a MCB pointer 03DB7 D0094041 5 ZBM 1902 INC R5,PRELMCBCNT move up our count of MCB pointers 03DB8 E41D4803 0 51 BASE 1903 ST R0 R5,PRELMCBPTR(R1) put FBI's MCB into PREL 1904 * \ / 1905 00003DB9 1906 NOTFAST LABEL 03DB9 EC095F10 5 ZBM 1907 STZ R5,PRELLINK new PREL doesn't point anywhere 1908 LLOCK ENCRYLOCK get the list locked 03DBE 6000480E 0 1909 LD R0 ENCRYQTL want to link this on the tail 03DBF E5481F10 5 0 ZBM 1910 ST R5 R0,PRELLINK make the old tail point to the new PREL 03DC0 E540480E 5 1911 ST R5 ENCRYQTL now the new PREL is the tail 03DC1 D000480F 1912 INC ENCRQCNT say another element in the queue 03DC2 EC004810 1913 STZ ENCRYLOCK release the lock 03DC3 61440000 5 IMM 1914 LD R5 0 say no current PREL 03DC4 EC004908 1915 STZ CPRFORM no current record format 03DC5 5D1F8001 6 STAK 1916 LEAVE POP 1917 * --- 1918 1919 END LINKINENCR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 171 (DTTPACK) F 20 Tape String Building Routines 1922 1923 TSBUILD BLOCK tape string building routines 1924 1925 ENTRY TSVOL 1926 ENTRY TSNAME 1927 ENTRY TSMOVE 1928 1929 ********************************************************************************** 1930 * * 1931 * This is the PAK6TOCHAR subroutine. It is called to * 1932 * convert a PAK6 symbol to its ascii equivalent and place it * 1933 * in NAMEBUF starting at the position passed it. * 1934 * Call: * 1935 * CALL PAK6TOCHAR * 1936 * PARV * 1937 * PARVL * 1938 * * 1939 * Returns R2 with index to first position in NAMEBUF beyond last char. * 1940 * Eats R0:R2 * 1941 * * 1942 ********************************************************************************** 1943 1944 PAK6TOCHAR BLOCK 1945 1946 ENTRY PAK6TOCHAR 1947 03DC6 20303132 1948 P6TAB TEXT " 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ!&_" 03DD0 020C3DC6 1949 P6CHARS PTR P6TAB/BITS 0:7 PAK6 decode table 1950 03DD1 00000001 1951 FORTYTAB VFD 40 POWER 0 powers of 40 03DD2 00000028 1952 VFD 40 POWER 1 03DD3 00000640 1953 VFD 40 POWER 2 03DD4 0000FA00 1954 VFD 40 POWER 3 03DD5 00271000 1955 VFD 40 POWER 4 03DD6 061A8000 1956 VFD 40 POWER 5 1957 1958 1959 BEGFRAME 00178801 6 BASE 1960 PAK6R3 BSS 1 temp to save R3 1961 ENDFRAME 1962 03DD7 DD1F8002 6 STAK 1963 PAK6TOCHAR ENTR PUSH 03DD8 C1524000 1 REG 1964 STPV R1 value to convert 03DD9 C0528000 2 REG 1965 STPVL R2 index into NAMEBUF 03DDA E4D78801 3 6 BASE 1966 ST R3 SP,PAK6R3 save R3 1967 03DDB 60C40005 3 IMM 1968 LD R3 6-1 six digits 00003DDC 1969 PAK6O10 LABEL 03DDC EC120000 0 REG 1970 STZ R0 eliminate confusing junk 03DDD 58C40010 IMM 1971 IORPSR PSRMODIF say we want special handling 03DDE 14263DD1 0 3 1972 DIV R0 FORTYTAB(R3) extract a "digit" (0-39) 03DDF 58840010 IMM 1973 CLBPSR PSRMODIF undo funny magic 03DE0 FA023DE5 0 1974 JEQZ R0 PAK6OEXIT jump if all done 03DE1 60303DD0 0 0 @ 1975 LD R0 @P6CHARS(R0) get the real character 03DE2 E43448F5 0 2 @ 1976 ST R0 @NAMEBUFPTR(R2) add into output buffer 03DE3 18840001 2 IMM 1977 ADD R2 1 advance buffer pointer 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 172 (DTTPACK) F 20 Tape String Building Routines 03DE4 FAE63DDC 3 1978 JDR R3 PAK6O10 recycle 1979 * \ / 1980 00003DE5 1981 PAK6OEXIT LABEL 03DE5 60D78801 3 6 BASE 1982 LD R3 SP,PAK6R3 restore R3 03DE6 5D1F8002 6 STAK 1983 LEAVE POP 1984 * --- 1985 1986 END PAK6TOCHAR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 173 (DTTPACK) F 20 Tape String Building Routines 1988 1989 ********************************************************************************** 1990 * * 1991 * TSVOL -- Create Volume Name Part of Tapestring * 1992 * * 1993 * This subroutine creates the volume name portion of a * 1994 * tape string. This is put in NAMEBUF and is then used to * 1995 * start all tapestrings that go in logical records in this * 1996 * DISKTOTAPE. * 1997 * Call: * 1998 * CALL TSVOL * 1999 * PARV2L * 2000 * * 2001 * Puts volume name in NAMEBUF and sets ACCTINDEX to index the * 2002 * first char following the volume name. * 2003 * Eats R0:R2 * 2004 * * 2005 ********************************************************************************** 2006 2007 TSVOL BLOCK 2008 2009 ENTRY TSVOL 2010 2011 BEGFRAME 00178801 6 BASE 2012 TSVOLNAME BSS 2 temp to save second part of volume name 2013 ENDFRAME 2014 03DE7 DD1F8003 6 STAK 2015 TSVOL ENTR PUSH 03DE8 C2578801 6 BASE 2016 STPV2L SP,TSVOLNAME 2017 03DE9 60178801 0 6 BASE 2018 LD R0 SP,TSVOLNAME(0) pick up the volume name 03DEA DC003DD7 2019 CALL PAK6TOCHAR convert first word to ascii 03DEB 41520000 0 REG 2020 PARV R0 first word to convert 03DEC 40440000 IMM 2021 PARVL 0 index to start conversion in buffer 03DED 60178802 0 6 BASE 2022 LD R0 SP,TSVOLNAME(1) pick up second word of the volume name 03DEE DC003DD7 2023 CALL PAK6TOCHAR convert the second word to ascii 03DEF 41520000 0 REG 2024 PARV R0 second word to convert 03DF0 40528000 2 REG 2025 PARVL R2 where to start this word in NAMEBUF 03DF1 E480492B 2 2026 ST R2 ACCTINDEX this is where to start the account name 03DF2 5D1F8003 6 STAK 2027 LEAVE POP 2028 * --- 2029 2030 END TSVOL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 174 (DTTPACK) F 20 Tape String Building Routines 2032 2033 ********************************************************************************** 2034 * * 2035 * TSNAME -- Convert a Name to Ascii * 2036 * * 2037 * This subroutine converts a complete name of the form * 2038 * . to its equivalent ascii format. * 2039 * Call: * 2040 * CALL TSNAME * 2041 * PARV * 2042 * PARV2 * 2043 * PARVL * 2044 * * 2045 * Places a colon into NAMEBUF at the index passed and converts * 2046 * the name following that. * 2047 * Returns R2 with an index to the first char following * 2048 * the name (total length of string). * 2049 * * 2050 * Eats R0:R2 * 2051 * * 2052 ********************************************************************************** 2053 2054 TSNAME BLOCK 2055 2056 ENTRY TSNAME 2057 2058 BEGFRAME 00178801 6 BASE 2059 TSP12NAME BSS 2 PAK12 name 00178803 6 BASE 2060 TSP6NAME BSS 1 PAK6 name 00178804 6 BASE 2061 TSINDX BSS 1 index into NAMEBUF 2062 ENDFRAME 2063 03DF3 DD1F8005 6 STAK 2064 TSNAME ENTR PUSH 03DF4 C1578804 6 BASE 2065 STPV SP,TSINDX save index into buffer 03DF5 C3578801 6 BASE 2066 STPV2 SP,TSP12NAME PAK12 part of name 03DF6 C0578803 6 BASE 2067 STPVL SP,TSP6NAME PAK6 part of name 2068 03DF7 60978804 2 6 BASE 2069 LD R2 SP,TSINDX index into buffer 03DF8 6004003A 0 IMM 2070 LD R0 ":" get terminator for previous item 03DF9 E43448F5 0 2 @ 2071 ST R0 @NAMEBUFPTR(R2) tack it onto the end 03DFA 18840001 2 IMM 2072 ADD R2 1 move to next char postition 03DFB 60178801 0 6 BASE 2073 LD R0 SP,TSP12NAME get first word to convert 03DFC DC003DD7 2074 CALL PAK6TOCHAR convert to characters 03DFD 41520000 0 REG 2075 PARV R0 word to convert 03DFE 40528000 2 REG 2076 PARVL R2 where in NAMEBUF to start 03DFF 60178802 0 6 BASE 2077 LD R0 SP,TSP12NAME(1) get second word to convert 03E00 DC003DD7 2078 CALL PAK6TOCHAR convert to characters 03E01 41520000 0 REG 2079 PARV R0 word to convert 03E02 40528000 2 REG 2080 PARVL R2 where in NAMEBUF to start 03E03 6004002E 0 IMM 2081 LD R0 "." period to separate words 03E04 E43448F5 0 2 @ 2082 ST R0 @NAMEBUFPTR(R2) put it in the string 03E05 18840001 2 IMM 2083 ADD R2 1 move index up 03E06 60178803 0 6 BASE 2084 LD R0 SP,TSP6NAME get PAK6 word to convert 03E07 DC003DD7 2085 CALL PAK6TOCHAR convert to characters 03E08 41520000 0 REG 2086 PARV R0 word to convert 03E09 40528000 2 REG 2087 PARVL R2 where in NAMEBUF to start 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 175 (DTTPACK) F 20 Tape String Building Routines 03E0A 5D1F8005 6 STAK 2088 LEAVE POP 2089 * --- 2090 2091 END TSNAME 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 176 (DTTPACK) F 20 Tape String Building Routines 2093 2094 ********************************************************************************** 2095 * * 2096 * TSMOVE -- Move Tapestring Into Record * 2097 * * 2098 * This subroutine null fills the current tape string * 2099 * in NAMEBUF, places the string length into the first * 2100 * character position of that buffer, and moves the entire * 2101 * melange into the record header. The move into the * 2102 * record header is a whole number of words. This prevents * 2103 * residual parity errors from killing us. * 2104 * * 2105 * Call: * 2106 * LD R3 * 2107 * CALL TSMOVE * 2108 * PARVL * 2109 * returns R3 -> word beyond tapestring * 2110 * * 2111 * Eats R0:R2 * 2112 * * 2113 ********************************************************************************** 2114 2115 TSMOVE BLOCK 2116 2117 ENTRY TSMOVE 2118 2119 BEGFRAME 2120 ENDFRAME 2121 03E0B DD1F8001 6 STAK 2122 TSMOVE ENTR PUSH 03E0C C0520000 0 REG 2123 STPVL R0 collect length of string 03E0D E41048F4 0 @ 2124 ST R0 @NAMEBUFLCH store into length byte 2125 03E0E 38B048F5 2 0 @ 2126 LEA R2 @NAMEBUFPTR(R0) get pointer to current string end 03E0F 60440003 1 IMM 2127 LD R1 3 to fill out the word 03E10 FE580000 2128 CFILL 000 with nulls 2129 03E11 18040004 0 IMM 2130 ADD R0 4 one to include length byte, rest 2131 * to cause proper whole word round 03E12 7807FFFC 0 IMM 2132 AND R0 0FFFFFFFC chop to whole word 2133 03E13 3840490D 1 2134 LEA R1 NAMEBUFW R0 -> name buffer 03E14 DAC84000 3 10 2135 MOVE R3,R1,R0 move the save set name into the record 03E15 5D1F8001 6 STAK 2136 LEAVE POP 2137 * --- 2138 2139 END TSMOVE 2140 END TSBUILD of tape string building routines 2141 END PHYSRECPCK of physical record packing process 1644 INPUT DISKTOTAPE.OPSYS:DTTENCR 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 177 (DTTENCR) F 21 Encryption Process 3 4 ENCRYPTPROC BLOCK encrypt process 5 6 ENTRY ENCRYPT 7 8 ********************************************************************************** 9 * * 10 * The encryption process picks elements from the encrypt * 11 * queue which should be PRELs, processes them according to * 12 * their encryption type, and then moves the physical record * 13 * to the tapewrite queue. Since multiple CPUs may be * 14 * encrypting and the PRELs must be put in the tapewrite queue * 15 * in the sequence they appear in the encrypt queue, the * 16 * physical record is only moved to the tapewrite queue when * 17 * it is at the head of the encrypt queue. PRELs stay in the * 18 * encrypt queue while their physical records are being * 19 * encrypted but a flag is set in the PREL saying this PREL * 20 * is being encrypted. * 21 * * 22 * ALGORITHM: * 23 * Scan encrypt queue for non busy entry. Set busy flag. * 24 * Checksum if required. * 25 * Encrypt if required. Set done flag * 26 * If entry is at head of queue move to tapewrite queue. * 27 * Else unset busy flag. * 28 * * 29 * We check each time before we start encrypting a new * 30 * physical record to see if the ratio of number of entries in * 31 * the encrypt queue and tape write queue has reached a level * 32 * where it would be advisable to start a CPU writing to tape * 33 * and reading from disk. If so, and neither of these two * 34 * processes are currently busy the CPU leaves the encryptor * 35 * and returns to the scheduler to be sent to one of these * 36 * processes. * 37 * * 38 ********************************************************************************** 39 40 ENCRYMC BLOCK main control 41 42 ENTRY ENCRYPT 43 ENTRY ENCRDONE 44 45 BEGFRAME2 00178800 6 BASE 46 CHUNKPTR BSS 1 pointer to position in physical record 00178801 6 BASE 47 SEQNUM BSS 1 PR sequence number 00178802 6 BASE 48 NUMCHUNKS BSS 1 number of chunks PR is split into 00178803 6 BASE 49 CHUNKSIZE BSS 1 size of chunks being sent to encryptor 00178804 6 BASE 50 EXTRA BSS 1 number of chunks that get an extra word 51 ENDFRAME 52 00003E16 53 ENCRYPT LABEL 03E16 DC403E7F 54 CALLNP GETSTACK get some stack space 03E17 FE0E3E66 55 JMP NOSTACK if there was none to be had 03E18 EC1F8005 6 STAK 56 STZ PUSH initialize stack 57 00003E19 58 ENCRYLOOP LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 178 (DTTENCR) F 21 Encryption Process 03E19 6040480F 1 59 LD R1 ENCRQCNT see if anything to encrypt 03E1A FA4A3E58 1 60 JLEZ R1 ENCRDONE if not, then time to leave 03E1B 60004813 0 61 LD R0 TAPEQCNT get number of entries in tape queue 03E1C 14124000 0 1 REG 62 DIV R0 R1 find ratio to encrypt queue 03E1D 64040009 0 IMM 63 CPR R0 QUITRATIO see if the ratio has reached the quitting point 03E1E FE083E23 64 JLT KEEPGOIN if not then keep on encrypting 65 * \ / 66 03E1F 5C004802 67 CMZ WRITELOCK see if the tape needs starting 03E20 FE023E58 68 JEQ ENCRDONE if so go do it 03E21 5C004800 69 CMZ READLOCK see if the disk needs reading 03E22 FE023E58 70 JEQ ENCRDONE ditto 71 * \ / 72 00003E23 73 KEEPGOIN LABEL 03E23 DC403E92 74 CALLNP FINDPHYREC get a record to encrypt 03E24 FE0E3E58 75 JMP ENCRDONE if no records are there to encrypt 03E25 60094C20 0 5 ZBM 76 LD R0 R5,PRELENCRY get encrypt code 03E26 5CA03E27 0 77 LDPC ENCRYTAB(R0) do the right thing 78 * --- 79 00003E27 80 ENCRYTAB LABEL 03E27 00003E67 81 VFD ADR TBMMARKER tapebootmake marker 03E28 00003E73 82 VFD ADR TBMENCRYPT tapebootmake encryption 03E29 00003E2B 83 VFD ADR NORMALENC normal checksum and encryption 03E2A 00003E2B 84 VFD ADR NORMALENC no encryption, but checksum 85 86 ********************************************************************************** 87 * * 88 * We have a physical record that needs to be run through the * 89 * checksummer. We map it in, checksum it, then check to see if * 90 * it needs to be encrypted. * 91 * Note the oddity that we checksum the tape label record * 92 * even though it does not have a tape number in it yet. We have * 93 * initialized the tape number to zero to clear parity errors. * 94 * The tape writing process picks off the tape label record and * 95 * re-checksums it each time it needs to write it. * 96 * * 97 ********************************************************************************** 98 00003E2B 99 NORMALENC LABEL 03E2B DC00345C 100 CALL MAPINPR map in the physical record 03E2C 404400A4 IMM 101 PARVL ENCRPRPN where to start it 102 * \ / 03E2D 61174802 4 5 BASE 103 LD R4 R5,PRELPRINX index into first page of start of record 03E2E 39289000 4 4 104 LEA R4 ENCRPRPAGE(R4) R4 -> start of physical record 03E2F 60C96101 3 5 ZBM 105 LD R3 R5,PRELPRLEN size of record 03E30 DC4040DC 106 CALLNP CHECKSUM generate its checksum 107 * \ / 03E31 60094C20 0 5 ZBM 108 LD R0 R5,PRELENCRY get encrypt code 03E32 64040003 0 IMM 109 CPR R0 ENCRNONE check for checksum only 03E33 FE023E56 110 JEQ NOENCRYPT jump if checksum only 111 112 ********************************************************************************** 113 * * 114 * Here we have a record that must be encrypted by the * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 179 (DTTENCR) F 21 Encryption Process 115 * normal encryptor. It is split up here into chunks less than or * 116 * equal to MAXENCRSIZ then carefully mangled by the encryptor. * 117 * * 118 ********************************************************************************** 119 * \ / 03E34 60174802 0 5 BASE 120 LD R0 R5,PRELPRINX index into first page of start of record 03E35 38209000 0 0 121 LEA R0 ENCRPRPAGE(R0) R0 -> start of physical record 03E36 60560800 1 0 BASE 122 LD R1 R0,PHSSEQNUM get the sequence number 03E37 E4578801 1 6 BASE 123 ST R1 SP,SEQNUM save on stack 03E38 38160803 0 0 BASE 124 LEA R0 R0,PHSENCSTRT R0 -> start of encrypted section 03E39 E4178800 0 6 BASE 125 ST R0 SP,CHUNKPTR save for encryptor 126 03E3A 60096101 0 5 ZBM 127 LD R0 R5,PRELPRLEN size of record 03E3B 10040003 0 IMM 128 SUB R0 PHSNOESIZE subtract the unencrypted size 03E3C 60520000 1 0 REG 129 LD R1 R0 keep this number around for later 03E3D 18040FFF 0 IMM 130 ADD R0 MAXENCRSIZ-1 so the divide will give number of chunks 03E3E 14041000 0 IMM 131 DIV R0 MAXENCRSIZ see how many sections to divide PR into 03E3F E4178802 0 6 BASE 132 ST R0 SP,NUMCHUNKS save this for a counter 133 03E40 60040000 0 IMM 134 LD R0 0 set up for a funny divide (R1 = length) 03E41 58C40010 IMM 135 IORPSR PSRMODIF funky arithmetic 03E42 14178802 0 6 BASE 136 DIV R0 SP,NUMCHUNKS see how big to make each encrypt chunk 03E43 58840010 IMM 137 CLBPSR PSRMODIF restore normalcy 03E44 E4178803 0 6 BASE 138 ST R0 SP,CHUNKSIZE save this 03E45 E4578804 1 6 BASE 139 ST R1 SP,EXTRA and the remainder, too 140 * \ / 141 00003E46 142 CHUNKLOOP LABEL 03E46 60578803 1 6 BASE 143 LD R1 SP,CHUNKSIZE get size of each encrypt chunk 03E47 D0578804 6 BASE 144 DEC SP,EXTRA see if this chunk should be bigger 03E48 FE083E4A 145 JLT HAVESIZE 03E49 18440001 1 IMM 146 ADD R1 1 make size one bigger 147 * \ / 148 00003E4A 149 HAVESIZE LABEL 03E4A 60978800 2 6 BASE 150 LD R2 SP,CHUNKPTR pointer to first of chunk 03E4B 98578800 1 6 BASE 151 ADDM R1 SP,CHUNKPTR for next time through 03E4C 60D78801 3 6 BASE 152 LD R3 SP,SEQNUM get the sequence number from the stack 03E4D DC003F37 153 CALL CRYPT encrypt the block 03E4E 41168400 2 @R 154 PAR @R2 where the buffer is 03E4F 41524000 1 REG 155 PARV R1 how many words in buffer 03E50 4340481A 156 PARV2 OPTKEY password mixed with optional key 03E51 43404822 157 PARV2 STARTTIME time 03E52 4052C000 3 REG 158 PARVL R3 sequence number 03E53 FE0E3E7E 159 JMP BADBUF buffer size was screwed up 160 03E54 D0578802 6 BASE 161 DEC SP,NUMCHUNKS see if we are through 03E55 FE043E46 162 JGT CHUNKLOOP if not continue on 163 * \ / 164 165 * At this point we have either an encrypted physical record or 166 * one that does not need to be encrypted. In either case link it 167 * onto the write queue and go around again. 168 * \ / 169 00003E56 170 NOENCRYPT LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 180 (DTTENCR) F 21 Encryption Process 03E56 DC403E9F 171 CALLNP LINKINTWQ link it onto the tape write queue 03E57 FE0E3E19 172 JMP ENCRYLOOP do another physical record 173 * --- 174 00003E58 175 ENCRDONE LABEL 03E58 D9124000 1 REG 176 STMSR R1 get MSR contents 03E59 604A7840 1 1 CBM 177 LD R1 R1/MSRSLOT get the slot number of this CPU 03E5A 6022497D 0 1 178 LD R0 ENCRSTKPTR(R1) get pointer to encryption stack 03E5B 60C400A3 3 IMM 179 LD PFPTR ENCRVARPN page number of encryption variables 03E5C 80D2C000 3 REG 180 PFRC R3 clear it out 181 182 * We cannot use PAGERETURN because we lose our stack when 183 * we give up the page. 184 LLOCK PAGEQLOCK lock the page queue 03E61 60404804 1 185 LD R1 PAGEQ get the first element 03E62 E4481F10 1 0 ZBM 186 ST R1 R0,MCBLINK link in our returning element 03E63 E4004804 0 187 ST R0 PAGEQ returned page is start of list 03E64 D0004806 188 INC FREEPGCNT one more page returned 03E65 EC004805 189 STZ PAGEQLOCK free the list 00003E66 190 NOSTACK LABEL 03E66 FE0E3191 191 JMP CHEKTAPE 192 * --- 193 194 * We have finished with the tapebootmake information. 195 * The encryptor no longer needs the extra pages so decrease 196 * the free page minimum count for the reading and packing 197 * process and put the marker in the write queue. 198 00003E67 199 TBMMARKER LABEL 03E67 60040003 0 IMM 200 LD R0 TTBM see if this is a tapebootmake marker 03E68 64094040 0 5 ZBM 201 CPR R0 R5,PRELTYPE check the type 03E69 FE0C3E72 202 JNE ENCRYERR if not then error 203 * \ / 03E6A 60174801 0 5 BASE 204 LD R0 R5,PRELTBM get the type of marker 03E6B 64040002 0 IMM 205 CPR R0 TBMEND see if it is the end of TBM marker 03E6C FE0C3E70 206 JNE LINKTBM the others just pass through 207 * \ / 208 209 * End of tapebootmake info. No longer need extra pages for encryption. 03E6D 60040018 0 IMM 210 LD R0 TPBTPAGES number of pages reserved for tapebootmake 03E6E B0004818 0 211 RSBM R0 READMINPAG decrease the minimum page level 03E6F B0004819 0 212 RSBM R0 PACKMINPAG decrease the minimum page level 00003E70 213 LINKTBM LABEL 03E70 DC403E9F 214 CALLNP LINKINTWQ link this into the tape write queue 03E71 FE0E3E19 215 JMP ENCRYLOOP 216 * --- 217 218 * A bad entry was found in the encryption queue. 219 00003E72 220 ENCRYERR LABEL 03E72 00173220 221 HALT HALTW3220 bad encryption format code 222 * --- 223 224 * The physical record contains a tapebootmake block. 225 * Encrypt it with its special encryptor and then send it to 226 * be written. 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 181 (DTTENCR) F 21 Encryption Process 227 00003E73 228 TBMENCRYPT LABEL 03E73 E5578804 5 6 BASE 229 ST R5 SP,EXTRA save pointer to PREL 03E74 DC00345C 230 CALL MAPINPR map in the physical record 03E75 404400A4 IMM 231 PARVL TBMPN1 where to start it at 232 * \ / 03E76 DC403EBE 233 CALLNP MAPIN12 map in 12 pages for random numbers 03E77 FE0E3E58 234 JMP ENCRDONE done encrypting for now 03E78 DC403EF3 235 CALLNP SETUPENCR set up encryption keys 03E79 DC403EFD 236 CALLNP BUENCRYPT encrypt the page 03E7A DC403EE8 237 CALLNP UNMAP12 return and unmap the pages and PREL 03E7B 61578804 5 6 BASE 238 LD R5 SP,EXTRA restore pointer to PREL 03E7C DC403E9F 239 CALLNP LINKINTWQ link this into the tape write queue 03E7D FE0E3E19 240 JMP ENCRYLOOP 241 * --- 242 243 * The normal encryptor thinks we gave it a chunk to encrypt 244 * that was too large. 00003E7E 245 BADBUF LABEL 03E7E 00173221 246 HALT HALTW3221 bad buffer size 247 * --- 248 249 END ENCRYMC of main encrypt control 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 182 (DTTENCR) F 21 Encryption Process 251 252 ********************************************************************************** 253 * * 254 * GETSTACK * 255 * * 256 * This subroutine gets a free page to keep its local * 257 * variables and stack on. It saves the pointer to its MCB * 258 * in an array indexed by CPU slot number. We have no stack * 259 * coming into here so enter using a register to hold callers * 260 * R7. The stack pointer is initialized here. Since it is * 261 * not set until we have our free page we can not call the * 262 * standard free page get subroutine. * 263 * Call: * 264 * CALLNP GETSTACK * 265 * JMP * 266 * Sets SP * 267 * Eats R0:R2 * 268 * * 269 ********************************************************************************** 270 271 GETSTACK BLOCK 272 273 ENTRY GETSTACK 274 03E7F DD528000 2 REG 275 GETSTACK ENTRNP R2 276 LLOCK PAGEQLOCK lock PAGE list 03E84 60004804 0 277 LD R0 PAGEQ get pointer to first MCB 03E85 FA023E90 0 278 JEQZ R0 NOPAGES jump if no pages for stack usage 03E86 D0404806 279 DEC FREEPGCNT say that we are taking one 03E87 60481F10 1 0 ZBM 280 LD R1 R0,MCBLINK get pointer to next MCB 03E88 E4404804 1 281 ST R1 PAGEQ make it the first 03E89 60C400A3 3 IMM 282 LD PFPTR ENCRVARPN page number to map it into 03E8A 00D60801 0 BASE 283 LDPF R0,MCBPMV map in our page 284 03E8B D9124000 1 REG 285 STMSR R1 get MSR contents 03E8C 604A7840 1 1 CBM 286 LD R1 R1/MSRSLOT get the slot number of this CPU 03E8D E422497D 0 1 287 ST R0 ENCRSTKPTR(R1) save pointer to MCB 03E8E 61848CAC 6 IMM 288 LD SP ADR CRYPTSTACK set up the stack pointer 289 * \ / 03E8F 19C40001 7 IMM 290 ADD R7 1 normal return 291 * \ / 00003E90 292 NOPAGES LABEL 03E90 EC004805 293 STZ PAGEQLOCK free the list 03E91 5D128000 2 REG 294 LEAVE R2 295 * --- 296 297 END GETSTACK 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 183 (DTTENCR) F 21 Encryption Process 299 300 ********************************************************************************** 301 * * 302 * FINDPHYREC -- Get a physical record to encrypt * 303 * * 304 * This subroutine gets a non-busy entry from the encrypt * 305 * queue, sets the busy flag for it, maps in the physical * 306 * record, and returns a pointer to the entry. If no non-busy * 307 * entry is in the queue it gives an error return. * 308 * Call: * 309 * CALLNP FINDPHYREC * 310 * JMP * 311 * returns R5 -> PREL * 312 * Eats R0:R3 * 313 * * 314 ********************************************************************************** 315 316 FINDPHYREC BLOCK 317 318 ENTRY FINDPHYREC 319 320 BEGFRAME 321 ENDFRAME 322 03E92 DD5F8001 6 STAK 323 FINDPHYREC ENTRNP PUSH 324 LLOCK ENCRYLOCK 03E97 6140480D 5 325 LD R5 ENCRYQHD R5 -> first element in queue 03E98 60440000 1 IMM 326 LD R1 0 want zero in the busy field 03E99 3C494820 1 5 ZBM 327 LSRCH R1 R5,PRELFLAGS search for a non-busy and non-done element 03E9A FE0C3E9D 328 JNE NOFOUND 329 * \ / 330 03E9B EDC94810 5 ZBM 331 STW R5,PRELBUSY say this one is busy 03E9C 19C40001 7 IMM 332 ADD R7 1 indicate normal return 00003E9D 333 NOFOUND LABEL 03E9D EC004810 334 STZ ENCRYLOCK release lock 03E9E 5D1F8001 6 STAK 335 LEAVE POP 336 * --- 337 338 END FINDPHYREC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 184 (DTTENCR) F 21 Encryption Process 340 341 ********************************************************************************** 342 * * 343 * LINKINTWQ -- link a PREL onto the tapewrite queue * 344 * * 345 * This subroutine does the finish up for an encrypted * 346 * physical record. It sets the flags to not busy and done, * 347 * and moves the element from the encrypt queue to the * 348 * tapewrite queue if it is the first element in the encrypt * 349 * queue. We then see if the next entry in the encrypt queue * 350 * is ready to move and move it if so. * 351 * Call: * 352 * R5 -> PREL * 353 * CALLNP LINKINTWQ * 354 * * 355 * Eats R0,R1,R5 * 356 * * 357 ********************************************************************************** 358 359 LINKINTWQ BLOCK 360 361 ENTRY LINKINTWQ 362 363 BEGFRAME 364 ENDFRAME 365 03E9F DD5F8001 6 STAK 366 LINKINTWQ ENTRNP PUSH 367 LLOCK ENCRYLOCK re-lock the encryption queue 03EA4 EDC94A10 5 ZBM 368 STW R5,PRELDONE say we are done with this chunk 03EA5 EC094810 5 ZBM 369 STZ R5,PRELBUSY no longer using this entry 03EA6 6540480D 5 370 CPR R5 ENCRYQHD is this the first entry? 03EA7 FE0C3EBC 371 JNE NOTFIRST if not then don't remove it 372 * \ / 373 LLOCK TAPEQLOCK get tape queue locked 374 * \ / 00003EAC 375 MOVENEXT LABEL 03EAC 60095F10 0 5 ZBM 376 LD R0 R5,PRELLINK get pointer to next PREL 03EAD E400480D 0 377 ST R0 ENCRYQHD make this the head 03EAE D040480F 378 DEC ENCRQCNT one less entry in this queue 379 * \ / 380 03EAF EC095F10 5 ZBM 381 STZ R5,PRELLINK wipe out our trailing link 03EB0 60404812 1 382 LD R1 TAPEQTAIL R1 -> last element in queue 03EB1 E5485F10 5 1 ZBM 383 ST R5 R1,PRELLINK link ours on the end 03EB2 E5404812 5 384 ST R5 TAPEQTAIL and we are now the tail 03EB3 D0004813 385 INC TAPEQCNT one more entry in this queue 386 * \ / 387 03EB4 FA023EB9 0 388 JEQZ R0 LASTENCR last entry has been removed from encrypt queue 03EB5 5C080A10 0 ZBM 389 CMZ R0,PRELDONE is the new encrypt queue head done? 03EB6 FE023EBB 390 JEQ MOVEDONE if not then quit 03EB7 61520000 5 0 REG 391 LD R5 R0 R5 -> first element in encrypt queue 03EB8 FE0E3EAC 392 JMP MOVENEXT 393 * --- 394 00003EB9 395 LASTENCR LABEL 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 185 (DTTENCR) F 21 Encryption Process 03EB9 6004480D 0 IMM 396 LD R0 ADR ENCRYQHD get address of queue's head 03EBA E400480E 0 397 ST R0 ENCRYQTL tail points to head 398 * \ / 399 00003EBB 400 MOVEDONE LABEL 03EBB EC004814 401 STZ TAPEQLOCK let the lock go 402 * \ / 403 00003EBC 404 NOTFIRST LABEL 03EBC EC004810 405 STZ ENCRYLOCK release queue 03EBD 5D1F8001 6 STAK 406 LEAVE POP 407 * --- 408 409 END LINKINTWQ 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 186 (DTTENCR) F 21 Encryption Process 411 412 ********************************************************************************** 413 * * 414 * MAPIN12 * 415 * * 416 * We come here to get and map in enough pages for * 417 * the PRN table. * 418 * Call: * 419 * CALLNP MAPIN12 * 420 * JMP * 421 * * 422 * Returns R5 -> PREL and pages mapped * 423 * Eats R0:R5 * 424 * * 425 ********************************************************************************** 426 427 MAPIN12 BLOCK 428 429 ENTRY MAPIN12 430 431 BEGFRAME 00178801 6 BASE 432 MAPINR5 BSS 1 temp to hold pointer to original PREL 433 ENDFRAME 434 03EBE DD5F8002 6 STAK 435 MAPIN12 ENTRNP PUSH 03EBF E5578801 5 6 BASE 436 ST R5 SP,MAPINR5 save for error recovery 437 LLOCK PRELQLOCK 03EC4 5C004809 438 CMZ FREEPRELCT see if there are enough PRELs 03EC5 FE0A3EDC 439 JLE CANTDO can't do it if not enough PRELs 03EC6 DC403454 440 CALLNP UNLINKPREL get a PREL 441 03EC7 6004000C 0 IMM 442 LD R0 (L*3)/WPP number of pages we need 443 LLOCK PAGEQLOCK 03ECC 64004806 0 444 CPR R0 FREEPGCNT are there enough pages? 03ECD FE043EDE 445 JGT NOGO if not then clean up and leave 446 03ECE E4094041 0 5 ZBM 447 ST R0 R5,PRELMCBCNT put in the count 03ECF 70520000 1 0 REG 448 LDN R1 R0 initialize our loop counter 03ED0 60C400A6 3 IMM 449 LD PFPTR PRNTABPN page number of first page in PRN table 00003ED1 450 MAP12LOOP LABEL 03ED1 D0404806 451 DEC FREEPGCNT say we are taking a page 03ED2 61004804 4 452 LD R4 PAGEQ get pointer to first free MCB 03ED3 60091F10 0 4 ZBM 453 LD R0 R4,MCBLINK get pointer to next MCB on the list 03ED4 E4004804 0 454 ST R0 PAGEQ and call it the first free MCB 03ED5 E51D480F 4 51 BASE 455 ST R4 R5,PRELMCBPTR((L*3)/WPP)(R1) put pointer in PREL 03ED6 00D70801 4 BASE 456 LDPF R4,MCBPMV map in the page 03ED7 18C40001 3 IMM 457 ADD PFPTR 1 move to next page file value 03ED8 FA603ED1 1 458 IRJ R1 MAP12LOOP if not then keep going 459 * \ / 03ED9 EC004805 460 STZ PAGEQLOCK 03EDA 19C40001 7 IMM 461 ADD R7 1 good return 462 * \ / 463 00003EDB 464 ERRETURN LABEL 03EDB 5D1F8002 6 STAK 465 LEAVE POP 466 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 187 (DTTENCR) F 21 Encryption Process 467 00003EDC 468 CANTDO LABEL 03EDC EC004808 469 STZ PRELQLOCK release lock 03EDD FE0E3EE0 470 JMP ERRMERGE 471 * --- 472 00003EDE 473 NOGO LABEL 03EDE EC004805 474 STZ PAGEQLOCK 03EDF DC403471 475 CALLNP PRELRETURN return the PREL 476 00003EE0 477 ERRMERGE LABEL 03EE0 61578801 5 6 BASE 478 LD R5 SP,MAPINR5 R5 -> PREL we have locked in TWQ 479 LLOCK TAPEQLOCK lock the tape write queue 03EE5 EC094810 5 ZBM 480 STZ R5,PRELBUSY say this PREL is no longer busy 03EE6 EC004814 481 STZ TAPEQLOCK free the list 03EE7 FE0E3EDB 482 JMP ERRETURN 483 * --- 484 485 END MAPIN12 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 188 (DTTENCR) F 21 Encryption Process 487 488 ********************************************************************************** 489 * * 490 * UNMAP12 * 491 * * 492 * This simply unmaps and returns to memory the pages * 493 * mapped in by MAPIN12. The PREL is also returned. * 494 * Call: * 495 * R5 -> PREL * 496 * CALLNP UNMAP12 * 497 * * 498 * Eats R0:R5 * 499 * * 500 ********************************************************************************** 501 502 UNMAP12 BLOCK 503 504 ENTRY UNMAP12 505 506 BEGFRAME 507 ENDFRAME 508 03EE8 DD5F8001 6 STAK 509 UNMAP12 ENTRNP PUSH 03EE9 60C400A6 3 IMM 510 LD PFPTR PRNTABPN where to start the unmapping at 03EEA 6044000C 1 IMM 511 LD R1 (L*3)/WPP how many there are to unmap 00003EEB 512 UNMAPLOOP LABEL 03EEB 80D20000 0 REG 513 PFRC R0 clear the page 03EEC FA623EEB 1 514 DRJ R1 UNMAPLOOP do another one 515 * \ / 516 03EED 60C400A4 3 IMM 517 LD PFPTR TBMPN1 page number for first page in record 03EEE 80D20000 0 REG 518 PFRC R0 clear this page 03EEF 18C40001 3 IMM 519 ADD PFPTR 1 move to the next location 03EF0 80D20000 0 REG 520 PFRC R0 and clear this page 521 * \ / 522 03EF1 DC40347C 523 CALLNP FREEALL now return the PRN table pages 03EF2 5D1F8001 6 STAK 524 LEAVE POP 525 * --- 526 527 END UNMAP12 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 189 (DTTENCR) F 21 Encryption Process 529 530 ********************************************************************************** 531 * * 532 * SETUPENCR * 533 * * 534 * The encyption keys consist of an indicator set in the * 535 * header by the packing process, and the time (also set in * 536 * the header by the packing process) exclusive or'd with the * 537 * system's password. These must be put in varibles defined * 538 * exactly like those defined by TAPEBOOTMAKE so that we can * 539 * use the same encryptor. Since many CPUs may be encrypting * 540 * these variables are defined to be on the beginning of the * 541 * page that is mapped in with the header. * 542 * Call: * 543 * CALLNP SETUPENCR * 544 * * 545 * Eats R0:R2 * 546 * * 547 ********************************************************************************** 548 549 SETUPENCR BLOCK 550 551 ENTRY SETUPENCR 552 553 BEGFRAME 554 ENDFRAME 555 03EF3 DD5F8001 6 STAK 556 SETUPENCR ENTRNP PUSH 03EF4 608493F5 2 IMM 557 LD R2 TBMFBIPOS R2 -> header of file page block 03EF5 62168803 012 BASE 558 LD2 R0 R2,TBMDATE get the date from the header 03EF6 E6008C01 01 559 ST2 R0 KEYPWDDAT and set it up for the encryptor 03EF7 62004825 01 560 LD2 R0 SYSPWD get the system's password 03EF8 F4008C01 0 561 XORM R0 KEYPWDDAT(0) combine into key date 03EF9 F4408C02 1 562 XORM R1 KEYPWDDAT(1) combine into key date 03EFA 60168802 0 2 BASE 563 LD R0 R2,TBMIND get the indicator 03EFB E4008C00 0 564 ST R0 KEYINDIC and set up for the encryptor 03EFC 5D1F8001 6 STAK 565 LEAVE POP 566 * --- 567 568 END SETUPENCR 569 570 END ENCRYPTPROC of encrypt process 571 1645 INPUT DISKTOTAPE.OPSYS:DTCHECKSUM 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 190 (DTCHECKSUM) F 26 Cryptor's Definitions 2 3 ********************************************************************************** 4 * * 5 * CHECKSUM * 6 * This routine is designed to calculate a ones complement * 7 * checksum as fast as practical. We use this clever table to * 8 * almost completely remove any loop overhead from our checksum * 9 * timing. A CPU 4 with an SMU will do a checksum in about 3 * 10 * milliseconds per block. A CPU3 with an MCU will still be * 11 * only about 5 milliseconds per block. * 12 * Call: * 13 * R3 = block word length * 14 * R4 = address of block * 15 * CALLNP CHECKSUM * 16 * * 17 * * 18 * Eats R0:R2 * 19 * * 20 ********************************************************************************** 21 22 CHECKSUM BLOCK checksum routine 23 ENTRY CHECKSUM 24 00000007 ABS 25 LOGTABSIZ EQU 7 size of add table 26 040DC DD5F8001 6 STAK 27 CHECKSUM ENTRNP STAK SP,1 040DD EC170804 4 BASE 28 STZ R4,PHSCKSUM clear checksum loc in physical record 040DE 604AC190 1 3 CBM 29 LD R1 R3/BITS 0:(31-LOGTABSIZ) get number of blocks 040DF 604A4E00 1 1 CBM 30 LD R1 R1/BITS LOGTABSIZ:(LOGTABSIZ-1) make block number into offset 040E0 708AF270 2 3 CBM 31 LDN R2 R3/BITS (32-LOGTABSIZ):31 get the offset 040E1 18844167 2 IMM 32 ADD R2 ADR LOOPTOP(128) generate entry address 040E2 58840004 IMM 33 CLBPSR PSRCARRY clear the carry bit 040E3 58C40010 IMM 34 IORPSR PSRMODIF turn on modified arithmetic 040E4 60040000 0 IMM 35 LD R0 0 initialize the checksum 040E5 5C928000 2 REG 36 LDPC R2 and start the operation 37 * --- 38 000040E6 39 RELOOP LABEL 040E6 604A4E00 1 1 CBM 40 LD R1 R1/BITS LOGTABSIZ:(LOGTABSIZ-1) make block number into offset 000040E7 41 LOOPTOP LABEL 040E7 181D087F 0 41 BASE 42 ADD R0 R4,127(R1) 040E8 181D087E 0 41 BASE 43 ADD R0 R4,126(R1) 040E9 181D087D 0 41 BASE 44 ADD R0 R4,125(R1) 040EA 181D087C 0 41 BASE 45 ADD R0 R4,124(R1) 040EB 181D087B 0 41 BASE 46 ADD R0 R4,123(R1) 040EC 181D087A 0 41 BASE 47 ADD R0 R4,122(R1) 040ED 181D0879 0 41 BASE 48 ADD R0 R4,121(R1) 040EE 181D0878 0 41 BASE 49 ADD R0 R4,120(R1) 040EF 181D0877 0 41 BASE 50 ADD R0 R4,119(R1) 040F0 181D0876 0 41 BASE 51 ADD R0 R4,118(R1) 040F1 181D0875 0 41 BASE 52 ADD R0 R4,117(R1) 040F2 181D0874 0 41 BASE 53 ADD R0 R4,116(R1) 040F3 181D0873 0 41 BASE 54 ADD R0 R4,115(R1) 040F4 181D0872 0 41 BASE 55 ADD R0 R4,114(R1) 040F5 181D0871 0 41 BASE 56 ADD R0 R4,113(R1) 040F6 181D0870 0 41 BASE 57 ADD R0 R4,112(R1) 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 191 (DTCHECKSUM) F 26 Cryptor's Definitions 040F7 181D086F 0 41 BASE 58 ADD R0 R4,111(R1) 040F8 181D086E 0 41 BASE 59 ADD R0 R4,110(R1) 040F9 181D086D 0 41 BASE 60 ADD R0 R4,109(R1) 040FA 181D086C 0 41 BASE 61 ADD R0 R4,108(R1) 040FB 181D086B 0 41 BASE 62 ADD R0 R4,107(R1) 040FC 181D086A 0 41 BASE 63 ADD R0 R4,106(R1) 040FD 181D0869 0 41 BASE 64 ADD R0 R4,105(R1) 040FE 181D0868 0 41 BASE 65 ADD R0 R4,104(R1) 040FF 181D0867 0 41 BASE 66 ADD R0 R4,103(R1) 04100 181D0866 0 41 BASE 67 ADD R0 R4,102(R1) 04101 181D0865 0 41 BASE 68 ADD R0 R4,101(R1) 04102 181D0864 0 41 BASE 69 ADD R0 R4,100(R1) 04103 181D0863 0 41 BASE 70 ADD R0 R4,99(R1) 04104 181D0862 0 41 BASE 71 ADD R0 R4,98(R1) 04105 181D0861 0 41 BASE 72 ADD R0 R4,97(R1) 04106 181D0860 0 41 BASE 73 ADD R0 R4,96(R1) 04107 181D085F 0 41 BASE 74 ADD R0 R4,95(R1) 04108 181D085E 0 41 BASE 75 ADD R0 R4,94(R1) 04109 181D085D 0 41 BASE 76 ADD R0 R4,93(R1) 0410A 181D085C 0 41 BASE 77 ADD R0 R4,92(R1) 0410B 181D085B 0 41 BASE 78 ADD R0 R4,91(R1) 0410C 181D085A 0 41 BASE 79 ADD R0 R4,90(R1) 0410D 181D0859 0 41 BASE 80 ADD R0 R4,89(R1) 0410E 181D0858 0 41 BASE 81 ADD R0 R4,88(R1) 0410F 181D0857 0 41 BASE 82 ADD R0 R4,87(R1) 04110 181D0856 0 41 BASE 83 ADD R0 R4,86(R1) 04111 181D0855 0 41 BASE 84 ADD R0 R4,85(R1) 04112 181D0854 0 41 BASE 85 ADD R0 R4,84(R1) 04113 181D0853 0 41 BASE 86 ADD R0 R4,83(R1) 04114 181D0852 0 41 BASE 87 ADD R0 R4,82(R1) 04115 181D0851 0 41 BASE 88 ADD R0 R4,81(R1) 04116 181D0850 0 41 BASE 89 ADD R0 R4,80(R1) 04117 181D084F 0 41 BASE 90 ADD R0 R4,79(R1) 04118 181D084E 0 41 BASE 91 ADD R0 R4,78(R1) 04119 181D084D 0 41 BASE 92 ADD R0 R4,77(R1) 0411A 181D084C 0 41 BASE 93 ADD R0 R4,76(R1) 0411B 181D084B 0 41 BASE 94 ADD R0 R4,75(R1) 0411C 181D084A 0 41 BASE 95 ADD R0 R4,74(R1) 0411D 181D0849 0 41 BASE 96 ADD R0 R4,73(R1) 0411E 181D0848 0 41 BASE 97 ADD R0 R4,72(R1) 0411F 181D0847 0 41 BASE 98 ADD R0 R4,71(R1) 04120 181D0846 0 41 BASE 99 ADD R0 R4,70(R1) 04121 181D0845 0 41 BASE 100 ADD R0 R4,69(R1) 04122 181D0844 0 41 BASE 101 ADD R0 R4,68(R1) 04123 181D0843 0 41 BASE 102 ADD R0 R4,67(R1) 04124 181D0842 0 41 BASE 103 ADD R0 R4,66(R1) 04125 181D0841 0 41 BASE 104 ADD R0 R4,65(R1) 04126 181D0840 0 41 BASE 105 ADD R0 R4,64(R1) 04127 181D083F 0 41 BASE 106 ADD R0 R4,63(R1) 04128 181D083E 0 41 BASE 107 ADD R0 R4,62(R1) 04129 181D083D 0 41 BASE 108 ADD R0 R4,61(R1) 0412A 181D083C 0 41 BASE 109 ADD R0 R4,60(R1) 0412B 181D083B 0 41 BASE 110 ADD R0 R4,59(R1) 0412C 181D083A 0 41 BASE 111 ADD R0 R4,58(R1) 0412D 181D0839 0 41 BASE 112 ADD R0 R4,57(R1) 0412E 181D0838 0 41 BASE 113 ADD R0 R4,56(R1) 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 192 (DTCHECKSUM) F 26 Cryptor's Definitions 0412F 181D0837 0 41 BASE 114 ADD R0 R4,55(R1) 04130 181D0836 0 41 BASE 115 ADD R0 R4,54(R1) 04131 181D0835 0 41 BASE 116 ADD R0 R4,53(R1) 04132 181D0834 0 41 BASE 117 ADD R0 R4,52(R1) 04133 181D0833 0 41 BASE 118 ADD R0 R4,51(R1) 04134 181D0832 0 41 BASE 119 ADD R0 R4,50(R1) 04135 181D0831 0 41 BASE 120 ADD R0 R4,49(R1) 04136 181D0830 0 41 BASE 121 ADD R0 R4,48(R1) 04137 181D082F 0 41 BASE 122 ADD R0 R4,47(R1) 04138 181D082E 0 41 BASE 123 ADD R0 R4,46(R1) 04139 181D082D 0 41 BASE 124 ADD R0 R4,45(R1) 0413A 181D082C 0 41 BASE 125 ADD R0 R4,44(R1) 0413B 181D082B 0 41 BASE 126 ADD R0 R4,43(R1) 0413C 181D082A 0 41 BASE 127 ADD R0 R4,42(R1) 0413D 181D0829 0 41 BASE 128 ADD R0 R4,41(R1) 0413E 181D0828 0 41 BASE 129 ADD R0 R4,40(R1) 0413F 181D0827 0 41 BASE 130 ADD R0 R4,39(R1) 04140 181D0826 0 41 BASE 131 ADD R0 R4,38(R1) 04141 181D0825 0 41 BASE 132 ADD R0 R4,37(R1) 04142 181D0824 0 41 BASE 133 ADD R0 R4,36(R1) 04143 181D0823 0 41 BASE 134 ADD R0 R4,35(R1) 04144 181D0822 0 41 BASE 135 ADD R0 R4,34(R1) 04145 181D0821 0 41 BASE 136 ADD R0 R4,33(R1) 04146 181D0820 0 41 BASE 137 ADD R0 R4,32(R1) 04147 181D081F 0 41 BASE 138 ADD R0 R4,31(R1) 04148 181D081E 0 41 BASE 139 ADD R0 R4,30(R1) 04149 181D081D 0 41 BASE 140 ADD R0 R4,29(R1) 0414A 181D081C 0 41 BASE 141 ADD R0 R4,28(R1) 0414B 181D081B 0 41 BASE 142 ADD R0 R4,27(R1) 0414C 181D081A 0 41 BASE 143 ADD R0 R4,26(R1) 0414D 181D0819 0 41 BASE 144 ADD R0 R4,25(R1) 0414E 181D0818 0 41 BASE 145 ADD R0 R4,24(R1) 0414F 181D0817 0 41 BASE 146 ADD R0 R4,23(R1) 04150 181D0816 0 41 BASE 147 ADD R0 R4,22(R1) 04151 181D0815 0 41 BASE 148 ADD R0 R4,21(R1) 04152 181D0814 0 41 BASE 149 ADD R0 R4,20(R1) 04153 181D0813 0 41 BASE 150 ADD R0 R4,19(R1) 04154 181D0812 0 41 BASE 151 ADD R0 R4,18(R1) 04155 181D0811 0 41 BASE 152 ADD R0 R4,17(R1) 04156 181D0810 0 41 BASE 153 ADD R0 R4,16(R1) 04157 181D080F 0 41 BASE 154 ADD R0 R4,15(R1) 04158 181D080E 0 41 BASE 155 ADD R0 R4,14(R1) 04159 181D080D 0 41 BASE 156 ADD R0 R4,13(R1) 0415A 181D080C 0 41 BASE 157 ADD R0 R4,12(R1) 0415B 181D080B 0 41 BASE 158 ADD R0 R4,11(R1) 0415C 181D080A 0 41 BASE 159 ADD R0 R4,10(R1) 0415D 181D0809 0 41 BASE 160 ADD R0 R4,9(R1) 0415E 181D0808 0 41 BASE 161 ADD R0 R4,8(R1) 0415F 181D0807 0 41 BASE 162 ADD R0 R4,7(R1) 04160 181D0806 0 41 BASE 163 ADD R0 R4,6(R1) 04161 181D0805 0 41 BASE 164 ADD R0 R4,5(R1) 04162 181D0804 0 41 BASE 165 ADD R0 R4,4(R1) 04163 181D0803 0 41 BASE 166 ADD R0 R4,3(R1) 04164 181D0802 0 41 BASE 167 ADD R0 R4,2(R1) 04165 181D0801 0 41 BASE 168 ADD R0 R4,1(R1) 04166 181D0800 0 41 BASE 169 ADD R0 R4,0(R1) 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 193 (DTCHECKSUM) F 26 Cryptor's Definitions 170 * \ / end of table 04167 604A4190 1 1 CBM 171 LD R1 R1/BITS 0:(31-LOGTABSIZ) get number of blocks 04168 FA6640E6 1 172 JDR R1 RELOOP if more to do, go back 173 * \ / done with checksum 04169 18040000 0 IMM 174 ADD R0 0 add in final carry 0416A 58840010 IMM 175 CLBPSR PSRMODIF restore normal arithmetic 0416B 7407FFFF 0 IMM 176 XOR R0 0FFFFFFFF make ones complement 0416C E4170804 0 4 BASE 177 ST R0 R4,PHSCKSUM and store into physical record 0416D 5D1F8001 6 STAK 178 LEAVE STAK SP,1 return to caller 179 * --- 180 181 END CHECKSUM of checksum routine 1646 INPUT DISKTOTAPE.OPSYS:DTTWRITE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 194 (DTTWRITE) F 27 Tape Writing Process 3 4 ********************************************************************************** 5 * * 6 * The tape writing process removes elements from the * 7 * tape write queue and writes them to mag tape. The tape * 8 * drive is opened in the initialization process for * 9 * DISKTOTAPE, and the tape control block resides in TAPECB. * 10 * This process is responsible for adding in the * 11 * necessary records for tape control purposes, detecting and * 12 * marking end of tape, selecting a new track if CT, and * 13 * requesting a new tape from the user. * 14 * If the tape gets too flaky (or tape drive) we will * 15 * halt and the user is screwed. It is not advisable at this * 16 * time to run DiskToTape to a BTI provided 9-track due to the * 17 * absolute shittiness and unreliablilty of the hardware. * 18 * * 19 ********************************************************************************** 20 21 TAPEWRITER BLOCK 22 23 ENTRY TAPEWRITE 24 ENTRY WRITEINIT 25 0000416E 26 TAPEWRITE LABEL 0416E 6380498E 67 27 LD2 SP WRITESPR7 restore these 0416F 5C80498D 28 LDPC WRITEPC 29 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 195 (DTTWRITE) F 27 Tape Writing Process 31 00004170 32 WRITEINIT LABEL 04170 618449D2 6 IMM 33 LD SP ADR WRITESTACK initialize stack pointer 04171 EDC04991 34 STW TAPENUM initialize tape counter 04172 6104483C 4 IMM 35 LD R4 ADR TAPECB R4 -> tape control block 04173 DC4043CE 36 CALLNP SETTAPE select the track and rewind (if CT) 37 04174 DC4041BA 38 CALLNP GETTWQENT get the first entry from the TWQ 04175 FE0E418F 39 JMP WRITEDEATH should not get either alternate returns 04176 FE0E418F 40 JMP WRITEDEATH 04177 E5404990 5 41 ST R5 WRTFSLRPREL save the pointer to file set record header 04178 DC404246 42 CALLNP WRITEFSLR write the beginning records 04179 FE0E4198 43 JMP BADFSLR if error 0417A 60008C00 0 44 LD R0 WRITEPRLOC R0 -> file set logical record 0417B EC16080C 0 BASE 45 STZ R0,PHSLOGDATA/BOOTINFO no boot info on the next tape 46 0000417C 47 WRITELOOP LABEL 0417C DC4041BA 48 CALLNP GETTWQENT get next entry from write queue 0417D FE0E41AC 49 JMP MARKTBM jump if concerns tape boot make info 0417E FE0E41B4 50 JMP ENDFILESET if at end of file set 51 0417F DC00345C 52 CALL MAPINPR map in the physical record 04180 404400A3 IMM 53 PARVL WRITEPRPN where to map it 54 04181 60848C00 2 IMM 55 LD R2 ADR WRITEPRLOC R2 -> physical record's location 04182 18974802 2 5 BASE 56 ADD R2 R5,PRELPRINX add index into page for record's start 57 04183 60496101 1 5 ZBM 58 LD R1 R5,PRELPRLEN number of words to write 04184 1C440004 1 IMM 59 MUL R1 CPW convert to character count 04185 6104483C 4 IMM 60 LD R4 ADR TAPECB R4 -> tape control block 04186 DC0042FF 61 CALL WRITETAPE write the thing on tape 04187 41568800 2 BASE 62 PARV R2,PHSSEQNUM pass sequence number for error log 04188 41524000 1 REG 63 PARV R1 how much to write 04189 40168400 2 @R 64 PARL @R2 where to take stuff to write from 0418A FE0E418E 65 JMP TAPEERROR error writing to tape 0418B FE0E4190 66 JMP ENDOFTAPE end of tape has been sighted 0000418C 67 RTNPREL LABEL 0418C DC40347C 68 CALLNP FREEALL return the pages and PREL to free space 0418D FE0E417C 69 JMP WRITELOOP keep on writing 70 * --- 71 0000418E 72 TAPEERROR LABEL 0418E 00173230 73 HALT HALTW3230 could not write on tape, die for now 74 * --- 75 0000418F 76 WRITEDEATH LABEL 0418F 00173231 77 HALT HALTW3231 first record on TWQ was not fileset 78 * --- logical record 79 00004190 80 ENDOFTAPE LABEL 04190 DC40347C 81 CALLNP FREEALL return the pages and PREL to free space 04191 6104483C 4 IMM 82 LD R4 ADR TAPECB R4 -> tape control block 04192 DC4041D3 83 CALLNP TAPEENDREC build an end of tape record 04193 FE0E4197 84 JMP TAPEENDERR 00004194 85 GETNEWTAPE LABEL 04194 DC40421E 86 CALLNP SWITCHTAPE go switch tapes (or tracks) 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 196 (DTTWRITE) F 27 Tape Writing Process 04195 FE0E4198 87 JMP BADFSLR if error 04196 FE0E417C 88 JMP WRITELOOP 89 * --- 90 00004197 91 TAPEENDERR LABEL 04197 00173233 92 HALT HALTW3233 could not write on tape, die for now 93 * --- 94 00004198 95 BADFSLR LABEL 04198 DC1013F9 @ 96 CALL @VPREPOUT complain about the new tape 04199 400041A0 97 PARL BADTAPMES what to say 0419A D0404991 98 DEC TAPENUM since the last tape didn't count 0419B 5C170802 4 BASE 99 CMZ R4,TPCBTRACK see if this is MT 0419C FE084194 100 JLT GETNEWTAPE if so don't reset the track 0419D 60040003 0 IMM 101 LD R0 3 last usable track on DEI 0419E E4170802 0 4 BASE 102 ST R0 R4,TPCBTRACK set to last track to force a new tape 0419F FE0E4194 103 JMP GETNEWTAPE 104 * --- 105 041A0 20436F75 106 BADTAPMES TEXTZ " Could not write on tape. Try a different one." 107 108 ********************************************************************************** 109 * * 110 * We arrive here when we have found a TBM type PREL. There * 111 * are three types. If this tape is not from a system volume, * 112 * there will be a TBMNONE marker indicating that tape boot is * 113 * not present on this tape. Previous processes have used that * 114 * information, but we merely discard the PREL and continue * 115 * processing. * 116 * If this is a system volume tape, the tape boot information * 117 * will be bracketed by a TBMBEGIN and TBMEND. On the tape, the * 118 * tape boot information should be bracketed by file marks, so * 119 * TBMBEGIN and TBMEND cause the tape writer to write those file * 120 * marks on the tape. * 121 * * 122 ********************************************************************************** 123 000041AC 124 MARKTBM LABEL 041AC 60174801 0 5 BASE 125 LD R0 R5,PRELTBM check type of TBM PREL 041AD 64040000 0 IMM 126 CPR R0 TBMNONE check for tape with no boot info 041AE FE02418C 127 JEQ RTNPREL jump if such, discarding PREL 041AF DC403471 128 CALLNP PRELRETURN return TBM marker PREL 041B0 6104483C 4 IMM 129 LD R4 ADR TAPECB R4 -> tape control block 041B1 DC4043B9 130 CALLNP WRITEFM write the file mark 041B2 00173232 131 HALT HALTW3232 tape error while writing file mark 041B3 FE0E417C 132 JMP WRITELOOP 133 * --- 134 000041B4 135 ENDFILESET LABEL 041B4 DC4041F9 136 CALLNP ENDFSREC do an end of fileset record 041B5 00173234 137 HALT HALTW3234 tape error at very end 041B6 FE0E3038 138 JMP DUMPDONE all done 139 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 197 (DTTWRITE) F 27 Tape Writing Process 141 142 ********************************************************************************** 143 * * 144 * Call: * 145 * JSR R0 SAVEWRITST * 146 * Eats R0:R5 * 147 * * 148 ********************************************************************************** 149 000041B7 150 SAVEWRITST LABEL 041B7 E400498D 0 151 ST R0 WRITEPC 041B8 E780498E 67 152 ST2 SP WRITESPR7 save these 041B9 FE0E3194 153 JMP DONETAPE 154 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 198 (DTTWRITE) F 27 Tape Writing Process 156 157 ********************************************************************************** 158 * * 159 * GETTWQENT -- Get a tape write queue entry * 160 * * 161 * This subroutine gets the next entry from the tape write * 162 * queue. * 163 * We will save our state and return to the scheduler if the * 164 * queue is empty so this will always return a queue entry. * 165 * * 166 * Call: * 167 * CALLNP GETTWQENT * 168 * JMP * 169 * JMP * 170 * * 171 * Returns R5 -> PREL from queue * 172 * Eats R0:R5 * 173 * * 174 ********************************************************************************** 175 176 GETTWQENT BLOCK 177 178 ENTRY GETTWQENT 179 180 BEGFRAME 181 ENDFRAME 182 041BA DD5F8001 6 STAK 183 GETTWQENT ENTRNP PUSH 000041BB 184 RETRY LABEL 185 LLOCK TAPEQLOCK 041BF 61404811 5 186 LD R5 TAPEQHEAD get the first entry 041C0 FB4241D0 5 187 JEQZ R5 NOENTRIES jump if nothing is there 041C1 60095F10 0 5 ZBM 188 LD R0 R5,PRELLINK get pointer to next entry 041C2 E4004811 0 189 ST R0 TAPEQHEAD put in new head 041C3 FA0C41C6 0 190 JNEZ R0 GETTWQEND don't reset tail pointer if not last element 191 * \ / 041C4 60044811 0 IMM 192 LD R0 ADR TAPEQHEAD RO -> tape write queue's head 041C5 E4004812 0 193 ST R0 TAPEQTAIL make the tail point to the head 194 * \ / 000041C6 195 GETTWQEND LABEL 041C6 D0404813 196 DEC TAPEQCNT fix counter of elements 041C7 EC004814 197 STZ TAPEQLOCK unlock the list 041C8 60094040 0 5 ZBM 198 LD R0 R5,PRELTYPE get the type code 041C9 64040004 0 IMM 199 CPR R0 TEOV see if it is end of volume 041CA FE0241CE 200 JEQ ENDVOL if so don't advance return 041CB 64040003 0 IMM 201 CPR R0 TTBM see if it is a tapebootmake info marker 041CC FE0241CF 202 JEQ TBMMARKER if so don't advance return 203 * \ / 204 041CD 19C40001 7 IMM 205 ADD R7 1 not end of tapeboot make info 000041CE 206 ENDVOL LABEL 041CE 19C40001 7 IMM 207 ADD R7 1 not end of volume 000041CF 208 TBMMARKER LABEL 041CF 5D1F8001 6 STAK 209 LEAVE POP 210 * --- 211 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 199 (DTTWRITE) F 27 Tape Writing Process 000041D0 212 NOENTRIES LABEL 041D0 EC004814 213 STZ TAPEQLOCK release list 041D1 FA2841B7 0 214 JSR R0 SAVEWRITST off to see the scheduler 041D2 FE0E41BB 215 JMP RETRY get the lock again 216 * --- 217 218 END GETTWQENT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 200 (DTTWRITE) F 27 Tape Writing Process 220 221 ********************************************************************************** 222 * * 223 * TAPEENDREC -- Make a End-of-Tape Record * 224 * * 225 * Here we build a end of tape record in WRITEBUF and * 226 * write it with its enclosing file marks on to the tape. * 227 * * 228 * Call: * 229 * R4 -> * 230 * CALLNP TAPEENDREC * 231 * JMP fatal error * 232 * * 233 * Eats R0:R5 * 234 * * 235 ********************************************************************************** 236 237 TAPEENDREC BLOCK 238 239 ENTRY TAPEENDREC 240 241 BEGFRAME 242 ENDFRAME 243 041D3 DD5F8001 6 STAK 244 TAPEENDREC ENTRNP PUSH 041D4 DC4043B9 245 CALLNP WRITEFM write the file mark 041D5 FE0E41F8 246 JMP BADERR on error 247 248 * build physical record header 041D6 60C449D2 3 IMM 249 LD R3 ADR WRITEBUF R3 -> record 250 041D7 EC16C800 3 BASE 251 STZ R3,PHSSEQNUM use zero for the physical sequence number 041D8 EC16C803 3 BASE 252 STZ R3,PHSDSEQNUM and the copy 041D9 EC08C012 3 ZBM 253 STZ R3,PHSNCRYPTD unencrypted physical record 041DA EC16C805 3 BASE 254 STZ R3,PHSREQCNT say no carry over logical record 041DB EC08C212 3 ZBM 255 STZ R3,PHSFILEDO not just file data 041DC 3896C806 2 3 BASE 256 LEA R2 R3,PHSFILLER want to zero fill the filler 041DD 60440004 1 IMM 257 LD R1 CPW*PHSFILLSIZ how much to fill 041DE FE580000 258 CFILL 00 all zeroes 259 260 * build logical record header 041DF 18C40007 3 IMM 261 ADD R3 PHSHDRLEN move record pointer beyond physical header 041E0 DC003CF7 262 CALL PACKLOGREC time to put in the logical header 041E1 40440002 IMM 263 PARVL RTYPESWCH end of tape or track 041E2 60040008 0 IMM 264 LD R0 TPERECLEN length of this logical record 041E3 E408E100 0 3 ZBM 265 ST R0 R3,LOGRECIFL put in the header 266 041E4 60004991 0 267 LD R0 TAPENUM this tape's number 041E5 E416C801 0 3 BASE 268 ST R0 R3,TAPENDNUM into the record 041E6 62004822 01 269 LD2 R0 STARTTIME get time stamp 041E7 E616C802 013 BASE 270 ST2 R0 R3,TAPENDTIME put in the record 041E8 3896C804 2 3 BASE 271 LEA R2 R3,TAPENDFIL want to zero fill the filler 041E9 60440010 1 IMM 272 LD R1 CPW*TPENDFILLN how much to fill 041EA FE580000 273 CFILL 00 all zeroes 274 041EB 610449D2 4 IMM 275 LD R4 ADR WRITEBUF get address of buffer 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 201 (DTTWRITE) F 27 Tape Writing Process 041EC 60C4003C 3 IMM 276 LD R3 (PHSHDRLEN+TPERECLEN)*CPW and its size 041ED DC4040DC 277 CALLNP CHECKSUM generate its checksum 278 * \ / 279 041EE 6104483C 4 IMM 280 LD R4 ADR TAPECB R4 -> tape control block 041EF DC0042FF 281 CALL WRITETAPE write the thing on tape 041F0 41440000 IMM 282 PARV 0 no sequence number available 041F1 4144003C IMM 283 PARV (PHSHDRLEN+TPERECLEN)*CPW how much to write 041F2 400049D2 284 PARL WRITEBUF where to take stuff to write from 041F3 FE0E41F8 285 JMP BADERR error on write 041F4 FEC00000 286 NOP 0 end of tape has been sighted (no shit) 287 041F5 DC4043B9 288 CALLNP WRITEFM write the file mark 041F6 FE0E41F8 289 JMP BADERR on error 290 041F7 19C40001 7 IMM 291 ADD R7 1 good return 000041F8 292 BADERR LABEL 041F8 5D1F8001 6 STAK 293 LEAVE POP 294 * --- 295 296 END TAPEENDREC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 202 (DTTWRITE) F 27 Tape Writing Process 298 299 ********************************************************************************** 300 * * 301 * ENDFSREC -- End of fileset logical record * 302 * * 303 * This subroutine creates and writes to tape an end * 304 * of fileset logical record. This record gets its own * 305 * physical record and is preceded and followed by a file * 306 * mark. * 307 * Call: * 308 * CALLNP ENDFSREC * 309 * * 310 * * 311 * Eats R0:R4 * 312 * * 313 ********************************************************************************** 314 315 ENDFSREC BLOCK 316 317 ENTRY ENDFSREC 318 319 BEGFRAME 320 ENDFRAME 321 041F9 DD5F8001 6 STAK 322 ENDFSREC ENTRNP PUSH 041FA 6104483C 4 IMM 323 LD R4 ADR TAPECB R4 -> tape control block 041FB DC4043B9 324 CALLNP WRITEFM write the file mark 041FC FE0E421D 325 JMP EFRWERR if error 326 327 * build physical record header 041FD 60C449D2 3 IMM 328 LD R3 ADR WRITEBUF R3 -> record 329 041FE EC16C800 3 BASE 330 STZ R3,PHSSEQNUM use zero for the sequence number 041FF EC16C803 3 BASE 331 STZ R3,PHSDSEQNUM and the the duplicate sequence number 04200 EC08C012 3 ZBM 332 STZ R3,PHSNCRYPTD unencrypted physical record 04201 EC16C805 3 BASE 333 STZ R3,PHSREQCNT say no carry over logical record 04202 EC08C212 3 ZBM 334 STZ R3,PHSFILEDO not just file data 04203 3896C806 2 3 BASE 335 LEA R2 R3,PHSFILLER want to zero fill the filler 04204 60440004 1 IMM 336 LD R1 CPW*PHSFILLSIZ how much to fill 04205 FE580000 337 CFILL 00 all zeroes 338 339 * build logical record header 04206 18C40007 3 IMM 340 ADD R3 PHSHDRLEN move record pointer beyond physical header 04207 DC003CF7 341 CALL PACKLOGREC time to put in the logical header 04208 40440001 IMM 342 PARVL RTYPEESET end of file set 04209 60040007 0 IMM 343 LD R0 SVERECLEN length of this logical record 0420A E408E100 0 3 ZBM 344 ST R0 R3,LOGRECIFL put in the header 345 0420B 62004822 01 346 LD2 R0 STARTTIME get time stamp 0420C E616C801 013 BASE 347 ST2 R0 R3,ENDTIME put in the record 0420D 3896C803 2 3 BASE 348 LEA R2 R3,ENDFILLER want to zero fill the filler 0420E 60440010 1 IMM 349 LD R1 CPW*ENDFILLEN how much to fill 0420F FE580000 350 CFILL 00 all zeroes 351 04210 610449D2 4 IMM 352 LD R4 ADR WRITEBUF get address of buffer 04211 60C40038 3 IMM 353 LD R3 (PHSHDRLEN+SVERECLEN)*CPW and its size 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 203 (DTTWRITE) F 27 Tape Writing Process 04212 DC4040DC 354 CALLNP CHECKSUM generate its checksum 355 * \ / 356 04213 6104483C 4 IMM 357 LD R4 ADR TAPECB R4 -> tape control block 04214 DC0042FF 358 CALL WRITETAPE write the thing on tape 04215 41440000 IMM 359 PARV 0 no sequence number available 04216 41440038 IMM 360 PARV (PHSHDRLEN+SVERECLEN)*CPW how much to write 04217 400049D2 361 PARL WRITEBUF where to take stuff to write from 04218 FE0E421D 362 JMP EFRWERR error writing to tape 04219 FEC00000 363 NOP 0 end of tape has been sighted 364 0421A DC4043B9 365 CALLNP WRITEFM write the file mark 0421B FE0E421D 366 JMP EFRWERR 0421C 19C40001 7 IMM 367 ADD R7 1 advance to skip return 0000421D 368 EFRWERR LABEL 0421D 5D1F8001 6 STAK 369 LEAVE POP 370 * --- 371 372 END ENDFSREC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 204 (DTTWRITE) F 27 Tape Writing Process 374 375 ********************************************************************************** 376 * * 377 * SWITCHTAPE * 378 * * 379 * We come here when a tape end has been reached. * 380 * Now either a new tape is requested or we switch tracks * 381 * (CT only). All necessary tape beginning stuff is * 382 * handled here. * 383 * * 384 * Call: * 385 * LD R4 ADR * 386 * CALLNP SWITCHTAPE * 387 * JMP error writing file set logical record * 388 * * 389 * Eats R0:R3 * 390 * * 391 ********************************************************************************** 392 393 SWITCHTAPE BLOCK 394 395 ENTRY SWITCHTAPE 396 397 BEGFRAME 00178801 6 BASE 398 TEMPR4 BSS 1 temp for R4 399 ENDFRAME 400 0421E DD5F8002 6 STAK 401 SWITCHTAPE ENTRNP PUSH 0421F 5C170802 4 BASE 402 CMZ R4,TPCBTRACK see if we have a 9-track tape 04220 FE084231 403 JLT JUSTREWIND jump if so, we need a new tape 04221 BC170802 0 4 BASE 404 INCL R0 R4,TPCBTRACK bump up the track number 04222 64040004 0 IMM 405 CPR R0 4 see if we have exceeded the number of tracks 04223 FE064230 406 JGE GETNEWCT if so then ask for a new tape 407 * \ / 04224 DC4043CE 408 CALLNP SETTAPE select track and rewind 409 * \ / 00004225 410 SWITCHDONE LABEL 04225 19C40001 7 IMM 411 ADD R7 1 00004226 412 ERRETURN LABEL 04226 5D1F8002 6 STAK 413 LEAVE POP 414 * --- 415 04227 2A07496E 416 ASK4MESS TEXTZ "*Insert tape #\D1\ and enter OK. " 417 00004230 418 GETNEWCT LABEL 04230 EC170802 4 BASE 419 STZ R4,TPCBTRACK set to track zero 00004231 420 JUSTREWIND LABEL 04231 DC4043D5 421 CALLNP REWIND and rewind the tape 04232 D0004991 422 INC TAPENUM allocate new tape number 423 04233 E5178801 4 6 BASE 424 ST R4 SP,TEMPR4 save R4 from I/O routines 00004234 425 ASKAGAIN LABEL 04234 DC1013F9 @ 426 CALL @VPREPOUT ask for a new tape 04235 41004991 427 PAR TAPENUM desired tape number 04236 40004227 428 PARL ASK4MESS what we will ask 429 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 205 (DTTWRITE) F 27 Tape Writing Process 04237 60440050 1 IMM 430 LD R1 BUFL buffer length 04238 60844827 2 IMM 431 LD R2 ADR BUF start of the thing 04239 DC5013F3 @ 432 CALLNP @VREADLINE read a line 0423A 30440050 1 IMM 433 RSB R1 BUFL see what's left 0423B FA4A4234 1 434 JLEZ R1 ASKAGAIN ask again if we didn't get anything 435 * \ / 436 0423C EC3248CB 1 @ 437 STZ @BUFP(R1) 0423D 610048CB 4 438 LD R4 BUFP R4 -> beginning of input buffer 0423E DC5013F5 @ 439 CALLNP @VFETCHITEM get parameter 0423F 648048D0 2 440 CPR R2 PACKOK is it an OK response? 04240 FE0C4234 441 JNE ASKAGAIN if not then make them get it right 442 * \ / 443 04241 61178801 4 6 BASE 444 LD R4 SP,TEMPR4 get our tape control block pointer back 04242 DC4043CE 445 CALLNP SETTAPE set the new track and rewind 04243 DC404246 446 CALLNP WRITEFSLR write the file set logical record 04244 FE0E4226 447 JMP ERRETURN if errors 04245 FE0E4225 448 JMP SWITCHDONE 449 * --- 450 451 END SWITCHTAPE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 206 (DTTWRITE) F 27 Tape Writing Process 453 454 ********************************************************************************** 455 * * 456 * WRITEFSLR -- Write file set logical record * 457 * * 458 * The file set logical record is contained in its own * 459 * physical record. The PREL for this record is pointed to * 460 * by WRTFSLRPREL and is always kept around for we never know * 461 * when we might need it. Here we put in the physical record * 462 * sequence number and tape number, checksum the record, then * 463 * write the physical record twice since that is how it is * 464 * supposed to be done. * 465 * Call: * 466 * CALLNP WRITEFSLR * 467 * JMP error * 468 * * 469 * Returns R4 -> tape control block * 470 * Eats R0:R5 * 471 * * 472 ********************************************************************************** 473 474 WRITEFSLR BLOCK 475 476 ENTRY WRITEFSLR 477 478 BEGFRAME 00178801 6 BASE 479 COUNT BSS 1 counter for number of times we write 480 ENDFRAME 481 04246 DD5F8002 6 STAK 482 WRITEFSLR ENTRNP PUSH 04247 61404990 5 483 LD R5 WRTFSLRPREL R5 -> PREL for file set logical record 04248 DC00345C 484 CALL MAPINPR map in the physical record 04249 404400A3 IMM 485 PARVL WRITEPRPN where to map it to 486 487 * Put in the tape number and physical record sequence number 0424A 61048C00 4 IMM 488 LD R4 ADR WRITEPRLOC R4 -> record 0424B EC170800 4 BASE 489 STZ R4,PHSSEQNUM use zero for the sequence number 0424C EC170803 4 BASE 490 STZ R4,PHSDSEQNUM and the duplicate sequence number 0424D 60004991 0 491 LD R0 TAPENUM put next tape number 0424E E4170809 0 4 BASE 492 ST R0 R4,PHSHDRLEN/SETTAPNUM ... into the logical record 493 * Now re-checksum the block. Must be redone for each TAPENUM 0424F 60C96101 3 5 ZBM 494 LD R3 R5,PRELPRLEN size of record 04250 DC4040DC 495 CALLNP CHECKSUM generate its checksum 496 * \ / 497 04251 60040002 0 IMM 498 LD R0 2 since we write this twice 04252 E4178801 0 6 BASE 499 ST R0 SP,COUNT counter for short loop 04253 6104483C 4 IMM 500 LD R4 ADR TAPECB R4 -> tape control block 00004254 501 WRITEAGAIN LABEL 04254 60496101 1 5 ZBM 502 LD R1 R5,PRELPRLEN get length of record (in words) 04255 1C440004 1 IMM 503 MUL R1 CPW turn into char count 04256 DC0042FF 504 CALL WRITETAPE write the record to tape 04257 41440000 IMM 505 PARV 0 no sequence number available 04258 41524000 1 REG 506 PARV R1 how much to write 04259 40008C00 507 PARL WRITEPRLOC where stuff is to write 0425A FE0E425F 508 JMP ERRETURN 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 207 (DTTWRITE) F 27 Tape Writing Process 0425B FE0E425F 509 JMP ERRETURN screwed up if first thing written on tap 510 * reaches the end of tape 0425C D0578801 6 BASE 511 DEC SP,COUNT say once more through 0425D FE044254 512 JGT WRITEAGAIN do this twice 513 * \ / 514 0425E 19C40001 7 IMM 515 ADD R7 1 0000425F 516 ERRETURN LABEL 0425F 5D1F8002 6 STAK 517 LEAVE POP 518 * --- 519 520 END WRITEFSLR 521 522 END TAPEWRITER 1647 INPUT BOOT.OPSYS:ERRLOGBLK 1648 INPUT BOOT.OPSYS:TALON 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 208 (TALON) F 29 Off-Line Tape Driver 3 4 ********************************************************************************** 5 * * 6 * Revisions Date * 7 * --------- ---- * 8 * 1.0 8608 11 Aug 86 * 9 * Revisions list added. * 10 * Minor fixes in OPENTAPE. CHKHDR and CHKDATA * 11 * moved to TAPELOAD. * 12 * 1.1 8608a 27 Aug 86 * 13 * Major changes and bug fixes. * 14 * Tape write code and error logging added. Misc * 15 * mods to organization, resets, and PPUIWAIT. RC * 16 * 1.2 8701 07 Jan 87 * 17 * Tape reader nows returns error without retry * 18 * if buffer too small. RC * 19 * A8703 31 Mar 87 * 20 * Fix in previous fix. RC * 21 * A8811 28 Nov 88 * 22 * Fix to WRITEFM to use proper retry counter. * 23 * Change to OPENTAPE to remove MTCMRESET. * 24 * Mods to allow operation on VT. RC * 25 * A8907 20 Jul 89 * 26 * Changed to tell controller the read length * 27 * set up when only one page is being read. * 28 * This is to prevent hangs when reading from * 29 * the VT. Filled in VT error code table. RC * 30 * A8907a 23 Jul 89 * 31 * Fixes to new VT code and related stuff broken * 32 * in A8811. RC * 33 * **** may still need adjustment to timeouts **** * 34 * * 35 ********************************************************************************** 36 00130000 4 REG 37 MTU EQU R4 tape unit controller element pointer 38 39 TALON BLOCK offline tape driver 40 41 ENTRY OPENTAPE tape open routine 42 ENTRY PPUIWAIT routine to wait for interrupt 43 ENTRY READTAPE tape read routine 44 ENTRY REWIND tape rewind routine 45 ENTRY SEFF tape search EOF forward routine 46 ENTRY SEFB tape search EOF backward routine 47 ENTRY SETTAPE tape density/track select 48 ENTRY TAPEFUNC tape function routine 49 ENTRY WRITETAPE tape write routine 50 ENTRY WRITEFM tape write file mark routine 51 52 ********************************************************************************** 53 * * 54 * OFFLINE TAPE-DRIVER ROUTINES * 55 * * 56 * These offline routines perform the tape operations * 57 * for TAPEBOOT and DISKTOTAPE: * 58 * * 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 209 (TALON) F 29 Off-Line Tape Driver 59 * OPENTAPE - intialize tape control block * 60 * READTAPE - read a given number of bytes from the * 61 * tape and store at a specified address. * 62 * REWIND - rewind tape to BOT. * 63 * SEFF - seek an end-of-file forward. * 64 * SEFB - seek an end-of-file backward. * 65 * SETTAPE - select a track, and do rewind (if CTC). * 66 * TAPEFUNC - perform a tape operation with an input * 67 * of the tape op code. * 68 * WRITETAPE - write a given number of bytes to the * 69 * tape from a specified address. * 70 * WRITEFM - write a file mark onto the tape. * 71 * * 72 * error codes * 73 * 1 Bad unit number * 74 * 2 Bad channel number * 75 * 3 Bad slot number * 76 * 4 Device not a tape drive * 77 * 5 Tape drive not on-line (unused) * 78 * 6 Tape drive not ready * 79 * 7 Irrecoverable tape error * 80 * 8 File mark on read * 81 * 9 File name not found on tape * 82 * 0A Header checksum error (from TAPELOAD) * 83 * 0B Data checksum error (from TAPELOAD) * 84 * 0C drive is write protected * 85 * 0D this tape is not a bootable tape * 86 * * 87 * Misc Caveats. * 88 * This code is designed to work in the off-line * 89 * environment. It is gathered together from various places, * 90 * so the coding style and even the assumptions about how the * 91 * hardware works are not consistent. * 92 * Several changes have been made to restore consistency. * 93 * Most notably, some code (primarily write) was originally * 94 * written as if the PPU interrupt for rollover or DMA * 95 * completion had to be set in order to get the rollover or * 96 * completion status bits to come up. Other code just waited on * 97 * the status bits without ever enabling the relevant interrupt. * 98 * Since this latter seemed to work, the other was removed. * 99 * * 100 ********************************************************************************** 101 102 ********************************************************************************** 103 * * 104 * Global equates and variables * 105 * * 106 ********************************************************************************** 107 108 * mask for error bits in PPU status 00006540 ABS 109 PPUMASK EQU 1*PPUIXTRA+1*PPUIDPPE+1*PPUICONF+1*PPUIMPE+1*PPUIBCNR 00000014 ABS 110 TAPEERRMAX EQU 20 maximum number of retries 00040000 ABS 111 CATCHWAIT EQU 2 POWER 18 about 2.5 seconds of wait. 112 * used after PPU abort to allow 113 * controller to become idle. 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 210 (TALON) F 29 open tape routine 116 117 ********************************************************************************** 118 * * 119 * OPENTAPE. This routine will initialize a tape control * 120 * element. It will parse the tape name and, if not already * 121 * established, it will set up the tape unit controller element. * 122 * Call: * 123 * LD R4 => tape control element * 124 * LD R0 pak6 tape name (TAPscu), or zero * 125 * if tape unit is already set up. * 126 * CALLNP OPENTAPE * 127 * JNEZ R0 * 128 * * 129 * Sets R0, Eats R1:R3 * 130 * stack required = 1 * 131 * * 132 ********************************************************************************** 133 134 OPENTAPE BLOCK 135 ENTRY OPENTAPE 136 137 BEGFRAME 138 ENDFRAME 139 04260 B8E21A69 140 TAP000 PAK6 TAP000 base for tape name unpacker 141 04261 DD5F8001 6 STAK 142 OPENTAPE ENTRNP PUSH 04262 FA024274 0 143 JEQZ R0 HAVETAPE jump if tape unit already found 04263 EC170800 4 BASE 144 STZ MTU,TPCBPFILE clean out page file 04264 10004260 0 145 SUB R0 TAP000 R0 = (slot * 40 + chan) * 40 + unit 04265 58C40010 IMM 146 IORPSR PSRMODIF set funky arithmetic 04266 62120000 010 REG 147 LD2 R0 R0 04267 14040028 0 IMM 148 DIV R0 40 R0 = slot * 40 + chan, R1 = unit 04268 68440004 1 IMM 149 UCPR R1 NMTPUNITS check for allowable unit 04269 FE06428E 150 JGE BADUNIT jump if unit out of range 0426A E4570801 1 4 BASE 151 ST R1 MTU,TPCBUNIT save unit number 0426B 62120000 010 REG 152 LD2 R0 R0 0426C 14040028 0 IMM 153 DIV R0 40 R0 = slot, R1 = channel 0426D 68440004 1 IMM 154 UCPR R1 PPUCHANS check for allowable channel 0426E FE064290 155 JGE BADCHAN jump if channel out of range 0426F E4493020 1 4 ZBM 156 ST R1 MTU,TPCBPFILE/PPUCHAN save channel number 04270 68040010 0 IMM 157 UCPR R0 NUMSLOTS now compare against maximum slot number 04271 FE064292 158 JGE BADSLOT jump if slot out of range 04272 E4090840 0 4 ZBM 159 ST R0 MTU,TPCBPFILE/PFSLOT save slot number 04273 58840010 IMM 160 CLBPSR PSRMODIF restore normal arithmetic 161 162 * See if we really have a tape. 163 * \ / 00004274 164 HAVETAPE LABEL 04274 60090840 0 4 ZBM 165 LD R0 MTU,TPCBPFILE/PFSLOT R0 = PPU slot number 04275 60200370 0 0 166 LD R0 IBSLOTS(R0) R0 = WRU response from slot 04276 600A0040 0 0 CBM 167 LD R0 R0/WRU0TYPE R0 = type field of WRU0 response 04277 64040003 0 IMM 168 CPR R0 SLTTPPU is it a PPU? 04278 FE0C4292 169 JNE BADSLOT jump if not 04279 60C40086 3 IMM 170 LD PFPTR PNCIX 0427A 00D70800 4 BASE 171 LDPF MTU,TPCBPFILE map in the controller 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 211 (TALON) F 29 open tape routine 0427B 60001800 0 172 LD R0 CIX(PPUCABLED) get the device WRU response 0427C 600A0080 0 0 CBM 173 LD R0 R0/DWRUTYPE R0 = device type field 174 0427D D1570802 4 BASE 175 STMW MTU,TPCBTRACK assume 9-track 0427E 64040009 0 IMM 176 CPR R0 DVCTMTC is it a tape controller? 0427F FE024287 177 JEQ UNITSTATUS jump if so 04280 6404000B 0 IMM 178 CPR R0 DVCTVTC is it a video tape controller? 04281 FE0C4284 179 JNE NOTVT jump if not 04282 D0570802 4 BASE 180 DEC MTU,TPCBTRACK indicate VT (-2) 04283 FE0E4287 181 JMP UNITSTATUS go do cleanups 182 * --- 183 00004284 184 NOTVT LABEL 04284 6404000A 0 IMM 185 CPR R0 DVCTCTC is it a cartridge tape controller? 04285 FE0C4294 186 JNE BADTAPE jump if not 04286 EC170802 4 BASE 187 STZ MTU,TPCBTRACK set track 0 of cartridge tape 00004287 188 UNITSTATUS LABEL 04287 EC001801 189 STZ CIX(PPUABORT) clean up the channel 04288 60570801 1 4 BASE 190 LD R1 MTU,TPCBUNIT get desired unit number 04289 EC221A38 1 191 STZ CIX(MTCMFUNC+MTSELECT+R1) select the correct unit 192 0000428A 193 UNITSTAT01 LABEL 0428A 60001A10 0 194 LD R0 CIX(MTLDSTAT) get controller status 0428B F2344296 0 195 JBF R0/MTDSTRDY NOTREADY jump if not ready 196 * \ / 0428C 60040000 0 IMM 197 LD R0 0 good return code 0000428D 198 GOBACK LABEL 0428D 5D1F8001 6 STAK 199 LEAVE POP return to user 200 * --- 201 0000428E 202 BADUNIT LABEL (Bad unit number) 0428E 60040001 0 IMM 203 LD R0 TERRBUN 0428F FE0E428D 204 JMP GOBACK 205 * --- 206 00004290 207 BADCHAN LABEL (Bad channel number) 04290 60040002 0 IMM 208 LD R0 TERRBCN 04291 FE0E428D 209 JMP GOBACK 210 * --- 211 00004292 212 BADSLOT LABEL (Bad slot number) 04292 60040003 0 IMM 213 LD R0 TERRBSN 04293 FE0E428D 214 JMP GOBACK 215 * --- 216 00004294 217 BADTAPE LABEL (Device not a tape drive) 04294 60040004 0 IMM 218 LD R0 TERRDNT 04295 FE0E428D 219 JMP GOBACK 220 * --- 221 00004296 222 NOTREADY LABEL (Drive not ready) 04296 60040006 0 IMM 223 LD R0 TERRDNR 04297 FE0E428D 224 JMP GOBACK and return 225 * --- 226 227 END OPENTAPE routine 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 212 (TALON) F 29 offline tape driver 230 231 ********************************************************************************** 232 * * 233 * READTAPE * 234 * This routine reads a record from the 9 track, cartridge * 235 * tape, or video tape. Note that this routine will read two * 236 * types of records. The first is the type that TAPEBOOTMAKE * 237 * writes out to the tape. The format of these records is * 238 * analagous to a disk block and FBI except that the header is * 239 * first. The second type is what +BACKUP writes onto the tape, * 240 * and is basicly a linear record. The second type of record * 241 * is distinguished by passing a zero address as the second * 242 * parameter. They may extend past page boundaries and are * 243 * read into ascending contiguous pages (as mapped in the monitor * 244 * page file). * 245 * * 246 * Call: * 247 * MTU => tape control block * 248 * CALL READTAPE * 249 * PARV * 250 * PARV * 251 * PARVL * 252 * JNEZ R0 ERROR * 253 * (R1 = # bytes read, R0 = error code) * 254 * Sets R0:R1, Eats R2. * 255 * stack required = 6 * 256 * 4 + MAX ( DOTWOBUF (2), DOONEBUF (2), INTFUNC (2), * 257 * LOGERROR (2), SETUPNMAP (1), UNMAP (1) ) * 258 * * 259 ********************************************************************************** 260 261 READTAPE BLOCK 262 ENTRY READTAPE 263 264 BEGFRAME 00178801 6 BASE 265 DATPAGE BSS 1 data address 00178802 6 BASE 266 HDRPAGE BSS 1 header address 00178803 6 BASE 267 R3SAVE BSS 1 temp for R3 268 ENDFRAME 269 04298 DD1F8004 6 STAK 270 READTAPE ENTR PUSH 04299 C140447E 271 STPV RECORDNUM save record number 0429A C1578801 6 BASE 272 STPV SP,DATPAGE save data address 0429B C0578802 6 BASE 273 STPVL SP,HDRPAGE and also header address 0429C E4D78803 3 6 BASE 274 ST R3 SP,R3SAVE save R3 from harm 275 0429D DC40442E 276 CALLNP SETUPNMAP do initial stuff 0000429E 277 RETRYLOOP LABEL 0429E D1401803 278 STMW CIX(PPUSCSTAT) set status and DMA to input 0429F 60578801 1 6 BASE 279 LD R1 SP,DATPAGE get address of data page 042A0 60978802 2 6 BASE 280 LD R2 SP,HDRPAGE get address of header page 042A1 FA8242A4 2 281 JEQZ R2 ONEBUF jump if we read sequential buffer 042A2 DC4042BB 282 CALLNP DOTWOBUF read buffer and header 042A3 FE0E42A5 283 JMP CHKSTAT go see if all is ok 284 * --- 285 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 213 (TALON) F 29 offline tape driver 000042A4 286 ONEBUF LABEL 042A4 DC4042D2 287 CALLNP DOONEBUF read a single sequential record 288 289 * When we get here we have: R0 = PPU status masked, 290 * R1 = PPU status 291 * R2 = controller status. 000042A5 292 CHKSTAT LABEL 042A5 FA0C42AD 0 293 JNEZ R0 BADREAD jump if PPU is complaining 042A6 F68442AD 2 294 JBT R2/MTSTANER BADREAD jump if controller un-happy 295 * R0 = 0 indicates we had a good read 042A7 F29042A9 2 296 JBF R2/MTSTEOF READEXIT but only if there was no EOF 042A8 60040008 0 IMM 297 LD R0 TERREOF else say we hit a file mark 000042A9 298 READEXIT LABEL 042A9 60401803 1 299 LD R1 CIX(PPUCHANS2) get number of bytes actually read 042AA DC40443C 300 CALLNP UNMAP unmap the controller 042AB 60D78803 3 6 BASE 301 LD R3 SP,R3SAVE restore this register 042AC 5D1F8004 6 STAK 302 LEAVE POP return to calling routine 303 * --- 304 305 * If we get any error on the read we will come here. 306 000042AD 307 BADREAD LABEL 042AD DC00444E 308 CALL LOGERROR make an entry in the error log 042AE 40440012 IMM 309 PARVL ERTOPREAD indicating read operation 042AF 60040006 0 IMM 310 LD R0 TERRDNR assume drive not ready 042B0 F2B442A9 2 311 JBF R2/MTDSTRDY READEXIT jump if good guess 042B1 60040007 0 IMM 312 LD R0 TERRITE get the catch-all error in case 042B2 F66242A9 1 313 JBT R1/PPUIXTRA READEXIT jump if buffer too small, no hope 042B3 D040447D 314 DEC RETRYCOUNT check to see if another attempt okay 042B4 FE0842A9 315 JLT READEXIT jump if retrys exhausted 042B5 F294429E 2 316 JBF R2/MTSTTMFWB RETRYLOOP retry if tape did not move 317 042B6 60040006 0 IMM 318 LD R0 MTFNBKSP otherwise back it up 042B7 DC40441C 319 CALLNP INTFUNC so we can make another try 042B8 DC00444E 320 CALL LOGERROR log backspace in error buffer 042B9 40440010 IMM 321 PARVL ERTOPBKSP indicate backspace 042BA FE0E429E 322 JMP RETRYLOOP go try it again 323 * --- 324 325 END READTAPE routine 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 214 (TALON) F 29 offline tape driver 327 328 ********************************************************************************** 329 * * 330 * DOTWOBUF * 331 * This routine will read a header, and a page of data from * 332 * the tape. The page of data must be read into a page aligned * 333 * buffer, and the header must be read into a buffer contained * 334 * all on one page. * 335 * Calling sequence: * 336 * R1 = address of page * 337 * R2 = address of header * 338 * CALLNP DOTWOBUF * 339 * R0 = masked PPU status * 340 * R1 = PPU status * 341 * R2 = controller status * 342 * Sets R0:R2, Eats R3. * 343 * stack required = 2 * 344 * 1 + PPUIWAIT(1) * 345 * * 346 ********************************************************************************** 347 348 DOTWOBUF BLOCK 349 ENTRY DOTWOBUF 350 351 BEGFRAME 352 ENDFRAME 353 042BB DD5F8001 6 STAK 354 DOTWOBUF ENTRNP PUSH 042BC 60CA9E70 3 2 CBM 355 LD PFPTR R2/FLDPAGE extract virtual page number 042BD 7CC40080 3 IMM 356 IOR PFPTR MONPF we're in monitor memory 042BE 80920000 0 REG 357 PFRD R0 get page file contents 042BF E40A94C0 0 2 CBM 358 ST R0 R2/FLDABSPG make relative physical page 042C0 E48A1560 2 0 CBM 359 ST R2 R0/PAGEANDISP combine with slot number 042C1 E4001805 0 360 ST R0 CIX(PPUADDR1) store address for header 361 042C2 60CA5E70 3 1 CBM 362 LD PFPTR R1/FLDPAGE extract virtual page number 042C3 7CC40080 3 IMM 363 IOR PFPTR MONPF we're in monitor memory 042C4 80920000 0 REG 364 PFRD R0 get page file contents 042C5 E40A54C0 0 1 CBM 365 ST R0 R1/FLDABSPG make relative physical page 042C6 E44A1560 1 0 CBM 366 ST R1 R0/PAGEANDISP combine with slot number 042C7 E4001807 0 367 ST R0 CIX(PPUADDR2) store address for data block 368 042C8 60049000 0 IMM 369 LD R0 PPUCLAST*1+CPP get length of data block 042C9 E4001806 0 370 ST R0 CIX(PPUCNT2) store data byte count 042CA 6004002C 0 IMM 371 LD R0 TPHDRLNTH*CPW get header length 042CB E4001804 0 372 ST R0 CIX(PPUCNT1) store header length 373 042CC 60570801 1 4 BASE 374 LD R1 MTU,TPCBUNIT get tape unit number 042CD 6004102C 0 IMM 375 LD R0 CPP+TPHDRLNTH*CPW get length set up 042CE E4221AC8 0 1 376 ST R0 CIX(MTCMREAD+MTINTREQ+MTSELECT+R1) 042CF DC004440 377 CALL PPUIWAIT wait for end of read interrupt 042D0 40442328 IMM 378 PARVL 9000 wait ninety seconds (ten ms units) 042D1 5D1F8001 6 STAK 379 LEAVE POP 380 * --- 381 382 END DOTWOBUF 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 215 (TALON) F 29 offline tape driver 384 385 ********************************************************************************** 386 * * 387 * DOONEBUF * 388 * This routine will read a single contiguous record from * 389 * the tape. The destination buffer need not start on a page * 390 * boundary but must start on a word boundary. No checking * 391 * is done for buffer overflow so the caller is responsible * 392 * for providing a large enough buffer for the any record * 393 * that will appear on the tape. * 394 * Call: * 395 * R1 = address of the buffer * 396 * CALLNP DOONEBUF * 397 * R0 = masked PPU status * 398 * R1 = PPU status * 399 * R2 = controller status * 400 * Sets R0:R2, Eats R3. * 401 * stack required = 2 * 402 * * 403 ********************************************************************************** 404 405 DOONEBUF BLOCK 406 ENTRY DOONEBUF 407 408 BEGFRAME 00178801 6 BASE 409 PAGADR BSS 1 temp. to hold address 410 ENDFRAME 411 042D2 DD5F8002 6 STAK 412 DOONEBUF ENTRNP PUSH 042D3 E4578801 1 6 BASE 413 ST R1 SP,PAGADR remember the start of the buffer 414 042D4 60CA5E70 3 1 CBM 415 LD PFPTR R1/FLDPAGE extract the virtual page number 042D5 7CC40080 3 IMM 416 IOR PFPTR MONPF we're in monitor memory 042D6 80920000 0 REG 417 PFRD R0 get the page file contents 042D7 E40A54C0 0 1 CBM 418 ST R0 R1/FLDABSPG make relative physical page 042D8 E44A1560 1 0 CBM 419 ST R1 R0/PAGEANDISP combine with slot number 042D9 E4001805 0 420 ST R0 CIX(PPUADDR1) store address for first part of record 421 042DA 60440000 1 IMM 422 LD R1 0 want zero offset into page 042DB 18C40001 3 IMM 423 ADD PFPTR 1 move to next virtual page number 042DC 80920000 0 REG 424 PFRD R0 get the page file contents 042DD E40A54C0 0 1 CBM 425 ST R0 R1/FLDABSPG make relative physical page 042DE E44A1560 1 0 CBM 426 ST R1 R0/PAGEANDISP combine with slot number 042DF E4001807 0 427 ST R0 CIX(PPUADDR2) and store the address 428 042E0 60041000 0 IMM 429 LD R0 CPP number of chars. to read 042E1 E4001806 0 430 ST R0 CIX(PPUCNT2) ... in the second page 431 042E2 6049ACA1 1 6 ZBM 432 LD R1 SP,PAGADR/DISPFIELD get displacement into page 042E3 30440400 1 IMM 433 RSB R1 WPP how many words are left on page 042E4 1C440004 1 IMM 434 MUL R1 CPW convert to a character count 042E5 E4401804 1 435 ST R1 CIX(PPUCNT1) store the count for this page 436 042E6 60570801 1 4 BASE 437 LD R1 MTU,TPCBUNIT get the unit number 042E7 EC221AC8 1 438 STZ CIX(MTCMREAD+MTINTREQ+MTSELECT+R1) do it 439 * \ / 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 216 (TALON) F 29 offline tape driver 000042E8 440 BCRCOUNT LABEL 042E8 60055F90 0 IMM 441 LD R0 90000 90 second dead-man timer (1 ms units) 000042E9 442 INTWAIT LABEL 042E9 00440064 IMM 443 WAIT 100 wait here for 1 millisecond 444 * \ / to avoid saturating the PPU 042EA 60401801 1 445 LD R1 CIX(PPUINTSTAT) get the status 042EB F67842EF 1 446 JBT R1/PPUIINTC ENDWAIT jump if all done 042EC F67642F6 1 447 JBT R1/PPUIROLL ROLLOVER jump if byte count rollover 042ED FA2642E9 0 448 JDR R0 INTWAIT wait for another ms 449 * \ / 042EE D1524000 1 REG 450 STMW R1 timed out, real bad 000042EF 451 ENDWAIT LABEL 042EF 60124000 0 1 REG 452 LD R0 R1 copy status 042F0 78046540 0 IMM 453 AND R0 PPUMASK mask off error bits 042F1 60801802 2 454 LD R2 CIX(PPUCHANS1) get controller status 042F2 FA0242F5 0 455 JEQZ R0 PPUSOKAY jump if PPU status clean 042F3 EC001801 456 STZ CIX(PPUABORT) clean up channel 042F4 00420008 IMM 457 WAIT CATCHWAIT wait for controller to catch up 000042F5 458 PPUSOKAY LABEL 042F5 5D1F8002 6 STAK 459 LEAVE POP 460 * --- 461 000042F6 462 ROLLOVER LABEL 042F6 60440000 1 IMM 463 LD R1 0 want zero offset into page 042F7 18C40001 3 IMM 464 ADD PFPTR 1 move to next virtual page number 042F8 80920000 0 REG 465 PFRD R0 get the page file contents 042F9 E40A54C0 0 1 CBM 466 ST R0 R1/FLDABSPG make relative physical page 042FA E44A1560 1 0 CBM 467 ST R1 R0/PAGEANDISP combine with slot number 042FB E4001807 0 468 ST R0 CIX(PPUADDR2) and store the address 469 042FC 60041000 0 IMM 470 LD R0 CPP number of chars. to read 042FD E4001806 0 471 ST R0 CIX(PPUCNT2) store for this page 472 042FE FE0E42E8 473 JMP BCRCOUNT go wait again 474 * --- 475 476 END DOONEBUF 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 217 (TALON) F 29 offline tape driver 478 479 ********************************************************************************** 480 * * 481 * WRITETAPE writes a record onto tape (MT, CT, or VT). * 482 * It will attempt a reasonable number of retries on non- * 483 * fatal errors. * 484 * The record must exist in contiguous pages in virtual * 485 * memory and cannot exceed 12 pages for 9 track tape or VT, and * 486 * 4 and 1/2 pages minus 2 words for cartridge tape. * 487 * For NRZI 9 track tape format, records shorter than * 488 * 24 characters should not be written. * 489 * Call: * 490 * LD MTU ADR * 491 * CALL WRITETAPE * 492 * PARV * 493 * PARV * 494 * PARL ADR (must be a word address) * 495 * JMP * 496 * JMP * 497 * * 498 * * 499 * Returns error code in R0 * 500 * Eats R0:R3 * 501 * Leaves CIX unmapped * 502 * stack required = 8 * 503 * 4 + max ( DOWRITE (4), INTFUNC (2), LOGERROR (2), * 504 * SETUPNMAP (1), UNMAP (1), WRITEGAP (3) ) * 505 * * 506 ********************************************************************************** 507 508 WRITETAPE BLOCK 509 510 ENTRY WRITETAPE 511 512 BEGFRAME 00178801 6 BASE 513 LENGTH BSS 1 length of record to write 00178802 6 BASE 514 RECADDR BSS 1 address of the record 00178803 6 BASE 515 GAPFLAG BSS 1 indicates if should gap before retry 516 ENDFRAME 517 518 042FF DD1F8004 6 STAK 519 WRITETAPE ENTR PUSH 04300 C140447E 520 STPV RECORDNUM save record number 04301 C1578801 6 BASE 521 STPV SP,LENGTH length of record to write (bytes) 04302 C0178802 6 BASE 522 STPL SP,RECADDR where the record is 04303 DC40442E 523 CALLNP SETUPNMAP do initial stuff 524 00004304 525 RETRYLOOP LABEL 04304 D1401802 526 STMW CIX(PPUSSSTAT) set status and DMA to output 527 04305 60938000 2 6 REG 528 LD R2 SP temp stack pointer for call 04306 DC00434C 529 CALL DOWRITE do the write 04307 41568801 2 BASE 530 PARV R2,LENGTH the length 04308 40568802 2 BASE 531 PARVL R2,RECADDR the address 04309 FE0E430F 532 JMP WRITEERR error writing to tape 0430A FE0E430C 533 JMP TAPEEND end of tape reached 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 218 (TALON) F 29 offline tape driver 534 * \ / 0000430B 535 NORMALBYE LABEL 0430B 19C40001 7 IMM 536 ADD R7 1 advance for normal return 0000430C 537 TAPEEND LABEL 0430C 19C40001 7 IMM 538 ADD R7 1 tape end return is one less 0000430D 539 RETURN0 LABEL 0430D DC40443C 540 CALLNP UNMAP unmap the controller 0430E 5D1F8004 6 STAK 541 LEAVE POP 542 * --- 543 0000430F 544 WRITEERR LABEL 0430F DC00444E 545 CALL LOGERROR log the error 04310 40440013 IMM 546 PARVL ERTOPWRITE indicating a write operation 547 04311 EC178803 6 BASE 548 STZ SP,GAPFLAG say we don't want to gap 04312 F6844327 2 549 JBT R2/MTSTANER CONTROLERR check for controller error 00004313 550 CHEKPPU LABEL 04313 F6644316 1 551 JBT R1/PPUIDPPE RETRY retry if parity error 04314 F66A4316 1 552 JBT R1/PPUICONF RETRY retry if PPU is confused 04315 F2724325 1 553 JBF R1/PPUIBCNR REALBAD any other error not retryable 554 * \ / retry if byte count rollover not ready 00004316 555 RETRY LABEL 04316 D040447D 556 DEC RETRYCOUNT indicate another retry attempt 04317 FE084325 557 JLT REALBAD cannot exceed our limit 04318 F294431E 2 558 JBF R2/MTSTTMFWB CHECKGAP if no forward motion see about gap 04319 F6924325 2 559 JBT R2/MTSTTMBKB REALBAD both bits on indicate lost controller 560 * \ / 561 0431A 60040006 0 IMM 562 LD R0 MTFNBKSP backspace request 0431B DC40441C 563 CALLNP INTFUNC before we write again 0431C DC00444E 564 CALL LOGERROR log backspace in error buffer 0431D 40440010 IMM 565 PARVL ERTOPBKSP indicate backspace 566 * \ / 0000431E 567 CHECKGAP LABEL 0431E 5C178803 6 BASE 568 CMZ SP,GAPFLAG should we do a gap? 0431F FE024304 569 JEQ RETRYLOOP if not then just try again 570 * \ / otherwise, write the gap first 04320 60178801 0 6 BASE 571 LD R0 SP,LENGTH size of record 04321 DC0043A2 572 CALL WRITEGAP write the gap 04322 40520000 0 REG 573 PARVL R0 how big the record is 04323 FE0E4325 574 JMP REALBAD couldn't even write a gap 04324 FE0E4304 575 JMP RETRYLOOP now try write again 576 * --- 577 00004325 578 REALBAD LABEL 04325 60040007 0 IMM 579 LD R0 TERRITE bad error 00004326 580 RETURNERR LABEL place to breakpoint any error 04326 FE0E430D 581 JMP RETURN0 582 * --- 583 584 00004327 585 CONTROLERR LABEL 04327 6004000C 0 IMM 586 LD R0 TERRWPRT assume write protected 04328 F6B84326 2 587 JBT R2/MTDSTWPRT RETURNERR jump if a good guess 04329 F6A04316 2 588 JBT R2/MTSTDPPE RETRY retry data path parity errors 0432A 600A9650 0 2 CBM 589 LD R0 R2/MTSTERSTAT get the error status bits 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 219 (TALON) F 29 offline tape driver 0432B FA02433A 0 590 JEQZ R0 NOCONTERR if error code of zero then no error 0432C 60D70802 3 4 BASE 591 LD R3 MTU,TPCBTRACK check tape type (-1 sez 9 trk) 0432D FAC6433D 3 592 JGEZ R3 CARTRIDGE jump out if CT 0432E FAEC4333 3 593 JEQMW R3 NINETRACK jump out if MT 594 * \ / through here for VT 595 0432F 50040016 0 IMM 596 MIN R0 VTERRMAX+1 if higher than max use fatal error code 04330 6030434B 0 0 @ 597 LD R0 @VTERRPTR(R0) find out what to do about the error 04331 FA024316 0 598 JEQZ R0 RETRY 0 => try again 04332 FE0E4325 599 JMP REALBAD return bad error 600 * --- 601 00004333 602 NINETRACK LABEL 04333 004400C8 IMM 603 WAIT 200 wait a bit before backspacing 04334 5004001B 0 IMM 604 MIN R0 MTERRMAX+1 if higher than max use fatal error code 04335 60304345 0 0 @ 605 LD R0 @MTERRPTR(R0) find out what to do about the error 04336 FA024316 0 606 JEQZ R0 RETRY 0 => try again 04337 EDD78803 6 BASE 607 STW SP,GAPFLAG indicate we want a gap 04338 F63E4316 0 608 JBT R0/GAPRTRY RETRY write a gap and retry 04339 FE0E4325 609 JMP REALBAD return bad error 610 * --- 611 0000433A 612 NOCONTERR LABEL 0433A 78446540 1 IMM 613 AND R1 PPUMASK isolate the PPU error bits 0433B FA42430B 1 614 JEQZ R1 NORMALBYE if no PPU error then just leave 0433C FE0E4313 615 JMP CHEKPPU 616 * --- 617 0000433D 618 CARTRIDGE LABEL 0433D 5004001A 0 IMM 619 MIN R0 CTERRMAX+1 if higher than max use fatal error code 0433E 60304348 0 0 @ 620 LD R0 @CTERRPTR(R0) find out what to do about the error 0433F FA024316 0 621 JEQZ R0 RETRY 0 => try again 04340 EDD78803 6 BASE 622 STW SP,GAPFLAG indicate we want a gap 04341 F63E4316 0 623 JBT R0/GAPRTRY RETRY write a gap and retry 04342 FE0E4325 624 JMP REALBAD return bad error 625 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 220 (TALON) F 29 offline tape driver 627 628 ********************************************************************************** 629 * * 630 * These tables are used to determine what to do about * 631 * controller errors. They are indexed by the error code * 632 * returned from the controller. There are separate tables * 633 * for 9 track tape, cartridge tape, and video tape since * 634 * their controllers return different error codes. * 635 * Any error considered fatal indicates a hardware * 636 * problem of some sort, either tape, drive, or driver, * 637 * and is serious enough to abort the process doing the * 638 * write. * 639 * The codes in the following table are: * 640 * 0 = retry * 641 * 1 = write a gap and retry * 642 * 2 = fatal error * 643 * * 644 ********************************************************************************** 645 00003E10 BYTE 646 GAPRTRY EQU BIT 31 bit indicating gap and retry 647 648 * Codes for MT (Rev 5 u-code) 04342 00000000 649 MTERRTAB VFDB 2:0 00 - no error 04342 00000000 650 VFDB 2:0 01 - multi-track (hard) error reading PE data 04342 00000000 651 VFDB 2:0 02 - vertical parity error reading PE data 04342 00000000 652 VFDB 2:0 03 - vertical parity error reading NRZI data 04342 00000000 653 VFDB 2:0 04 - crc error reading NRZI data 04342 00000000 654 VFDB 2:0 05 - lrc error reading NRZI data 04342 00000000 655 VFDB 2:0 06 - no rdr while attempting to read data 04342 00000000 656 VFDB 2:0 07 - rate error while reading data 04342 00000000 657 VFDB 2:0 08 - rate error while writing data 04342 00000001 658 VFDB 2:1 09 - multi-track error writing PE data 04342 00000001 659 VFDB 2:1 0A - vertical parity error writing PE data 04342 00000001 660 VFDB 2:1 0B - vertical parity error writing NRZI data 04342 00000001 661 VFDB 2:1 0C - crc error writing NRZI data 04342 00000001 662 VFDB 2:1 0D - lrc error writing NRZI data 04342 00000000 663 VFDB 2:0 0E - bad checksum in string from PPU 04343 00000002 664 VFDB 2:2 0F - drive not ready for requested operation 04343 00000002 665 VFDB 2:2 10 - unrecognized command 04343 00000002 666 VFDB 2:2 11 - illegal command with tape at EOT/BOT 04343 00000000 667 VFDB 2:0 12 - data after write count exhausted 04343 00000002 668 VFDB 2:2 13 - bad filemark read or written 04343 00000000 669 VFDB 2:0 14 - bad phase encoded ID zone 04343 00000002 670 VFDB 2:2 15 - timeout: 80 inches of blank tape read 04343 00000000 671 VFDB 2:0 16 - spurious NAK from PPU 04343 00000000 672 VFDB 2:0 17 - bad first byte (not 96 or 62) 04343 00000000 673 VFDB 2:0 18 - data path parity error 04343 00000000 674 VFDB 2:0 19 - timeout on PPU data path 0000001A ABS 675 MTERRMAX EQU (DISPB MTERRTAB)/2 max error codes 04343 00000002 676 VFDB 2:2 fatal error if exceeds max 04345 00884343 677 MTERRPTR PTR MTERRTAB 678 04345 00000000 679 CTERRTAB VFDB 2:0 00 - no error 04345 00000002 680 VFDB 2:2 01 - illegal drive 04345 00000002 681 VFDB 2:2 02 - illegal store 04345 00000002 682 VFDB 2:2 03 - illegal track 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 221 (TALON) F 29 offline tape driver 04345 00000002 683 VFDB 2:2 04 - illegal tape motion 04345 00000000 684 VFDB 2:0 05 - no go byte 04345 00000002 685 VFDB 2:2 06 - timeout during FF or rewind 04345 00000002 686 VFDB 2:2 07 - offline during FF or rewind or write gap 04345 00000002 687 VFDB 2:2 08 - load point hole late 04345 00000001 688 VFDB 2:1 09 - sync zone late 04345 00000001 689 VFDB 2:1 0A - IRG found when not expecting it 04345 00000001 690 VFDB 2:1 0B - dropout during write 04345 00000001 691 VFDB 2:1 0C - ID zone late 04345 00000001 692 VFDB 2:1 0D - leading ID zone bad 04345 00000001 693 VFDB 2:1 0E - word count CRC bad 04346 00000001 694 VFDB 2:1 0F - data CRC bad (MFM mode only) 04346 00000001 695 VFDB 2:1 10 - reverse word count check bad (GCR mode only) 04346 00000001 696 VFDB 2:1 11 - trailing ID zone bad 04346 00000001 697 VFDB 2:1 12 - trailing sync zone bad 04346 00000001 698 VFDB 2:1 13 - GCR byte count not match blockette number 04346 00000001 699 VFDB 2:1 14 - GCR record not recoverable / write error 04346 00000001 700 VFDB 2:1 15 - GCR read not all right but recoverable 04346 00000001 701 VFDB 2:1 16 - GCR record not recoverable 04346 00000002 702 VFDB 2:2 17 - EOT caused some other error to be detected 04346 00000002 703 VFDB 2:2 18 - BOT caused some other error to be detected 00000019 ABS 704 CTERRMAX EQU (DISPB CTERRTAB)/2 max error codes 04346 00000002 705 VFDB 2:2 fatal error if exceeds max 04348 00884346 706 CTERRPTR PTR CTERRTAB 707 04348 00000000 708 VTERRTAB VFDB 2:0 00 - no error 04348 00000002 709 VFDB 2:2 01 - (unused, hardware error) 04348 00000002 710 VFDB 2:2 02 - unit not ready 04348 00000002 711 VFDB 2:2 03 - bad tape or EOT/BOT 04348 00000002 712 VFDB 2:2 04 - tape unit self test failure 04348 00000002 713 VFDB 2:2 05 - illegal request 04348 00000002 714 VFDB 2:2 06 - reset or cartridge change 04348 00000002 715 VFDB 2:2 07 - write protected cartridge 04348 00000002 716 VFDB 2:2 08 - blank tape during read 04348 00000002 717 VFDB 2:2 09 - illegal operation 04348 00000002 718 VFDB 2:2 0A - (unused, copy aborted) 04348 00000002 719 VFDB 2:2 0B - command aborted 04348 00000002 720 VFDB 2:2 0C - (unused) 04348 00000002 721 VFDB 2:2 0D - EOT encountered during write 04348 00000002 722 VFDB 2:2 0E - (unused) 04349 00000002 723 VFDB 2:2 0F - (reserved) 04349 00000002 724 VFDB 2:2 10 - (unused) 04349 00000002 725 VFDB 2:2 11 - tape not present 04349 00000002 726 VFDB 2:2 12 - power failure 04349 00000002 727 VFDB 2:2 13 - bad command from PPU 04349 00000002 728 VFDB 2:2 14 - bad data from tape unit 00000015 ABS 729 VTERRMAX EQU (DISPB VTERRTAB)/2 max error codes 04349 00000002 730 VFDB 2:2 fatal error if exceeds max 0434B 00884349 731 VTERRPTR PTR VTERRTAB 732 733 END WRITETAPE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 222 (TALON) F 29 offline tape driver 735 736 ********************************************************************************** 737 * * 738 * DOWRITE writes a record onto tape. The record must * 739 * exist on contiguous virtual pages in memory and start on * 740 * a word boundary. The write will start at the address * 741 * given and continue to write to tape until the byte count * 742 * is exhausted. * 743 * Call: * 744 * PPU mapped into CIX, all status bits set * 745 * LD MTU ADR * 746 * CALL DOWRITE * 747 * PARV * 748 * PARVL ADR must be a word address * 749 * JMP error * 750 * JMP end of tape * 751 * * 752 * Returns R0 = masked PPU status (error bits only) * 753 * R1 = unmasked PPU status * 754 * R2 = controller status * 755 * Eats R0:R3 * 756 * stack required = 4 * 757 * * 758 ********************************************************************************** 759 760 DOWRITE BLOCK 761 762 ENTRY DOWRITE 763 764 BEGFRAME 00178801 6 BASE 765 LENGTH BSS 1 length of record to write 00178802 6 BASE 766 ADDRREC BSS 1 address of record 00178803 6 BASE 767 COUNT BSS 1 count of bytes remaining to write 768 ENDFRAME 769 0434C DD1F8004 6 STAK 770 DOWRITE ENTR PUSH 0434D C1578801 6 BASE 771 STPV SP,LENGTH length of record to write 0434E C0578802 6 BASE 772 STPVL SP,ADDRREC address of the record 773 774 ********************************************************************************** 775 * * 776 * Special code to allow testing on a PPU that does double * 777 * word reads and erroneously reports memory parity errors for * 778 * an unused second word. * 779 * The special code extends to the line of *s. * 780 * It uses only COUNT as a temporary variable and needs no special * 781 * variables or labels other than this short block of code. * 782 * * 783 ********************************************************************************** 784 0434F 60578802 1 6 BASE 785 LD R1 SP,ADDRREC pick up the virtual starting address 04350 184981E1 1 6 ZBM 786 ADD R1 SP,LENGTH/BITS 0:29 add on the word length 787 * creating the first word past end 788 * (all writes in DTT are whole word) 04351 F27E435F 1 789 JBF R1/BIT 31 NOPROB skip all this if even address 04352 60CA5E70 3 1 CBM 790 LD PFPTR R1/FLDPAGE extract the page number 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 223 (TALON) F 29 offline tape driver 04353 7CC40080 3 IMM 791 IOR PFPTR MONPF make monitor page number 04354 80920000 0 REG 792 PFRD R0 get the page file contents 04355 E40A54C0 0 1 CBM 793 ST R0 R1/FLDABSPG make relative physical page 04356 E44A1560 1 0 CBM 794 ST R1 R0/PAGEANDISP put in with the page offset 04357 604A0080 1 0 CBM 795 LD R1 R0/BITS 0:7 isolate the slot number 04358 2803FE00 0 IMM 796 BSUB R0 0FF000000 remove the slot number 04359 7C024000 0 IMM 797 IOR R0 020000000 and insert a read command 0435A E4178803 0 6 BASE 798 ST R0 SP,COUNT save the command word temporarily 0435B 0C120000 0 REG 799 LDFB R0 and do the read 0435C FE14435F 800 JOC NOPROB jump if the word came back okay 0435D 60099183 0 6 ZBM 801 LD R0 SP,COUNT/BITS 8:31 pick up the command word, dropping read command 0435E 0C520000 0 REG 802 STTB R0 use command word as data too 0000435F 803 NOPROB LABEL 804 *************************************************************************** 805 0435F 60578802 1 6 BASE 806 LD R1 SP,ADDRREC get the address 04360 60CA5E70 3 1 CBM 807 LD PFPTR R1/FLDPAGE extract virtual page number 04361 7CC40080 3 IMM 808 IOR PFPTR MONPF keep in monitor memory 04362 80920000 0 REG 809 PFRD R0 get the page file contents 04363 E40A54C0 0 1 CBM 810 ST R0 R1/FLDABSPG make relative physical page 04364 E44A1560 1 0 CBM 811 ST R1 R0/PAGEANDISP put in with the page offset 04365 E4001805 0 812 ST R0 CIX(PPUADDR1) store starting address of record 813 04366 6049ACA2 1 6 ZBM 814 LD R1 SP,ADDRREC/DISPFIELD records displacement on page 04367 30440400 1 IMM 815 RSB R1 WPP see how many words are left on page 04368 1C440004 1 IMM 816 MUL R1 CPW convert to char count 04369 50578801 1 6 BASE 817 MIN R1 SP,LENGTH in case it doesn't go to page boundary 0436A 60978801 2 6 BASE 818 LD R2 SP,LENGTH get the total write's length 0436B 10924000 2 1 REG 819 SUB R2 R1 subtract bytes in first block 0436C FA8C436F 2 820 JNEZ R2 MORETHAN1 not 0, then more than one page 821 * \ / 0436D 7C448000 1 IMM 822 IOR R1 1*PPUCLAST say first byte count is last 0436E FE0E437C 823 JMP JUSTONE just one page to write 824 * --- 825 0000436F 826 MORETHAN1 LABEL 0436F E4978803 2 6 BASE 827 ST R2 SP,COUNT current count 04370 60840000 2 IMM 828 LD R2 0 we want zero offset into the page 04371 18C40001 3 IMM 829 ADD PFPTR 1 move to next virtual page 04372 80920000 0 REG 830 PFRD R0 get the page file contents 04373 E40A94C0 0 2 CBM 831 ST R0 R2/FLDABSPG make relative physical page 04374 E48A1560 2 0 CBM 832 ST R2 R0/PAGEANDISP put in with the page offset 04375 E4001807 0 833 ST R0 CIX(PPUADDR2) store as address of next block 834 04376 60841000 2 IMM 835 LD R2 CPP second byte count 04377 50978803 2 6 BASE 836 MIN R2 SP,COUNT can't exceed remaining count 04378 B0978803 2 6 BASE 837 RSBM R2 SP,COUNT and account for these 04379 FE0C437B 838 JNE NOTLAST if zero then set last byte count flag 839 * \ / 0437A 7C848000 2 IMM 840 IOR R2 1*PPUCLAST say last byte count 0000437B 841 NOTLAST LABEL 0437B E4801806 2 842 ST R2 CIX(PPUCNT2) set second block's byte count 843 * \ / 0000437C 844 JUSTONE LABEL 0437C 60178801 0 6 BASE 845 LD R0 SP,LENGTH get the total length of this write 0437D 60970801 2 4 BASE 846 LD R2 R4,TPCBUNIT get the tape unit number 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 224 (TALON) F 29 offline tape driver 0437E E4401804 1 847 ST R1 CIX(PPUCNT1) set first block's byte count 0437F E4241AD8 0 2 848 ST R0 CIX(MTCMWRITE+MTINTREQ+MTSELECT+R2) start things going 849 * \ / 00004380 850 WRITELOOP LABEL 04380 6004C350 0 IMM 851 LD R0 50000 50 second dead man timer (1 ms units) 00004381 852 ROLLWAIT LABEL 04381 00440064 IMM 853 WAIT 100 wait 1 msecs 854 * \ / 04382 60401801 1 855 LD R1 CIX(PPUINTSTAT) get the status 04383 F6784387 1 856 JBT R1/PPUIINTC ENDWAIT jump if controller interrupt (done) 04384 F6764393 1 857 JBT R1/PPUIROLL ROLLOVER or if rollover interrupt request 00004385 858 ROLLCOUNT LABEL 04385 FA264381 0 859 JDR R0 ROLLWAIT go wait for the roll over 860 * \ / 04386 D1524000 1 REG 861 STMW R1 indicate massive error on fall through 00004387 862 ENDWAIT LABEL 04387 60124000 0 1 REG 863 LD R0 R1 copy status 04388 78046540 0 IMM 864 AND R0 PPUMASK just keep error bits 04389 60801802 2 865 LD R2 CIX(PPUCHANS1) get controller status 0438A FA0C4390 0 866 JNEZ R0 DOPRESET if non-zero, error happened 0438B F6844392 2 867 JBT R2/MTSTANER ERRSPOT jump if controller error 0438C F6B2438F 2 868 JBT R2/MTDSTEOT ENDTAPE check for EOT warning 0438D 19C40002 7 IMM 869 ADD R7 2 advance beyond error return 0438E 5D1F8004 6 STAK 870 RETURN0 LEAVE POP 871 * --- 872 0438F FBE0438E 7 873 ENDTAPE IRJ R7 RETURN0 advance to end of tape return 874 * --- 875 00004390 876 DOPRESET LABEL 04390 EC001801 877 STZ CIX(PPUABORT) clean up channel 04391 00420008 IMM 878 WAIT CATCHWAIT wait for controller to catch up 00004392 879 ERRSPOT LABEL 04392 5D1F8004 6 STAK 880 LEAVE POP separate leave so we can breakpoint 881 * --- 882 00004393 883 ROLLOVER LABEL 04393 5C178803 6 BASE 884 CMZ SP,COUNT see if we are done with byte counts 04394 FE024385 885 JEQ ROLLCOUNT if so just wait for controller completion 886 * \ / 04395 60440000 1 IMM 887 LD R1 0 we want zero offset into the page 04396 18C40001 3 IMM 888 ADD PFPTR 1 move to next virtual page 04397 80920000 0 REG 889 PFRD R0 get the page file contents 04398 E40A54C0 0 1 CBM 890 ST R0 R1/FLDABSPG make relative physical page 04399 E44A1560 1 0 CBM 891 ST R1 R0/PAGEANDISP put in with the page offset 0439A E4001807 0 892 ST R0 CIX(PPUADDR2) store as address of next block 893 0439B 60578803 1 6 BASE 894 LD R1 SP,COUNT get remaining length 0439C 50441000 1 IMM 895 MIN R1 CPP one block max 0439D B0578803 1 6 BASE 896 RSBM R1 SP,COUNT keep track of how much we have written 0439E FE0C43A0 897 JNE STILLMORE if not zero, then don't set last count bit 898 * \ / 0439F 7C448000 1 IMM 899 IOR R1 1*PPUCLAST say last byte count 000043A0 900 STILLMORE LABEL 043A0 E4401806 1 901 ST R1 CIX(PPUCNT2) store for this page 043A1 FE0E4380 902 JMP WRITELOOP 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 225 (TALON) F 29 offline tape driver 903 * --- 904 905 END DOWRITE 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 226 (TALON) F 29 offline tape driver 907 908 ********************************************************************************** 909 * * 910 * WRITEGAP writes a gap onto the tape. The length of the * 911 * gap is calculated from the size of the record being written. * 912 * The gap will be approximately 1/3 the length of the * 913 * original record. This is all irrelevant for 9-track tape * 914 * since the 9-track controller will only write 3 inch gaps. * 915 * A reasonable number of retries will be attempted. * 916 * This routine is for internal use only, as it does not * 917 * map in the tape controller. * 918 * Call: * 919 * PPU mapped into CIX * 920 * LD R4 ADR * 921 * CALL WRITEGAP * 922 * PARVL record size (in chars) * 923 * JMP error * 924 * Returns PPU status in R1, Channel status in R2 * 925 * Eats R0:R2 * 926 * stack required = 4 * 927 * 3 + MAX ( LOGERROR (2), PPUIWAIT (1) ) * 928 * * 929 ********************************************************************************** 930 931 WRITEGAP BLOCK 932 933 ENTRY WRITEGAP 934 935 BEGFRAME 00178801 6 BASE 936 TRYCOUNT BSS 1 counter for error retries 00178802 6 BASE 937 GAPSIZE BSS 1 size of gap 938 ENDFRAME 939 043A2 DD1F8003 6 STAK 940 WRITEGAP ENTR PUSH 043A3 C0528000 2 REG 941 STPVL R2 save the record size 043A4 14840960 2 IMM 942 DIV R2 2400 since there are 800 chars to inch 043A5 18840001 2 IMM 943 ADD R2 1 add an extra inch to round up 043A6 E4978802 2 6 BASE 944 ST R2 SP,GAPSIZE save for retry 043A7 60040014 0 IMM 945 LD R0 TAPEERRMAX counter for error retries 043A8 E4178801 0 6 BASE 946 ST R0 SP,TRYCOUNT set up our counter 947 * \ / 948 000043A9 949 GAPLOOP LABEL 043A9 60170801 0 4 BASE 950 LD R0 MTU,TPCBUNIT unit number of drive 043AA 60978802 2 6 BASE 951 LD R2 SP,GAPSIZE get the gap size 043AB E4A01AE8 2 0 952 ST R2 CIX(MTCMERASE+MTINTREQ+MTSELECT+R0) start things going 953 043AC DC004440 954 CALL PPUIWAIT call to wait for operation complete 043AD 40440064 IMM 955 PARVL 100 wait for up to 1 second 043AE FA0C43B6 0 956 JNEZ R0 GAPERROR jump if PPU error 043AF F28443B5 2 957 JBF R2/MTSTANER GAPLEAVE no error, let's leave 043B0 F2B443B6 2 958 JBF R2/MTDSTRDY GAPERROR big error, it's offline 043B1 F6B843B6 2 959 JBT R2/MTDSTWPRT GAPERROR error, it's writeprotected 960 * \ / 043B2 D0578801 6 BASE 961 DEC SP,TRYCOUNT we have tried again and failed 043B3 FE0643A9 962 JGE GAPLOOP if above or equal to zero we can try again 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 227 (TALON) F 29 offline tape driver 043B4 FE0E43B6 963 JMP GAPERROR out of tries 964 * --- 965 000043B5 966 GAPLEAVE LABEL 043B5 19C40001 7 IMM 967 ADD R7 1 good return 000043B6 968 GAPERROR LABEL bad return 043B6 DC00444E 969 CALL LOGERROR log the gap operation in error buffer 043B7 40440016 IMM 970 PARVL ERTOPGAP indicate it's a gap operation 043B8 5D1F8003 6 STAK 971 LEAVE POP 972 * --- 973 974 END WRITEGAP 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 228 (TALON) F 29 offline tape driver 976 977 ********************************************************************************** 978 * * 979 * WRITEFM * 980 * * 981 * Routine to write a file mark to tape with error recovery. * 982 * We will try a reasonable number of times to write a file mark. * 983 * * 984 * Call: * 985 * LD R4 ADR tape control block * 986 * CALLNP WRITEFM * 987 * JMP could not do it * 988 * * 989 * Leaves CIX unmapped. * 990 * Eats R0:R3 * 991 * stack required = 4 * 992 * 1 + max ( INTFUNC (2), LOGERROR (2), SETUPNMAP (1), * 993 * UNMAP (1), WRITEGAP (3) ) * 994 * * 995 ********************************************************************************** 996 997 WRITEFM BLOCK 998 999 ENTRY WRITEFM 1000 1001 BEGFRAME 1002 ENDFRAME 1003 043B9 DD5F8001 6 STAK 1004 WRITEFM ENTRNP PUSH 043BA DC40442E 1005 CALLNP SETUPNMAP do initial stuff 1006 000043BB 1007 RETRYLOOP LABEL 043BB 60040018 0 IMM 1008 LD R0 MTFNWFM code for write file mark 043BC DC40441C 1009 CALLNP INTFUNC write the file mark 043BD FA0C43C2 0 1010 JNEZ R0 FILEMERR PPU error 043BE F68443C2 2 1011 JBT R2/MTSTANER FILEMERR controller error 043BF 19C40001 7 IMM 1012 ADD R7 1 good return 000043C0 1013 FATALERR LABEL 043C0 DC40443C 1014 CALLNP UNMAP unmap the controller 043C1 5D1F8001 6 STAK 1015 LEAVE POP 1016 * --- 1017 000043C2 1018 FILEMERR LABEL 043C2 DC00444E 1019 CALL LOGERROR log the error 043C3 40440014 IMM 1020 PARVL ERTOPWFM indicate during WFM 043C4 D040447D 1021 DEC RETRYCOUNT one more retry 043C5 FE0843C0 1022 JLT FATALERR out of chances 043C6 60040006 0 IMM 1023 LD R0 MTFNBKSP back space 043C7 DC40441C 1024 CALLNP INTFUNC ignore any error 043C8 DC00444E 1025 CALL LOGERROR log backspace in error buffer 043C9 40440010 IMM 1026 PARVL ERTOPBKSP indicate backspace 043CA DC0043A2 1027 CALL WRITEGAP now write a gap 043CB 40440000 IMM 1028 PARVL 0 record size (not much to a file mark) 043CC FE0E43C0 1029 JMP FATALERR if we could not write the gap 043CD FE0E43BB 1030 JMP RETRYLOOP try again 1031 * --- 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 229 (TALON) F 29 offline tape driver 1032 1033 END WRITEFM 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 230 (TALON) F 29 offline tape driver 1035 1036 ********************************************************************************** 1037 * * 1038 * SETTAPE * 1039 * This routine will select a track (if CT), and do a rewind. * 1040 * * 1041 * LD MTU => tape control block * 1042 * CALLNP SETTAPE * 1043 * ST R0 error code (0 if ok) * 1044 * Sets R0, Eats R1:R3. * 1045 * stack required = 6 * 1046 * 1 + MAX( REWIND (3), TAPEFUNC (3) ) * 1047 * * 1048 ********************************************************************************** 1049 1050 SETTAPE BLOCK 1051 ENTRY SETTAPE 1052 1053 BEGFRAME 1054 ENDFRAME 1055 043CE DD5F8001 6 STAK 1056 SETTAPE ENTRNP PUSH 043CF 60970802 2 4 BASE 1057 LD R2 MTU,TPCBTRACK load track number for CTC 043D0 FA8843D3 2 1058 JLTZ R2 TRAKOK jump if nine-track - all ok 1059 * \ / 043D1 60169010 0 2 REG 1060 LD R0 MTFNTRSEL+R2 track select op code 043D2 DC404423 1061 CALLNP TAPEFUNC 1062 000043D3 1063 TRAKOK LABEL 043D3 DC4043D5 1064 CALLNP REWIND rewind the drive 043D4 5D1F8001 6 STAK 1065 LEAVE PUSH 1066 * --- 1067 1068 END SETTAPE routine 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 231 (TALON) F 29 offline tape driver 1070 1071 ********************************************************************************** 1072 * * 1073 * REWIND * 1074 * This routine will do a rewind on the tape drive. * 1075 * Call: * 1076 * MTU => tape control block * 1077 * CALLNP REWIND * 1078 * R0 = error code * 1079 * Sets R0, Eats R1:R3. * 1080 * stack required = 3 * 1081 * 1 + MAX ( LONGFUNC (2), LOGERROR (2), PPUIWAIT (1), * 1082 * SETUPNMAP (1), UNMAP (1) ) * 1083 * * 1084 ********************************************************************************** 1085 1086 REWIND BLOCK 1087 ENTRY REWIND 1088 1089 BEGFRAME 1090 ENDFRAME 1091 043D5 DD5F8001 6 STAK 1092 REWIND ENTRNP PUSH 043D6 DC40442E 1093 CALLNP SETUPNMAP do initial stuff 000043D7 1094 REWRETRY LABEL 043D7 60040002 0 IMM 1095 LD R0 MTFNREWIND rewind op-code 043D8 DC404419 1096 CALLNP LONGFUNC do the rewind 043D9 FA0C43E5 0 1097 JNEZ R0 REWERR jump if PPU is un-happy 043DA F68443E5 2 1098 JBT R2/MTSTANER REWERR jump if problems 1099 * \ / 1100 1101 ********************************************************************************** 1102 * When we get here the CTC will always be at BOT, since he will * 1103 * interrupt us when he is done with the rewind. The 9-track * 1104 * may not be at BOT in which case we will have to set up an * 1105 * interrupt on state change to wait for the rewind to complete. * 1106 ********************************************************************************** 1107 1108 * \ / 043DB F6B643E2 2 1109 JBT R2/MTDSTBOT REWOK jump if at BOT 1110 043DC 60040009 0 IMM 1111 LD R0 MTFNDSCION state change interrupt enable code 043DD E4001A30 0 1112 ST R0 CIX(MTCMFUNC) enable the state change 1113 043DE DC004440 1114 CALL PPUIWAIT wait for 9-track rewind to complete 043DF 40447530 IMM 1115 PARVL 30000 wait max of five minutes 1116 043E0 FA0C43E5 0 1117 JNEZ R0 REWERR jump if PPU is un-happy 043E1 F68443E5 2 1118 JBT R2/MTSTANER REWERR jump if problems 000043E2 1119 REWOK LABEL 043E2 EC120000 0 REG 1120 STZ R0 get the all-clear code 000043E3 1121 REWEXIT LABEL 043E3 DC40443C 1122 CALLNP UNMAP unmap the controller 043E4 5D1F8001 6 STAK 1123 LEAVE POP 1124 * --- 1125 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 232 (TALON) F 29 offline tape driver 000043E5 1126 REWERR LABEL 043E5 DC00444E 1127 CALL LOGERROR log the error 043E6 40440011 IMM 1128 PARVL ERTOPREW indicate during REW 043E7 F6B643E2 2 1129 JBT R2/MTDSTBOT REWOK all ok if at front of tape 043E8 60040006 0 IMM 1130 LD R0 TERRDNR drive not ready? 043E9 F2B443E3 2 1131 JBF R2/MTDSTRDY REWEXIT exit if that was the error 043EA D040447D 1132 DEC RETRYCOUNT see if we should try again 043EB FE0643D7 1133 JGE REWRETRY go give it another chance 043EC 60040007 0 IMM 1134 LD R0 TERRITE say it's irrecoverable 043ED FE0E43E3 1135 JMP REWEXIT and return the bad news 1136 * --- 1137 1138 END REWIND 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 233 (TALON) F 29 offline tape driver 1140 1141 ********************************************************************************** 1142 * * 1143 * SEFF * 1144 * This routine will search forward past the next * 1145 * file mark on the tape. * 1146 * Call: * 1147 * LD MTU => tape control block * 1148 * CALLNP SEFF * 1149 * ST R0 error code (0 if ok) * 1150 * Sets R0, Eats R1:R2. * 1151 * stack required = 3 * 1152 * 1 + MAX ( INTFUNC (2), LONGFUNC (2), LOGERROR (2), * 1153 * SETUPNMAP (1), UNMAP (1) ) * 1154 * * 1155 ********************************************************************************** 1156 1157 SEFF BLOCK 1158 ENTRY SEFF 1159 1160 BEGFRAME 1161 ENDFRAME 1162 043EE DD5F8001 6 STAK 1163 SEFF ENTRNP PUSH 043EF DC40442E 1164 CALLNP SETUPNMAP do initial stuff 000043F0 1165 RETRYLOOP LABEL 043F0 60040005 0 IMM 1166 LD R0 MTFNSEFF seek EOF forward opcode 043F1 DC404419 1167 CALLNP LONGFUNC do operation 043F2 FA0C43F7 0 1168 JNEZ R0 SEFFERR jump on PPU error 043F3 F68443F7 2 1169 JBT R2/MTSTANER SEFFERR jump on controller error 043F4 EC120000 0 REG 1170 STZ R0 say all is ok 000043F5 1171 SEFFEXIT LABEL 043F5 DC40443C 1172 CALLNP UNMAP unmap the controller 043F6 5D1F8001 6 STAK 1173 LEAVE POP 1174 * --- 1175 000043F7 1176 SEFFERR LABEL 043F7 DC00444E 1177 CALL LOGERROR log the error 043F8 40440015 IMM 1178 PARVL ERTOPSEFF indicate during SEFF 043F9 60040006 0 IMM 1179 LD R0 TERRDNR assume drive not ready 043FA F2B443F5 2 1180 JBF R2/MTDSTRDY SEFFEXIT jump if good guess 043FB F2944400 2 1181 JBF R2/MTSTTMFWB RETRY if tape didn't move, retry 043FC 60040006 0 IMM 1182 LD R0 MTFNBKSP tape moved forward 043FD DC40441C 1183 CALLNP INTFUNC backspace before retrying 1184 043FE 60040007 0 IMM 1185 LD R0 TERRITE assume bad error 043FF F68443F5 2 1186 JBT R2/MTSTANER SEFFEXIT give up if bksp doesn't work 1187 * \ / 00004400 1188 RETRY LABEL 04400 D040447D 1189 DEC RETRYCOUNT decrement the retry count 04401 FE0643F0 1190 JGE RETRYLOOP try again a few times 1191 * \ / 04402 60040007 0 IMM 1192 LD R0 TERRITE else use the default 04403 FE0E43F5 1193 JMP SEFFEXIT 1194 * --- 1195 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 234 (TALON) F 29 offline tape driver 1196 END SEFF 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 235 (TALON) F 29 offline tape driver 1198 1199 ********************************************************************************** 1200 * * 1201 * SEFB - Seek End-of-File Backward * 1202 * Call: * 1203 * LD MTU => tape control block * 1204 * CALLNP SEFB * 1205 * ST R0 error code (0 if ok) * 1206 * Sets R0, Eats R1:R2 * 1207 * stack required = 3 * 1208 * 1 + MAX ( INTFUNC (2), LONGFUNC (2), LOGERROR (2), * 1209 * SETUPNMAP (1), UNMAP (1) ) * 1210 * * 1211 ********************************************************************************** 1212 1213 SEFB BLOCK 1214 ENTRY SEFB 1215 1216 BEGFRAME 1217 ENDFRAME 1218 04404 DD5F8001 6 STAK 1219 SEFB ENTRNP PUSH 04405 DC40442E 1220 CALLNP SETUPNMAP do initial stuff 00004406 1221 RETRYLOOP LABEL 04406 60040004 0 IMM 1222 LD R0 MTFNSEFB seek EOF backward opcode 04407 DC404419 1223 CALLNP LONGFUNC do operation, check for errors 04408 FA0C440D 0 1224 JNEZ R0 SEFBERR jump if channel error 04409 F284440B 2 1225 JBF R2/MTSTANER SEFBOK any error? return if ok 0440A F2B6440D 2 1226 JBF R2/MTDSTBOT SEFBERR tape at load point? ok if so 1227 * \ / 0000440B 1228 SEFBOK LABEL R0 = 0 indicates OK 0440B DC40443C 1229 CALLNP UNMAP unmap the controller 0440C 5D1F8001 6 STAK 1230 LEAVE POP 1231 * --- 1232 0000440D 1233 SEFBERR LABEL 0440D DC00444E 1234 CALL LOGERROR log the error 0440E 40440017 IMM 1235 PARVL ERTOPSEFB indicate during SEFB 0440F F2924415 2 1236 JBF R2/MTSTTMBKB SEFBBAD retry if tape didn't move 04410 60040007 0 IMM 1237 LD R0 MTFNFWSP tape moved backward 04411 DC40441C 1238 CALLNP INTFUNC forward space before retrying 04412 F6844415 2 1239 JBT R2/MTSTANER SEFBBAD give up if got error here 04413 D040447D 1240 DEC RETRYCOUNT decrement the retry count 04414 FE064406 1241 JGE RETRYLOOP try again if not hard error 00004415 1242 SEFBBAD LABEL 04415 60040006 0 IMM 1243 LD R0 TERRDNR maybe the drive isn't ready 04416 F2B44418 2 1244 JBF R2/MTDSTRDY SEFBEXIT exit if not 04417 60040007 0 IMM 1245 LD R0 TERRITE else use the catch-all 1246 * \ / 00004418 1247 SEFBEXIT LABEL 04418 FE0E440B 1248 JMP SEFBOK jump to completion 1249 * --- 1250 1251 END SEFB 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 236 (TALON) F 29 offline tape driver 1253 1254 ********************************************************************************** 1255 * * 1256 * INTFUNC, LONGFUNC * 1257 * * 1258 * These routines perform a tape function on the drive, then wait * 1259 * for the interrupt completion. They are intended for internal use. * 1260 * The two entry points give different allowances for the timeout * 1261 * value. INTFUNC allows 80 seconds while LONGFUNC allows 10 minutes. * 1262 * * 1263 * LD MTU => tape control block * 1264 * LD R0 * 1265 * CALLNP INTFUNC (or LONGFUNC) * 1266 * R0 = masked PPU status * 1267 * R1 = PPU status * 1268 * R2 = controller status * 1269 * Sets R0:R2. * 1270 * stack required = 2 * 1271 * 1 + PPUIWAIT(1) * 1272 * * 1273 ********************************************************************************** 1274 1275 INTFUNC BLOCK 1276 ENTRY INTFUNC 1277 ENTRY LONGFUNC 1278 1279 BEGFRAME 1280 ENDFRAME 1281 04419 DD5F8001 6 STAK 1282 LONGFUNC ENTRNP PUSH entry for ten minute allowance 0441A 6084EA60 2 IMM 1283 LD R2 60000 10 minute timeout (10 ms units) 0441B FE0E441E 1284 JMP FUNCCOMMON and share the remainder 1285 * --- 1286 0441C DD5F8001 6 STAK 1287 INTFUNC ENTRNP PUSH entry for 10 second allowance 0441D 60841F40 2 IMM 1288 LD R2 8000 80 second timeout (10 ms units) 0000441E 1289 FUNCCOMMON LABEL 0441E 60570801 1 4 BASE 1290 LD R1 MTU,TPCBUNIT get tape unit number 0441F E4221AB8 0 1 1291 ST R0 CIX(MTCMFUNC+MTINTREQ+MTSELECT+R1) 1292 04420 DC004440 1293 CALL PPUIWAIT wait for PPU interrupt 04421 40528000 2 REG 1294 PARVL R2 indicate maximum wait likely 04422 5D1F8001 6 STAK 1295 LEAVE POP 1296 * --- 1297 1298 END INTFUNC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 237 (TALON) F 29 offline tape driver 1300 1301 ********************************************************************************** 1302 * * 1303 * TAPEFUNC * 1304 * * 1305 * This routine performs a tape function on the drive, and waits * 1306 * for the interrupt completion. * 1307 * * 1308 * LD MTU => tape control block * 1309 * LD R0 * 1310 * CALLNP TAPEFUNC * 1311 * R0 = masked PPU status * 1312 * R1 = PPU status * 1313 * R2 = controller status * 1314 * Sets R0:R2. * 1315 * stack required = 3 * 1316 * 2 + MAX ( PPUIWAIT(1), SETUPNMAP (1), UNMAP (1) ) * 1317 * * 1318 ********************************************************************************** 1319 1320 TAPEFUNC BLOCK 1321 ENTRY TAPEFUNC 1322 1323 BEGFRAME 00178801 6 BASE 1324 R3SAVE BSS 1 1325 ENDFRAME 1326 04423 DD5F8002 6 STAK 1327 TAPEFUNC ENTRNP PUSH 04424 E4D78801 3 6 BASE 1328 ST R3 SP,R3SAVE save R3 from harm 04425 60920000 2 0 REG 1329 LD R2 R0 load desired function 04426 DC40442E 1330 CALLNP SETUPNMAP do initial stuff 1331 04427 60570801 1 4 BASE 1332 LD R1 MTU,TPCBUNIT get tape unit number 04428 E4A21AB8 2 1 1333 ST R2 CIX(MTCMFUNC+MTINTREQ+MTSELECT+R1) 1334 04429 DC004440 1335 CALL PPUIWAIT wait for PPU interrupt 0442A 4044EA60 IMM 1336 PARVL 60000 wait max of ten minutes 1337 0442B DC40443C 1338 CALLNP UNMAP unmap the controller 0442C 60D78801 3 6 BASE 1339 LD R3 SP,R3SAVE restore R3 0442D 5D1F8002 6 STAK 1340 LEAVE POP 1341 * --- 1342 1343 END TAPEFUNC 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 238 (TALON) F 29 offline tape driver 1345 1346 ********************************************************************************** 1347 * * 1348 * SETUPNMAP * 1349 * Routine to do various setup operations. We load up the * 1350 * page file to point to the appropriate tape controller, and * 1351 * select any necessary conditions there in. Before loading * 1352 * the page file to point to the tape controller, we fetch the * 1353 * current clock from the SSU. We accept the slight risk of * 1354 * acquiring the wrong time at rollover. It is used in error * 1355 * ÿlogging. * 1356 * Call: * 1357 * LD R4 => control block * 1358 * CALLNP SETUPNMAP * 1359 * * 1360 * Eats R0:R1, R3. * 1361 * Stack required: 1 * 1362 * * 1363 ********************************************************************************** 1364 1365 SETUPNMAP BLOCK 1366 1367 ENTRY SETUPNMAP 1368 1369 BEGFRAME 1370 ENDFRAME 1371 0442E DD5F8001 6 STAK 1372 SETUPNMAP ENTRNP PUSH 0442F 60C40086 3 IMM 1373 LD PFPTR PNCIX get channel index page number 04430 00C00310 1374 LDPF SSUPF load the page file for the SSU 04431 60401802 1 1375 LD R1 CIX(SSUCLOCKL) fetch low half clock 04432 60001801 0 1376 LD R0 CIX(SSUCLOCKU) fetch high half clock 04433 E600447B 01 1377 ST2 R0 CLOCKTIME save the current time for later 04434 00D70800 4 BASE 1378 LDPF MTU,TPCBPFILE map in the controller 04435 60040000 0 IMM 1379 LD R0 0 value for retry count (none) for vt 04436 60570802 1 4 BASE 1380 LD R1 MTU,TPCBTRACK pick up track 04437 6447FFFE 1 IMM 1381 CPR R1 -2 is it a video tape? 04438 FE02443A 1382 JEQ SETRETRY if so, use 1 for retry count 04439 60040014 0 IMM 1383 LD R0 TAPEERRMAX get retry count 0000443A 1384 SETRETRY LABEL 0443A E400447D 0 1385 ST R0 RETRYCOUNT for error recovery 0443B 5D1F8001 6 STAK 1386 LEAVE POP 1387 * --- 1388 1389 END 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 239 (TALON) F 29 offline tape driver 1391 1392 ********************************************************************************** 1393 * * 1394 * UNMAP * 1395 * Clean up. * 1396 * Call: * 1397 * CALLNP UNMAP * 1398 * Eats R3 * 1399 * stack required = 1 * 1400 * * 1401 ********************************************************************************** 1402 1403 UNMAP BLOCK 1404 ENTRY UNMAP 1405 1406 BEGFRAME 1407 ENDFRAME 1408 0443C DD5F8001 6 STAK 1409 UNMAP ENTRNP PUSH 0443D 60C40086 3 IMM 1410 LD PFPTR PNCIX load controller window page number 0443E 80D2C000 3 REG 1411 PFRC PFPTR and clear PF location 0443F 5D1F8001 6 STAK 1412 LEAVE POP 1413 * --- 1414 1415 END UNMAP 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 240 (TALON) F 29 offline tape driver 1417 1418 ********************************************************************************** 1419 * * 1420 * PPUIWAIT, wait for PPU interrupt * 1421 * * 1422 * This routine waits for an interrupt from the PPU to * 1423 * indicate an I/O operation has been completed. This is done * 1424 * by waiting for the 'controller requests interrupt' bit to * 1425 * become true in the PPU status. This implies that the * 1426 * controller was told to interrupt on completion when the * 1427 * operation was started. This routine leaves the PPU status * 1428 * in R1, the error bits from the PPU status in R0, and the * 1429 * controller status in R2. * 1430 * Call: * 1431 * CALL PPUIWAIT * 1432 * PARVL * 1433 * R0 = masked PPU status * 1434 * R1 = PPU status * 1435 * R2 = controller status * 1436 * Sets R0:R2. * 1437 * stack required = 1 * 1438 * * 1439 ********************************************************************************** 1440 1441 PPUIWAIT BLOCK 1442 ENTRY PPUIWAIT 1443 1444 BEGFRAME 1445 ENDFRAME 1446 04440 DD1F8001 6 STAK 1447 PPUIWAIT ENTR PUSH 04441 C0520000 0 REG 1448 STPVL R0 save max wait time (1 = 10 millisecs) 00004442 1449 INTWAIT LABEL 04442 004403E8 IMM 1450 WAIT 1000 wait here for 10 milliseconds 1451 * \ / to avoid saturating the PPU 04443 60401801 1 1452 LD R1 CIX(PPUINTSTAT) get PPU status 04444 F6784447 1 1453 JBT R1/PPUIINTC ENDWAIT if completed, jump out of loop 04445 FA264442 0 1454 JDR R0 INTWAIT continue if max time not exceeded 1455 * \ / 04446 D1524000 1 REG 1456 STMW R1 say we timed out 00004447 1457 ENDWAIT LABEL 04447 60124000 0 1 REG 1458 LD R0 R1 copy status 04448 78046540 0 IMM 1459 AND R0 PPUMASK mask off the bad bits 04449 60801802 2 1460 LD R2 CIX(PPUCHANS1) get controller status at interrupt time 0444A FA02444D 0 1461 JEQZ R0 NOPPUERR jump if PPU happy 0444B EC001801 1462 STZ CIX(PPUABORT) clean up channel 0444C 00420008 IMM 1463 WAIT CATCHWAIT wait for controller to catch up 0000444D 1464 NOPPUERR LABEL 0444D 5D1F8001 6 STAK 1465 LEAVE POP 1466 * --- 1467 1468 1469 END PPUIWAIT 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 241 (TALON) F 29 offline tape driver 1471 1472 ********************************************************************************** 1473 * * 1474 * LOGERROR - Log a tape I/O error. * 1475 * See ERRLOGBLK for the format of the entries. * 1476 * Call: * 1477 * RECORDNUM = record number or optional data * 1478 * R1 = PPU status * 1479 * R2 = controller status * 1480 * R4 = address of tape control block * 1481 * CALL LOGERROR eats R0:R1 before passing parameters * 1482 * PARVL * 1483 * * 1484 * Eats R0 * 1485 * Stack required = 2 * 1486 * * 1487 ********************************************************************************** 1488 1489 LOGERROR BLOCK error log routine 1490 1491 ENTRY LOGERROR 1492 1493 BEGFRAME 00178801 6 BASE 1494 PPUSTATUS BSS 1 to hold the PPU status 1495 ENDFRAME 1496 0444E DD9F8002 6 STAK 1497 LOGERROR ENTRS PUSH 0444F E4578801 1 6 BASE 1498 ST R1 SP,PPUSTATUS save the PPU status 04450 604013EA 1 1499 LD R1 VERRLOGPTR R1 -> error log buffer 04451 FA424478 1 1500 JEQZ R1 LOGSKIP jump if no log buffer exists 04452 60164800 0 1 BASE 1501 LD R0 R1,0 get first word 04453 FA2C4477 0 1502 JEQMW R0 LOGFULL jump if log is full 1503 04454 60090840 0 4 ZBM 1504 LD R0 R4,DCBPFILE/PFSLOT get slot number of PPU 04455 E4084843 0 1 ZBM 1505 ST R0 R1,ERRSLOT save it 04456 60093020 0 4 ZBM 1506 LD R0 R4,DCBPFILE/PPUCHAN get channel number of controller 04457 E4085043 0 1 ZBM 1507 ST R0 R1,ERRCHAN save it 04458 60170801 0 4 BASE 1508 LD R0 R4,DCBUNIT get tape unit number 04459 E4085843 0 1 ZBM 1509 ST R0 R1,ERRUNIT save it 1510 0445A DCD3C000 7 REG 1511 EXPCS R7 go get parms 0445B C0564004 1 CACH 1512 STPVL R1,ERROPER save operation type 0445C 6000447E 0 1513 LD R0 RECORDNUM retrieve record number 0445D E4085181 0 1 ZBM 1514 ST R0 R1,ERRBLOCK and save it 0445E 60178801 0 6 BASE 1515 LD R0 SP,PPUSTATUS retrieve PPU status 0445F E4086103 0 1 ZBM 1516 ST R0 R1,ERRPPUSTAT save PPU status 04460 E4964804 2 1 BASE 1517 ST R2 R1,ERRCTLSTAT save tape status 1518 04461 38964004 2 1 CACH 1519 LEA R2 R1,ERRCOMPARE R2 -> beginning of part to compare 04462 E4961005 2 0 REG 1520 ST R2 R0+ERRLNTH R0 -> previous log entry 04463 60440010 1 IMM 1521 LD R1 ERREND DISPC ERRCOMPARE R1 = size to compare 04464 FE540000 1522 CMS same error as previous entry? 1523 * condition bits held for later test 04465 600013EA 0 1524 LD R0 VERRLOGPTR re-fetch error log buffer pointer 04466 60960804 2 0 BASE 1525 LD R2 R0,ERRCTLSTAT retrieve callers controller status 04467 FE0C446B 1526 JNE SETTIME jump if not 1 Assembler C9208 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:12 PAGE 242 (TALON) F 29 offline tape driver 04468 10040005 0 IMM 1527 SUB R0 ERRLNTH make pointer to previous entry 04469 D0160000 0 CACH 1528 INC R0,ERRCOUNT increment number of times for this error 0446A FE0E4475 1529 JMP LOGDONE and we're all done 1530 * --- 1531 0000446B 1532 SETTIME LABEL 0446B 6200447B 01 1533 LD2 R0 CLOCKTIME get the time last read from SSU 0446C 160403E8 01 IMM 1534 DIV2 R0 1000 convert value to seconds 0446D 58C40010 IMM 1535 IORPSR PSRMODIF 0446E 14055180 0 IMM 1536 DIV R0 86400 R1 = seconds past midnight 0446F 58840010 IMM 1537 CLBPSR PSRMODIF 04470 600013EA 0 1538 LD R0 VERRLOGPTR restore pointer to log file entry 04471 E4481180 1 0 ZBM 1539 ST R1 R0,ERRTIME save time of error 04472 EDD60000 0 CACH 1540 STW R0,ERRCOUNT say error has occurred once 04473 18040005 0 IMM 1541 ADD R0 ERRLNTH point to next entry 04474 E40013EA 0 1542 ST R0 VERRLOGPTR update pointer to error log buffer 1543 * \ / 1544 00004475 1545 LOGDONE LABEL 04475 60578801 1 6 BASE 1546 LD R1 SP,PPUSTATUS restore PPU status 04476 5D1F8002 6 STAK 1547 LEAVE POP return 1548 * --- 1549 00004477 1550 LOGFULL LABEL 04477 D0164801 1 BASE 1551 INC R1,1 increment number of lost errors 1552 * \ / 1553 00004478 1554 LOGSKIP LABEL throw away the parameters 04478 DCD3C000 7 REG 1555 EXPCS R7 go get parms 04479 C0520000 0 REG 1556 STPVL R0 get operation in error 0447A FE0E4475 1557 JMP LOGDONE 1558 * --- 1559 1560 END LOGERROR of error log routine 1561 0000447B 1562 CLOCKTIME BSS 2 holds the current time 0000447D 1563 RETRYCOUNT BSS 1 retry counter 0000447E 1564 RECORDNUM BSS 1 current record number (for error log) 1565 1566 END TALON of tape driver 1649 END DISKTOTAPE 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 1 A 00003F35 F 23 80 85= ACCTBIT 00003A10 F 18 1572j 1686= 1692e ACCTENCR 0000490A F 17 512= F 20 377 625s 1073 1463 ACCTEND 0000362B F 18 817j 829= 838j 926j ACCTIN 0000386F F 18 1572j 1580= ACCTINDEX 0000492B F 17 518= F 20 141 465 633 2026s ACCTINIDX 00178803 F 18 709= 718s 721 745 ACCTMAXTS 0000000A F 17 430= 436e ACCTMCB 00178802 F 20 588= 593s 600 687 ACCTNOALSL 00000076 F 17 437= F 20 605 ACCTRECSIZ 00000876 F 17 436= 437e F 20 596 ACTB 00000004 F 18 1692= 1706x 1707x 1709x 1710x 1711x 1712x 1714x 1715x 1716x 1717x 1718x ACTFILLEN 00000004 F 16 260= 261 F 20 628 *ACTHDR 00160800 F 16 256= ACTHDRFAST 00160804 F 16 259= F 20 623s ACTHDRFILL 00160805 F 16 261= F 20 627a *ACTHDRNAME 00160809 F 16 262= ACTHDRNOSL 00160803 F 16 258= F 20 614s ACTHDRSER 00160801 F 16 257= F 20 612s ACTRECLEN 00000009 F 16 264= F 17 436e F 20 631 ADDRREC 00178802 F 29 766= 772s 785 806 814 ALLDONE 00003433 F 0 1254j 1267= ANYENCR 00003D0B F 20 1415j 1420= ANYTYPE 00003848 F 18 1508j 1514= ASK4MESS 00004227 F 27 416= 428a ASKAGAIN 00004234 F 27 425= 434j 441j ASKIFOK 000031FC F 0 780= 790j 802j ASKMESS 00003212 F 0 784a 811= ASNB 00000010 F 18 1694= 1706x 1707x 1714x 1718x ASNBIT 00003610 F 18 1608j 1684= 1694e AUNSUBTAB 00003F1D F 22 104 116= AVAILABLE 00178802 F 20 1502= 1515s 1522 BADASHL 00003640 F 18 783j 841= BADAUTH 00003643 F 18 799j 847= BADBLOCK 00003DA6 F 20 1815j 1828= BADBUF 00003E7E F 21 159j 245= BADBYE 000035D0 F 18 673= 680j BADCHAN 00004290 F 29 155j 207= BADDIR1 0000363E F 18 739j 836= BADDIR2 0000366F F 18 885j 929= BADENTRY 00003DA4 F 20 1811j 1824= BADERR 000041F8 F 27 246j 285j 289j 292= BADFIL 0000357D F 18 481j 508= BADFILMSG 00003581 F 18 511a 515= BADFSHL 000036B4 F 18 1009j 1023= BADFSLR 00004198 F 27 43j 87j 95= BADIDX 000035D1 F 18 642j 677= BADIDXMES 000035D4 F 18 679a 683= BADLEAVE 0000376A F 18 1399= 1405j BADMIN 0000372E F 18 1252j 1267= BADNAMEM 0000367C F 18 943a 948= BADREAD 000042AD F 29 293j 294j 307= BADRELNUM 000038C8 F 18 1790j 1796= BADRTN 000035B0 F 18 547j 555j 576j 596= BADSAF 000036EE F 18 1110j 1127= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 2 BADSLOT 00004292 F 29 158j 169j 212= BADTAPE 00004294 F 29 186j 217= BADTAPMES 000041A0 F 27 97a 106= BADUDIRNAM 00003671 F 18 896j 899j 934= BADUNIT 0000428E F 29 150j 202= BAILOUT 00003708 F 18 1184j 1196= 1217j 1237j BAILOUT 0000376B F 18 1384j 1403= BCRCOUNT 000042E8 F 29 440= 473j BEFORE 000048F7 F 17 458= 473a BEGFRAME2 MACRO F 17 159= F 21 45 BEGREC 00178803 F 20 589= 598s 603 683 684 BFILLER 000035C8 F 18 649j 660= BIGDIR 00003646 F 18 810j 862= BILDRANDOM 00003F07 F 22 35 49 69= BILDSPOT 00178008 F 0 1079= 1085a BILDSPOTW 00178802 F 0 1078= 1086s 1094 BKUPHDRLEN 00000002 F 0 250= F 17 436e 439e 441e 445e F 20 641 1368 BKUPHDRW1 00160800 F 0 250= F 20 1366s BKUPHDRW2 00160801 F 0 250= F 20 511s 527s 664s 678s 959s 988s 1117s 1119s 1207s 1209s 1367s BKUPREV 00001F10 F 0 250= F 20 1365s BLINKBIT 00003410 F 18 1551j 1683= 1691e BLINKIN 00003862 F 18 1551j 1559= BLNKB 00000020 F 18 1691= 1704x 1709x BLOCKEND 00178805 F 19 87= 109s 115 119 185 198 BLOCKNUM 00178801 F 18 2036= 2126s 2160a BOOTBAD 00003528 F 18 338j 393= BOOTBADM 0000352B F 18 395a 399= BOOTDONE 00003B07 F 20 221j 276= BOOTINFO 00160805 F 16 179= F 20 159s 167s F 27 45s BOOTLOOP 00003AD9 F 20 217= 273j BRLOOP 00003F0A F 22 74= 77j BSORT 000037C9 F 19 53 243 248= BUBEND 000037D7 F 19 267j 271= BUBSEND 00003778 F 19 50j 56= BUBSORT 00003775 F 19 37j 48= BUCKET 00178802 F 18 625= 629s 654 668s BUCKNUM 00178808 F 18 713= 717s BUENCRYPT 00003EFD F 21 236 F 22 6 34= BUF 00004827 F 0 671a 787a F 17 251= F 27 431a BUFC 02004827 F 17 252= 342a BUFL 00000050 F 0 670 673 786 789 863 F 17 250= 252 F 27 430 433 BUFP 000048CB F 0 680s 681 792s 793 F 17 342= F 27 437s 438 BUILDBLOCK 00003420 F 0 1235= 1262j BUILDMCBS 000033F4 F 0 356 1112= 1114 1119= 1145 BUILDPAGE 00003426 F 0 1237j 1247= 1258j BUILDPRELS 0000343E F 0 357 1326= 1328 1333= 1353 CALLFAST 00003B38 F 20 369j 372j 400= CANTDO 00003EDC F 21 439j 468= CARTRIDGE 0000433D F 29 592j 618= CATCHWAIT 00040000 F 29 111= 457 878 1463 CDCHEK 000038D9 F 18 1547 1841= 1843 1850= 1890 CDCHEKR1 00178801 F 18 1846= 1851s 1865 1870 1882 CDCHEKR2 00178802 F 18 1847= 1877s 1883 CDERR 000038EA F 18 1858j 1861j 1876= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 3 CDEXIT 000038E4 F 18 1864= 1872j 1887j CDZERO 000038E6 F 18 1855j 1869= CHECKGAP 0000431E F 29 558j 567= CHECKSUM 000040DC F 21 106 F 26 22= 23 27= 181 F 27 277 354 495 CHEK4END 00003D1F F 20 1429j 1445= 1474j CHEK4ROOM 00003D03 F 20 594 879 1289 1402= 1404 1410= 1477 CHEKAUTHL 00003BD1 F 20 655j 667= CHEKENCR 00003190 F 0 294 530 569j 580= 610j CHEKENCRT 00178801 F 20 1407= 1411s 1414 1458 CHEKFBIFLG 0000487C F 17 307= F 18 298s 470s 489s 1515 CHEKFLAG 00003855 F 18 1533j 1540= CHEKFSN 0000387E F 18 1594j 1604= CHEKIFDONE 00003195 F 0 296 532 586j 604= CHEKPACK 00003187 F 0 292 528 554j 567= 608j F 18 379j CHEKPPU 00004313 F 29 550= 615j CHEKPROJ 00003873 F 18 1577j 1587= CHEKREAD 0000317E F 0 552= 606j CHEKRELBLK 00003866 F 18 1556j 1566= CHEKSECT 00003814 F 19 448j 450= CHEKTAPE 00003191 F 0 295 531 584= F 21 191j CHEKTYPE 000036FB F 18 1164a 1169= CHICKENMS 0000304A F 0 379a 383= CHKSTAT 000042A5 F 29 283j 292= CHUNKLOOP 00003E46 F 21 142= 162j CHUNKPTR 00178800 F 21 46= 125s 150 151s CHUNKSIZE 00178803 F 21 49= 138s 143 CLEANUP 0000351D F 18 374= 404j 421j CLEANUP 00003C75 F 20 1002= 1012j CLEARAREA 00004800 F 0 472a F 17 183= 217e CLEARLEN 00000016 F 0 473 F 17 217= CLEARLOOP 00003179 F 0 542= 546j CLOCKTIME 0000447B F 29 1377s 1533 1562= CMINUS1 00003F36 F 23 81 86= COMJTAB 000031DD F 0 702 720= COMMANDS 0000322B F 0 724a 815= COMMES 00003220 F 0 813= 822a 830a COMMHELPT 00003269 F 0 917 946= COMMLOOP 000031B9 F 0 687= 690j COMMTAB 000031C9 F 0 648 688 705= 715e 817a 818a 819a 820a 821a 825a 826a 827a 828a 829a 906 COMMTABL 00000009 F 0 649 686 715= 904 CONTAUTH 0000361B F 18 790j 804= CONTROLERR 00004327 F 29 549j 585= CONTSHL 00003610 F 18 774j 788= 844j 850j COPYFILE 0000358E F 18 480 536= 537 543= 600 COUNT 00178801 F 27 479= 499s 511s COUNT 00178803 F 29 767= 798s 801 827s 836 837s 884 894 896s CPRFORM 00004908 F 17 507= F 20 59s 313s 370 540s 1068s 1427 1442s 1457s 1619s 1896 1915s CPRPN 00004909 F 17 511= F 20 479s 1097s 1436s 1516s 1662s CPUCOUNT 00004815 F 0 549s 613s F 17 215= *CR 0000000D F 17 389= CRYPT 00003F37 F 21 153 F 25 5 113= CRYPTSTACK 00008CAC F 21 288a F 24 36= CTERRMAX 00000019 F 29 619 704= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 4 CTERRPTR 00004348 F 29 620 706= CTERRTAB 00804346 F 29 679= 704e 706a CURBLK 00004864 F 17 287= F 18 1480s 1485 1486s 1497 1643 1789 1800 1807 1881 1938 1999 CURBLOCK 00178806 F 19 88= 106s 215 223 CURDATE 000048CA F 17 341= F 18 1859 1885 CURUDIR1 00178807 F 18 712= 729s 940a CYLEND 00003817 F 19 423j 456= DATAACTSER 00160801 F 16 318= F 20 1249s DATABAD 00003754 F 18 1332j 1348= DATAFILL 00160805 F 16 325= F 20 1255a DATAFILLEN 00000003 F 16 324= 325 F 20 1256 *DATAHDR 00160800 F 16 317= DATAPAGESN 00081184 F 16 322= F 20 1254s DATASEQNUM 00160803 F 16 319= F 20 1251s DATPAGE 00178801 F 29 265= 272s 279 *DCBBTRAX 00081187 F 14 27= DCBFILLADR 00160802 F 14 15= 28e *DCBFILLLEN 00000006 F 14 28= DCBLEN 00000008 F 14 30= F 17 257 *DCBLUN 0016001C F 14 26= *DCBMAIMNT 00080216 F 14 22= *DCBNORETRY 00080416 F 14 23= *DCBNOSUBS 00080016 F 14 21= DCBPFILE 00160800 F 14 13= F 29 1504 1506 DCBSCSI 00080816 F 14 25= F 18 1308 DCBSECPTRK 00160802 F 0 348 F 14 16= *DCBSUBLIST 00160804 F 14 18= DCBTRKPCYL 00160803 F 0 350 F 14 17= DCBUNIT 00160801 F 14 14= F 29 1508 *DCBVERIFY 00080616 F 14 24= DCBVOLSIZE 00160805 F 0 346 F 14 19= DCBWORD 00160806 F 14 20= 21e 22e 23e 24e 25e DESTBLOCK 00178807 F 19 89= 107s 216 222 DESTBLOCK 00178802 F 19 388= 396s 469s 475 DIR1IDEMP 0000366E F 18 867j 925= DIR1INDEX 00178801 F 18 707= 805s 813 824s 863 920s DIR2FDEMP 0000366A F 18 905j 918= 931j DIR2INDEX 00178802 F 18 708= 888s 912s DISKCB 00004844 F 0 340a F 17 257= F 18 375a 453a 545a 1307a 1494a DISKCTLBLK 00000400 F 14 12= 30e 31a DISKNAME 00004820 F 0 341 424a 431a 659s 752s 782a F 17 239= DISKTOTAPE 00003000 F 0 233a 285 305= *DIVBY4BITS 000001E0 F 17 391= DIVEND 000037EE F 19 345j 360= DIVLOOP 000037E6 F 19 349= 356j DIVSECTOR 000037E2 F 18 1310 F 19 339 344= DONEPACK 0000318F F 0 293 529 572j 578= F 20 65j 1867j DONEREAD 00003186 F 0 291 527 559j 565= F 18 183j DONETAPE 00003194 F 0 297 533 590= F 27 153j DONTDUMP 00003047 F 0 322j 377= DONTMAP 00003A8D F 20 42j 44= DONTREAD 000036B3 F 18 978j 1019= DONTSEND 00003B1D F 20 339j 343= DOONEBUF 000042D2 F 29 287 405= 406 412= 476 DOPRESET 00004390 F 29 866j 876= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 5 DOTWOBUF 000042BB F 29 282 348= 349 354= 382 DOWRITE 0000434C F 29 529 760= 762 770= 905 DUMPDONE 00003038 F 0 286 366= 614j F 27 138j DUMPDONEM 0000303D F 0 370a 374= *ECBLKREUS 0000000D F 14 74= *ECCHAN 00000003 F 14 64= ECDA 0000000C F 14 73= F 18 1637 *ECDATA 00000001 F 14 62= *ECFBI 00000002 F 14 63= ECFBIACCT 00000009 F 14 70= F 18 1582 ECFBIBDAT 00000019 F 14 86= F 18 1873 ECFBIBLNE 00000011 F 14 78= F 18 1553 ECFBIBLNK 0000000B F 14 72= F 18 1561 ECFBIFDAT 00000013 F 14 80= F 18 1860 ECFBIFLAG 0000000F F 14 76= F 18 1543 ECFBIFLNK 0000000E F 14 75= F 18 1535 ECFBIFSN 0000000A F 14 71= F 18 1616 ECFBINBAN 00000015 F 14 82= F 18 1574 ECFBINBFS 00000018 F 14 85= F 18 1624 ECFBINBPJ 00000016 F 14 83= F 18 1591 ECFBIODAT 00000012 F 14 79= F 18 1857 ECFBIPROJ 00000017 F 14 84= F 18 1599 ECFBIRBN 00000014 F 14 81= F 18 1778 1799 *ECFBISUB 00000010 F 14 77= ECFBITYPE 00000008 F 14 69= F 18 1510 *ECMPE 00000007 F 14 68= *ECNOCODE 00000000 F 14 61= *ECNOTRDY 00000005 F 14 66= *ECRECBAD 0000001D F 14 90= *ECSAFBAD 0000001C F 14 89= *ECSEEK 00000004 F 14 65= *ECSUBENT 0000001B F 14 88= ECUDIRORD 0000001A F 14 87= F 18 1034 *ECWRPROT 00000006 F 14 67= EFRWERR 0000421D F 27 325j 362j 366j 368= EMPTY 000048D7 F 17 403= F 18 1536 1554 1592 EMPTY2 000048D6 F 17 402= 403e F 18 1575 1625 EMPTYMIN 00003753 F 18 1319j 1344= EMPTYQ 00003D90 F 20 1752j 1767= EMPTYSLOT 00003400 F 0 1129j 1135= ENCRDEFEND 0000498D F 17 589= 595a ENCRDONE 00003E58 F 21 43 60j 68j 70j 75j 175= 234j ENCRFASTFL 0000481C F 0 657s 737s F 17 234= F 20 374 617 1461 ENCRNONE 00000003 F 17 105= F 20 102 105 376 1078 1467 F 21 109 ENCRNORM 00000002 F 17 104= F 20 379 454 595 1072 1460 ENCRPRPAGE 00009000 F 17 593= F 21 104a 121a ENCRPRPN 000000A4 F 17 598= F 21 101 ENCRQCNT 0000480F F 17 207= F 20 1912s F 21 59 378s ENCRSTKPTR 0000497D F 17 587= F 21 178 287s ENCRTBM 00000001 F 17 103= F 20 228 ENCRVARPAG 00008C00 F 17 592= F 24 22a ENCRVARPN 000000A3 F 17 597= 598e F 21 179 282 ENCRYALL 00003BAF F 20 618j 622= ENCRYERR 00003E72 F 21 202j 220= ENCRYLOCK 00004810 F 17 208= F 20 1908s 1913s F 21 324s 334s 367s 405s ENCRYLOOP 00003E19 F 21 58= 172j 215j 240j 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 6 ENCRYMC F 21 40= 249 ENCRYOK 00003B31 F 20 375j 385= ENCRYPT 00003E16 F 0 581j F 21 6 42 53= ENCRYPTPROC F 21 4= 570 ENCRYQHD 0000480D F 0 504a 609 F 17 205= F 21 325 370 377s 396a ENCRYQTL 0000480E F 0 505s F 17 206= F 20 1909 1911s F 21 397s ENCRYTAB 00003E27 F 21 77 80= ENCTYP 00080101 F 16 171= F 20 115s ENDFILESET 000041B4 F 27 50j 135= ENDFILLEN 00000004 F 16 202= 203 F 27 349 ENDFILLER 00160803 F 16 203= F 27 348a ENDFSREC 000041F9 F 27 136 315= 317 322= 372 *ENDHEADER 00160800 F 16 200= ENDOFBUKT 000035CC F 18 630j 635j 652j 667= ENDOFTAPE 00004190 F 27 66j 80= ENDTAPE 0000438F F 29 868j 873= ENDTIME 00160801 F 16 201= F 27 347s ENDVOL 000041CE F 27 200j 206= ENDWAIT 000042EF F 29 446j 451= ENDWAIT 00004387 F 29 856j 862= ENDWAIT 00004447 F 29 1453j 1457= ENUFPAGE 00003D31 F 20 604 747 884 1178 1496= 1498 1506= 1532 ENUFR3 00178803 F 20 1503= 1508s 1528 EQPBLK 0000487E F 17 312= F 18 452a 544a EQPFILNAM 00004883 F 17 316= F 18 451s 475s 510a ERRBLKLEN 0000000F F 17 305= F 18 300 ERRBLOCK 00081181 F 28 53= F 29 1514s ERRCHAN 00081043 F 28 60= F 29 1507s ERRCODE 00178803 F 18 1919= 1925s 1937 ERRCODE 00178803 F 18 1980= 1986s 1998 ERRCODETAB 0000391A F 18 2041= 2131a ERRCOMPARE 00160004 F 28 23= F 29 1519a 1521 ERRCOUNT 00160000 F 28 20= F 29 1528s 1540s ERRCTLSTAT 00160804 F 28 64= F 29 1517s 1525 *ERRDEVICE 000808C3 F 28 58= ERREND 00160805 F 28 65= F 29 1521 ERRETURN 00003245 F 0 866j 870j 872= ERRETURN 00003DA3 F 20 1820= 1826j ERRETURN 00003EDB F 21 464= 482j ERRETURN 00004226 F 27 412= 447j ERRETURN 0000425F F 27 508j 509j 516= *ERRHDR 00160800 F 16 340= ERRLNTH 00000005 F 28 67= F 29 1520s 1527 1541 ERRLOGBLK 00004260 F 28 19= 67e 68a ERRMERGE 00003EE0 F 21 470j 477= *ERROPCKSEG 00000005 F 28 32= ERROPER 00160004 F 28 25= F 29 1512s *ERROPFMT 0000000C F 28 40= *ERROPINQ 00000008 F 28 36= *ERROPMS 0000000A F 28 38= *ERROPMSN 0000000B F 28 39= *ERROPOFSET 00000006 F 28 33= *ERROPRDC 0000000D F 28 41= *ERROPREAD 00000002 F 28 29= *ERROPRES 00000009 F 28 37= *ERROPRS 0000000E F 28 42= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 7 *ERROPRTN 00000007 F 28 34= *ERROPSEEK 00000000 F 28 27= *ERROPSEG 00000004 F 28 31= *ERROPWRITE 00000003 F 28 30= *ERROPZERO 00000001 F 28 28= ERRORBLOCK 0000486D F 17 295= 305e F 18 301a 756a ERRORCODE 00004865 F 17 288= F 18 2125s 2130 2132s 2159a ERROREXIT 0000388E F 18 1631= 1648j 1666j ERRPPUSTAT 00082103 F 28 62= F 29 1516s ERRRECLEN 00000001 F 16 342= F 20 1291 1294 *ERRSEEKADR 00160802 F 28 55= ERRSLOT 00080843 F 28 59= F 29 1505s ERRSPOT 00004392 F 29 867j 879= ERRSTRING 00003484 F 0 1610= 1631a ERRTIME 00081180 F 28 21= F 29 1539s ERRUNIT 00081843 F 28 61= F 29 1509s ERTOPBKSP 00000010 F 28 44= F 29 321 565 1026 ERTOPGAP 00000016 F 28 50= F 29 970 ERTOPREAD 00000012 F 28 46= F 29 309 ERTOPREW 00000011 F 28 45= F 29 1128 ERTOPSEFB 00000017 F 28 51= F 29 1235 ERTOPSEFF 00000015 F 28 49= F 29 1178 ERTOPWFM 00000014 F 28 48= F 29 1020 ERTOPWRITE 00000013 F 28 47= F 29 546 EXTRA 00178804 F 21 50= 139s 144s 229s 238 FASTEND 00003CB9 F 20 1130j 1140= FASTFBIMCB 0000492D F 17 521= F 20 1066s 1430 1900 FASTFBIPTR 0000492E F 17 427a 522= F 20 1083s 1111 1125s 1440 FASTFORM 00000002 F 17 510= F 20 1067 1428 1897 FASTHDRLOC 000097F0 F 17 549= F 20 1063a FASTPHSHDR 000097F0 F 17 546= 548a F 20 1076 1084 1098 1135 FASTR4 00178801 F 20 1053= 1061s 1092 FASTRECLEN 0000040D F 17 445= 446e F 20 1100 1129 1188 FATALERR 000043C0 F 29 1013= 1022j 1029j FBI2FLDCHEK 00003907 F 18 1573 1581 1615 1623 1973= 1975 1985= 2012 FBIADR 00178803 F 18 1473= 1482s 1499a 1506 1650 FBIFLAGPTR 000038B5 F 18 1544 1737= FBIFLAGVAL 00C038B2 F 18 1732= 1737a FBIFLDCHEK 000038F4 F 18 1534 1542 1552 1560 1590 1598 1777 1912= 1914 1924= 1951 FBILOC 00178805 F 18 1921= 1927s 1929 1943s FBILOC 00178806 F 18 1982= 1988s 1990 2004s FBIMAJBITS 000898A4 F 18 1768= 1791 1819s FBIMINBITS 0008ACA4 F 18 1299= 1333 FBIMINBITS 0008ACA4 F 18 1767= 1786 1817s FBITYPEMAX 00000017 F 18 2111= 2145 FBITYPETAB 000039B8 F 18 1658a 2032 2073= 2148a FBITYPEX 00178801 F 18 1471= 1479s 1507 1522 1541 1644 FBITYPEX 00178802 F 18 2037= 2127s 2135 2139s 2149s 2161a FDEPTR 00004850 F 17 272= F 18 818s 906s 975 994 1014 1042 1099 1156 1375 1437 FERM 00003A78 F 18 2141j 2151= FFPNPTR 000048F6 F 17 427= F 20 1439s FILBLKRECL 00000416 F 17 446= F 20 388 1179 1183 FILEBEGPTR 00178801 F 20 869= 883s 997 998 1010 FILEBLHDR 00003CDC F 20 1085 1181 1238= 1240 1245= 1261 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 8 FILEBLOCK 00003B25 F 20 326a 368= FILEFILLEN 00000004 F 16 285= 286 F 20 917 FILEINDEX 0000492C F 17 519= F 20 636s 924 FILEINFOT 000000F0 F 0 250= F 20 1363s FILEINFOTA 00000001 F 0 250= F 20 647 *FILEINFOTD 00000003 F 0 250= FILEINFOTF 00000002 F 0 250= F 20 938 FILEINFOTM 00000004 F 0 250= F 20 1114 1204 FILEINFOTV 00000000 F 0 250= F 20 475 FILELINE 000036C3 F 18 1041a 1046= FILEMAXTS 0000000F F 17 431= 442e FILEMERR 000043C2 F 29 1010j 1011j 1018= FILENOSL 0000003D F 17 443= F 20 885 FILEOSSIZE 0000001A F 17 441= 442e F 20 931 FILER3 00178804 F 20 872= 971s 979 FILERECSIZ 0000043D F 17 442= 443e F 20 881 FILESETLR 00003A9A F 20 60 91= 93 98= 182 *FILHDR 00160800 F 16 275= FILHDRASER 00160801 F 16 276= F 20 892s FILHDRBDAT 0016080C F 16 283= F 20 910s 912s FILHDRCDAT 0016080A F 16 282= F 20 909s FILHDRFILL 0016080F F 16 286= F 20 916a FILHDRGOST 0016080E F 16 284= F 20 915s FILHDRNAME 00160813 F 16 287= F 20 921a FILHDRNOSL 00160803 F 16 277= F 20 893s FILHDRRDAT 00160806 F 16 280= F 20 902s 904s FILHDRSIZE 00160805 F 16 279= F 20 900s FILHDRTYPE 00160804 F 16 278= F 20 898s FILHDRWDAT 00160808 F 16 281= F 20 905s 907s *FILLERHDR 00160800 F 16 352= *FILLERRECL 00000001 F 16 354= FILPRELPTR 00178803 F 20 871= 878s 895 960 1003s 1005 FILRECLEN 00000013 F 16 289= F 17 442e FINDLOOP 000038CE F 18 1804= 1809j FINDPHYREC 00003E92 F 21 74 316= 318 323= 338 FINDTEXTZ 0000348B F 0 289 390 426 1603= 1604 1612= F 18 1656 2129 2146 2152 FINISHUP 00003BDA F 20 669j 681= FIPRECLEN 00000008 F 16 327= F 17 446e 546e F 20 1088 1090 1102 FLD2CHKEND 00003918 F 18 1992j 2007= FLD2CHKR2 00178802 F 18 1979= 1995s 2001 FLD2CHKR3 00178801 F 18 1978= 1989s 2000 2008 FLDCHKEND 00003905 F 18 1931j 1946= FLDCHKR1 00178801 F 18 1917= 1928s 1939 1947 FLDCHKR2 00178802 F 18 1918= 1934s 1940 FLINKBIT 00003010 F 18 1533j 1681= 1690e FLNKB 00000080 F 18 1690= 1704x 1709x *FNAMBLKLEN 0000000A F 14 100= FNBLKPROT 00000400 F 14 92= 100e 101a FNDEND 00003C17 F 20 827j 836= FORTYTAB 00003DD1 F 20 1951= 1972 FOUNDEND 00003C09 F 20 789j 796= FOUNDFLAG 00178801 F 19 387= 412s 431s 458s FOUNDIT 000031C8 F 0 689j 701= FOUNDIT 000038D4 F 18 1808j 1815= FOUNDSEC 0000380B F 19 425j 437= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 9 FPLRSEQNUM 00004907 F 17 506= F 20 877s 1250s FPSEQNUM 00004906 F 17 505= F 20 876s 1057s 1180s 1253 FREEALL 0000347C F 0 300 1552= 1554 1559= F 21 523 F 27 68 81 FREELOOP 0000347F F 0 1564= 1568j FREEMESS 00003A07 F 18 1652a 2033 2100= 2138a FREEPGCNT 00004806 F 0 558 571 1252s 1379s 1496s F 17 194= F 18 84 F 20 1566 F 21 188s 279s 444 451s FREEPRELCT 00004809 F 0 485s 561 574 1413s 1529s F 17 199= F 18 132 F 20 1612 F 21 438 FREESPACE 00004817 F 0 477s 1299 1306s F 17 226= FSNB 00000001 F 18 1695= 1706x 1707x 1709x 1710x 1711x 1712x 1714x 1715x 1716x 1717x 1718x FSNBIT 00003E10 F 18 1607j 1688= 1695e FSTBKUPLEN 000000F0 F 0 250= F 20 511s 664s 959s FUNCCOMMON 0000441E F 29 1284j 1289= GAPERROR 000043B6 F 29 956j 958j 959j 963j 968= GAPFLAG 00178803 F 29 515= 548s 568 607s 622s GAPLEAVE 000043B5 F 29 957j 966= GAPLOOP 000043A9 F 29 949= 962j GAPRTRY 00003E10 F 29 608j 623j 646= GAPSIZE 00178802 F 29 937= 944s 951 GENERAL 0000324E F 0 902j 903j 911= GENMCB 00003434 F 0 1251 1291= 1293 1298= 1310 GETAPAGE 0000349B F 18 49 72= 74 80= 304 331 347 570 719 777 793 1003 1104 1209 1325 1378 GETAPAGEL 0000349C F 18 75 81= 97a *GETAPREL F 18 121= GETAPREL 000034AA F 18 123 128= 146 243 315 369 418 460 490 501 1436 GETAUTHLEN 00003C02 F 20 738j 785= GETENCPARM 000033CF F 0 354 1021= 1023 1028= 1054 GETLOCK 00003D82 F 20 1749= 1772j GETNEWCT 00004230 F 27 406j 418= GETNEWTAPE 00004194 F 27 85= 100j 103j GETNEXPRPQ 00003D81 F 20 128 160 218 318 1740= 1742 1748= 1775 1808 GETNEXR3 00178801 F 20 1745= 1769s 1771 GETPACKPAG 00003D44 F 20 225 480 1064 1517 1552= 1554 1561= 1582 1659 GETPACKPAGL 00003D46 F 20 1555 1563= 1579j GETPARAMS 000031A4 F 0 321 645= 647 656= 835 GETPRPQEND 00003D8B F 20 1756= 1764j GETSHLLEN 00003C0E F 20 743j 822= GETSPACE 00003D37 F 20 1514= 1526j GETSTACK 00003E7F F 21 54 271= 273 275= 297 GETTWQEND 000041C6 F 27 190j 195= GETTWQENT 000041BA F 27 38 48 176= 178 183= 218 GIVEERR 00003499 F 0 1618j 1620j 1630= *GIVEERROR F 18 235= GIVEERROR 000034CF F 18 237 242= 250 837 843 849 930 1025 1129 1197 1268 1349 1404 GIVEHELP 00003246 F 0 732 892= 894 900= 1003 GOBACK 0000428D F 29 198= 204j 209j 214j 219j 224j GOFLAG 0000481D F 0 661s 666s 764s 770 F 17 236= GOOFNAME 000048F2 F 17 422= F 18 450 GOTSEC 00003511 F 18 357= 390j GTPACKPREL 00003D54 F 20 227 1601= 1603 1608= 1629 1663 HAVECODE 00003B2F F 20 378j 380= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 10 HAVELENGTH 00003BF0 F 20 739j 744= HAVEMEMORY 00003404 F 0 1130 1176= 1177 1189= 1271 HAVEOFFL 0000355C F 18 455j 459= HAVEPREL 00003C98 F 20 1058j 1095= HAVESIZE 00003E4A F 21 145j 149= HAVESN 00003884 F 18 1608j 1614= HAVETAPE 00004274 F 29 143j 164= HAVETYPE 00003D2F F 20 1459j 1462j 1464j 1472= HCSMASK FFC00000 F 17 129= F 20 268 HDRPAGE 00178802 F 29 266= 273s 280 HDRPROTO 00000400 F 0 250= 250e 250a HDRTYP0 00000400 F 16 168= 189e 190a HDRTYP1 00000400 F 16 199= 205e 206a HDRTYP2 00000400 F 16 222= 229e 230a HDRTYP3 00000400 F 16 239= 245e 246a HDRTYP4 00000400 F 16 255= 264e 265a HDRTYP5 00000400 F 16 274= 289e 290a HDRTYP6 00000400 F 16 316= 327e 328a HDRTYP7 00000400 F 16 339= 342e 343a HDRTYP8 00000400 F 16 351= 354e 355a HDRTYPWRD1 00160801 F 16 170= 171e 173e F 20 1672s HEADERLOC 00178801 F 20 1654= 1658s 1666 1671 HELP 000031E6 F 0 725a 731= HELPBUG 00003261 F 0 940a 944= HELPCOMFND 00003250 F 0 907j 916= HELPCOMLP 0000324B F 0 905= 908j HELPDONE 0000325D F 0 927j 934= 941j HELPERR 0000325E F 0 925j 938= HELPMSG 000031BF F 0 695a 699= HELPNXTLIN 00003252 F 0 920= 931j HELPWPTR 00003251 F 0 913j 918= HIBLOCK 00178804 F 19 86= 117s 122 183 HICOMMAND 000032D6 F 0 950a 968= HICOUNT 00178802 F 19 84= 98s 121s 156s 165 169 HIDONE 000037A8 F 19 157j 173= HIENC 0000330B F 0 948a 949a 979= HIEXIT 000032E4 F 0 947a 971= HIGENHELP 00003272 F 0 912a 957= HIGO 000032F7 F 0 952a 975= HIHELP 000032B8 F 0 951a 964= HIID 00003368 F 0 954a 990= HIKEY 00003391 F 0 953a 995= HIOT 0000332F F 0 955a 984= INDEX 00178801 F 0 1607= 1613s 1619 1626s INDEX 00178801 F 18 624= 646s 662s INEND 000037D3 F 19 258j 262= INITIALIZE 00003159 F 0 324 463= 465 470= 512 INITPPTF 00003168 F 0 490= 493j INNRLOOP 000037CD F 19 255= 264j INTFUNC 0000441C F 29 319 563 1009 1024 1183 1238 1275= 1276 1287= 1298 INTOLOOP 00003463 F 0 1454j 1460= INTOLOOP 00003481 F 0 1561j 1567= INTWAIT 000042E9 F 29 442= 448j INTWAIT 00004442 F 29 1449= 1454j ITSOK 00003210 F 0 800j 805= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 11 ITSSET 00003AD3 F 20 166j 171= JUSTONE 0000437C F 29 823j 844= JUSTREWIND 00004231 F 27 403j 420= KEEPGOIN 0000372B F 18 1258= 1269j KEEPGOIN 00003E23 F 21 64j 73= KEEPON 00003C0F F 20 824= 832j *KEYHALF 04008C00 F 17 575= KEYINDIC 00008C00 F 17 576= F 21 564s F 23 33 KEYPWDDAT 00008C01 F 17 577= F 21 559s 561s 562s F 23 31 KICKMSG 000031A0 F 0 654= 668a KICKUSER 000031AC F 0 665= 674j 696j 771j 796j 798j 832j KILLFILE 00003C79 F 20 975j 1009= KPONTRUKIN 00003C03 F 20 787= 793j LARGERAF 00003716 F 18 1167a 1175j 1231= LASTELEM 00003D8D F 20 1755j 1761= LASTENCR 00003EB9 F 21 388j 395= LASTPN 0000002B F 0 1196 F 17 487= LASTSYS 00178804 F 0 1185= 1191s 1199s 1249 LENGTH 00178801 F 29 513= 521s 530 571 LENGTH 00178801 F 29 765= 771s 786 817 818 845 *LF 0000000A F 17 390= LINKINENCR 00003DB1 F 20 172 174 272 279 340 347 397 1137 1450 1888= 1890 1895= 1919 *LINKINPRPQ F 18 201= LINKINPRPQ 000034C3 F 18 203 208= 219 245 320 340 344 362 371 420 464 495 585 769 784 800 1010 1113 1219 1337 1392 1442 LINKINTWQ 00003E9F F 21 171 214 239 359= 361 366= 409 LINKTBM 00003575 F 18 493= 504j LINKTBM 00003E70 F 21 206j 213= LISTFBITYP 00178801 F 20 720= 726s 729 735 LISTLEN 00178802 F 20 721= 745s 752 759 LISTR3 00178803 F 20 722= 727s 746 753s 761 LLOCK MACRO F 0 1492 1525 F 17 141= F 18 82 130 211 F 20 1564 1611 1750 1908 F 21 184 276 324 367 373 437 443 479 F 27 185 LOADPMV 00003A8A F 20 40= 46j LOCKWAIT 00000002 F 0 1492 1525 F 17 176= F 18 82 130 211 F 20 1564 1611 1750 1908 F 21 184 276 324 367 373 437 443 479 F 27 185 LOCOUNT 00178803 F 19 85= 97s 146s 175 179 188s 213s LODONE 000037A1 F 19 147j 163= LOGDONE 00004475 F 29 1529j 1545= 1557j LOGERROR 0000444E F 29 308 320 545 564 969 1019 1025 1127 1177 1234 1489= 1491 1497= 1560 LOGFULL 00004477 F 29 1502j 1550= LOGHDRLEN 00000001 F 16 100= 169 200 223 240 256 275 317 340 352 *LOGRECBZY 00080210 F 16 86= LOGRECCWD 00160800 F 16 84= 85e 86e 87e 98e F 20 1329s LOGRECHDR 00000400 F 16 83= 100e 101a LOGRECIFL 00082100 F 16 98= F 20 153s 537s 685s 999s 1089s 1101s 1184s 1295s F 27 265s 344s *LOGRECOSQ 00080010 F 16 85= LOGRECTYP 00081650 F 16 87= F 20 1330s LOGSKIP 00004478 F 29 1500j 1554= LOGTABSIZ 00000007 F 26 25= 29 30 30 31 40 40 171 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 12 LONGFUNC 00004419 F 29 1096 1167 1223 1277 1282= LOOP 0000348E F 0 1616= 1627j LOOP 00003791 F 19 139= 150j 160j LOOP 000037CB F 19 251= 268j LOOPEND 000037AE F 19 170j 182= LOOPTEST 00003D40 F 20 1511j 1524= LOOPTOP 000040E7 F 26 32a 41= MAJHOLE 0000372C F 18 1243j 1262= MAJINDEX 00178801 F 18 1152= 1244s 1259 MAKEOSHDR 00003CFB F 20 474 646 937 1113 1203 1355= 1357 1362= 1372 MAP12LOOP 00003ED1 F 21 450= 458j MAPFBIT 00178802 F 20 1801= 1806s 1814 MAPIN12 00003EBE F 21 233 427= 429 435= 485 MAPINPR 0000345C F 0 301 1443= 1445 1450= F 21 100 230 F 27 52 484 MAPINR5 00178801 F 21 432= 436s 478 MAPLOOP 00003461 F 0 1457= 1462j MAPNEXPRPQ 00003D95 F 20 486 503 519 730 972 1795= 1797 1804= 1832 MARKTBM 000041AC F 27 49j 124= MAXENCRSIZ 00001000 F 16 58= F 21 130 131 MAXMEMRY 000001F4 F 0 1253 F 17 327= MAXPRELS 0000012C F 0 484 1335 1340 F 17 75= *MAXRECTYP 00000008 F 16 97= MC F 0 283= 1640 MCBFBI 00170802 F 17 43= F 18 310a 337a 352a 388a 575a 579a 782a 798a 1008a 1109a 1117 1119 1216a 1331a 1333 1383a F 20 246a 495a 1115a 1205a 1812a MCBLINK 00091F10 F 0 1303s 1381 1384s 1494s 1527s F 17 39= F 18 210s 213s F 20 1753 F 21 186s 280 453 MCBLNTH 00000010 F 0 1305 F 17 34= 44 MCBPLACE 00004C00 F 0 273= 274e 476 1120 MCBPMV 00170801 F 0 1300s 1459 F 17 42= F 18 90 F 20 240 601 1195 1572 1817 F 21 283 456 MCBPTR 00178801 F 20 213= 224s 234 MCBSDONE 00003403 F 0 1131j 1141= MCBTYPE 00090040 F 0 1301s F 17 40= F 18 209s F 20 129 219 1809 MCBWORDA 00170800 F 17 38= 39e 40e 41e 44 MCBWPRT 00090810 F 17 41= F 18 1112s 1218s 1336s F 20 1118 1208 MEMBITS 00178802 F 0 1182= 1236s 1261 MEMDEVICE 00000001 F 0 1125 1134 F 17 337= MEMDOUBLE 00003411 F 0 1204= 1206j MEMMASK 00178801 F 0 1180= 1212s 1241 1257 MEMPFILE 00178803 F 0 1184= 1190s 1192s 1243s 1248 1256s MERGEDONE 000037C5 F 19 209j 220= MESPTR 00178801 F 0 897= 919s 921 929s MESSAGES 00003A22 F 18 2114= 2154a MESSAGETAB 00003A0B F 18 2104= 2111e 2153 MINELEMS 0000000F F 19 30= 36 MINEND 00178803 F 18 1295= 1317s 1323 MININDEX 00178804 F 18 1296= 1320s 1341s MINORSIZE 00178802 F 18 1294= 1306s 1311 1313 MINPCKPREL 00000005 F 0 573 F 17 332= 334e F 20 1610 MINPRELS 00000019 F 0 560 F 17 334= F 18 131 MORETHAN1 0000436F F 29 820j 826= MOVEDONE 00003BFE F 20 760= 767j MOVEDONE 00003EBB F 21 390j 400= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 13 MOVEFDE 00003822 F 18 993 1428= 1430 1435= 1447 MOVEINLIST 00003BE2 F 20 658 672 715= 717 725= 840 953 MOVELOOP 000037DC F 19 303= 311j MOVELPEND 000037E0 F 19 305j 310= MOVENEXT 00003EAC F 21 375= 392j MOVESTUFF 000037D8 F 19 33 293 298= MSMASK 000048C9 F 17 339= F 18 1484 1788 1806 F 19 406 439 470 MSORT 0000377B F 19 40 80 93= MTERRMAX 0000001A F 29 604 675= MTERRPTR 00004345 F 29 605 677= MTERRTAB 00804343 F 29 649= 675e 677a MTU 00130000 F 29 37= 144s 151s 156s 159s 165 171 175s 180s 187s 190 374 437 591 950 1057 1290 1332 1378 1380 *NAME 00000005 F 14 96= NAMEBAD 000035F8 F 18 748j 754= NAMEBADMSG 0000362C F 18 761a 833= NAMEBUF 0200490D F 17 424a 425a 517= NAMEBUFLCH 000048F4 F 17 424= F 20 2124s NAMEBUFPTR 000048F5 F 17 425= F 20 1976s 2071s 2082s 2126a NAMEBUFW 0000490D F 17 516= F 20 2134a *NAMEEXT 00000007 F 14 97= NAMEGOOD 000035FF F 18 751j 764= NAMTAB 000048D8 F 17 409= 419e F 18 474 NEWACCT 00003B3A F 20 330a 408= NEWFILE 00003B23 F 20 325a 359= NEXTBLOCK 00003430 F 0 1244j 1260= NEXTBUKT 000035B4 F 18 633= 670j NEXTBYTE 000033EC F 0 1087= 1093j NEXTCOMM 000031F8 F 0 733j 738j 746j 753j 760j 767= NEXTCYL 00178803 F 19 389= 399s 403 457s NEXTDIR2 00003647 F 18 864= 922j NEXTEND 00003751 F 18 1340= 1350j NEXTENT 000035BF F 18 647= 664j NEXTENTRY 00003B0E F 20 317= 361j 393j 402j 410j 418j NEXTFDE 00003622 F 18 814= 826j NEXTFDEX 00003661 F 18 902= 914j 945j NEXTFILE 00003567 F 18 473= 486j NEXTMAJB 0000371D F 18 1241= 1263j NEXTMEM 000033FA F 0 1126= 1138j NEXTMINE 00003741 F 18 1322= 1342j NEXTSAF 000036DE F 18 1103= 1120j NEXTSEC 0000381A F 19 433j 462= NEXTWORD 00003AFC F 20 260= 262j NINETRACK 00004333 F 29 593j 602= NOBOOTINFO 00003A98 F 20 61j 63= NOCHEKEXT 0000369E F 18 985j 990= NOCODE 00003C70 F 20 968j 993= NOCONTERR 0000433A F 29 590j 612= NOCURPREL 00003D21 F 20 1413j 1453= NODATA 000034E0 F 18 274j 276= NOENCRYPT 00003E56 F 21 110j 170= NOENTRIES 000041D0 F 27 187j 212= *NOFORM 00000000 F 17 508= NOFOUND 00003E9D F 21 328j 333= NOFSN 00003889 F 18 1607j 1622= NOGO 00003211 F 0 721a 807= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 14 NOGO 00003EDE F 21 445j 473= NOGODISK 000030D0 F 0 344j 421= NOGODISKM 000030DC F 0 425a 436= NOGOTAPE 00003055 F 0 329j 385= NOGOTAPEM 00003061 F 0 389a 400= NOHOLE 0000359D F 18 563j 567= NOHOLE1 0000359E F 18 569= 590j NOLIST 00003C00 F 20 733j 765= NOOFF 00003579 F 18 457j 500= NOORDER 000036B7 F 18 983j 988j 1030= NOPAGES 00003D51 F 20 1567j 1576= NOPAGES 00003E90 F 21 278j 292= NOPPUERR 0000444D F 29 1461j 1464= NOPRELS 00003D61 F 20 1613j 1623= NOPROB 0000435F F 29 789j 800j 803= NOREGENSYS 0000342D F 0 1250j 1255= NORMALBYE 0000430B F 29 535= 614j NORMALENC 00003E2B F 21 83a 84a 99= NORMFORM 00000001 F 17 509= F 20 371 539 1441 1456 NORMR4 00178801 F 20 1173= 1177s 1193 NOSHARE 00003C5B F 20 950j 963= NOSHL 000036AF F 18 999j 1013= 1026j NOSTACK 00003E66 F 21 55j 190= NOTBOOTMEM 0000340F F 0 1195j 1201= NOTFAST 00003DB9 F 20 1898j 1906= NOTFIRST 00003EBC F 21 371j 404= NOTFREE 00003A73 F 18 2137j 2144= NOTLAST 0000437B F 29 838j 841= NOTREADY 00004296 F 29 195j 222= NOTSCSIDSK 0000373C F 18 1309j 1315= NOTUDIR1 0000384F F 18 1519j 1531= NOTVT 00004284 F 29 179j 184= NUMBERWORD 00160804 F 16 320= 321e 322e F 20 1252s NUMBPAGES 00080084 F 16 321= F 20 1099s 1182s NUMBYTES 00178801 F 0 1077= 1084s 1092s NUMCHUNKS 00178802 F 21 48= 132s 136 161s NUMELEM 00178801 F 19 27= 35s 44 NUMELEM 00178808 F 19 90= 94s 208 214 221 NUMMCBPAG 00000008 F 0 274e 1121 F 17 35= NUMPRELPAG 00000008 F 0 275e F 17 76= NXTINDX 0000356E F 18 483= 512j NXTPAG 0000359A F 18 561= 564j *ODBADNAME 00000001 F 14 41= *ODBADPL 00000004 F 14 44= *ODBADSB 00000006 F 14 46= *ODBADVL 00000005 F 14 45= *ODISYR 0000000B F 14 51= *ODNOTDISK 00000002 F 14 42= *ODOFFLINE 00000003 F 14 43= *ODOOPS 00000008 F 14 48= *ODPFM 0000000A F 14 50= *ODSUBBIG 00000007 F 14 47= *ODVIU 00000009 F 14 49= OKEXIT 00003707 F 18 1170j 1192= 1198j 1221j 1264j OLDDATE 000048D5 F 17 399= F 18 1856 ONCEAGAIN 000034AB F 18 129= 143a 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 15 ONCEAGAIN 00003D55 F 20 1609= 1626j ONEBUF 000042A4 F 29 281j 286= ONLYONE 0000381D F 19 395j 468= OPENERRTAB 000030E8 F 0 428a 438= OPENTAPE 00004261 F 0 328 F 29 41 134= 135 142= *OPHSREQCNT 00160801 F 16 50= OPLVECTPC! 00000400 F 13 10= 54a OPTKEY 0000481A F 0 658s 744s 745s 1043 1044s F 17 233= F 21 156 ORDEND 00003820 F 19 432j 474= ORDERCYL 000037EF F 18 1312 F 19 384 393= ORDLOOP 000037F6 F 19 402= 459j OSHDRPTR 00178802 F 20 870= 933s 955 984 *OSINFO 00160801 F 16 139= OSINFOSIZ 00160800 F 16 138= F 20 469s 642s 661s 675s 932s 956s 985s 1086s 1103s 1189s OSRECPTR 00178802 F 20 447= 473s 508 524 OSRECPTR 00178801 F 20 587= 640s 660 674 OUTLOOP 00003787 F 19 113= 189j OVERVERS 0000300F F 0 306j 312= P6CHARS 00003DD0 F 20 1949= 1975 P6TAB 00003DC6 F 20 1948= 1949a PACKACCT 00003B98 F 20 409 582= 584 592= 692 PACKACCTSN 0000490B F 17 514= F 20 613s 891 1248 PACKBOOT 00003AD8 F 20 62 208= 210 216= 283 PACKDEATH 00003B85 F 20 489j 506j 522j 544= PACKDEFEND 0000497D F 17 532= 581a PACKERROR 00003CEA F 20 417 1011 1278= 1280 1285= 1300 PACKFASTBL 00003C7C F 20 401 1048= 1050 1056= 1144 PACKFILE 00003C18 F 20 360 864= 866 875= 1015 PACKINIT 00003A92 F 0 497a F 20 7 55= PACKLOCK 00004801 F 0 568s 579s F 17 186= PACKLOGREC 00003CF7 F 20 8 107 457 608 887 1246 1292 1321= 1323 1328= F 27 262 341 PACKMINPAG 00004819 F 0 482s 570 F 17 229= F 20 1565 F 21 212s PACKN 000048CD F 0 797 F 17 345= PACKNO 000048CC F 0 795 F 17 344= PACKNORMBL 00003CBA F 20 392 1168= 1170 1176= 1220 PACKOK 000048D0 F 17 348= F 27 440 PACKPC 00004900 F 0 498s F 17 499= F 20 51 1853s PACKPMVTAB 0000492F F 0 491s F 17 525= F 20 41 1862s PACKPMVTABL 0000000E F 0 487 491s F 17 524= 525 F 20 38 41 1858 1862s PACKPRPAGE 00009400 F 17 538= F 20 100a 147a 149a 158a 453a 1455a 1468a PACKPRPN 000000A5 F 17 544= F 20 1660 1661 PACKR4R5 00004903 F 17 501= F 20 50 1855s PACKSEQNUM 00004905 F 17 503= F 20 57s 101s 1711s PACKSPR7 00004901 F 17 500= F 20 49 1854s PACKSTACK 0000497D F 17 530= F 20 56a PACKSTART 00003A88 F 0 575j F 20 6 37= PACKVOL 00003B0B F 20 64 305= 307 312= 421 PACKVOLEND 00003B1B F 20 328a 338= PACKVOLERR 00003B22 F 20 324a 327a 329a 333a 352= PACKWNDO1 00008C00 F 17 536= F 20 493a 512a 528a 611 619 634 635 651a 654 668 977a 1197a PACKWNDO2 00009000 F 17 537= F 20 750a 788 825 1082a PACKY 000048CF F 0 801 F 17 347= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 16 PACKYES 000048CE F 0 799 F 17 346= PAGADR 00178801 F 29 409= 413s 432 PAGEERROR 00178806 F 18 1475= 1640s 1642 1646 PAGEIN 0000382C F 18 306 333 348 384 550 571 637 734 778 794 880 1004 1105 1179 1212 1232 1247 1327 1379 1466= 1468 1478= 1739 PAGEINBL 00178802 F 18 1472= 1481s 1491 PAGEINR34 00178804 F 18 1474= 1483s 1632 PAGEMASK 000003FF F 17 394= F 20 243 1509 1716 PAGENUM 00178801 F 20 1558= 1562s 1571 PAGENUM 00178801 F 20 1800= 1805s 1816 PAGEQ 00004804 F 0 1302 1304s 1380 1382s 1493 1495s F 17 192= F 21 185 187s 277 281s 452 454s PAGEQLOCK 00004805 F 0 1383s 1492s 1497s F 17 193= F 18 82s 95s F 20 1564s 1577s F 21 184s 189s 276s 293s 443s 460s 474s PAGERETURN 00003466 F 0 298 1484= 1486 1491= 1566 F 18 842 848 1024 1128 F 20 499 515 530 688 758 990 1216 PAK6O10 00003DDC F 20 1969= 1978j PAK6OEXIT 00003DE5 F 20 1974j 1981= PAK6R3 00178801 F 20 1960= 1966s 1982 *PAK6TOCHAR F 20 1944= PAK6TOCHAR 00003DD7 F 20 1946 1963= 1986 2019 2023 2074 2078 2085 PAKCODE 00004885 F 17 317= F 18 468 PARMERROR 000031BC F 0 684j 693= 743j 751j 758j PASSEND 000037B5 F 19 116j 196= PASSEND1 000037BB F 19 186j 205= PASSLOOP 00003783 F 19 105= 217j PASSSIZE 00178801 F 19 83= 96s 120 184 187 206 212s PASTVOLEND 00003890 F 18 1488j 1636= PBENCRANDM F 23 4= 90 PFCLNMASK 000048C8 F 0 1197 F 17 338= PHSCKSUM 00160804 F 16 62= F 26 28s 177s PHSDSEQNUM 00160803 F 16 60= 70e F 20 1713s F 27 252s 331s 490s *PHSEHDRSIZ 00000004 F 16 70= PHSENCSTRT 00160803 F 16 59= F 21 124a PHSFILEDO 00080212 F 16 54= F 20 1136s F 27 255s 334s PHSFILLER 00160806 F 16 68= F 27 256a 335a PHSFILLSIZ 00000001 F 16 67= 68 F 27 257 336 PHSFLAGWRD 00160802 F 16 52= 53e 54e PHSHDRLEN 00000007 F 16 73= F 17 546e F 20 152 1084 1090 1098 1669 1708 F 27 261 276 283 340 353 360 492s PHSLOGDATA 00160807 F 16 71= F 20 151a 158a F 27 45s PHSNCRYPTD 00080012 F 16 53= F 20 150s 1077s 1469s 1714s F 27 253s 332s PHSNOESIZE 00000003 F 16 56= F 21 128 PHSRECHDR 00000400 F 16 48= 73e 74a PHSREQCNT 00160805 F 16 64= F 27 254s 333s PHSSEQNUM 00160800 F 16 49= 56e F 20 1712s F 21 122 F 27 62 251s 330s 489s PHYSHDR 00003D75 F 20 1667 1698= 1700 1705= 1721 PHYSRECPCK F 20 4= 2141 PHYSRECSIZ 0000483B F 0 338s F 17 254= F 20 118 386 1127 1421 PHYSRECSIZ9 000048D1 F 0 331 F 17 383= PHYSRECSIZC 000048D3 F 0 336 F 17 387= PHYSRECSIZV 000048D2 F 0 334 F 17 385= PHYSRECSZ 00160806 F 16 180= F 20 119s PKPNWNDO1 000000A3 F 17 542= 543e F 20 487 504 520 599 973 1194 PKPNWNDO2 000000A4 F 17 543= 544e F 20 731 756 1065 1133 1434 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 17 PLACE 00178801 F 18 540= 568s 588s PMINPAGES 00000002 F 0 481 F 17 329= PPUIWAIT 00004440 F 29 42 377 954 1114 1293 1335 1441= 1442 1447= PPUMASK 00006540 F 29 109= 453 613 864 1459 PPUSOKAY 000042F5 F 29 455j 458= PPUSTATUS 00178801 F 29 1494= 1498s 1515 1546 PRELANDPAG 00003D64 F 20 99 452 1062 1454 1649= 1651 1657= 1676 PRELBUSY 0008C810 F 17 83= F 20 346s F 21 331s 369s 480s PRELDONE 0008CA10 F 17 84= F 20 345s F 21 368s 389 PRELENCRY 0008CC20 F 17 85= F 20 103s 106s 229s 381 455s 1080s 1416 1473s F 21 76 108 PRELFDE 0016C801 F 17 87= F 18 1439a F 20 896a 942a 948a 965a PRELFLAGS 0008C820 F 17 82= F 21 327 PRELLINK 0008DF10 F 0 1344s 1415 F 17 80= F 20 1907s 1910s F 21 376 381s 383s F 27 188 PRELLNTH 00000019 F 0 1335 1343 F 17 74= 99 PRELLOOP 00003445 F 0 1341= 1346j PRELMCBCNT 0008C041 F 0 1452 1560 F 17 95= F 20 237s 482 483s 1106 1107s 1431 1432s 1519 1520s 1665s 1901 1902s F 21 447s PRELMCBPTR 0016C803 F 0 1458 1565 F 17 98= F 20 233s 235s 484s 1108s 1433s 1521s 1664s 1903s F 21 455s PRELPLACE 00006C00 F 0 274= 275e 1334 1338 PRELPRINX 0016C802 F 17 97= F 20 244s 1717s F 21 103 120 F 27 56 PRELPRLEN 0008E101 F 17 96= F 20 148s 231s 387 538s 686s 1000s 1091s 1104s 1128 1185s 1422 1670s F 21 105 127 F 27 58 494 502 PRELQ 00004807 F 0 1339s 1414 1416s 1526 1528s F 17 196= PRELQLOCK 00004808 F 0 1417s 1525s 1530s F 17 198= F 18 130s 141s F 20 1611s 1624s F 21 437s 469s PRELRETURN 00003471 F 0 299 1517= 1519 1524= 1571 F 20 144 1004 1287 F 21 475 F 27 128 PRELTBM 0016C801 F 17 90= F 18 462s 492s 503s F 20 164 277 F 21 204 F 27 125 PRELTYPE 0008C040 F 17 81= F 20 161 319 1618s F 21 201 F 27 198 PRELVOLNAM 0016C801 F 17 88= F 18 318s F 20 136 PRELWORDA 0016C800 F 0 1348s 1418s F 17 79= 80e 81e 82e 83e 84e 85e 99 PRELWORDB 0016C801 F 17 86= 87e 88e 90e 95e 96e PREVBLOCK 0000486A F 17 291= F 18 1097s 1118s 1562 2166a PRJB 00000002 F 18 1693= 1706x 1707x 1709x 1710x 1711x 1712x 1714x 1715x 1716x 1717x 1718x PRNTABLE 00009800 F 17 557= F 22 76s 162 PRNTABPN 000000A6 F 17 560= F 21 449 510 PROCPAGE 00008C00 F 0 275= 277e F 17 459a 534a 546e 551e 574a 591a 614a PROCPARMS 000031B7 F 0 663j 683= 769j PROCPN 000000A3 F 0 277= 489 541 F 17 542e 558e 597e 616e F 18 176 265 F 20 39 1859 PROGB 00009400 F 0 1046a F 17 556= F 20 261 *PROGBC 02009400 F 17 555= PROGPLACE 00003000 F 0 271= 272e 303a PROJBIT 00003C10 F 18 1589j 1687= 1693e PROJIN 0000387A F 18 1589j 1597= PRPQHEAD 0000480A F 0 502a 607 F 17 201= F 20 1751 1754s 1762a PRPQLOCK 0000480C F 17 203= F 18 211s 215s F 20 1750s 1757s 1768s PRPQTAIL 0000480B F 0 503s F 17 202= F 18 212 214s F 20 1763s PUTINR1 0000379A F 19 141j 153= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 18 QUITMESS 00003B88 F 20 546a 550= QUITRATIO 00000009 F 17 585= F 21 63 R3SAVE 00178803 F 29 267= 274s 301 R3SAVE 00178801 F 29 1324= 1328s 1339 RAFCHECK 000038C0 F 18 1772j 1774j 1785= RAFJTAB 000036F7 F 18 1160 1163= RANDINIT 00003F28 F 22 71 F 23 6 23= 25 30= RANDOM 00003F2F F 22 75 F 23 7 34 35 70= 72 77= RDDATAPMV 000048FF F 17 485= F 18 173s 273 275 RDDATAPN 000000AB F 17 470= F 18 89 172 RDIDXLOC 00009000 F 17 462= 477x F 18 640a 645a 663a RDLOADPMV 000034D8 F 18 266= 271j RDMAJLOC 0000A000 F 17 466= 481x F 18 1235a 1242 RDMERGELOC 0000A800 F 17 468= 483x 487e F 19 58a 100a RDMINLOC 00009C00 F 17 465= 480x F 18 553a 562 573 589 1182a 1210s 1250a 1334 1382a 1388a 1787 1805 F 19 299a RDSECLOC 00008C00 F 17 461= 476x F 18 351a 358a 387a 634 669 RDSORTLOC 0000A400 F 17 467= 482x F 19 57a 101a 256 257 259s 260s 306s RDUDIR1LOC 00009400 F 17 463= 478x F 18 737a 747 750 757a 758a 765a 773 789 808a 815a 865a 1520 RDUDIR2LOC 00009800 F 17 464= 479x F 18 883a 893a 903a READACCT 00004872 F 17 299= F 18 723s 1583 2162a *READACCTPW 00004875 F 17 301= READACNT 000035DC F 18 655 702= 704 716= 951 READASN 00004866 F 17 289= F 18 1521s 1610 READCODE 00003756 F 18 1059 1367= 1369 1374= 1408 READDATA 0000AC00 F 17 471= F 18 309a 316 323 325 336a 360a 574a 767a 781a 797a 1007a 1108a 1215a 1330a 1390a READDEATH 0000354F F 18 367j 396j 412j 417= READDISK F 18 47= 2174 READDONE 00004803 F 0 605 F 17 189= F 18 378s READERROR 00003891 F 18 1501a 1511j 1639= READERROR 00003B3C F 20 331a 416= READEXIT 000042A9 F 29 296j 298= 311j 313j 315j READEXT 00004879 F 17 303= F 18 469s 807s 987 991s 1032s 1040a 2165a READFBI 00004851 F 17 274= F 18 554a 641a 738a 759a 760a 884a 1183a 1236a 1251a READFILE 00003691 F 18 819 907 967= 969 974= 1075 *READFILEPW 0000487A F 17 304= READIDX 000035B1 F 18 366 619= 621 628= 685 READINIT 000034E3 F 0 495a F 18 50 296= READKEY 0000487D F 17 308= F 18 478s 582s READLOCK 00004800 F 0 553s 566s F 17 185= F 21 69 READMINOR 00003730 F 18 1187 1255 1288= 1290 1301= 1353 1395 READMINPAG 00004818 F 0 480s 557 F 17 228= F 18 83 F 21 211s READNAME 00004877 F 17 302= F 18 476s 580 806s 981 982s 1039a 2164a READNVM 000033E7 F 0 1035 1039 1072= 1074 1082= 1098 READOK 0000388D F 18 1516j 1619j 1629= READPC 0000484F F 0 496s F 17 270= F 18 168s 279 READPMV 000048F7 F 17 475= 484e F 18 267 READPMVL 00000008 F 17 484= F 18 175 264 267 READPROJ 00004874 F 17 300= F 18 725s 1600 2163a READR2 0000484C F 17 268= F 18 170s 278 READRAF 000036F1 F 18 1058 1147= 1149 1155= 1272 READSAF 000036D9 F 18 1057 1089= 1091 1096= 1133 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 19 READSERIAL 00004868 F 17 290= F 18 997s 1611s 1617 READSPR7 0000484D F 17 269= F 18 169s 277 READSTACK 000048C8 F 17 321= F 18 297a READSTART 000034D5 F 0 562j F 18 51 262= *READSYS 0000486F F 17 297= *READSYSPW 00004870 F 17 298= READTAPE 00004298 F 29 43 261= 262 270= READVOL 0000486D F 17 296= F 18 317s REALBAD 00004325 F 29 553j 557j 559j 574j 578= 599j 609j 624j RECADDR 00178802 F 29 514= 522s 531 RECORDNUM 0000447E F 29 271s 520s 1513 1564= RELBLKCHEK 000038B6 F 18 1567 1759= 1761 1770= 1823 RELBLKEND 000038BF F 18 1781= 1793j 1812j 1820j RELBLKR12 00178801 F 18 1764= 1797s 1816 RELBLOCK 00004861 F 17 284= F 18 305s 332s 636s 727s 873s 1002s 1098s 1111s 1158s 1246s 1376s 1779 1792 1818 RELOOP 000040E6 F 26 39= 172j RETERROR 0000369F F 18 992= 1043j RETRY 000041BB F 27 184= 215j RETRY 00004316 F 29 551j 552j 555= 588j 598j 606j 608j 621j 623j RETRY 00004400 F 29 1181j 1188= RETRYCOUNT 0000447D F 29 314s 556s 1021s 1132s 1189s 1240s 1385s 1563= RETRYLOOP 0000429E F 29 277= 316j 322j RETRYLOOP 00004304 F 29 525= 569j 575j RETRYLOOP 000043BB F 29 1007= 1030j RETRYLOOP 000043F0 F 29 1165= 1190j RETRYLOOP 00004406 F 29 1221= 1241j RETURN 00003432 F 0 1216j 1223j 1265= RETURN 0000349A F 0 1621j 1634= RETURN0 0000430D F 29 539= 581j RETURN0 0000438E F 29 870= 873j RETURNERR 00004326 F 29 580= 587j REVHIGH 41393130 F 0 309x F 3 77= REVLOW 38202020 F 0 309x F 3 78= REWERR 000043E5 F 29 1097j 1098j 1117j 1118j 1126= REWEXIT 000043E3 F 29 1121= 1131j 1135j REWIND 000043D5 F 0 368 F 27 421 F 29 44 1064 1086= 1087 1092= REWOK 000043E2 F 29 1109j 1119= 1129j REWRETRY 000043D7 F 29 1094= 1133j RMINPAGES 0000000A F 0 479 F 17 328= ROLLCOUNT 00004385 F 29 858= 885j ROLLOVER 000042F6 F 29 447j 462= ROLLOVER 00004393 F 29 857j 883= ROLLWAIT 00004381 F 29 852= 859j RPTERROR 00003A64 F 18 1033 1641 1798 1879 1936 1997 2030= 2031 2124= 2172 RTNPREL 0000418C F 27 67= 127j RTYPEACC 00000004 F 16 92= F 20 609 RTYPEERR 00000007 F 16 95= F 20 1293 RTYPEESET 00000001 F 16 89= F 27 342 RTYPEFIL 00000005 F 16 93= F 20 888 *RTYPEFLR 00000008 F 16 96= RTYPEFP 00000006 F 16 94= F 20 1247 RTYPESET 00000000 F 16 88= F 20 108 RTYPESWCH 00000002 F 16 90= F 27 263 RTYPEVOL 00000003 F 16 91= F 20 458 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 20 RUNRECPTR 00178803 F 20 448= 476s 491 498s 509 514s 525 SAFDONE 000036ED F 18 1123= 1130j SAVEPACKST 00003DA7 F 20 1578j 1625j 1770j 1848= 1850 1852= 1870 SAVESETFIL 0016080B F 16 186= F 20 124a SAVESTATE 000034B7 F 18 96j 142j 162= 164 166= 186 SAVEWRITST 000041B7 F 27 150= 214j SAVSETFMT 00082101 F 16 173= F 20 113s SAVSETNAME 00160810 F 16 187= F 20 135a SAYGO 000031F7 F 0 726a 763= SCHEDULER 00003178 F 0 290 361a 524= 526 540= SEC2BAD 00003542 F 18 389j 409= SEC2DA 00004863 F 17 286= F 18 326s 386a SECBAD 00003521 F 18 353j 383= SECBADM 00003545 F 18 411a 415= SECDA 00004862 F 17 285= F 18 324s 350a SECPCYL 0000485D F 0 352s F 17 277= F 19 407 409 SECPTR 000048D4 F 17 397= F 19 451 463s SECPTRAK 0000485C F 0 349s F 17 276= F 19 352 411 447 449 SECTBITS 00000040 F 19 335= 354s 424 SECTLEND 00003807 F 19 421j 426= SECTLOOP 00003801 F 19 419= 427j 452j SECTMOD 00003810 F 19 445= 453j 465j SECTORS 00404860 F 17 282= 397a SECTORSW 00004860 F 17 281= F 19 415s SEFB 00004404 F 29 46 1213= 1214 1219= SEFBBAD 00004415 F 29 1236j 1239j 1242= SEFBERR 0000440D F 29 1224j 1226j 1233= SEFBEXIT 00004418 F 29 1244j 1247= SEFBOK 0000440B F 29 1225j 1228= 1248j SEFF 000043EE F 29 45 1157= 1158 1163= SEFFERR 000043F7 F 29 1168j 1169j 1176= SEFFEXIT 000043F5 F 29 1171= 1180j 1186j 1193j SENDMESS 000038A2 F 18 1654j 1662= SENDPREL 00003B37 F 20 382j 389j 396= SENDPREL 00003D20 F 20 1417j 1424j 1449= SEQNUM 00178801 F 21 47= 123s 152 SETENCR 00003C8D F 20 1074j 1079= SETFLAG 000031E8 F 0 722a 723a 736= SETID 000031EF F 0 728a 749= SETKEY 000031EA F 0 727a 741= SETOT 000031F3 F 0 729a 756= SETRETRY 0000443A F 29 1382j 1384= SETTAPE 000043CE F 27 36 408 445 F 29 47 1050= 1051 1056= SETTAPNUM 00160802 F 16 177= F 20 111s F 27 492s SETTIME 0000446B F 29 1526j 1532= SETTIMSTP 00160803 F 16 178= F 20 117s SETUPBLOCK 0000341E F 0 1217j 1228= SETUPENCR 00003EF3 F 21 235 549= 551 556= 568 SETUPNMAP 0000442E F 29 276 523 1005 1093 1164 1220 1330 1365= 1367 1372= SHARELIST 00003BEF F 20 737j 742= SHLTAB 00003C0A F 20 816= 830 SKIPEQUAL 0000323A F 0 742 750 757 854= 856 861= 876 SMALLRAF 000036FE F 18 1166a 1178= SNDBKUPLEN 00001F10 F 0 250= F 20 527s 678s 988s SORT 0000376D F 18 1305 F 19 24 32= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 21 SORTEND 00003773 F 19 43= 59j SPACENEED 00178801 F 20 1501= 1507s 1525 SPINADDR 00004816 F 0 360s 615 F 17 224= SSENCRFN 00000001 F 16 172= F 20 114 SSFILLEN 00000005 F 16 185= 186 F 20 125 SSOWNER 00160809 F 16 184= F 20 110s SSSSN 00160808 F 16 183= F 20 122s SSTAPEFN 00000006 F 16 176= F 20 112 *SSTAPEFN5 00000005 F 16 174= *SSTAPEFN6 00000006 F 16 175= STARTTIME 00004822 F 0 1030s F 17 243= 341a F 20 116 F 21 157 F 27 269 346 STILLMORE 000043A0 F 29 897j 900= STOPINST 0000341D F 0 1221 1226= STORERSIZ 00003023 F 0 333j 335j 337= SVERECLEN 00000007 F 16 205= F 27 343 353 360 *SVSRECLEN 00000010 F 16 189= SWITCHDONE 00004225 F 27 410= 448j SWITCHTAPE 0000421E F 27 86 393= 395 401= 451 *SYSACCT 00000000 F 14 93= *SYSPROJ 00000002 F 14 94= SYSPWD 00004825 F 0 1042s F 17 246= F 21 560 SYSSN 00004824 F 0 1038s F 17 245= F 20 121 TABINDX 00178801 F 18 446= 471s 484s TABLEINDEX 00008C03 F 17 579= F 22 36s 161s TABMAX 00000009 F 17 419= F 18 485 TALON F 29 39= 1566 TALPH 00003C10 F 0 684j 870j 903j F 13 48= TAP000 00004260 F 29 140= 145 TAPEBOOTMA 00003553 F 18 329 441= 443 449= 517 TAPECB 0000483C F 0 326a 367a F 17 256= F 27 35a 60a 82a 129a 280a 323a 357a 500a TAPECTLBLK 00000400 F 15 14= 26e 27a TAPEEND 0000430C F 29 533j 537= TAPEENDERR 00004197 F 27 84j 91= TAPEENDREC 000041D3 F 27 83 237= 239 244= 296 TAPEERRMAX 00000014 F 29 110= 945 1383 TAPEERROR 0000418E F 27 65j 72= TAPEFUNC 00004423 F 29 48 1061 1320= 1321 1327= TAPENAME 0000481E F 0 327 388a 395a 660s 759s 783a F 17 238= TAPENDFIL 00160804 F 16 227= F 27 271a *TAPENDHDR 00160800 F 16 223= TAPENDNUM 00160801 F 16 224= F 27 268s TAPENDTIME 00160802 F 16 225= F 27 270s TAPENUM 00004991 F 17 606= F 27 34s 98s 267 422s 427a 491 TAPEQCNT 00004813 F 17 212= F 21 61 385s F 27 196s TAPEQHEAD 00004811 F 0 506a F 17 210= F 27 186 189s 192a TAPEQLOCK 00004814 F 17 213= F 21 373s 401s 479s 481s F 27 185s 197s 213s TAPEQTAIL 00004812 F 0 507s F 17 211= F 21 382 384s F 27 193s TAPERRTAB 0000306D F 0 392a 402= TAPEWRITE 0000416E F 0 587j F 27 23 26= TAPEWRITER F 27 21= 522 TAPHDR1000 00000400 F 16 137= 141e 142a TAPHDR1000L 00000001 F 16 141= F 17 436e 442e 446e 546e F 20 470 643 662 676 936 957 986 1088 1090 1190 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 22 *TAPSTRCHS 00160000 F 16 123= TAPSTRDEF 00000400 F 16 122= 125a *TBLNK 00003610 F 13 51= TBMBEGIN 00000001 F 17 92= F 18 461 TBMDATE 00168803 F 17 122= F 20 253s F 21 558 TBMDCS 00168809 F 17 125= F 20 266s TBMENCRYPT 00003E73 F 21 82a 228= TBMEND 00000002 F 17 93= F 18 491 F 21 205 TBMFBIPOS 000093F5 F 17 551= 552a F 20 241 242 F 21 557 TBMFIL1 00168805 F 17 123= F 20 254s TBMFIL2 00168807 F 17 124= F 20 255s TBMHCS 0016880A F 17 126= F 20 271s TBMIND 00168802 F 17 121= F 18 583s F 20 249 250s F 21 563 TBMMARKER 00003E67 F 21 81a 199= TBMMARKER 000041CF F 27 202j 208= TBMNAME 00168800 F 17 120= F 18 581s F 20 247 248s TBMNONE 00000000 F 17 91= F 18 502 F 20 165 F 27 126 TBMPN1 000000A4 F 17 558= 559e 560e F 20 226 F 21 231 517 TBMPN2 000000A5 F 17 559= F 20 239 TBMRECSIZ 0000040B F 17 448= F 20 230 *TDELM 00003A10 F 13 49= TEMPR4 00178801 F 27 398= 424s 444 TEOL 00003810 F 0 663j 769j 902j F 13 50= TEOV 00000004 F 17 29= F 18 372 F 27 199 *TERR 00000000 F 13 52= TERRBCN 00000002 F 15 36= F 29 208 TERRBSN 00000003 F 15 37= F 29 213 TERRBUN 00000001 F 15 35= F 29 203 *TERRDCS 0000000B F 15 45= TERRDNR 00000006 F 15 40= F 29 223 310 1130 1179 1243 TERRDNT 00000004 F 15 38= F 29 218 TERREOF 00000008 F 15 42= F 29 297 *TERRFNF 00000009 F 15 43= *TERRHCS 0000000A F 15 44= TERRITE 00000007 F 15 41= F 29 312 579 1134 1185 1192 1245 *TERRNBT 0000000D F 15 47= *TERRNOL 00000005 F 15 39= TERROR 00000007 F 17 32= F 18 246 F 20 1825 TERRWPRT 0000000C F 15 46= F 29 586 TFDE 00000001 F 17 26= F 18 1443 THISCYL 00178804 F 19 390= 404s 446 THISPLACE 000035C4 F 18 650j 653= TINYRAF 0000370A F 18 1165a 1208= TITLELINE 00003004 F 0 310= 319a TMCB 00000002 F 0 1229 F 17 27= F 18 341 345 363 586 785 801 1011 1114 1220 1338 1393 F 20 1810 *TNUM 00003E10 F 13 47= TOOFEWPAG 000034A7 F 18 85j 94= TOOFEWPREL 000034B4 F 18 133j 140= TPBTPAGES 00000018 F 0 479 481 F 17 331= F 21 210 *TPCBDENSE 00160803 F 15 20= TPCBLEN 00000008 F 15 26= F 17 256 TPCBPFILE 00160800 F 15 15= F 29 144s 156s 159s 165 171 1378 TPCBTRACK 00160802 F 0 332 F 15 17= F 27 99 102s 402 404s 419s F 29 175s 180s 187s 591 1057 1380 TPCBUNIT 00160801 F 15 16= F 29 151s 190 374 437 846 950 1290 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 23 1332 TPENDFILLN 00000004 F 16 226= 227 F 27 272 TPERECLEN 00000008 F 16 229= F 27 264 276 283 TPHDRLOC 000093F5 F 17 554= F 20 269 TPREL 00000000 F 17 25= F 20 1617 TRAKOK 000043D3 F 29 1058j 1063= TRASHPOINT 00000400 F 17 4= 130a TRYCOUNT 00178801 F 29 936= 946s 961s TS 00000000 F 16 119= 187 243 262 287 TSBUILD F 20 1923= 2140 TSINDX 00178804 F 20 2061= 2065s 2069 TSMOVE 00003E0B F 20 140 464 637 927 1927 2115= 2117 2122= TSNAME 00003DF3 F 20 632 923 1926 2054= 2056 2064= TSP12NAME 00178801 F 20 2059= 2066s 2073 2077 TSP6NAME 00178803 F 20 2060= 2067s 2084 TSVOL 00003DE7 F 20 137 1925 2007= 2009 2015= TSVOLNAME 00178801 F 20 2012= 2016s 2018 2022 TTBM 00000003 F 17 28= F 18 465 496 F 20 162 220 F 21 200 F 27 201 TUDIR 00000006 F 17 31= F 18 770 TVOLNAM 00000005 F 17 30= F 18 321 F 20 130 TYPEFBI 00178801 F 18 1293= 1302s 1326 TYPEJTAB 00003B12 F 20 321 324= 332e TYPEJTABL 00000008 F 20 320 332= TYPELAST 00000010 F 18 1016 1072= TYPETAB 000036C8 F 18 1017 1055= 1072e TYPETAB 000038B1 F 18 1532 1550 1570 1588 1605 1719= TYPETABLE 020038AB F 18 1697= 1719a UDIR1EXT 00178806 F 18 711= 870s 898 942a UDIR1NAME 00178804 F 18 710= 868s 895 941a UDIRBLOCK 0000486C F 17 293= F 18 730s 877s 937a 1035 UDIRKEEPL 00000060 F 17 395= 436e F 18 766 F 20 641 650 UDIRTYPE 0000486B F 17 292= F 18 732s 875s 1036 *UNITSTAT01 0000428A F 29 193= UNITSTATUS 00004287 F 29 177j 181j 188= UNLINKPAGE 0000344C F 0 287 1371= 1373 1378= F 18 88 F 20 1570 UNLINKPREL 00003454 F 0 288 1405= 1407 1412= F 18 136 F 20 1616 F 21 440 UNLOADPMV 00003DAC F 20 1860= 1864j UNMAP 0000443C F 29 300 540 1014 1122 1172 1229 1338 1403= 1404 1409= 1415 UNMAP12 00003EE8 F 21 237 502= 504 509= 527 UNMAPLOOP 000034BF F 18 177= 180j UNMAPLOOP 00003EEB F 21 512= 514j UNSUBS5 00003F0E F 22 37 39 41 87 100= UNSUBSLOOP 00003F10 F 22 102= 106j UNSUBTABLE 02003F15 F 22 111= 116a UNTRANLOOP 00003F20 F 22 160= 167j UNTRANSPOSE 00003F1E F 22 38 40 42 123 158= VALUE 00178804 F 18 1920= 1926s 1930 1942 VALUE 00178804 F 18 1981= 1987s 1991 2003 VARPLACE 00004800 F 0 272= 273e F 17 174a 611 VCLOSEDISK 000013EC F 13 26= F 18 376 *VDISKCB 000013E4 F 13 18= VDISPLAY 000013E3 F 0 313 F 13 17= VDONEEXIT 000013F0 F 0 371 380 397 433 F 13 32= 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 24 *VERRLOGPT1 000013FA F 13 42= VERRLOGPTR 000013EA F 13 24= F 29 1499 1524 1538 1542s VERSION 00003001 F 0 309= 318a VEXTRACPUS 000013FC F 0 359 362s 363 616s 617 F 13 44= *VFETCHFNM 000013F6 F 13 38= VFETCHITEM 000013F5 F 0 662 682 768 794 869 901 F 13 37= F 27 439 *VFETCHITMH 000013F8 F 13 40= VGETDATE 000013FB F 0 1029 F 13 43= F 20 252 VMEMPF 000013E6 F 0 1193 F 13 20= F 18 263 *VMEMSPACE 000013ED F 13 27= VOLBADM 00003538 F 18 403a 407= VOLFILLEN 00000004 F 16 241= 242 F 20 461 VOLLBAD 00003535 F 18 311j 401= VOLLOGPTR 00178801 F 20 446= 459s 535 VOLLOGREC 00003B3E F 20 314 441= 443 451= 553 *VOLMAXTS 00000004 F 17 429= VOLMCB 0000485F F 17 279= F 18 314s 343 VOLRECFILL 00160801 F 16 242= F 20 460a VOLRECLEN 00000005 F 16 245= F 20 463 *VOLRECNAME 00160805 F 16 243= VOLRECSIZ 00000467 F 17 439= F 20 468 VOLSIZE 0000485E F 0 347s F 17 278= F 18 1487 VOPENDISK 000013EB F 0 343 F 13 25= VPF4SSU 000013E5 F 0 1032 F 13 19= *VPFWNDO1 000013E8 F 13 22= *VPFWNDO2 000013E9 F 13 23= VPREPOUT 000013F9 F 0 317 369 378 387 394 423 430 667 694 781 816 824 939 F 13 41= F 18 394 402 410 509 678 755 936 1038 1663 2158 F 20 545 F 27 96 426 VREAD 000013E0 F 13 14= F 18 1496 *VREADCHAR 000013F1 F 13 33= VREADLINE 000013F3 F 0 672 788 F 13 35= F 27 432 *VSCANOVER 000013F7 F 13 39= *VSLOTWRU 000013E7 F 13 21= VSRCHDIR 000013E2 F 13 16= F 18 454 546 *VSRCHDIRSN 000013EE F 13 28= VTERRMAX 00000015 F 29 596 729= VTERRPTR 0000434B F 29 597 731= VTERRTAB 00804349 F 29 708= 729e 731a *VWRITE 000013E1 F 13 15= *VWRITECHAR 000013F2 F 13 34= VWRITELINE 000013F4 F 0 930 F 13 36= WHODONE 00160807 F 16 181= F 20 120s WRITEAGAIN 00004254 F 27 501= 512j WRITEBUF 000049D2 F 17 611= 612e F 27 249a 275a 284a 328a 352a 361a *WRITEBUFL 0000022E F 17 612= WRITEDEATH 0000418F F 27 39j 40j 76= WRITEERR 0000430F F 29 532j 544= WRITEFM 000043B9 F 27 130 245 288 324 365 F 29 50 997= 999 1004= WRITEFSLR 00004246 F 27 42 446 474= 476 482= 520 WRITEGAP 000043A2 F 29 572 931= 933 940= 974 1027 WRITEINIT 00004170 F 0 499a F 27 24 32= WRITELOCK 00004802 F 0 585s 591s F 17 187= F 21 67 WRITELOOP 0000417C F 27 47= 69j 88j 132j 1 Jimbo's CREF Extractor 2.0 DISKTOTAPE, Offline Disk to Tape Backup A9108 28-Sep-93 11:17 PAGE 25 WRITELOOP 00004380 F 29 850= 902j WRITEPC 0000498D F 0 500s F 17 602= F 27 28 151s WRITEPRLOC 00008C00 F 17 615= F 27 44 55a 488a 507a WRITEPRPN 000000A3 F 17 616= F 27 53 485 WRITESPR7 0000498E F 17 603= F 27 27 152s WRITESTACK 000049D2 F 17 609= F 27 33a WRITETAPE 000042FF F 27 61 281 358 504 F 29 49 508= 510 519= WRONGMES 000038A6 F 18 1665a 1669= WRONGTYPE 00003AD7 F 20 131j 163j 178= WRTFSLRPREL 00004990 F 17 604= F 27 41s 483