;	$BEGIN	RMSINT,033 

; 

;	INTERNAL RMS STRUCTURE DEFINITIONS 

; 

;	MODIFIED BY: 

; 

;	R A NEWELL,      17-AUG-78  10:29	; WC VER FLG FOR CURRENT FILE 

;	L F LAVERDURE,   14-JUL-78  17:19 

;	W KOENIG,	23-MAR-78   AVBN AND AMAX FOR PLG & IFAB 

;				    IDX_PTR & NUM_KEYS FOR IFAB 

;	W KOENIG,	30-MAR-78   KBUFSIZE & UBUFSIZE FOR IFAB 

;	W KOENIG,	 5-APR-78   RRV_ID,RRV_VBN,KEYBUF,KEYSIZE FOR IRAB 

;	W KOENIG,	 6-APR-78   EXTRABUF FOR IFAB 

;	W KOENIG,	13-APR-78   CHANGED "SIZE" TO "SZ" 

;	E H MARISON,	13-APR-78   ADD POSITION CTX DATA FOR IDX FO IN IRAB 

;	E H MARISON,	19-APR-78   IRAB CHANGES FOR INDEXED 

;	E H MARISON,	26-APR-78   GENERAL CHANGES 

;	J A KRYCKA,	27-APR-78   ADD NETWORK SYMBOLS TO IFAB, IRAB, & FWA 

;				    DELETE TPT STRUCTURE DEFINITION 

;	J A KRYCKA,	23-MAY-78   EXPAND NODEBUF IN FWA, ADD NWA_PTR TO IRAB 

;	W KOENIG,	14-JUN-78   ADDED MAXSUBDIR AND MAXDIRLEN TO FWA DEFS 

;	J A KRYCKA,	21-JUN-78   DEFINE NETWORK WORK AREA (NWA) STRUCTURE 

;				    ADD QUOTED DESCRIPTOR TO FWA AND 

;				    MOVE QUOTED STRING STORAGE TO NWA 

;	J A KRYCKA,	21-JUL-78   REVISE NWA 

; 

;++ 

; 

;	IFAB FIELD DEFINITIONS 

; 

;  THERE IS ONE IFAB (INTERNAL FILE ACCESS BLOCK) PER OPEN FILE 

; 

	.MACRO	$IFBDEF,$GBL



	$DEFINI	IFB,$GBL



 

;+++++***** 

;  THE FIELDS THRU LAST_FAB INCLUSIVE ARE COMMON BETWEEN THE IFAB AND IRAB 

; 

				 		; DEVICE CHARACTERISTIC AND BOOKKEEPING BIT VECTORS 

	$VIELD	IFB,0,<-  

		<,32,>- 		; BOOKKEEPING BITS START IN LONGWORD 2 

-			; (BUT HAVE DEFINITIONS THAT ALLOW THEM TO 

-			;  BE REFERENCED FROM THE START OF THE IFAB) 

-			;++ 

-			;  THE FOLLOWING BITS ARE DEFINED IN 

-			;  COMMON WITH THE IRAB 

-			; 

		<BUSY,,>- 		; STREAM BUSY 

		<EOF,,>- 		; FILE POSITIONED AT EOF 

		<PPF_IMAGE,,>- 	; FLAG FOR INDIRECT PROCESSING OF PROCESS- 

-			; PERMANENT FILES (RESTRICTS ALLOWABLE OPERATIONS) 

		<ASYNC,,>- 		; ASYNC I/O FLAG (MUST BE ZERO FOR IFAB) 

		<ASYNCWAIT,,>- 	; WAIT ON ASYNC I/O (MUST BE ZERO FOR IFAB) 

-			;-- 

-			; 

-			;  IFAB SPECIFIC BITS 

-			; 

		<ACCESSED,,>- 	; FILE IS ACCESSED 

		<ANSI_D,,>- 	; ANSI D VARIABLE RECORDS 

		<RWC,,>- 		; COPY OF FOP BIT FROM OPEN 

		<DMO,,>- 		; COPY OF FOP BIT FROM OPEN 

		<SPL,,>- 		; COPY OF FOP BIT FROM OPEN 

		<SCF,,>- 		; COPY OF FOP BIT FROM OPEN 

		<DLT,,>- 		; COPY OF FOP BIT FROM OPEN 

		<DFW,,>- 		; DEFERRED WRITE (COPY OF FOP BIT FROM $OPEN) 

		<SQO,,>- 		; SEQUENTIAL OPERATIONS ONLY 

		<PPF_INPUT,,>- 	; THIS IS COMMAND 'INPUT' STREAM 

		<,1,>- 			; SPARE 

		<WRTACC,,>- 	; LOGICAL OR OF FAC BITS: 

-			;   PUT, UPD, DEL, TRN 

		<MSE,,>- 		; MULTI-STREAMS ENABLED 

		<CREATE,,>- 	; SET IF DOING CREATE (MAY BE "CREATE IF") 

		<NORECLK,,>- 	; RECORD LOCKING NOT REQUIRED 

-			; (I.E., NO SHARED ACCESS OR MULTI-STREAM) 

		<RW_ATTR,,>- 	; SET IF FILE ATTRIBUTES MUST BE RE-WRITTEN 

		<TMP,,>- 		; TEMPORARY FILE (I.E., NO DIRECTORY ENTRY) 

		<TEF,,>- 		; TRUNCATE AT EOF DUE TO LARGE AUTO EXTEND 

		<,5,>- 		; SPARE 

		<NWA,,>- 		; NETWORK WORK AREA CONTROL BLOCK PRESENT 

		<DAP_OPEN,,>- 	; OPEN/CREATE FUNCTION WAS PERFORMED VIA DAP 

		<DAP,,>- 		; DATA ACCESS PROTOCOL TRANSMISSION 

		<NSP,,>- 		; NETWORK SERVICES PROTOCOL TRANSMISSION 

		>	

$DEF	IFB$L_PRIM_DEV		 	; DEVICE CHARACTERISTICS BITS 

			; (FOR PRIMARY DEVICE - BIT ENCODING SAME AS FOR FAB) 

			.BLKL	1 

$DEF	IFB$L_BKPBITS		 	; BOOKKEEPING BITS 

; 

			.BLKL	1 

$DEF	IFB$B_BID		 		; BLOCK ID 

$EQU	IFB$C_BID	11		; IFAB ID CODE 

			.BLKB	1 

$DEF	IFB$B_BLN		 		; BLOCK LENGTH IN LONGWORDS 

			.BLKB	1 

$DEF	IFB$B_MODE		 	; CALLER'S MODE 

			.BLKB	1 

$DEF	IFB$B_EFN		 		; EVENT FLAG USED FOR SYNCHRONOUS QIO 

			.BLKB	1 

$DEF	IFB$L_IOS		 		; INTERNAL I/O STATUS BLOCK 

$DEF	IFB$L_BWB		 	; BUCKET WAIT BLOCK FOR INTER STREAM WAITING 

			.BLKB	2 

$DEF	IFB$W_IOS2		 	; HIGH WORD OF IO STATUS BLOCK 

			.BLKW	1 

$DEF	IFB$L_IOS4		 	; 2ND LONGWORD OF IO STATUS BLOCK 

			.BLKL	1 

$DEF	IFB$L_ASBADDR		 	; ADDRESS OF ASYNCHRONOUS CONTEXT BLOCK 

			.BLKL	1 

$DEF	IFB$L_ARGLST		 	; USER CALL PARAMETERS ADDR 

			.BLKL	1 

$DEF	IFB$L_IRAB_LNK		 	; POINTER TO IRAB(S) 

			.BLKL	1 

$DEF	IFB$W_CHNL		 	; I/O CHANNEL NUMBER 

			.BLKW	1 

$DEF	IFB$B_FAC		 		; FILE ACCESS 

	$VIELD	IFB,0,<-  

		<PUT,,M>- 		; (SAME AS IN FAB'S FAC FIELD) 

		<GET,,M>-  

		<DEL,,M>-  

		<UPD,,M>-  

		<TRN,,M>-  

		<BIO,,M>-  

		<BRO,,M>-  

		<EXE,,M>-  

		>	

			; NOTE: IF BOTH BIO AND BRO SET, IMPLIES BLOCK I/O 

			;	ACCESS ONLY ALLOWED FOR THIS CONNECT, RESETS 

			;	TO BRO ON DISCONNECT (SEQ. FILE ORG. ONLY). 

			; 

			.BLKB	1 

$DEF	IFB$B_ORGCASE		 	; COPY OF ORG FOR CASE DISPATCHING 

			.BLKB	1 

$DEF	IFB$L_LAST_FAB		 	; ADDRESS OF FAB FOR LAST OPERATION 

;-----***** 

			.BLKL	1 

$DEF	IFB$L_NWA_PTR		 	; POINTER TO NWA CONTROL BLOCK IF NWA BIT SET, OTHERWISE 

$DEF	IFB$L_FRB_PTR		 	; POINTER TO THE "SHARED" FILE RESOURCE BLOCK 

			.BLKL	1 

$DEF	IFB$L_RLB_LNK		 	; POINTER TO RECORD LOCK LIST (RLB'S) 

			.BLKL	1 

$DEF	IFB$L_BDB_FLNK		 	; POINTER TO BDB(S) 

			.BLKL	1 

$DEF	IFB$L_BDB_BLNK		 	; BDB BACKWARD LINK 

			.BLKL	1 

$DEF	IFB$W_DEVBUFSIZ		 	; DEVICE DEFAULT (OR BLS IF MT) BUFF SIZE 

			.BLKW	1 

$DEF	IFB$W_RTDEQ		 	; RUN-TIME DEFAULT EXTEND QUANTITY 

; 

;+++++***** 

; 

;  THE FOLLOWING FIELDS MUST REMAIN AS IS SINCE 

;  THEY CORRESPOND TO THE RMS ATTRIBUTES STORED 

;  IN THE FILE HEADER 

; 

			.BLKW	1 

$DEF	IFB$B_RFMORG		 	; ORGANIZATION AND RECORD FORMAT 

	$VIELD	IFB,0,<-  

		<RFM,4,>- 		; RECORD FORMAT 

-			; (N.B. CONSTANT VALUES DEFINED 

-			;  IN RFM FIELD OF FAB) 

		<ORG,4,>- 		; FILE ORGANIZATION 

		>	

$EQU	IFB$C_SEQ	0		; SEQUENTIAL 

$EQU	IFB$C_REL	1		; RELATIVE 

$EQU	IFB$C_IDX	2		; INDEXED 

$EQU	IFB$C_DIR	3		; DIRECT 

$EQU	IFB$C_MAXORG	2		; RELEASE 1 MAXIMUM 

			.BLKB	1 

$DEF	IFB$B_RAT		 		; RECORD ATTRIBUTES 

			; (N.B. BIT OFFSETS DEFINED IN 

			;  RAT FIELD OF FAB) 

			.BLKB	1 

$DEF	IFB$W_LRL		 		; LONGEST RECORD'S LENGTH 

			; (OR FIXED RECORD LENGTH) 

			.BLKW	1 

$DEF	IFB$L_HBK		 		; HI VBN ALLOCATED 

			; (NOTE: REVERSED ON DISK!) 

			.BLKL	1 

$DEF	IFB$L_EBK		 		; EOF VBN 

			; (NOTE: REVERSED ON DISK!) 

$DEF	IFB$W_EBK0		  

			.BLKW	1 

$DEF	IFB$W_EBK2		  

			.BLKW	1 

$DEF	IFB$W_FFB		 		; FIRST FREE BYTE IN EOF BLOCK 

			.BLKW	1 

$DEF	IFB$B_BKS		 		; BUCKET SIZE (# VBNS) 

			.BLKB	1 

$DEF	IFB$B_FSZ		 		; RECORD HEADER SIZE FOR VFC 

			.BLKB	1 

$DEF	IFB$W_MRS		 		; MAX RECORD SIZE ALLOWABLE 

			.BLKW	1 

$DEF	IFB$W_DEQ		 		; DEFAULT EXTEND QUANTITY 

			.BLKW	1 

$DEF	IFB$C_FHAEND

$DEF	IFB$K_FHAEND			; END OF FILE HEADER ATTRIBUTES 

;-----***** 

;++ 

; 

;  TEMPORARY FIELD(S) 

; 

$DEF	IFB$L_NRP_LNK		 	; PTR TO NRP LIST FOR IDX FILES, TEMP FOR OTHER ORGS 

$DEF	IFB$L_FWA_BDB		 	; FWA PAGE BDB 

$DEF	IFB$L_RNS_LEN		 	; RESULTANT NAME STRING LENGTH 

			; (USED BY $SEARCH) 

$DEF	IFB$L_LOCK_BDB		 	; LOCK BDB ADDRESS (USED BY $EXTEND FOR REL. FILE) 

;-- 

; 

;  ORGANIZATION-DEPENDENT FIELDS 

; 

;  THE FOLLOWING FIELDS ARE USED DIFFERENTLY 

;  DEPENDING UPON THE FILE'S ORGANIZATION 

; 

			 

;++ 

; 

;  SEQUENTIAL ORG SPECIFIC FIELDS 

; 

			.BLKL	1 

$DEF	IFB$L_AS_DEV		 	; ASSIGNED DEVICE CHARACTERISTICS 

			.BLKL	1 

				 		; (SPARE) 

			.BLKW	1 

$DEF	IFB$W_ASDEVBSIZ		 	; ASSIGNED DEVICE BUFFER SIZE 

			.BLKW	1 

$DEF	IFB$C_BLN_SEQ

$DEF	IFB$K_BLN_SEQ		 

;-- 

;++ 

; 

;  RELATIVE ORG SPECIFIC FIELDS 

; 

	. = 80  

			.BLKW	2 

$DEF	IFB$L_MRN		 		; (REL) MAX RECORD NUMBER 

			.BLKL	1 

$DEF	IFB$L_DVBN		 	; (REL) FIRST DATA BUCKET VBN 

			.BLKL	1 

$DEF	IFB$W_BKS_BYTES		 	; (REL) # OF BYTES IN A BUCKET 

			.BLKW	1 

$DEF	IFB$W_BKS_RECS		 	; (REL) # OF RECORDS IN A BUCKET 

			.BLKW	1 

$DEF	IFB$C_BLN_REL

$DEF	IFB$K_BLN_REL		 

;-- 

 

;++ 

; 

;  INDEXED ORG SPECIFIC FIELDS 

; 

	. = 80  

			.BLKW	2 

$DEF	IFB$L_IDX_PTR		 	; (IDX) POINTER TO PRIMARY KEY INDEX DESCRIPTOR 

			.BLKL	1 

$DEF	IFB$B_AVBN		 	; (IDX) VBN OF 1ST AREA DESCRIPTOR 

			.BLKB	1 

$DEF	IFB$B_AMAX		 	; (IDX) TOTAL NUMBER OF AREA DESCRIPTORS 

			.BLKB	1 

$DEF	IFB$B_NUM_KEYS		 	; (IDX) # OF KEYS IN FILE 

			.BLKB	1 

$DEF	IFB$B_UBUFSZ		 	; (IDX) UPDATE BUFFER SIZE FOR KEYS 

			.BLKB	1 

$DEF	IFB$B_KBUFSZ		 	; (IDX) KEY BUFFER SIZE 

			.BLKB	1 

$DEF	IFB$B_EXTRABUF		 	; (IDX) NUMBER OF EXTRA BUFFERS FOR 'CACHE'ING 

			.BLKB	1 

				  

			; TEMPORARILY SPARE 2 BYTES -- TO KEEP THE OVERALL 

			; LENGTH OF THE IFAB LONG ENOUGH FOR RELATIVE 

			.BLKB	2 

$DEF	IFB$C_BLN_IDX

$DEF	IFB$K_BLN_IDX		 

;-- 

$DEF	IFB$C_BLN

$DEF	IFB$K_BLN				; IFAB LENGTH 



	$DEFEND	IFB,$GBL,DEF



	.ENDM	$IFBDEF

 

; 

;	 IRAB FIELD DEFINITIONS 

; 

;  THERE IS 1 IRAB PER CONNECTED RECORD ACCESS STREAM 

; 

	.MACRO	$IRBDEF,$GBL	; INTERNAL RAB 



	$DEFINI	IRB,$GBL



 

;+++++***** 

; 

;  THE FIELDS THRU LAST_RAB INCLUSIVE ARE COMMON BETWEEN THE IRAB AND IFAB 

; 

				 		; USED TO GET BOOKKEEPING BIT DEFINITIONS 

			; TO APPLY FROM START OF IRAB 

	$VIELD	IRB,0,<-  

		<,32,>- 		; BOOKKEEPING BITS START IN LONGWORD 2 

-			;++ 

-			; 

-			;  THE FOLLOWING BITS ARE DEFINED IN COMMON 

-			;  WITH THE IFAB 

-			; 

		<BUSY,,>- 		; FILE BUSY 

		<EOF,,>- 		; STREAM POSITIONED AT EOF 

		<PPF_IMAGE,,>- 	; FLAG FOR INDIRECT PROCESSING OF PROCESS- 

-			; PERMANENT FILE 

		<ASYNC,,>- 		; ASYNCHRONOUS I/O REQUEST 

		<ASYNCWAIT,,>- 	; $WAIT ISSUED FOR ASYNCHRONOUS I/O REQUEST 

-			;-- 

-			; 

-			;   IRAB SPECIFIC BITS 

-			; 

		<FIND_LAST,,>- 	; LAST OPERATION WAS A FIND 

		<PUTS_LAST,,>- 	; LAST OPERATION WAS A PUT SEQUENTIAL 

		<BIO_LAST,,>- 	; THIS/LAST OPERATION IS/WAS A BLOCK I/O OPERATION 

-			; NOTE: THIS BIT IS SET ONLY IF MIXED BLOCK AND RECORD 

-			;       OPERATIONS (BRO ACCESS).  AFTER CALL TO RM$RSET 

-			;	REFERS TO THE CURRENT OPERATION AND BRO_SW GIVES 

-			;	TYPE OF LAST OPERATION. 

		<BRO_SW,,>- 	; SWITCHED FROM RECORD OPERATION TO BLOCK I/O OPERATION 

		<FIND,,>- 		; OPERATION IS A FIND 

		<RAHWBH,,>- 	; READ AHEAD OR WRITE BEHIND PROCESSING 

		<SKIP_NEXT,,>- 	; SKIP TO NEXT RECORD FLAG FOR INDEX FO 

		<DUP,,>- 		; DUPLICATE RECORDS SEEN 

		<UNLOCK_RP,,>- 	; RELEASE LOCK ON CURRENT (RP) RECORD 

		<PPF_EOF,,>- 	; GIVE ONE-SHOT RMS$_EOF ERROR ON SYS$INPUT 

		<PPF_SKIP,,>- 	; SKIP SYS$INPUT RECORD ($DECK), REDOING $GET 

-			; OR $FIND ON NEXT RECORD 

		<PPF_FNDSV,,>- 	; SAVE VALUE FOR FIND BIT WHEN PPF_SKIP SET 

		<IDX_ERR,,>- 	; INDEX UPDATE ERROR OCCURRED 

		<,12,>- 		; SPARE 

		<DAP_CONN,,>- 	; CONNECT FUNCTION WAS PERFORMED VIA DAP 

		<DAP_FMODE,,>- 	; DAP FILE TRANSFER MODE IN EFFECT 

		>	

; 

;  THE FOLLOWING ARE ALTERNATE DEFINITIONS FOR ALTERNATE 

;  (NON-CONFLICTING) USE OF THE ABOVE BITS 

; 

	$VIELD	IRB,0,<-  

		<,41,>- 		; START RE-USE WITH FIND 

		<WRITE,,>- 		; OPERATION IS A WRITE 

		>	

$DEF	IRB$L_IFAB_LNK		 	; POINTER TO IFAB 

			.BLKL	1 

$DEF	IRB$L_BKPBITS		 	; BOOKKEEPING STATUS BITS 

; 

			.BLKL	1 

$DEF	IRB$B_BID		 		; BLOCK ID 

$EQU	IRB$C_BID	10		; IRAB CODE 

			.BLKB	1 

$DEF	IRB$B_BLN		 		; BLOCK LENGTH IN LONGWORDS 

			.BLKB	1 

$DEF	IRB$B_MODE		 	; CALLER'S MODE 

			.BLKB	1 

$DEF	IRB$B_EFN		 		; EVENT FLAG FOR SYNCHRONOUS IO 

			.BLKB	1 

$DEF	IRB$L_IOS		 		; INTERNAL I/O STATUS BLOCK 

$DEF	IRB$L_BWB		 	; BUCKET WAIT BLOCK FOR INTER STREAM LOCKING 

			.BLKB	2 

$DEF	IRB$W_IOS2		 	; HIGH WORD OF IO STATUS BLOCK 

			.BLKW	1 

$DEF	IRB$L_IOS4		 	; IO STATUS BLOCK (2ND LONGWORD) 

			.BLKL	1 

$DEF	IRB$L_ASBADDR		 	; ADDRESS OF PERMANENT ASYNCHRONOUS CONTEXT BLOCK 

			.BLKL	1 

$DEF	IRB$L_ARGLST		 	; USER ARG LIST ADDRESS 

			; IF ASYNC, POINTS TO COPY AT HEAD 

			; OF ASYNC CONTEXT BLOCK 

			.BLKL	1 

$DEF	IRB$L_IRAB_LNK		 	; POINTER TO NEXT IRAB 

			.BLKL	1 

$DEF	IRB$L_CURBDB		 	; CURRENT BDB ADDRESS 

			.BLKL	1 

$DEF	IRB$L_LAST_RAB		 	; ADDRESS OF RAB FOR LAST OPERATION 

;-----***** 

			.BLKL	1 

$DEF	IRB$L_NXTBDB		 	; NEXT BDB ADDRESS 

			.BLKL	1 

$DEF	IRB$L_NRP_VBN		 	; NEXT RECORD POINTER VBN 

$DEF	IRB$L_NRP		 	; NEXT RECORD POINTER (RELATIVE RECORD #) 

			.BLKL	1 

$DEF	IRB$L_NRP_OFF		 	; NEXT RECORD POINTER OFFSET 

$DEF	IRB$W_NRP_OFF		 	;     " 

$DEF	IRB$L_CURVBN		 	; VBN OF CURRENT RECORD (RELATIVE) 

$DEF	IRB$B_NRP_ID		 	; RECORD ID (INDEXED) 

			.BLKB	1 

$DEF	IRB$B_NRP_KREF		 	; KEY OF REFERENCE (INDEXED) 

			.BLKB	1 

$DEF	IRB$W_DUP_POS		 	; DUPLICATE POSITION COUNT (INDEXED) 

			.BLKW	1 

$DEF	IRB$L_RP_VBN		 	; RECORD POINTER VBN 

$DEF	IRB$L_RP		 	; RECORD POINTER (RELATIVE RECORD #) 

			.BLKL	1 

$DEF	IRB$L_RP_OFF		 	; RECORD POINTER OFFSET 

$DEF	IRB$W_RP_OFF		 	;    " 

$DEF	IRB$B_RP_ID		 	; RECORD ID (INDEXED) 

			.BLKB	1 

$DEF	IRB$B_RP_KREF		 	; KEY OF REFERENCE (INDEXED) 

			.BLKB	1 

			.BLKB	2 

$DEF	IRB$L_OWNER_ID		 	; OWNER ID USED FOR RECORD LOCKS 

$DEF	IRB$W_OWN_ID		 	; INDEX PART OF PROCESS ID (PID) 

			.BLKW	1 

$DEF	IRB$W_OWN_ISI		 	; ISI VALUE FOR THIS IRAB 

$DEF	IRB$B_PPF_ISI		 	; ISI VALUE FOR THIS PROCESS-PERMANENT IRAB 

			.BLKB	1 

			.BLKB	1 

$DEF	IRB$B_BCNT		 	; I/O BUFFER COUNT 

			.BLKB	1 

$DEF	IRB$B_MBC		 		; MULTI-BLOCK COUNT 

;++ 

; 

;  START OF ORGANIZATION DEPENDENT FIELDS 

; 

			 

;++ 

; 

;  SEQUENTIAL ORG SPECIFIC FIELDS 

; 

			.BLKB	1 

$DEF	IRB$W_CSIZ		 	; CURRENT RECORD SIZE (SEQ) 

			.BLKW	1 

$DEF	IRB$L_TEMP0		  

$DEF	IRB$W_ROVHDSZ		 	; OVERHEAD SIZE FOR RECORD 

$DEF	IRB$B_PRE_CCTL		 	; 'PRE' CARRIAGE CONTROL 

			.BLKB	1 

$DEF	IRB$B_POST_CCTL		  ; 'POST' CARRIAGE CONTROL 

			.BLKB	1 

$DEF	IRB$W_RTOTLSZ		 	; TOTAL SIZE FOR RECORD 

			.BLKW	1 

$DEF	IRB$L_TEMP1		  

$DEF	IRB$B_NVBNS		 	; NUMBER OF VBNS TRANSFERRED (NXTBLK1) 

			.BLKB	1 

			.BLKB	3 

$DEF	IRB$C_BLN_SEQ

$DEF	IRB$K_BLN_SEQ		 

;++ 

; 

;  RELATIVE ORG SPECIFIC FIELDS 

; 

	. = 65  

 

			.BLKB	1 

				 		; (CSIZ) = CELL SIZE 

			.BLKW	1 

$DEF	IRB$L_RLB_ADDR		 	; RECORD LOCK BLOCK ADDRESS(ALSO USED IN INDEXED ORG) 

			.BLKL	1 

$DEF	IRB$C_BLN_REL

$DEF	IRB$K_BLN_REL		 

; 

; INDEXED ORG SPECIFIC FIELDS 

; 

	. = 65  

			.BLKB	1 

$DEF	IRB$B_STOPLEVEL		 	; LEVEL TO STOP AT ON TREE SEARCH 

			.BLKB	1 

$DEF	IRB$B_SRCHFLAGS		 	; SEARCH FLAGS 

	$VIELD	IRB,0,<-  

		<POSINSERT,,>- 	; POSITION FOR INSERT 

		<SRCHGT,,>- 		; APPROXIMATE SEARCH GT 

		<LOCKABOVE,,>- 	; LOCK LEVEL ABOVE 

		<NEW_IDX,,>- 	; NEED TO READ IN NEW IDX DSC FROM FILE 

		>	

			.BLKB	1 

				 		; THIS IS RLB_ADDR 

			.BLKL	1 

$DEF	IRB$L_KEYBUF		 	; ADDRESS OF INTERNAL KEY BUFFER & UPDATE BUFFER 

			.BLKL	1 

$DEF	IRB$L_RRV_VBN		 	; BUCKET START VBN FOR RRV 

			.BLKL	1 

$DEF	IRB$B_RRV_ID		 	; RECORD ID FOR RRV 

			.BLKB	1 

$DEF	IRB$B_KEYSZ		 	; SIZE OF KEY IN KEYBUFFER #2 

			.BLKB	1 

$DEF	IRB$W_SAVE_POS		 	; SAVED DUPLICATE POSITION FOR SEARCH NRP DATA 

			.BLKW	1 

$DEF	IRB$L_RFA_VBN		 	; RFA VBN FOR SEARCH NRP DATA 

			.BLKL	1 

$DEF	IRB$B_RFA_ID		 	; SAVE ID FOR SEARCH NRP DATA 

			.BLKB	1 

				 		; SPARE 

			.BLKB	1 

				 		; SPARE 

			.BLKW	1 

$DEF	IRB$L_LOCK_BDB		 	; LOCK BDB ADDR OF LEVEL BELOW ON SPLITS 

			.BLKL	1 

				 		; SPARES FOR PUT, ETC. 

			.BLKL	3 

$DEF	IRB$C_BLN_IDX

$DEF	IRB$K_BLN_IDX		 



	$DEFEND	IRB,$GBL,DEF



	.ENDM	$IRBDEF

 

; 

;  ASYNCHRONOUS OPERATIONS REQUIRE THAT AN IRAB HAVE 

;  AN ASYNCHRONOUS CONTEXT BLOCK (ASB) 

;  THE ASB IS POINTED TO BY THE ARGLST FIELD OF THE 

;  IRAB IF THE ASYNC BOOKKEEPING BIT IS SET 

; 

;  THE FIRST FOUR LONGWORDS ARE USED TO SAVE THE 

;  CALLER'S ARGUMENT LIST 

; 

	.MACRO	$ASBDEF,$GBL



	$DEFINI	ASB,$GBL



 

$DEF	ASB$B_ARGCNT		 	; ARGUMENT COUNT 

			; VALUE WILL BE 0, 1, 2, OR 3 

			.BLKB	1 

$DEF	ASB$B_BLN		 		; BLOCK LENGTH IN LONGWORDS 

			.BLKB	1 

$DEF	ASB$B_STKSIZ		 	; SIZE OF SAVED STACK IN BYTES 

			.BLKB	1 

				 		; SPARE 

			.BLKB	1 

$DEF	ASB$L_FABRAB		 	; FAB OR RAB ADDRESS 

			.BLKL	1 

$DEF	ASB$L_ERR		 		; ERR ROUTINE ADDR 

			.BLKL	1 

$DEF	ASB$L_SUC		 		; SUC ROUTINE ADDR 

			.BLKL	1 

$DEF	ASB$L_REGS		 	; WORK SPACE FOR REGISTER AND STACK SAVE 

			; (REGS 6,7,8,10,11 - R4,R5 SAVED ON STACK) 

			.BLKL	24 

$DEF	ASB$C_BLN_FAB

$DEF	ASB$K_BLN_FAB			; BLOCK LENGTH FOR FAB-RELATED OPERATIONS 

				 		; ADDITIONAL SPACE FOR SEQ ORG IRAB OPERATIONS 

			.BLKL	4 

$DEF	ASB$C_BLN_SEQ

$DEF	ASB$K_BLN_SEQ			; BLOCK LENGTH FOR SEQ ORG IRAB OPERATIONS 

				 		; ADDITIONAL SPACE FOR RELATIVE ORG 

			.BLKL	1 

$DEF	ASB$C_BLN_REL

$DEF	ASB$K_BLN_REL			; BLOCK LENGTH FOR REL ORG IRAB OPERATIONS 

				 		; ADDITIONAL SPACE FOR INDEXED ORG 

			.BLKL	10 

$DEF	ASB$C_BLN_IDX

$DEF	ASB$K_BLN_IDX		 



	$DEFEND	ASB,$GBL,DEF



	.ENDM	$ASBDEF

 

; 

;	 FILE WORK AREA DEFINITIONS 

; 

;  THE FILE WORK AREA IS USED FOR EXPANDING THE FILE 

;  NAME STRING AND SETTING UP THE VARIOUS PARAMETER 

;  BLOCKS FOR INTERFACING WITH F11ACP 

; 

	.MACRO	$FWADEF,$GBL



	$DEFINI	FWA,$GBL



 

$DEF	FWA$Q_FLAGS		 	; VARIOUS PARSE STATUS FLAGS 

	$VIELD	FWA,0,<-  

		<DUPOK,,M>- 	; DISCARD DUPLICATE ELEMENT 

		<NAMEFLG,,M>- 	; NAME SEEN THIS PARSE 

		<TYPEFLG,,M>- 	; TYPE SEEN THIS PARSE 

		<RLF_PASS,,M>- 	; SET IF APPLYING RELATED FILE DEFAULTS 

		<FNA_PASS,,M>- 	; SET IF PRIMARY NAME STRING PARSE PASS 

		<NAM_DVI,,M>- 	; SET IF OPEN BY NAME BLOCK 

		<CUR_VER,,>- 		; SET IF CUR FILE HAS WC VER 

		<,1,>- 		; SPARE 

		>		; (END OF PASSFLGS BYTE) 

	$VIELD	FWA,0,<-  

		<,8,>- 		; START DEFS AT BYTE 1 

		<,3,>- 		; MUST BE ZERO 

		<VERSION,,M>- 	; SET IF VERSION SEEN 

		<TYPE,,M>- 	; SET IF TYPE SEEN 

		<NAME,,M>- 	; SET IF NAME SEEN 

		<DIR,,M>- 		; SET IF DIRECTORY SPEC SEEN 

		<DEVICE,,M>- 	; SET IF DEVICE SEEN 

-			; (END OF FLDFLGS BYTE) 

		<EXP_VER,,M>- 	; SET IF EXPLICIT VERSION 

		<EXP_TYPE,,M>- 	; SET IF EXPLICIT TYPE 

		<EXP_NAME,,M>- 	; SET IF EXPLICIT NAME 

		<WC_VER,,>- 		; SET IF WILDCARD (*) VERSION 

		<WC_TYPE,,>- 		;          "		TYPE 

		<WC_NAME,,>- 		;	   "		NAME 

		<EXP_DIR,,M>- 	; SET IF EXPLICIT DIRECTORY 

		<EXP_DEV,,M>- 	; SET IF EXPLICIT DEVICE 

-			; (END OF WILDFLGS BYTE) 

		<WILDCARD,,>- 	; SET IF ANY WILDCARD SEEN 

		<NODE,,>- 		; SET IF NODE NAME SEEN 

		<QUOTED,,>- 		; SET IS QUOTED STRING SEEN 

-			; (VALID ONLY IF NODE SET AND NO FLDFLGS) 

		<GRPMBR,,>- 		; SET IF DIRECTORY IN [GRP,MBR] FORMAT 

		<WILD_DIR,,>- 	; INCLUSIVE OR OF DIRECTORY WILD CARDS 

		<DIR_LVLS,3,>- 	; # OF DIRECTORY SUBLEVELS (0 = UFD ONLY) 

-			; (END OF PARSEFLGS BYTE) 

		>	

	$VIELD	FWA,0,<-  

		<,32,>- 		; CONTINUE BIT DEFINITIONS OF 2ND LONGWORD 

		<DIR1,,>- 		; UFD LEVEL DIRECTORY OR GROUP SEEN 

		<DIR2,,>- 		; SFD LEVEL 1 DIRECTORY OR MEMBER SEEN 

		<,6,>- 		; ADDITIONAL SUB DIRECTORY LEVEL FLAGS 

-			; (END OF DIRFLGS BYTE) 

		<WILD_UFD,,>- 	; THE DIR1 SPEC WAS A WILD CARD 

		<WILD_SFD1,,>- 	; THE DIR2 SPEC WAS A WILD CARD 

		<,6,>- 		; ADDITIONAL SUB DIRECTORY WILDCARD FLAGS 

-			; (END OF DIRWCFLGS BYTE) 

		<LOGNAME,,>- 		; A LOGICAL NAME HAS BEEN SEEN THIS PASS 

-			; (NOTE: THIS BYTE IS SAVED AS CONTEXT 

-			; WHEN PROCESSING [.DIR-LIST] FORMAT) 

		<OBJTYPE,,>- 		; SET IF QUOTED STRING IS OF THE 

-			; "OBJECTTYPE=..." FORM 

-			; (VALID ONLY IF QUOTED SET) 

		<NETSTR,,>- 		; SET IF QUOTED STRING IS OF THE 

-			; "OBJECTTYPE=TASKNAME/..." FORM 

-			; (VALID ONLY IF QUOTED AND OBJTYPE SET) 

		<,5,>- 		; SPARES 

-			; (END OF LNFLG BYTE) 

		>	

	$VIELD	FWA,0,<-  

		<,40,>- 		; ALTERNATE DEFINITION FOR DIR1 AND DIR2 

		<WILD_GRP,,>- 	; THE GRP SPEC CONTAINED A WILD CARD 

		<WILD_MBR,,>- 	; THE MBR SPEC CONTAINED A WILD CARD 

		>	

$DEF	FWA$B_PASSFLGS		 	; FLAGS FOR PASS ONLY 

			.BLKB	1 

$DEF	FWA$B_FLDFLGS		 	; FLAGS FOR FIELDS SEEN 

			.BLKB	1 

$DEF	FWA$B_WILDFLGS		 	; FLAGS FOR WILD CARDS 

			.BLKB	1 

$DEF	FWA$B_PARSEFLGS		 	; FLAGS FOR PARSE RESULTS 

			.BLKB	1 

$DEF	FWA$B_DIRFLGS		 	; FLAGS PRIMARILY FOR DIRECTORY SPEC 

			.BLKB	1 

$DEF	FWA$B_DIRWCFLGS		 	; DIRECTORY WILD FLAGS 

			.BLKB	1 

$DEF	FWA$B_LNFLG		 	; LOGICAL NAME FLAG BYTE 

			.BLKB	1 

$DEF	FWA$B_DIRTERM		 	; DIRECTORY SPEC TERMINATOR (']' OR '>') 

			; (NOTE: THIS BYTE MUST FOLLOW THE LNFLG BYTE) 

$EQU	FWA$C_ALL	<<FWA$M_DEVICE!FWA$M_DIR!FWA$M_NAME!FWA$M_TYPE!FWA$M_VERSION>@-8>		

			; VALUE FOR ALL FILENAME ELEMENTS EXCEPT NODE 

; 

			.BLKB	1 

$DEF	FWA$L_ESCSTRING		 	; ESCAPE EQUIVALENCE STRING 

$DEF	FWA$B_ESCFLG		 	; SET TO THE CHAR <ESC> IF AN ESCAPE STRING 

			; SEEN, ZERO OTHERWISE 

			.BLKB	1 

$DEF	FWA$B_ESCTYP		 	; ESCAPE 'TYPE' BYTE 

			 

			.BLKB	1 

$DEF	FWA$W_ESCIFI		 	; ESCAPE IFI VALUE 

; 

			.BLKW	1 

	. = 9  

			; TEMPORARY USAGE OF THE ESCIFI FIELD 

			; FOR LOGICAL NAME TRANSLATION 

			.BLKB	1 

$DEF	FWA$B_XLTMODE		 	; MODE OF EQUIVALENCE STRING 

			.BLKB	1 

$DEF	FWA$B_XLTTBL		 	; TABLE OF EQUIVALENCE STRING 

			.BLKB	1 

$DEF	FWA$Q_XLTBUF1		 	; PRIMARY TRANSLATION BUFFER DISCRIPTOR 

$DEF	FWA$Q_FIB		 	; RE-USE FOR FIB DESCRIPTOR 

			.BLKQ	1 

$DEF	FWA$L_BUFFLG		 	; FLAG FOR WHICH BUFFER IN USE 

			; (0 = BUF2 IN USE, 1 = BUF1 IN USE) 

			.BLKL	1 

$DEF	FWA$L_XLTSIZ		 	; LENGTH OF EQUIVALENCE STRING 

$DEF	FWA$W_FNAMSIZ		 	; FILE NAME SIZE (WITHOUT TYPE AND VERSION) 

			; AFTER EXIT FROM XPFN 

			.BLKW	1 

			.BLKW	1 

$DEF	FWA$Q_LOGNAME		 	; LOGICAL NAME DESCRIPTOR 

$DEF	FWA$L_UIC		 	; FILE OWNER UIC 

$DEF	FWA$L_LOOKUP		 	; ADDRESS OF NEW DIRECTORY CACHE NODE 

			.BLKL	1 

$DEF	FWA$L_DEVNODADR		 	; ADDRESS OF DEVICE DIRECTORY CACHE NODE 

$DEF	FWA$W_PRO		 	; FILE PROTECTION WORD 

			.BLKW	1 

			.BLKW	1 

$DEF	FWA$Q_XLTBUF2		 	; SECONDARY TRANSLATION BUFFER DESCRIPTOR 

$DEF	FWA$Q_DIR		 	; DIRECTORY NAME SCRATCH BUFFER 

			.BLKQ	1 

$DEF	FWA$L_XLTCNT		 	; NUMBER OF TRANSLATIONS DONE 

$DEF	FWA$W_UCHAR		 	; REUSE TO RECEIVE USER CHARACTERISTICS WORD 

			.BLKW	1 

			.BLKW	1 

$DEF	FWA$B_DIRLEN		 	; OVERALL DIRECTORY SPEC LENGTH 

			.BLKB	1 

				 		; SPARES 

; 

;  DESCRIPTORS FOR PARSED FILENAME ELEMENTS 

; 

;******++++++ 

;  THE FOLLOWING DESCRIPTORS MUST BE CONTIGUOUS. 

			.BLKB	3 

$DEF	FWA$Q_NODE		 		; NODE NAME DESCRIPTOR 

$EQU	FWA$C_MAXNODE	40			; MAX NODE NAME SIZE 

			.BLKQ	1 

$DEF	FWA$Q_DEVICE		 		; DEVICE NAME DESCRIPTOR 

$EQU	FWA$C_MAXDEVICE	15		; MAX DEVICE NAME SIZE 

			.BLKQ	1 

$DEF	FWA$Q_DIR1		 		; DIRECTORY AND SUBDIRECTORY DESCRIPTORS 

			.BLKQ	1 

$DEF	FWA$Q_DIR2		 		; (NOTE: ONLY 1 AND 2 EXPLICITLY NAMED) 

			.BLKQ	1 

				  

			.BLKQ	1 

				  

			.BLKQ	1 

				  

			.BLKQ	1 

				  

			.BLKQ	1 

				  

			.BLKQ	1 

				  

$EQU	FWA$C_MAXSUBDIR	7			; MAX NUMBER OF SUB DIRECTORIES 

$EQU	FWA$C_MAXDIRLEN	60		; MAX SIZE OF TOTAL DIRECTORY SPEC 

			.BLKQ	1 

$DEF	FWA$Q_NAME		 		; FILE NAME DESCRIPTOR 

$EQU	FWA$C_MAXNAME	9			; MAX FILE NAME SIZE 

			.BLKQ	1 

$DEF	FWA$Q_TYPE		 		; FILE TYPE DESCRIPTOR 

$DEF	FWA$Q_RNS		 		; RE-USE AS RESULTANT NAME STRING DESCRIPTOR 

$EQU	FWA$C_MAXTYPE	3			; MAX FILE TYPE SIZE 

$EQU	FWA$C_RNSBUFSIZ	20		; MAX RESULTANT NAME STRING SIZE 

			.BLKQ	1 

$DEF	FWA$Q_VERSION		 		; FILE VERSION DESCRIPTOR 

$DEF	FWA$Q_STATBLK		 		; RE-USE TO READ STATISTICS 

$DEF	FWA$L_SBN		 		; STARTING LBN IF CONTIGUOUS 

			.BLKL	1 

$DEF	FWA$L_HBK		 		; HIGH VBN 

$EQU	FWA$C_MAXVER	6			; MAX FILE VERSION SIZE 

;******------ 

			.BLKL	1 

$DEF	FWA$Q_QUOTED		 		; QUOTED STRING DESCRIPTOR 

$EQU	FWA$C_MAXQUOTED	127		; MAX QUOTED STRING SIZE 

			.BLKQ	1 

$DEF	FWA$T_FIBBUF		 		; FIB BUFFER 

$EQU	FWA$C_FIBLEN	44			; FIB BUFFER SIZE 

; 

;  DIRECTORY NAME BUFFERS 

; 

			.BLKB	44 

$DEF	FWA$T_DIR1BUF		 		; UFD LEVEL (OR GROUP) 

			.BLKB	9 

$DEF	FWA$T_DIR2BUF		 		; 1ST SFD LEVEL (OR MEMBER) 

			.BLKB	9 

				 			; ADDITIONAL SUBDIRECTORY LEVELS 

$EQU	FWA$C_DIRBUFSIZ	9			; SIZE OF EACH DIRECTORY BUFFER 

;******++++++ 

;  THE FOLLOWING BUFFERS MUST BE CONTIGUOUS AS EVENTUALLY THE 

;  TYPE AND VERSION ARE APPENDED TO THE NAME STRING 

			.BLKB	54 

$DEF	FWA$T_NAMEBUF		 		; FILE NAME BUFFER (ALSO USED FOR RESULTANT NAME) 

$EQU	FWA$C_NAMBUFSIZ	10			; FILE NAME BUFFER SIZE 

			.BLKB	10 

$DEF	FWA$T_TYPEBUF		 		; FILE TYPE BUFFER 

$EQU	FWA$C_TYPBUFSIZ	4			; FILE TYPE BUFFER SIZE 

			.BLKB	4 

$DEF	FWA$T_VERBUF		 		; FILE VERSION BUFFER 

$EQU	FWA$C_VERBUFSIZ	6			; FILE VERSION BUFFER SIZE 

;******------ 

			.BLKB	6 

$DEF	FWA$T_NODEBUF		 		; NODE NAME BUFFER 

$EQU	FWA$C_NODBUFSIZ	40		; NODE NAME BUFFER SIZE 

			.BLKB	40 

$DEF	FWA$B_UNDERLINE		 		; SINGLE CHARACTER '_' STORED HERE TO PREVENT 

				; ADDITIONAL LOGICAL NAME TRANSLATION 

			.BLKB	1 

$DEF	FWA$T_DEVICEBUF		  	; DEVICE NAME BUFFER 

$EQU	FWA$C_DEVBUFSIZ	15		; DEVICE NAME BUFFER SIZE 

			.BLKB	15 

$DEF	FWA$T_ATR_LIST		 	; ATTRIBUTE LIST WORK AREA 

$DEF	FWA$T_XLTBUFF1		 	; SCRATCH TRANSLATION BUFFER 

				; (ALSO USED FOR ATTRIBUTE LIST AREA IN RM$ACCESS) 

			.BLKB	16 

$DEF	FWA$T_DIB		 		; DEVICE INFORMATION BLOCK 

			.BLKB	48 

$DEF	FWA$T_XLTBUFF2		 	; SCRATCH TRANSLATION BUFFER 

				; (ALSO USED FOR DIRECTORY PROCESSING IN RM$SETDID 

				;  AND ATTRIBUTE LIST AREA IN RM$ACCESS) 

$EQU	FWA$C_XLTBUFSIZ	63		; SCRATCH TRANSLATION BUFFER SIZE 

			.BLKB	64 



	$DEFEND	FWA,$GBL,DEF



	.ENDM	$FWADEF

 

; 

;	NETWORK WORK AREA DEFINITIONS 

; 

;  THE NETWORK WORK AREA CONTAINS THE DAP CONTROL BLOCK, STORAGE 

;  FOR THE QUOTED STRING, AND SCRATCH BUFFERS FOR NETWORK OPERATIONS. 

;  IFB$L_NWA_PTR POINTS TO IT. NWA IS ALLOCATED BY RM0XPFN WHEN NODENAME 

;  IS DETECTED AND IT IS DEALLOCATED BY RMS0CLOSE WHEN THE IFAB IS 

;  DEALLOCATED. 

; 

	.MACRO	$NWADEF,$GBL



	$DEFINI	NWA,$GBL



	 

$DEF	NWA$T_DAP		 		; DAP CONTROL BLOCK 

				; ITS SYMBOLS ARE DEFINED BY $DAPDEF 

$EQU	NWA$C_DAPSIZ	192			; DAP CONTROL BLOCK SIZE 

$DEF	NWA$Q_FLG		 		; MAP NWA$Q_FLG OVER DAP$Q_FLG 

				;  BITS 00-31 ARE DEFINED BY NWA 

				;  BITS 32-63 ARE DEFINED BY DAP 

			.BLKQ	1 

			.BLKQ	23 

$DEF	NWA$T_FILESPEC		 	; FILE SPEC STRING SENT TO FAL STORED 

				;  AS A COUNTED ASCII STRING 

$DEF	NWA$T_QUOTEDBUF		 	; QUOTED STRING BUFFER 

			.BLKB	127 

$DEF	NWA$B_QUOTEDTRN		 	; # BYTES TRUNCATED FROM QUOTED STRING COUNT 

				; IN FWA$Q_QUOTED BUT STILL IN NWA$T_QUOTEDBUF 

			.BLKB	1 

$DEF	NWA$Q_BUFFER		 		; PRIMARY SCRATCH BUFFER DESCRIPTOR 

			.BLKQ	1 

$DEF	NWA$Q_BUFFER2		 		; SECONDARY SCRATCH BUFFER DESCRIPTOR 

			.BLKQ	1 

$DEF	NWA$T_SPARE		 		; UNUSED SPACE 

			.BLKB	16 

$DEF	NWA$T_BUFFER		 		; SCRATCH BUFFER 

$EQU	NWA$C_BUFFERSIZ	672		; SCRATCH BUFFER SIZE 

			.BLKB	672 

$DEF	NWA$C_BLN

$DEF	NWA$K_BLN					; THIS SHOULD EQUAL 1024 OR 2 PAGES!!! 



	$DEFEND	NWA,$GBL,DEF



	.ENDM	$NWADEF

 

; 

;	 BDB FIELD DEFINITIONS 

; 

;  BUFFER DESCRIPTOR BLOCK (BDB) 

; 

;  THERE IS ONE BDB PER I/O BUFFER 

;  ( THE I/O BUFFERS EXIST IN SEPARATE PAGES, PAGE ALIGNED) 

;  SOME BDB'S MAY NOT HAVE AN ASSOCIATED I/O BUFFER 

; 

	.MACRO	$BDBDEF,$GBL



	$DEFINI	BDB,$GBL



 

$DEF	BDB$L_FLINK		 	; FORWARD LINK 

			.BLKL	1 

$DEF	BDB$L_BLINK		 	; BACKWARD LINK 

			.BLKL	1 

$DEF	BDB$B_BID		 		; BLOCK ID 

$EQU	BDB$C_BID	12		; BDB ID CODE 

			.BLKB	1 

$DEF	BDB$B_BLN		 		; BLOCK LENGTH IN LONGWORDS 

			.BLKB	1 

$DEF	BDB$B_FLGS		 	; BDB FLAGS 

	$VIELD	BDB,0,<-  

		<VAL,,M>- 		; BUFFER CONTENTS VALID 

		<DRT,,M>- 		; BUFFER CONTENT DIRTY 

		<IOP,,M>- 		; BUFFER HAS I/O IN PROGRESS 

		<PRM,,M>- 		; BUFFER HAS PERMANENCE FACTOR 

		<NOLOCATE,,M>- 	; BUFFER SHARED - NO LOCATE MODE 

-			; (SET/CLEARED BY RM$CACHE) 

		<WFO,,M>- 		; OTHER STREAMS AWAITING 

-			; THE RELEASING OF THIS BDB 

		<AST_DCL,,M>- 	; AST HAS BEEN DECLARED FOR 

-			; WAITING STREAM 

		<LKDINWS,,M>- 	; BUFFER IS LOCKED IN WORKING SET 

		>	

			.BLKB	1 

$DEF	BDB$B_USECNT		 	; USE COUNT (NOT USED FOR SEQ. ORG) 

			.BLKB	1 

$DEF	BDB$L_OWN		 		; IRAB ADDR OF OWNING STREAM 

			.BLKL	1 

$DEF	BDB$W_NUMB		 	; # OF BYTES OF BUFFER IN USE 

			.BLKW	1 

$DEF	BDB$W_SIZE		 	; # BYTES IN BUFFER 

			.BLKW	1 

$DEF	BDB$L_ADDR		 	; ADDRESS OF BUFFER 

			.BLKL	1 

$DEF	BDB$L_VBN		 		; 1ST VBN IN BUFFER 

			.BLKL	1 

$DEF	BDB$L_WAIT		 	; WAIT THREAD (IRAB ADDR) 

			; (FOR INTER-STREAM INTRA- 

			;  PROCESS LOCKING ONLY) 

			 

			.BLKL	1 

$DEF	BDB$L_WK1		 		; WORK AREA 

$DEF	BDB$B_REL_VBN		 	; CURRENT VBN REL TO START OF BUFFER 

			.BLKB	1 

$DEF	BDB$B_VAL_VBNS		 	; # OF VALID VBNS IN BUFFER 

			.BLKB	1 

$DEF	BDB$B_PRE_CCTL		 	; UNIT RECORD CARRIAGE CONTROL BYTE ('PRE') 

			.BLKB	1 

$DEF	BDB$B_POST_CCTL		 	; UNIT RECORD CARRIAGE CONTROL BYTE ('POST') 

			.BLKB	1 

$DEF	BDB$L_CURBUFADR		 	; CURRENT BUFFER ADDR 

			.BLKL	1 

	. = 28 		; RE-USE FOR I/O STATUS BLOCK 

			.BLKL	1 

$DEF	BDB$L_IOSB		 	; I/O STATUS BLOCK FOR BUFFER 

			.BLKL	2 

$DEF	BDB$C_BLN

$DEF	BDB$K_BLN				; LENGTH OF BDB BLOCK 



	$DEFEND	BDB,$GBL,DEF



	.ENDM	$BDBDEF

 

; 

;	RLB FIELD DEFINITIONS 

; 

;  RECORD LOCK BLOCK (RLB) 

; 

;  THE RLB DESCRIBES ONE LOCKED RECORD FOR A PARTICULAR 

;  PROCESS-RECORD STREAM (RAB/IRAB). IF THE OWNER FIELD 

;  IS 0 THEN THE RLB IA AVALIABLE FOR USE. OTHERWISE, IT 

;  DESCRIBES A LOCKED RECORD. NOTE: WHEN OWNER IS 0 THE 

;  RECORD RFA FIELDS ARE ZEROED (0). 

; 

	.MACRO	$RLBDEF,$GBL



	$DEFINI	RLB,$GBL



 

$DEF	RLB$L_LNK		 		; LINK TO NEXT RLB 

			.BLKL	1 

$DEF	RLB$L_OWNER		 	; OWNER ID FOR LOCKED RECORD 

$DEF	RLB$W_PID		 	; ID PART OF PROCESS ID (PID) 

			.BLKW	1 

$DEF	RLB$W_ISI		 	; ISI FOR STREAM 

			.BLKW	1 

$DEF	RLB$B_BID		 		; BLOCK ID 

$EQU	RLB$C_BID	14		; RLB CODE 

			.BLKB	1 

$DEF	RLB$B_BLN		 		; BLOCK LENGTH IN LONGWORDS 

			.BLKB	1 

$DEF	RLB$W_RFA4		 	; 3'RD WORD OF RECORDS RFA 

			; OFFSET FOR SEQ F.O. (BITS 0:14) 

			; ALWAYS 0 FOR REL F.O. (BITS 0:14) 

$DEF	RLB$B_ID		 	; ID FOR IDX F.O. (BITS 8:14 ARE 0) 

	$VIELD	RLB,0,<-  

		<,15,M>-  

		<ALLOWREAD,,M>- 	; ALLOW READER ACCESS TO LOCK RECORD FLAG (BIT 15) 

		>	

			.BLKB	1 

			.BLKB	1 

$DEF	RLB$L_RFA0		 	; 1'ST AND 2'ND WORDS OF RECORD'S RFA 

			; SEQ F.O. VBN 

			; REL F.O. RELATIVE RECORD NUMBER 

			; IDX F.O. START VBN 

			.BLKL	1 

$DEF	RLB$C_BLN

$DEF	RLB$K_BLN				; LENGTH OF RLB 



	$DEFEND	RLB,$GBL,DEF



	.ENDM	$RLBDEF

 

; 

;	 PROLOGUE FIELD DEFINITIONS 

; 

; 

;  COMMON VBN1 FORMAT FOR INDEXED AND RELATIVE FILES 

; 

;  (NOTE: INDEXED FILE DEFINTIONS NOT INCLUDED AT THIS TIME) 

; 

	.MACRO	$PLGDEF,$GBL



	$DEFINI	PLG,$GBL



 

				 		; LEAVE SPACE FOR INDEXED FILE THINGS 

			.BLKB	11 

$DEF	PLG$B_DBKTSIZ		 	; DATA BUCKET SIZE 

			.BLKB	1 

				 		; FILLER 

			.BLKL	1 

$DEF	PLG$B_FLAGS		 	; FLAG BITS 

	$VIELD	PLG,0,<-  

		<NOEXTEND,,>- 	; NO EXTEND ALLOWED (REL) 

		>	

			.BLKB	1 

				 		; SPACE FILLER 

			.BLKB	85 

$DEF	PLG$B_AVBN		 	; VBN OF FIRST AREA DESCRIPTOR 

			.BLKB	1 

$DEF	PLG$B_AMAX		 	; MAXIMUM NUMBER OF AREAS 

			.BLKB	1 

$DEF	PLG$W_DVBN		 	; FIRST DATA BUCKET VBN 

			.BLKW	1 

				 		; SPARE 

			.BLKW	1 

$DEF	PLG$L_MRN		 		; MAXIMUM RECORD NUMBER (REL) 

			.BLKL	1 

$DEF	PLG$L_EOF		 		; EOF VBN (REL) 

			.BLKL	1 

$DEF	PLG$W_VER_NO		 	; VERSION NUMBER 

$EQU	PLG$C_VER_NO	1		; CURRENT PROLOG VERSION NUMBER 

			.BLKW	1 

$DEF	PLG$C_BLN

$DEF	PLG$K_BLN		 



	$DEFEND	PLG,$GBL,DEF



	.ENDM	$PLGDEF

; 

; 

;  RELATIVE FILE DELETION CONTROL BYTE BIT DEFINITIONS 

; 

	.MACRO	$DLCDEF,$GBL



	$DEFINI	DLC,$GBL



 

	$VIELD	DLC,0,<-  

		<,2,M>- 		; (START WITH BIT 2) 

		<DELETED,,M>- 		; RECORD DELETED 

		<REC,,M>- 		; RECORD EXISTS (BUT MAY HAVE BEEN DELETED) 

		>	



	$DEFEND	DLC,$GBL,DEF



	.ENDM	$DLCDEF

 

; 

;  DIRECTORY CACHE NODE DEFINITIONS 

; 

	.MACRO	$DRCDEF,$GBL



	$DEFINI	DRC,$GBL



 

$DEF	DRC$L_NXTFLNK		 	; LINK TO NEXT ENTRY, THIS LEVEL 

			.BLKL	1 

$DEF	DRC$L_NXTBLNK		 	; LINK TO PREVIOUS ENTRY, THIS LEVEL 

			.BLKL	1 

$DEF	DRC$L_LVLFLNK		 	; LINK TO FIRST ENTRY, NEXT LOWER LEVEL 

			.BLKL	1 

$DEF	DRC$L_LVLBLNK		 	; LINK TO LAST ENTRY, NEXT LOWER LEVEL 

			; NOTE: THE LINKS ARE MAINTAINED IN LRU ORDER 

			.BLKL	1 

$DEF	DRC$T_NAME		 	; DIRECTORY NAME OR DEVICE AND UNIT 

			; NOTE: STORED AS COUNTED STRING COUNTING COUNT ITSELF 

			.BLKB	10 

$DEF	DRC$W_DID		 	; FILE ID FOR DIRECTORY 

$DEF	DRC$W_DIRSEQ		 	; DIRECTORY SEQUENCE # FOR DEVICE NODE 

			.BLKW	1 

			.BLKW	2 

$DEF	DRC$C_BLN

$DEF	DRC$K_BLN				; LENGTH OF DIRECTORY CACHE NODE 



	$DEFEND	DRC,$GBL,DEF



	.ENDM	$DRCDEF

 

 

; 

;		RELEASE OPTION FLAG DEFINITIONS 

; 

	.MACRO	$RLSDEF,$GBL



	$DEFINI	RLS,$GBL



 

	$VIELD	RLS,0,<-  

		<RETURN,,M>- 		; RETURN BUFFER AND BDB TO FREE SPACE LISTS 

		<WRT_THRU,,M>- 	; WRITE BUFFER IF DIRTY 

		<KEEP_LOCK,,M>- 	; KEEP BDB LOCKED 

		<KEEP_ACC,,M>- 	; KEEP BDB ACCESSED ON I/O ERROR 

		>	



	$DEFEND	RLS,$GBL,DEF



	.ENDM	$RLSDEF

; 

;		CACHE OPTION FLAG DEFINITIONS 

; 

	.MACRO	$CSHDEF,$GBL



	$DEFINI	CSH,$GBL



 

	$VIELD	CSH,0,<-  

		<LOCK,,M>- 		; OBTAIN EXCLUSIVE ACCESS TO BLOCK 

		<NOWAIT,,M>- 		; DO NOT WAIT FOR BLOCK ON ACCESS INTERLOCK 

-			; COLLISION 

		<NOREAD,,M>- 		; DO NOT READ IN BLOCK 

		<READAHEAD,,M>- 	; START TRANSFER FOR BLOCK BUT DON'T WAIT 

-			; FOR IO DONE 

		<NOBUFFER,,M>- 	; OBTAIN ACCESS TO BLOCK BUT DON'T ALLOCATE 

-			; A BUFFER FOR IT AND DON'T READ IT 

		>	



	$DEFEND	CSH,$GBL,DEF



	.ENDM	$CSHDEF

 

; 

; 

;  RMS OVERALL STATUS BIT DEFINITIONS 

; 

	.MACRO	$PIODEF,$GBL



	$DEFINI	PIO,$GBL



 

	$VIELD	PIO,0,<-  

		<INHAST,,>- 		; SET IF ASTS IMPLICITLY INHIBITED 

-			; IF RESET BY DISABLED AST, AST MUST BE RE- 

-			; ENABLED 

		<EOD,,>- 		; SET IF SEARCHING FOR 'EOD' STRING ON 'INPUT' 

		<SYNC1,,>- 		; SYNC STALLED OPERATION USING EFN 27 

		<SYNC2,,>- 		; SYNC STALLED OPERATION USING EFN 28 

		>	



	$DEFEND	PIO,$GBL,DEF



	.ENDM	$PIODEF

 

 

; 

;	DEFINITIONS FOR RMS DEBUG FAILURE CODES 

; 

; 

;  THE FOLLOWING CODES ARE FOR TEMPORARY BUG CHECK TESTS, AND ARE 

;  INTERNAL TO RMS.  ALL OF THE CODES ARE NEGATIVE, IMPLYING THAT THEY 

;  DO NOT RETURN TO THE CALLER, PROBABLY KILLING THE PROCESS (IF NOT 

;  THE ENTIRE SYSTEM). 

; 

	.MACRO	$FTLDEF,$GBL



	$DEFINI	FTL,$GBL



 

$EQULST FTL$_,$GBL,0,1,<-  

		<SETPRTFAIL,-1>- 	;SET PROTECTION SYSTEM SERVICE FAILED (RM0BUFMGR) 

		<STKTOOBIG,-2>- 	;STACK TOO BIG FOR ASB (RM0STALL) 

		<BADIFAB,-3>- 	;INVALID IFAB (OR IRAB) (RM0FSET,RM0CONN,RM0RSET, 

-			; RM0PRFLNM) 

		<GTCHNFAIL,-4>- 	;GET CHANNEL SYSTEM SERVICE FAILURE (RM0PRFLNM) 

		<BADORGCASE,-5>- 	;INVALID ORGCASE VALUE FOR DISPATCH (ALL RMS$ 

-			; LEVEL ROUTINES EXECEPT OPEN AND CREATE) 

		<BADBDB,-6>- 	;BLOCK NOT A BDB (RM0BUFMGR) 

		<ASBALLFAIL,-7>- 	;COULDN'T ALLOCATE AN ASB (RM0STALL) 

		<BADASTPRM,-8>- 	;AST PARAMETER NOT A VALID IFAB/IRAB ADDR (RM0STALL) 

		<CANTDOAST,-9>- 	;COULDN'T REDECLARE AST (INSF. MEM.) (RM0STALL) 

		<NOSTRUCT,-10>- 	;RAB OR FAB NOT SAME ON AST (RM0STALL) 

		>

$EQULST FTL$_,$GBL,,1,<-

		<NOASB,-11>- 	;ASB NOT ALLOCATED OR STREAM NOT BUSY ON AST (RM0STALL) 

		<NONXTBDB,-12>- 	;NO NEXT BDB AVAILABLE (RM1SEQXFR) 

		<BADBUFSIZ,-13>- 	;DISK BUFFER SIZE NOT = 512 (RM1CONN) 

-			; (-14, -15, -16 NO LONGER USED) 

		<DEALLERR,-17>- 	;IFAB DEALLOCATION ATTEMPTED WITH OTHER BLOCK(S) 

-			; STILL ALLOCATED (RMS0CLOSE) 

		<IORNDN,-18>- 	;I/O RUNDOWN INCONSISTENCY (EITHER IFAB OR IRAB 

-			; TABLE ENTRIES NOT ZEROED) (RMS0RNDWN) 

		<XFERSIZE,-19>- 	;SIZE OF REQUESTED TRANSFER NOT EQUAL TO 

-			; OR LESS THAN THE CURRENT NUMBER OF BYTES 

-			; IN USE FOR THE BDB (RM0CACHE) 

		<NOTLOCKED,-20>- 	;BDB NOT LOCKED AND A KEEP LOCK REQUEST 

-			; WAS MADE ON A RELEASE REQUEST. 

		<NODIDORFID,-21>- 	;NEITHER A FID NOR A DID WAS SET UPON EXIT FROM 

-			; RM$SETDID (RMS0ERASE) 

		<RELEASFAIL,-22>- 	;RELEASE OF NON-DIRTY BDB FAILED (RM0XTND23,RMS0EXTEND) 

		<NOLOCKBDB,-23>- 	;NO LOCK BDB FOUND (RM0XTND23) 

		<NONETWORK,-24>- 	;network routine entered but no network support in RMS 

		>

$EQULST FTL$_,$GBL,,1,<-

		<LOCKFAILED,-25>- 	;FAILED TO LOCK PROLOG (RM2CREATE) 

		<BADLEVEL,-26>- 	;to search by id, structure level must be 0 

		>

 



	$DEFEND	FTL,$GBL,DEF



	.ENDM	$FTLDEF

 

; 

;  THE FOLLOWING INTERNAL CODES ARE FOR NON-FATAL BUG CHECK REPORTING. 

;  THESE CODES ARE POSITIVE BYTE VALUES.  THEY TRIGGER A REPORTING ACTION 

;  AND RETURN TO THE CALLER WITH R0 SET TO RMS$_BUG+<8*THE BUG CODE>, 

;  WHICH IS AN EXTERNALLY DOCUMENTED RMS ERROR CODE. 

; 

	.MACRO	$BUGDEF,$GBL



	$DEFINI	BUG,$GBL



 

$EQULST BUG$_,$GBL,0,1,<-  

		<BADDFLTDIR,1>- 	;DEFAULT DIRECTORY STRING INVALID (RM0XPFN) 

		>

 



	$DEFEND	BUG,$GBL,DEF



	.ENDM	$BUGDEF

