Google
 

Trailing-Edge - PDP-10 Archives - cuspjul86upd_bb-jf24a-bb - 10,7/galaxy/nebprm.mac
There are 8 other files named nebprm.mac in the archive. Click here to see a list.
UNIVERSAL NEBPRM - GALAXY-10 Network Queue Controller parameter file
SUBTTL	D. P. Mastrovito & Joseph A. Dziedzic /DPM/JAD


;
;
;	      COPYRIGHT (c) DIGITAL EQUIPMENT CORPORATION
;                               1986.
;			ALL RIGHTS RESERVED.
;
;
;     THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY  BE  USED
;     AND COPIED ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE
;     AND WITH THE INCLUSION OF THE ABOVE COPYRIGHT NOTICE.   THIS
;     SOFTWARE  OR ANY OTHER COPIES THEREOF MAY NOT BE PROVIDED OR
;     OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.  NO  TITLE  TO
;     AND OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
;
;     THE INFORMATION  IN  THIS  SOFTWARE  IS  SUBJECT  TO  CHANGE
;     WITHOUT  NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT
;     BY DIGITAL EQUIPMENT CORPORATION.
;
;     DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR RELIABILITY
;     OF  ITS  SOFTWARE  ON  EQUIPMENT  WHICH  IS  NOT SUPPLIED BY
;     DIGITAL.


	NEBVER==1		;MAJOR VERSION
	NEBMIN==0		;MINOR VERSION
	NEBWHO==0		;WHO LAST PATCHED
	NEBEDT==6		;EDIT LEVEL
SUBTTL	Revision history


COMMENT	\

1	Conception.
	17-Jun-86  GCO 10418  /DPM/JAD

2	Add revision history, zero relative file number when starting to
	process remote create, accept remote queue name from QUEUE when
	doing a remote queue list.
	18-Jun-86  GCO 10422  /JAD

3	Fix bug in NEBDCN which prevents us from releasing stale channels
	after we're done with them.
	27-Jun-86  GCO 10427  /JAD

4	Fix lower case conversion of /CHARACTERISTICS
	27-Jun-86  GCO 10428  /TL

5	Implement an output "fairness counter" which prevents a transfer
	request stream from running "forever" if it never gets blocked
	due to flow control, filling all available buffers, etc.
	30-Jun-86  GCO 10430  /JAD

6	Check ITN rather than object block on a QUASAR ABORT message.
	30-Jun-86  GCO 10431  /JAD

\; END OF COMMENT

	DNNDA%==10		;NODE IS IN DIFFERENT AREA
				; (UNTIL IT'S DEFINED IN FIELD IMAGE UUOSYM)
SUBTTL	Module initialization macro


;MACRO TO INITIALIZE A MODULE
DEFINE	MODULE	(NAM),<

	XLIST			;;SUPPRESS LISTING

	SALL			;;FOR CLEAN LISTINGS
	.DIREC	FLBLST		;;FOR CLEANER LISTINGS

	SEARCH	JOBDAT		;;TOPS-10 JOB DATA SYMBOLS
	SEARCH	GLXMAC		;;GENERAL GALAXY SYMBOLS
	SEARCH	QSRMAC		;;QUASAR SYMBOLS
	SEARCH	ORNMAC		;;OPERATOR SYMBOLS

IFIDN	<NAM><NEBPRM>,<		;;SPECIAL CHECK FOR PARAMETER MODULE
	SEARCH	UUOSYM		;;NEED TOPS-10 SYMBOLS
>

IFDIF	<NAM><NEBPRM>,<		;;SPECIAL CHECK FOR OTHER MODULES
	PROLOG ('NAM)		;;KEEP GLXLIB HAPPY
	GLOB	<G$PGM,G$NAM>	;;FOR $TEXT
>
	RELOC	0		;;START LOADING HERE

	LIST			;;TURN ON LISTING

	%%.NEB==:<VRSN.(NEB)>	;;ASSEMBLE VERSION NUMBER

> ;END MODULE MACRO

	MODULE	(NEBPRM)
SUBTTL	Assembly parameters


ND	PRCN,^D20		;MAXIMUM NUMBER OF PROCESSING STREAMS
ND	LSTN,^D10		;MAXIMUM NUMBER OF LISTING STREAMS
ND	PDLMSZ,^D100		;PDL SIZE FOR MAIN TOP LEVEL SCHEDULER
ND	PDLSSZ,^D100		;PDL SIZE FOR STREAM
ND	GLBPSV,^D4		;NUMBER OF SPARE GLOBAL PSI VECTORS
ND	JOBPSV,^D2		;NUMBER OF PSI VECTORS PER STREAM
ND	ZZTIME,0		;WAKE ONLY ON INTERRUPTS
ND	UPDTIM,^D60*3		;NUMBER OF SECONDS BETWEEN STATUS UPDATES
ND	REQTIM,^D5		;NUMBER OF MINUTES TO REQUEUE JOBS
ND	OUTFCT,^D2		;MAXIMUM NUMBER OF CONCURRENT OUTPUT BUFFERS
				; FILLED BEFORE DESCHEDULING A STREAM
ND	BFSBYT,^D512		;BUFFER SIZE IN BYTES
XP	BFSWRD,<<BFSBYT+3>/4>	;BUFFER SIZE IN WORDS


SUBTTL	Parameters not easily changed


	JOBN==PRCN+LSTN		;TOTAL NUMBER OF STREAMS
	TIMLVL==0		;TIMER INTERRUPT PRIORITY LEVEL


;ACCUMULATOR DEFINITIONS

	S==14			;STATUS FLAGS
	R==15			;STREAM RELOCATION
	M==16			;IPCF MESSAGE
SUBTTL	I/O dispatch vector definitions


	IOLNK==1		;LINKED LIST FOR I/O VECTORS

	 .ORG	0
.IOLNK:! BLOCK	1		;LINK TO NEXT VECTOR
.IOABV:! BLOCK	1		;SIXBIT ABBREVIATION
.IONAM:! BLOCK	1		;DRIVER NAME
.IONTY:! BLOCK	1		;NETWORK TYPE CODE
.IOINI:! BLOCK	1		;INITIALIZE
.IOINF:! BLOCK	1		;RETURN INFORMATION ABOUT NODE
.IOOPN:! BLOCK	1		;OPEN
.IOCLS:! BLOCK	1		;CLOSE
.IOINP:! BLOCK	1		;BUFFER INPUT
.IOOUT:! BLOCK	1		;BUFFER OUTPUT
.IOABO:! BLOCK	1		;ABORT LINK
.IOSIA:! BLOCK	1		;SKIP IF INPUT AVAILABLE
.IOUUE:! BLOCK	1		;UUO TRANSLATION TABLE
.IOLEN::!			;LENGTH OF BLOCK
	 .ORG


;MACRO TO GENERATE VECTOR
DEFINE	IOVEC	(ABV,NAM),<
ABV::	XWD	0,0		;;LINK TO NEXT DISPATCH DEVTOR
	.LINK	IOLNK,'ABV
	SIXBIT	/   'ABV/	;;SIXBIT ABBREVIATION
	IFIW	[ASCIZ |'NAM|]	;;NAME
	XWD	0,ST.'ABV	;;NETWORK TYPE CODE
	IFIW	ABV'INI		;;INITIALIZE
	IFIW	ABV'INF		;;RETURN INFORMATION ABOUT NODE
	IFIW	ABV'OPN		;;OPEN
	IFIW	ABV'CLS		;;CLOSE
	IFIW	ABV'INP		;;BUFFER INPUT
	IFIW	ABV'OUT		;;BUFFER OUTPUT
	IFIW	ABV'ABO		;;ABORT LINK
	IFIW	ABV'SIA		;;SKIP IF INPUT AVAILABLE
	IFIW	ABV'UUE		;;UUO ERROR TRANSLATION TABLE

> ;END IOVEC MACRO
SUBTTL	UUO error translation


;MACRO TO GENERATE A TABLE OF OPCODES AND TRANSLATION TABLE POINTERS
DEFINE	UUO	(OPC,LEN,TAB),<
	OPC	0,0		;;OPCODE
	SIXBIT	/OPC/		;;OPCODE NAME
	XWD	-LEN,TAB	;;TRANSLATION TABEL
> ;END DEFINE UUO
SUBTTL	Job data base


	 .ORG	0

;QUASAR DATA
				;*** THE EQ PAGE MUST BE FIRST ***
.JQEQP:! BLOCK	PAGSIZ		;EQ PAGE
				;*** OTHER DATA FOLLOWS IN ANY ORDER ***
.JQOBJ:! BLOCK	OBJ.SZ		;OBJECT BLOCK
.JQCHK:! BLOCK	1		;JOB CHECKPOINT FLAG
.JQCRQ:! BLOCK	EQCKSZ		;CHECKPOINT/REQUEUE INFORMATION
.JQRQF:! BLOCK	1		;REQUEUE FLAGS
.JQTRS:! BLOCK	1		;TIME REQUEST STARTED PROCESSING
.JQLUT:! BLOCK	1		;LAST STATUS UPDATE TIME
.JQRFN:! BLOCK	1		;RELATIVE FILE NUMBER BEING PROCESSED
.JQCFD:! BLOCK	1		;ADDRESS OF CURRENT FD BEING PROCESSED

;JOB DATA
.JBWSC:! BLOCK	1		;WAIT STATE CODE
.JBFLG:! BLOCK	1		;JOB FLAGS
   JB.INP==1B0			   ;INPUT STREAM
   JB.SPR==1B1			   ;RUN TIMER QUEUED SUBROUTINE IN SCHEDULER
   JB.KIL==1B2			   ;KILL JOB
   JB.ABO==1B3			   ;ABORT LINK IN PROGRESS
.JBACS:! BLOCK	20		;JOB PROCESSOR ACS
.JBPDL:! BLOCK	PDLSSZ		;JOB PROCESSOR PDL
.JBIDN:! BLOCK	21		;IDENTIFYING TEXT
.JBTIM:! BLOCK	1		;TIMER IN SECONDS
.JBTQS:! BLOCK	1		;TIMER QUEUED SUBROUTINE ADDRESS
.JBNOD:! BLOCK	1		;REMOTE NODE NAME/NUMBER
.JBPSI:! BLOCK	1		;PSI VECTOR BLOCK ADDRESS
.JBPSR:! BLOCK	3		;PSI INTERRUPT TO HERE
.JBFCT:! BLOCK	1		;FAIRNESS COUNTER

;NETWORK I/O DATA
.JNIOV:! BLOCK	.IOLEN		;NETWORK I/O DISPATCH VECTOR
.JNIOC:! BLOCK	1		;NETWORK CHANNEL FOR I/O
.JNIOS:! BLOCK	1		;I/O STATUS
.JNARG:! BLOCK	.NSAMX		;NSP. UUO ARGUMENT BLOCK

;FILE STUFF
.JFFOB:! BLOCK	FOB.SZ		;FILE OPEN BLOCK
.JFIFN:! BLOCK	1		;IFN OF CURRENT FILE
;I/O DATA AND BUFFERS
.JIIBR:!			;INPUT BUFFER RING HEADER
.JIIBA:! BLOCK	1		;INPUT BUFFER ADDRESS
.JIIBP:! BLOCK	1		;INPUT BUFFER BYTE POINTER
.JIIBC:! BLOCK	1		;INPUT BUFFER BYTE COUNT
.JIIBF:! BLOCK	BFSWRD		;INPUT BUFFER
.JIOBR:!			;OUTPUT BUFFER RING HEADER
.JIOBA:! BLOCK	1		;OUTPUT BUFFER ADDRESS
.JIOBP:! BLOCK	1		;OUTPUT BUFFER BYTE POINTER
.JIOBC:! BLOCK	1		;OUTPUT BUFFER BYTE COUNT
.JIOBF:! BLOCK	BFSWRD		;OUTPUT BUFFER

;LISTING ROUTINE VARIABLES
.JLPID:! BLOCK	1		;PID OF LIST REQUEST ORIGINATOR
.JLCOD:! BLOCK	1		;ACK CODE FOR MESSAGE ORIGINATOR
.JLTYP:! BLOCK	1		;REQUEST TYPE (0 = USER, -1 = OPR)
.JLQNM:! BLOCK	QNMLEN		;QUEUE NAME TO LIST (ZERO IF ALL)
.JLPAG:! BLOCK	1		;ADDRESS OF LISTING PAGE
.JLMPT:! BLOCK	1		;ZERO IF QUEUE EMPTY
.JLNJL:! BLOCK	1		;NUMBER OF JOBS LISTED
.JLNAJ:! BLOCK	1		;NUMBER OF ACTIVE JOBS LISTED
.JLNRM:! BLOCK	1		;NO ROOM LEFT IN OUTPUT PAGE FLAG
.JLCRF:! BLOCK	1		;LAST OUTPUT WAS CRLF FLAG
.JLBPT:! BLOCK	1		;BYTE POINTER INTO OUTPUT PAGE
.JLBCT:! BLOCK	1		;BYTE COUNT REMAINING IN OUTPUT PAGE
.JLDAA:! BLOCK	1		;ADDRESS OF DATA AREA IN OUTPUT PAGE

.JWRDS:!			;LENGTH OF DATA BASE IN WORDS
.JPAGS==1+<<.JWRDS-1>/PAGSIZ>	;LENGTH OF DATA BASE IN PAGES
	 .ORG

SUBTTL	Job states


;*** NOTE ***
;WAIT STATE 'RUN' MUST BE FIRST IN LIST

DEFINE	WSTATE,<

X	RUN,<Running>
X	WCC,<Waiting for connect confirm>
X	WRC,<Waiting for remote connect>
X	WDC,<Waiting for disconnect confirm>
X	OUT,<Output data request queued>
X	INP,<Input data request queued>
X	IDL,<Idle>

> ;END DEFINE WSTATE

	ZZ==-1
DEFINE	X	(NAM,TXT),<.WS'NAM==<ZZ==ZZ+1>>
	WSTATE
	PURGE	ZZ
SUBTTL	Job control macros


;MACRO TO RESCHEDULE A STREAM
;ARGUMENTS:	WSC = OPTIONAL WAIT STATE CODE
;		TIM = OPTIONAL TIME IN SECONDS
;
;IF COD = -1, WAIT STATE WILL NOT BE SET
;IF TIM = -1, TIMER WILL NOT BE SET

DEFINE	SCDSET	(COD,TIM),<

	GLOB	<SSCHED>
	PUSHJ	P,SSCHED
	<300>B8+<COD&777>B17+<TIM&777777>B35

> ;END DEFINE SCDSET
SUBTTL	Listing Control Macros


DEFINE	$ASCII(MSG),<
	PUSHJ	P,ASCOUI	;;CALL IN-LINE ASCII TEXT PROCESSOR
	CAI	[ASCIZ |MSG|]	;;ADDRESS OF THE TEXT
>; END DEFINE $ASCII
SUBTTL	Byte pointer macros


;MACRO TO CREATE A BYTE POINTER TO A BYTE IN A MESSAGE.
;ARGUMENTS:	OFS - BYTE OFFSET INTO MESSAGE
;		ADR - ADDRESS OF MESSAGE

DEFINE	BYTPNT	(OFS,ADR),<

	$$$WRD==OFS/4		;;WORD OFFSET
	$$$POS==<<<OFS&3>+1>*8>-1 ;;POSITION OF RIGHT-MOST BIT

	POINT	8,$$$WRD+ADR,$$$POS

>; END DEFINE BYTPNT
SUBTTL	Forms and characteristics type table entry formats

	.ORG	0

FT.COD:!BLOCK	1		;FORMS TYPE VALUE (BINARY)
FT.NAM:!BLOCK	FRMSIZ		;ASCII FORMS NAME
FT.SIZ:!			;SIZE OF AN ENTRY

	.ORG


	.ORG	0

CT.COD:!BLOCK	1		;CHARACTERISTICS TYPE VALUE (BINARY)
CT.NAM:!BLOCK	CHRSIZ		;ASCII CHARACTERISTIC NAME
CT.SIZ:!			;SIZE OF AN ENTRY

	.ORG
SUBTTL	DJS Protocol Definitions


	RADIX	5+5

;Message types

	.MTCRE==2		;CREATE
	.MTPAR==3		;PARAMETER
	.MTFSP==4		;FILE SPEC
	.MTFDT==5		;FILE DATA
	.MTEOF==6		;END OF FILE
	.MTEOR==7		;END OF RECORD
	.MTCOM==8		;COMMIT
	.MTWIT==9		;WITHDRAW
	.MTCAN==10		;CANCEL
	.MTDIS==11		;DISPLAY
	.MTMOD==12		;MODIFY
	.MTSUM==13		;SUMMARY
	.MTERR==15		;ERROR
	.MTEND==16		;END


;Block types for the ENVIRONMENT message (not used)

;	.BTPVN==1		;PROTOCOL VERSION
;	.BTBFS==3		;BUFFER SIZE
;	.BTSUP==4		;SUPPORTED FEATURES
;	.BTOST==5		;OPERATING SYSTEM TYPE
;Block types for the CREATE, MODIFY, CANCEL, DISPLAY, and SUMMARY
;messages - note that each message does not necessarily support
;all of the block types listed

	.BTJNB==1		;JOB NUMBER
	.BTJNA==3		;JOB NAME
	.BTJOW==4		;JOB OWNER
	.BTQUE==5		;QUEUE NAME
	.BTJBS==6		;JOB STATE
	.BTRJN==9		;REQUESTOR JOB NUMBER
	.BTTXT==10		;TEXT
	.BTJCT==11		;JOB COUNT
	.BTPGL==12		;PAGE LIMIT
	.BTPRI==13		;PRIORITY
	.BTAFT==14		;AFTER TIME
	.BTNOA==16		;NOTIFY ACTION
	.BTPVN==18		;PROTOCOL VERSION NUMBER
	.BTACT==19		;ACCOUNT NAME
	.BTJID==20		;JOBID LIST
	.BTCAS==21		;CASE TYPE
	.BTFRM==22		;FORMS TYPE
	.BTCHR==23		;CHARACTERISTICS
		.LNCHR==^D16		;LENGTH OF CHARACTERISTICS BYTE STRING
	.BTAJB==24		;ALL JOBS
	.BTNON==29		;NOTIFY NAME
	.BTFNT==30		;FONT NAME
	.BTP01==31		;PARAMETER 1
	.BTP02==32		;PARAMETER 2
	.BTP03==33		;PARAMETER 3
	.BTP04==34		;PARAMETER 4
	.BTP05==35		;PARAMETER 5
	.BTP06==36		;PARAMETER 6
	.BTP07==37		;PARAMETER 7
	.BTP08==38		;PARAMETER 8
	.BTNOT==39		;NOTE
	.BTTMQ==40		;TIME QUEUED
;Block types for the FILE SPEC message

	.BTFNM==6		;FILE NAME
	.BTFTY==8		;FILE DATA TYPE
	.BTFCC==11		;COPIES
	.BTFSE==12		;SEPARATOR
		SE.HDR==1		;FILE HEADERS
		SE.BST==2		;BURST
		SE.TRL==4		;TRAILERS
	.BTFEP==14		;END PAGE
	.BTFBL==15		;BLANK LINES
	.BTFPO==17		;PAGE OPTION
		PO.PAG==1		;PAGINATE
		PO.LFS==2		;LISTFILESPEC (NOT SUPPORTED)
	.BTFOR==18		;FAB ORG
	.BTFAT==19		;FAB RAT
	.BTFRS==20		;FAB MRS
	.BTFRN==21		;FAB MRN
	.BTFFM==22		;FAB RFM
	.BTFSZ==23		;FAB FSZ
	.BTFBK==24		;FAB BKS
	.BTFGB==25		;FAB GBC
	.BTFOP==26		;FAB FOP
	.BTFAL==27		;FAB ALQ
	.BTFSP==28		;START PAGE
	.BTFST==29		;FILE SETUP


;Block types for the FILE DATA message

	.BTDAT==1		;DATA TRANSFER
;Block types for the ERROR message

	.BTEEL==1		;ERROR LEVEL
	.BTEEC==2		;ERROR CLASS
	.BTECD==3		;ERROR CODE
	.BTEID==7		;MESSAGE ID
	.BTETX==10		;TEXT


;Status values

	.STHDJ==1		;HOLD WAITING FOR COMMIT
	.STHUS==2		;HOLD BY USER
	.STHOP==3		;HOLD BY OPERATOR
	.STHTI==4		;HOLD UNTIL DESIGNATED TIME
	.STHFT==5		;HOLD WAITING FOR FILE TRANSFER
	.STHRW==6		;HOLD WAITING FOR RESOURCES
	.STSCH==7		;SCHEDULED FOR EXECUTION
	.STEXC==8		;EXECUTION IN PROGRESS
	.STSUS==9		;EXECUTION SUSPENDED BY USER
	.STSOP==10		;EXECUTION SUSPENDED BY OPERATOR
	.STSRQ==11		;EXECUTION SUSPENDED BY JOB REQUEST
	.STSRW==12		;EXECUTION SUSPENDED BY RESOURCE WAIT
	.STCUS==13		;JOB CANCELLED BY USER
	.STCOP==14		;JOB CANCELLED BY OPERATOR
	.STCMK==15		;JOB MARKED FOR CANCELLATION
	.STSUC==16		;JOB COMPLETED (TERMINATED NORMALLY)
	.STFAI==17		;JOB COMPLETED (TERMINATED ABNORMALLY)


;Case types

	.CTANY==1		;ANY
	.CTLOW==2		;LOWER
	.CTUPR==3		;UPPER
	.CTLQP==4		;LQP
;Notify action bits

	NA.CMP==1		;NOTIFY ON COMPLETION
	NA.CHG==2		;NOTIFY ON CHANGE
	NA.TSK==4		;NOTIFY TASK


;Error types

	.ELFAT==4		;FATAL
	.ETWRN==3		;WARNING
	.ETINF==2		;INFORMATIONAL
	.ETSUC==1		;SUCCESS


;Error classes

	.ECRMT==4		;REMOTE
	.ECDJS==3		;DJS
	.ECUNS==2		;UNSUPPORTED
	.ECPRT==1		;PROTOCOL ERROR

	RADIX	4+4
SUBTTL	Definitions of bytes in message header and block


;The first "n" bytes in the DQS message are the message header.
;The contents of these bytes and their names are:

	.HDTYP==0		;MESSAGE TYPE (.MTxxx)
	.HDFLG==1		;FLAGS (NONE DEFINED?)
	.HDCTX==2		;SENDER'S CONTEXT
	.HDBLK==3		;NUMBER OF BLOCKS IN BODY OF MESSAGE
	.HDLNL==4		;LOW ORDER BYTE OF MESSAGE LENGTH
	.HDLNH==5		;HIGH ORDER BYTE OF MESSAGE LENGTH
	.HDSIZ==6		;SIZE OF MESSAGE HEADER


;The first "n" bytes in a DQS message block are the block header.
;The contents of these bytes and their names are:

	.BKTYP==0		;BLOCK TYPE (.BTxxx)
	.BKLNH==1		;HIGH ORDER BYTE OF BLOCK LENGTH
	.BKLNL==2		;LOW ORDER BYTE OF BLOCK LENGTH
	.BKSIZ==3		;SIZE OF BLOCK HEADER
	END