Google
 

Trailing-Edge - PDP-10 Archives - AP-4178E-RM - swskit-sources/red.lis
There is 1 other file named red.lis in the archive. Click here to see a list.
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1


      1						.IDENT	"V001A"
      2						.NLIST	TTM
      3						.NLIST	SYM
      4						.LIST	MEB
      5						.TITLE	REDIRECT
      6					;
      7					;
      8					;
      9					;
     10					;                             COPYRIGHT (C) 1973, 1978 BY
     11					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
     12					;
     13					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
     14					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
     15					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
     16					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     17					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     18					;
     19					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     20					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     21					;       CORPORATION.
     22					;
     23					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     24					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     25					;
     26					;
     27					;
     28					;
     29					;
     30					;
     31					;
     32					;
     33					;		VERSION: V001A
     34					;
     35					;		AUTHOR: R. MCLEAN
     36					;
     37					;		DATE: 19 MAR 73
     38					;
     39					;		MODIFIED BY ELLEN R GORDON
     40					;
     41					;		DATE: 5 NOV 1973
     42					;
     43					;	RSX20F -- R. MCLEAN
     44					;	DATE 20-OCT-75
     45					;
     46					;
     47					;
     48					;
     49					; VERSION V001A
     50					;+
     51					; MCR FUNCTION -- REDIRECT
     52					;
     53					;NOTE -- REDIRECT IS A PRIVILEDGED TASK
     54					;
     55					;NOTE -- REDIRECT USES 1 LUN.
     56					;
     57					;	THIS IS ONLY SUPPOSED TO BE USED
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-1


     58					;	TO REDIRECT SY FOR RSX20F!
     59					;
     60					;
     61					;TASK NAME "...RED" TO REDIRECT ALL I/O REQUESTS
     62					;FROM ONE PHYSICAL DEVICE-UNIT TO ANOTHER.
     63					;ONE LINE OF COMMAND INPUT OF THE FOLLOWING SYNTAX IS USED:
     64					;
     65					;	REDIRECT ::= "RED" $ <NBC> <BC>
     66					;		<NEW DEVICE> ("_"/"=") <OLD DEVICE> <LT>;
     67					;
     68					;		<OLD DEVICE> ::= <DEVICE-UNIT SYMBOL>;
     69					;		<NEW DEVICE> ::= <DEVICE-UNIT SYMBOL>;
     70					;		<DEVICE-UNIT SYMBOL> ::= <LETTER><LETTER>;
     71					;			(OCTAL VALUE/NUL);
     72					;		/ INDICATES ALTERNATION (OR)
     73					;		'$' INDICATES ANY NUMBER OF (INCLUNDING ZERO) OF
     74					;		'NUL' INDICATES THE EMPTY SET
     75					;		<BC> ::= SPACE [BREAK CHARACTER]
     76					;		<NBC> ::= NON-BREAK CHARACTER
     77					;		<LT> ::= <CR>/<AM>; [LINE TERMINATOR]
     78					;		<CR> ::= CARRAGE RETURN
     79					;		<AM> ::= ALTMODE
     80					;		<LETTER> ::= 'A'/'B'/.....'Z'
     81					;		<OCTAL VALUE> ::= 1-3 OCTAL DIGITS
     82					;
     83					;
     84					;	MACRO DEFINITIONS
     85					;-
     86						.MACRO	.QIO	WRIT,LUN,EFN,PRI,IOS,AST,PAR1,PAR2
     87						.BYTE	IO,9.
     88						.WORD	WRIT
     89						.WORD	LUN
     90						.BYTE	EFN,PRI
     91						.WORD	IOS
     92						.WORD	AST
     93						.WORD	PAR1
     94						.WORD	PAR2
     95						.WORD	40
     96						.ENDM
     97					;
     98						.MCALL	CALL,RETURN,DIR$,ALUN$S,QIOW$,WSIG$S,EXIT$S,RQST$,.CRASH
     99						.MCALL	QIO$,.INH
    100					;
    101					;
    102					;	DIRECTIVE DEFINITIONS
    103					;
    104		024577 			RDMCB=41.*400+127.	;READ MCR COMMAND BUFFER
    105		000026 			U.VA=26
    106		000463 			EXIT=1.*400+51.		;EXIT
    107		000003 			IO=3.			;Q I/O
    108		000001 			EFN1=1			;EVENT FLAG 1
    109		000400 			WRIT=400		;WRITE
    110		000002 			LUN=2			;LOGICAL UNIT
    111		000015 			CR=15			;CAR RTN
    112		000012 			LF=12			;LINE FEED
    113		000033 			AM=33			;ALTMODE
    114		000040 			SPA=40			;SPACE
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-2


    115					;
    116					;
    117					;
    118	000000	032767 	000000G	000002G	REDIR:	BIT	#EF.PR1,.COMEF+2 ;PRIMARY PROTOCOL?
    119	000006	001404 				BEQ	10$		;YES -- ALL OK
    120	000010	012746 	001576'			MOV	#SECMSG,-(SP)	;NO -- COMPLAIN
    121	000014	000167 	000662 		5$:	JMP	EXITMS
    122					;
    123	000020	012746 	001276'		10$:	MOV	#RDMCR,-(SP)	;READ THE MCR COMMAND LINE
    124	000024	104375 				EMT	375
    125	000026	103417 				BCS	MCRER1		;ERROR ON TRYING TO READ MCR LINE
    126	000030	012700 	001303'			MOV	#MCRBH+3,R0	;SET UP TO LOOK AT THE MCR BUFFER
    127	000034	112001 			REDSL:	MOVB	(R0)+,R1	;PICK UP A CHARACTER FROM THE BUFFER
    128	000036	022701 	000040 			CMP	#SPA,R1		;IS THIS A BREAK CHARACTER?
    129	000042	001426 				BEQ	FNDBC		;YES -- START DECODING LINE
    130	000044	022701 	000015 			CMP	#CR,R1		;NO -- IS IT A CARRAGE RETURN?
    131	000050	001404 				BEQ	SYNER4		;YES -- SYNTAX ERROR
    132	000052	022701 	000033 			CMP	#AM,R1		;NO -- IS IT AN ALTMODE?
    133	000056	001401 				BEQ	SYNER4		;YES -- SYNTAX ERROR
    134	000060	000765 				BR	REDSL		;NO -- THEN IT IS AN NBC
    135					;
    136	000062	000167 	000706 		SYNER4:	JMP	SYNER
    137					;
    138	000066				MCRER1:	DIR$	#QIOWMC		;PROMPT
	000066	012746 	002202'			MOV	#QIOWMC,-(SP)
	000072	104375 				EMT	375
    139	000074					DIR$	#QIORMC		;READ COMMAND LINE
	000074	012746 	002230'			MOV	#QIORMC,-(SP)
	000100	104375 				EMT	375
    140	000102	012700 	001300'			MOV	#MCRBH,R0	;POINT TO THE COMMAND LINE
    141	000106	016701 	002252 			MOV	STATUS+2,R1	;SET THE TERMINATING CHAR IN BUFFER
    142	000112	116761 	002245 	001300'		MOVB	STATUS+1,MCRBH(R1)
    143					;
    144					;
    145	000120	112067 	001274 		FNDBC:	MOVB	(R0)+,NEWDEV	;PICK UP THE DEVICE NAME (NEW DEVICE
    146	000124	112067 	001271 			MOVB	(R0)+,NEWDEV+1	;BOTH CHARACTERS
    147	000130	012703 	001434'			MOV	#NEWUNA,R3	;SAVE THE ASCII
    148	000134					CALL	PC,GETVAL	;FIND THE UNIT NUMBER
	000134	004767 	001064 			JSR	PC,GETVAL
    149	000140	120127 	000072 			CMPB	R1,#':		;ALLOW COLON AFTER DEVICE
    150	000144	001001 				BNE	1$
    151	000146	112001 				MOVB	(R0)+,R1	;MOVE PAST COLON
    152	000150	120127 	000075 		1$:	CMPB	R1,#'=		;IS THE CHARACTER AN =?
    153	000154	001051 				BNE	SYNER7		;NO -- NEITHER = OR _ THEREFORE SYNTAX ERROR
    154	000156	010267 	001242 		10$:	MOV	R2,NEWUNT	;YES -- SAVE THE NEW UNIT NUMBER
    155	000162	112067 	001234 			MOVB	(R0)+,OLDDEV	;SAVE THE OLD DEVICE NAME
    156	000166	112067 	001231 			MOVB	(R0)+,OLDDEV+1
    157	000172	012703 	001437'			MOV	#OLDUNA,R3	;SAVE THE ASCII DEVICE NAME
    158	000176					CALL	PC,GETVAL	;GET THE UNIT NUMBER OF THE OLD DEVICE
	000176	004767 	001022 			JSR	PC,GETVAL
    159	000202	010267 	001220 			MOV	R2,OLDUNT	;SAVE THE OLD UNIT NUMBER
    160	000206	120127 	000072 			CMPB	R1,#':		;ALLOW COLON AFTER DEVICE
    161	000212	001001 				BNE	2$
    162	000214	112001 				MOVB	(R0)+,R1	;MOVE PAST COLON
    163	000216	120127 	000015 		2$:	CMPB	R1,#CR		;IS THE TERMINATING CHARACTER A CARRTN?
    164	000222	001403 				BEQ	SYNOK		;YES -- SYNTAX IS OK
    165	000224	120127 	000033 			CMPB	R1,#AM		;NO -- IS IT ALTMODE?
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-3


    166	000230	001021 				BNE	SYNER8		;NO -- SYNTAX ERROR
    167	000232	012700 	000000G		SYNOK:	MOV	#.PUDBA,R0	;YES -- FIND THE BEGINNING OF THE PUD
    168	000236	026067 	000000G	001154 	COTSCN:	CMP	U.DN(R0),NEWDEV	;SEARCH FOR A MATCH
    169	000244	001431 				BEQ	FNDNEW		;FOUND MATCH ON NEW UNIT
    170	000246	026067 	000000G	001146 	CNTSCN:	CMP	U.DN(R0),OLDDEV	;SEARCH FOR MATCH ON OLD UNIT ALSO
    171	000254	001413 				BEQ	FNDOLD		;FOUND OLD UNIT MATCH
    172	000256	062700 	000000G		CNTNXT:	ADD	#U.SZ,R0	;ADD THE PUD SIZE TO POINTER FOR NEXT ENTRY
    173	000262	020027 	000000G			CMP	R0,#.PUDEA	;IS THIS THE END OF THE TABLE?
    174	000266	001363 				BNE	COTSCN		;NO -- CONTINUE SCAN
    175	000270	000167 	000514 			JMP	NTFND		;YES -- CAN'T FIND BOTH ENTRIES
    176					;
    177	000274	000167 	000452 		SYNER8:	JMP	SYNER2
    178	000300	000167 	000406 		SYNER7:	JMP	SYNER1
    179					;
    180	000304	126067 	000000G	001114 	FNDOLD:	CMPB	U.UN(R0),OLDUNT	;DO THE UNITS MATCH?
    181	000312	001361 				BNE	CNTNXT		;NO -- CONTINUE SCAN
    182	000314	010067 	001112 			MOV	R0,OLDADR	;YES -- SAVE THE PUD POINTER
    183	000320	005767 	001104 			TST	NEWADR		;HAVE WE FOUND BOTH?
    184	000324	001012 				BNE	FNDBTH		;YES -- STOP SCAN
    185	000326	000753 				BR	CNTNXT		;NO -- CONTINUE SCAN
    186					;
    187	000330	126067 	000000G	001066 	FNDNEW:	CMPB	U.UN(R0),NEWUNT	;DO THE UNITS MATCH?
    188	000336	001343 				BNE	CNTSCN		;NO -- CONTINUE SCAN
    189	000340	010067 	001064 			MOV	R0,NEWADR	;YES -- SAVE THE PUD POINTER
    190	000344	005767 	001062 			TST	OLDADR		;FOUND BOTH?
    191	000350	001736 				BEQ	CNTSCN		;NO -- CONTINUE SCAN
    192	000352	016700 	001054 		FNDBTH:	MOV	OLDADR,R0	;SAVE REDIRECTED ADDRESS
    193	000356	016004 	000000G			MOV	U.RP(R0),R4
    194	000362	012700 	000000G			MOV	#.PUDBA,R0	;YES -- SEARCH PUD FOR ENTRIES REDIRECTED TO OLD
    195	000366	026067 	000000G	001036 	RDLP:	CMP	U.RP(R0),OLDADR	;AND CHANGE TO THE NEW UNIT
    196	000374	001003 				BNE	RDNXT		;NO MATCH -- DON'T UPDATE REDIRECT POINTER
    197	000376	016760 	001026 	000000G		MOV	NEWADR,U.RP(R0)	;YES -- SET UP A NEW REDIRECT POINTER
    198	000404	062700 	000000G		RDNXT:	ADD	#U.SZ,R0	;LOOK AT THE NEXT ENTRY
    199	000410	022700 	000000G			CMP	#.PUDEA,R0	;AT THE END OF THE TABLE?
    200	000414	001364 				BNE	RDLP		;NO -- CONTINUE SCAN
    201	000416	022767 	054523 	000776 		CMP	#"SY,OLDDEV	;OLD DEVICE SY?
    202	000424	001117 				BNE	40$		;NO -- FORGET IT
    203	000426	016401 	000000G			MOV	U.ACP(R4),R1	;FIND THE ACP STD ADDRESS
    204	000432	005211 				INC	@R1		;CHANGE THE NAME OF THE FCP TASK
    205	000434	016700 	000772 			MOV	OLDADR,R0	;YES -- REDIRECT THE OLD PUD
    206	000440	005264 	000000G			INC	U.DACP(R4)	;UPDATE ACP
    207	000444	016705 	000760 			MOV	NEWADR,R5
    208	000450	005765 	000026 			TST	U.VA(R5)	;VOLUME MOUNTED?
    209	000454	001004 				BNE	3$
    210	000456					DIR$	#VOLNM
	000456	012746 	001522'			MOV	#VOLNM,-(SP)
	000462	104375 				EMT	375
    211	000464	000424 				BR	8$
    212					;
    213	000466	010560 	000000G		3$:	MOV	R5,U.RP(R0)
    214	000472	012767 	003000 	001636 		MOV	#3000,COUNT
    215	000500	010146 				MOV	R1,-(SP)	;SAVE STD ADDRESS
    216	000502					DIR$	#F11RQ		;REQUEST NEW F11ACP
	000502	012746 	002340'			MOV	#F11RQ,-(SP)
	000506	104375 				EMT	375
    217	000510				5$:	WSIG$S			;WAIT A WHILE
	000510	012746 				MOV	(PC)+,-(SP)
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-4


	000512	   061 	   001 			.BYTE	49.,1
	000514	104375 				EMT	375
    218	000516	012701 	002356'			MOV	#F11NM,R1	;SEARCH FOR F11ACP TO BE INSTALLED
    219	000522					CALL	..FSTD		;SEARCH
	000522	004767 	000000G			JSR	PC,..FSTD
    220	000526	001020 				BNE	10$		;FOUND IT -- NOW CAN WORK
    221	000530	005367 	001602 		7$:	DEC	COUNT
    222	000534	001365 				BNE	5$
    223	000536				8$:	DIR$	#VOLMS
	000536	012746 	002026'			MOV	#VOLMS,-(SP)
	000542	104375 				EMT	375
    224	000544	005364 	000000G			DEC	U.DACP(R4)
    225	000550					.INH
	000550	016746 	000000G			MOV	PS,-(SP)
	000554	112737 	000000G	000000G		MOVB	#PR7,@#PS	;;
    226	000562					.CRASH	RED
	000562	000004 				IOT
	000564	   122 	   105 	   104 		.ASCIZ	/RED/
	000567	   000
    227					;
    228	000570	032762 	000000G	000000G	10$:	BIT	#SF.IR,S.FW(R2)	;REALLY INSTALLED YET?
    229	000576	001354 				BNE	7$		;NOPE -- CONTINUE WAITING
    230	000600	042762 	000000G	000000G		BIC	#SF.EX,S.FW(R2)	;CLEAR THE REMOVEON EXIT FLAG
    231	000606	005364 	000000G			DEC	U.DACP(R4)	;RESET NAME
    232	000612	012600 				MOV	(SP)+,R0	;RESTORE OLD STD ADDRESS
    233	000614	012705 	000000G			MOV	#.PUDBA,R5	;SET UP ALL THE STD ADDRESSES
    234	000620	026500 	000000G		20$:	CMP	U.ACP(R5),R0	;CORRECT ACP?
    235	000624	001002 				BNE	30$
    236	000626	010265 	000000G			MOV	R2,U.ACP(R5)	;YES -- SET NEW ACP STD ADDRESS
    237	000632	062705 	000000G		30$:	ADD	#U.SZ,R5	;LOOK AT THE NEXT PUD ENTRY
    238	000636	022705 	000000G			CMP	#.PUDEA,R5	;END?
    239	000642	101366 				BHI	20$		;NO -- TRY NEXT ONE
    240	000644	052760 	000000G	000000G		BIS	#SF.EX,S.FW(R0)	;SET REMOVE ON EXIT FOR OLD ONE
    241	000652	005267 	001464 			INC	F11RQ+2		;RUN THIS ONE SO IT GETS REMOVED
    242	000656					DIR$	#F11RQ
	000656	012746 	002340'			MOV	#F11RQ,-(SP)
	000662	104375 				EMT	375
    243	000664	016700 	000540 		40$:	MOV	NEWADR,R0	;CHECK FOR HANDLER RESIDENT
    244	000670	005760 	000000G			TST	U.HA(R0)
    245	000674	001003 				BNE	EXITA		;YES -- NO WARNING MESSAGE
    246	000676	012746 	001442'			MOV	#HNRMSG,-(SP)	;PRINT WARNING MESSAGE
    247	000702	104375 			EXITMS:	EMT	375
    248	000704	012746 	000463 		EXITA:	MOV	#EXIT,-(SP)	;EXIT
    249	000710	104375 				EMT	375
    250					;
    251	000712	116767 	000502 	001011 	SYNER1:	MOVB	NEWDEV,SYNDEV	;SET UP TO PRINT THE DEVICE NAME
    252	000720	116767 	000475 	001004 		MOVB	NEWDEV+1,SYNDEV+1
    253	000726	012703 	001424'			MOV	#NEWUNTA,R3	;SET UP TO FIND THE UNIT NUMBER
    254	000732	012702 	001733'		SYNCOM:	MOV	#SYNUNT,R2	;SET UP THE BUFFER POINTER TO UNIT
    255	000736	012746 	002136'			MOV	#SYNMS1,-(SP)	;PUSH THE DPB ADDRESS
    256	000742	112322 				MOVB	(R3)+,(R2)+	;MOVE IN THE UNIT NUMBER
    257	000744	112322 				MOVB	(R3)+,(R2)+
    258	000746	112322 				MOVB	(R3)+,(R2)+
    259	000750	000754 				BR	EXITMS		;PRINT THE MESSAGE AND WAIT
    260					;
    261	000752	116767 	000444 	000751 	SYNER2:	MOVB	OLDDEV,SYNDEV	;SET UP THE DEVICE NAME
    262	000760	116767 	000437 	000744 		MOVB	OLDDEV+1,SYNDEV+1
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-5


    263	000766	012703 	001437'			MOV	#OLDUNA,R3	;AND UNIT NUMBER
    264	000772	000757 				BR	SYNCOM		;AND PRINT THE MESSAGE
    265	000774	012746 	001660'		SYNER:	MOV	#SYNMSG,-(SP)	;PRINT SYNTAX ERROR
    266	001000	000740 				BR	EXITMS		;WAIT FOR MESSAGE AND EXIT
    267					;
    268					;
    269	001002	012746 	002250'		MCRERR:	MOV	#MCRERM,-(SP)	;WRITE MCR ERROR
    270	001006	000735 				BR	EXITMS		;AND EXIT
    271					;
    272	001010	005767 	000414 		NTFND:	TST	NEWADR		;DIDN'T FIND A MATCH IS IT NEW?
    273	001014	001005 				BNE	NTFNDO		;NO -- MUST BE OLD WE DIDN'T FIND
    274	001016	016700 	000376 			MOV	NEWDEV,R0	;YES -- PRINT DEVICE NAME AND UNIT
    275	001022	016701 	000376 			MOV	NEWUNT,R1	;ON ERROR MESSAGE TTY
    276	001026	000404 				BR	OUTPUU		;BRANCH TO COMMON ERROR ROUTINE
    277					;
    278	001030	016700 	000366 		NTFNDO:	MOV	OLDDEV,R0	;PICK UP THE OLD UNIT NUMBER
    279	001034	016701 	000366 			MOV	OLDUNT,R1	;AND DEVICE NAME
    280	001040	010067 	000716 		OUTPUU:	MOV	R0,INCMSG	;STORE THE DEVICE NAME
    281	001044	012702 	001764'			MOV	#INCMSG+2,R2	;SET UP TO STORE THE UNIT NUMBER
    282		000012 				.REPT	10.
    283						ROL	R1
    284						ROL	R0
    285						.ENDR
	001050	006101 				ROL	R1
	001052	006100 				ROL	R0
	001054	006101 				ROL	R1
	001056	006100 				ROL	R0
	001060	006101 				ROL	R1
	001062	006100 				ROL	R0
	001064	006101 				ROL	R1
	001066	006100 				ROL	R0
	001070	006101 				ROL	R1
	001072	006100 				ROL	R0
	001074	006101 				ROL	R1
	001076	006100 				ROL	R0
	001100	006101 				ROL	R1
	001102	006100 				ROL	R0
	001104	006101 				ROL	R1
	001106	006100 				ROL	R0
	001110	006101 				ROL	R1
	001112	006100 				ROL	R0
	001114	006101 				ROL	R1
	001116	006100 				ROL	R0
    286	001120	042700 	177770 			BIC	#177770,R0	;MASK OFF GARGAGE
    287	001124	005700 				TST	R0		;ZERO SUPPRESS
    288	001126	001403 				BEQ	OUTP1
    289	001130	052700 	000060 			BIS	#60,R0		;MAKE OCTAL
    290	001134	110022 				MOVB	R0,(R2)+	;STORE DIGIT
    291	001136	006101 			OUTP1:	ROL	R1
    292	001140	006100 				ROL	R0
    293	001142	006101 				ROL	R1
    294	001144	006100 				ROL	R0
    295	001146	006101 				ROL	R1
    296	001150	006100 				ROL	R0
    297	001152	042700 	177770 			BIC	#177770,R0	;MASK OFF GARBAGE
    298	001156	005700 				TST	R0		;ZERO SUPPRESS
    299	001160	001403 				BEQ	OUTP2
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-6


    300	001162	052700 	000060 			BIS	#60,R0		;MAKE OCTAL
    301	001166	110022 				MOVB	R0,(R2)+	;STORE
    302	001170	006101 			OUTP2:	ROL	R1
    303	001172	006100 				ROL	R0
    304	001174	006101 				ROL	R1
    305	001176	006100 				ROL	R0
    306	001200	006101 				ROL	R1
    307	001202	006100 				ROL	R0
    308	001204	042700 	177770 			BIC	#177770,R0	;MASK OFF GARBAGE
    309	001210	052700 	000060 			BIS	#60,R0		;NO SUPPRESS
    310	001214	110022 				MOVB	R0,(R2)+	;STORE
    311	001216	012746 	002160'			MOV	#IDVERR,-(SP)	;PRINT MESSAGE
    312	001222	000627 				BR	EXITMS
    313					;
    314					;
    315					;	GETVAL -- ROUTINE TO PICK UP A UNIT NUMBER
    316					;		CALLING SEQUENCE:
    317					;	R0 -- LINE BUFFER POINTER
    318					;	R3 -- POINTER TO SAVE AREA FOR UNTI NUMBER
    319					;	JSR 	PC,GETVAL
    320					;
    321					;	EXIT CONDITIONS
    322					;	R0 -- POINTER TO NEXT CHARACTER IN BUFFER
    323					;	R2 -- OCTAL NUMBER
    324					;
    325	001224	012704 	000004 		GETVAL:	MOV	#4.,R4		;3 OCTAL DIGITS MAX
    326	001230	005002 				CLR	R2		;DEFAULT IS 0
    327	001232	112001 			NXTDIG:	MOVB	(R0)+,R1	;PICK  UP A CHARACTER
    328	001234	122701 	000057 			CMPB	#57,R1		;IS IT LT 60?
    329	001240	100015 				BPL	VALEND		;YES -- END OF DIGIT
    330	001242	122701 	000067 			CMPB	#67,R1		;IS IT GT 67?
    331	001246	100412 				BMI	VALEND		;YES -- END OF DIGIT
    332	001250	110123 				MOVB	R1,(R3)+	;SAVE THE ASCII CHARACTER
    333	001252	042701 	177770 			BIC	#177770,R1	;CONVERT TO OCTAL
    334	001256	006302 				ASL	R2
    335	001260	006302 				ASL	R2
    336	001262	006302 				ASL	R2
    337	001264	042702 	000007 			BIC	#7,R2		;CLEAR OUT JUNK
    338	001270	074102 				XOR	R1,R2		;MOVE IN NEW DIGIT
    339	001272	077421 				SOB	R4,NXTDIG	;END OF SCAN?
    340	001274				VALEND:	RETURN	PC		;YES RETURN TO CALLER
	001274	000207 				RTS	PC
    341					;
    342					;	TEMP STORAGE
    343					;
    344	001276	024577 			RDMCR:	.WORD	RDMCB
    345	001300				MCRBH:	.BLKB	80.		;MCR COMMAND BUFFER
    346	001420	   040 	   040 		NEWDEV:	.ASCII	/  /		;NEW DEVICE NAME
    347	001422	   040 	   040 		OLDDEV:	.ASCII	/  /		;OLD DEVICE NAME
    348	001424				NEWUNT:	.BLKW	1		;NEW UNIT NUMBER
    349	001426				OLDUNT:	.BLKW	1		;OLD UNIT NUMBER
    350	001430				NEWADR:	.BLKW	1		;ADDRESS OF NEW PUD
    351	001432				OLDADR:	.BLKW	1		;ADDRESS OF OLD PUD
    352	001434	   040 	   040 	   040 	NEWUNA:	.ASCII	/   /
    353	001437	   040 	   040 	   040 	OLDUNA:	.ASCII	/   /		;ASCII SAVE AREA FOR UNIT NUMBER
    354					;
    355					;	DIRECTIVES AND MESSAGES
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-7


    356					;
    357					;
    358	001442				HNRMSG:	.QIO	WRIT,LUN,EFN1,0,0,0,HNRBF,HNRSZ
	001442	   003 	   011 			.BYTE	IO,9.
	001444	000400 				.WORD	WRIT
	001446	000002 				.WORD	LUN
	001450	   001 	   000 			.BYTE	EFN1,0
	001452	000000 				.WORD	0
	001454	000000 				.WORD	0
	001456	001464'				.WORD	HNRBF
	001460	000036 				.WORD	HNRSZ
	001462	000040 				.WORD	40
    359					;
    360	001464	   122 	   105 	   104 	HNRBF:	.ASCII	/RED /
	001467	   040
    361	001470	000000 			HNRDEV:	.WORD	0
    362	001472	   040 	   055 	   055 		.ASCII	/ -- HANDLER NOT RESIDENT/
	001475	   040 	   110 	   101
	001500	   116 	   104 	   114
	001503	   105 	   122 	   040
	001506	   116 	   117 	   124
	001511	   040 	   122 	   105
	001514	   123 	   111 	   104
	001517	   105 	   116 	   124
    363						.EVEN
    364		000036 			HNRSZ=.-HNRBF
    365					;
    366	001522				VOLNM:	.QIO	WRIT,LUN,EFN1,0,0,0,VNMSG,VNSZ
	001522	   003 	   011 			.BYTE	IO,9.
	001524	000400 				.WORD	WRIT
	001526	000002 				.WORD	LUN
	001530	   001 	   000 			.BYTE	EFN1,0
	001532	000000 				.WORD	0
	001534	000000 				.WORD	0
	001536	001544'				.WORD	VNMSG
	001540	000031 				.WORD	VNSZ
	001542	000040 				.WORD	40
    367					;
    368	001544	   122 	   105 	   104 	VNMSG:	.ASCII	/RED -- NEW SY NOT MOUNTED/
	001547	   040 	   055 	   055
	001552	   040 	   116 	   105
	001555	   127 	   040 	   123
	001560	   131 	   040 	   116
	001563	   117 	   124 	   040
	001566	   115 	   117 	   125
	001571	   116 	   124 	   105
	001574	   104
    369		000031 			VNSZ=.-VNMSG
    370						.EVEN
    371					;
    372					;
    373	001576				SECMSG:	.QIO	WRIT,LUN,EFN1,0,0,0,SECBF,SECSZ
	001576	   003 	   011 			.BYTE	IO,9.
	001600	000400 				.WORD	WRIT
	001602	000002 				.WORD	LUN
	001604	   001 	   000 			.BYTE	EFN1,0
	001606	000000 				.WORD	0
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-8


	001610	000000 				.WORD	0
	001612	001620'				.WORD	SECBF
	001614	000037 				.WORD	SECSZ
	001616	000040 				.WORD	40
    374					;
    375	001620	   122 	   105 	   104 	SECBF:	.ASCII	/RED -- PRIMARY PROTOCOL RUNNING/
	001623	   040 	   055 	   055
	001626	   040 	   120 	   122
	001631	   111 	   115 	   101
	001634	   122 	   131 	   040
	001637	   120 	   122 	   117
	001642	   124 	   117 	   103
	001645	   117 	   114 	   040
	001650	   122 	   125 	   116
	001653	   116 	   111 	   116
	001656	   107
    376		000037 			SECSZ=.-SECBF
    377						.EVEN
    378					;
    379					;
    380	001660				SYNMSG:	.QIO	WRIT,LUN,EFN1,0,0,0,SYNBF,SYNSZ
	001660	   003 	   011 			.BYTE	IO,9.
	001662	000400 				.WORD	WRIT
	001664	000002 				.WORD	LUN
	001666	   001 	   000 			.BYTE	EFN1,0
	001670	000000 				.WORD	0
	001672	000000 				.WORD	0
	001674	001702'				.WORD	SYNBF
	001676	000023 				.WORD	SYNSZ
	001700	000040 				.WORD	40
    381						;
    382	001702	   122 	   105 	   104 	SYNBF:	.ASCII	/RED -- SYNTAX ERROR/
	001705	   040 	   055 	   055
	001710	   040 	   123 	   131
	001713	   116 	   124 	   101
	001716	   130 	   040 	   105
	001721	   122 	   122 	   117
	001724	   122
    383		000023 			SYNSZ=.-SYNBF
    384					;
    385	001725	   122 	   105 	   104 	SYNBF1:	.ASCII	/RED /
	001730	   040
    386	001731	   040 	   040 		SYNDEV:	.ASCII	/  /
    387	001733	   040 	   040 	   040 	SYNUNT:	.ASCII	/   /
    388	001736	   040 	   055 	   055 		.ASCII	/ -- SYNTAX ERROR/
	001741	   040 	   123 	   131
	001744	   116 	   124 	   101
	001747	   130 	   040 	   105
	001752	   122 	   122 	   117
	001755	   122
    389					;
    390		000031 			SYNSZ1=.-SYNBF1
    391					;
    392	001756	   122 	   105 	   104 	INCMS:	.ASCII	/RED /
	001761	   040
    393	001762	   040 	   040 	   040 	INCMSG:	.ASCII	/     /
	001765	   040 	   040
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-9


    394	001767	   040 	   055 	   055 		.ASCII	/ -- DEVICE NOT KNOWN TO SYSTEM/
	001772	   040 	   104 	   105
	001775	   126 	   111 	   103
	002000	   105 	   040 	   116
	002003	   117 	   124 	   040
	002006	   113 	   116 	   117
	002011	   127 	   116 	   040
	002014	   124 	   117 	   040
	002017	   123 	   131 	   123
	002022	   124 	   105 	   115
    395		000047 			INCSZ=.-INCMS
    396						.EVEN
    397	002026				VOLMS:	.QIO	WRIT,LUN,EFN1,0,0,0,VOLMSG,VOLMSZ
	002026	   003 	   011 			.BYTE	IO,9.
	002030	000400 				.WORD	WRIT
	002032	000002 				.WORD	LUN
	002034	   001 	   000 			.BYTE	EFN1,0
	002036	000000 				.WORD	0
	002040	000000 				.WORD	0
	002042	002050'				.WORD	VOLMSG
	002044	000065 				.WORD	VOLMSZ
	002046	000040 				.WORD	40
    398					;
    399	002050	   106 	   061 	   061 	VOLMSG:	.ASCII	/F11ACP NOT FOUND ON SYSTEM/<12><15>
	002053	   101 	   103 	   120
	002056	   040 	   116 	   117
	002061	   124 	   040 	   106
	002064	   117 	   125 	   116
	002067	   104 	   040 	   117
	002072	   116 	   040 	   123
	002075	   131 	   123 	   124
	002100	   105 	   115 	   012
	002103	   015
    400	002104	   123 	   131 	   123 		.ASCII	/SYSTEM MUST BE RELOADED/<12><15>
	002107	   124 	   105 	   115
	002112	   040 	   115 	   125
	002115	   123 	   124 	   040
	002120	   102 	   105 	   040
	002123	   122 	   105 	   114
	002126	   117 	   101 	   104
	002131	   105 	   104 	   012
	002134	   015
    401		000065 			VOLMSZ=.-VOLMSG
    402						.EVEN
    403					;
    404					;
    405	002136				SYNMS1:	.QIO	WRIT,LUN,EFN1,0,0,0,SYNBF1,SYNSZ1
	002136	   003 	   011 			.BYTE	IO,9.
	002140	000400 				.WORD	WRIT
	002142	000002 				.WORD	LUN
	002144	   001 	   000 			.BYTE	EFN1,0
	002146	000000 				.WORD	0
	002150	000000 				.WORD	0
	002152	001725'				.WORD	SYNBF1
	002154	000031 				.WORD	SYNSZ1
	002156	000040 				.WORD	40
    406					;
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-10


    407	002160				IDVERR:	.QIO	WRIT,LUN,EFN1,0,0,0,INCMS,INCSZ
	002160	   003 	   011 			.BYTE	IO,9.
	002162	000400 				.WORD	WRIT
	002164	000002 				.WORD	LUN
	002166	   001 	   000 			.BYTE	EFN1,0
	002170	000000 				.WORD	0
	002172	000000 				.WORD	0
	002174	001756'				.WORD	INCMS
	002176	000047 				.WORD	INCSZ
	002200	000040 				.WORD	40
    408					;
    409	002202				QIOWMC:	QIOW$	IO.WLB,LUN,EFN1,0,0,0,<MCMS,MCSZ,0>
	002202	   003 	   011 			.BYTE	3,$$$ARG
	002204	000000G				.WORD	IO.WLB
	002206	000002 				.WORD	LUN
	002210	   001 	   000 			.BYTE	EFN1,0
	002212	000000 				.WORD	0
	002214	000000 				.WORD	0
	002216	002224'				.WORD	MCMS
	002220	000004 				.WORD	MCSZ
	002222	000000 				.WORD	0
    410					;
    411	002224	   122 	   105 	   104 	MCMS:	.ASCII	/RED>/
	002227	   076
    412		000004 			MCSZ=.-MCMS
    413						.EVEN
    414					;
    415	002230				QIORMC:	QIOW$	IO.RLB,LUN,EFN1,0,STATUS,0,<MCRBH,80.>
	002230	   003 	   010 			.BYTE	3,$$$ARG
	002232	000000G				.WORD	IO.RLB
	002234	000002 				.WORD	LUN
	002236	   001 	   000 			.BYTE	EFN1,0
	002240	002362'				.WORD	STATUS
	002242	000000 				.WORD	0
	002244	001300'				.WORD	MCRBH
	002246	000120 				.WORD	80.
    416					;
    417					;
    418	002250				MCRERM:	.QIO	WRIT,LUN,EFN1,0,0,0,MCREMS,MCRBSZ
	002250	   003 	   011 			.BYTE	IO,9.
	002252	000400 				.WORD	WRIT
	002254	000002 				.WORD	LUN
	002256	   001 	   000 			.BYTE	EFN1,0
	002260	000000 				.WORD	0
	002262	000000 				.WORD	0
	002264	002272'				.WORD	MCREMS
	002266	000044 				.WORD	MCRBSZ
	002270	000040 				.WORD	40
    419	002272	   122 	   105 	   104 	MCREMS:	.ASCII	/RED -- CAN'T READ MCR COMMAND BUFFER/
	002275	   040 	   055 	   055
	002300	   040 	   103 	   101
	002303	   116 	   047 	   124
	002306	   040 	   122 	   105
	002311	   101 	   104 	   040
	002314	   115 	   103 	   122
	002317	   040 	   103 	   117
	002322	   115 	   115 	   101
REDIRECT	MACRO M1108  16-JAN-78 19:01  PAGE 1-11


	002325	   116 	   104 	   040
	002330	   102 	   125 	   106
	002333	   106 	   105 	   122
    420		000044 			MCRBSZ=.-MCREMS
    421						.EVEN
    422					;
    423	002336	000000 			COUNT:	.WORD 	0
    424	002340				F11RQ:	RQST$	F11ACP
	002340	   013 	   007 			.BYTE	11.,7
	002342	025167 	003310 			.RAD50	/F11ACP/
	002346	000000 	000000 			.WORD	0,0
	002352	000000 				.WORD
	002354	   000 	   000 			.BYTE	,
    425	002356	025167 	003310 		F11NM:	.RAD50	/F11ACP/
    426	002362				STATUS:	.BLKW	2
    427		000000'				.END	REDIR
ERRORS DETECTED:  0

VIRTUAL MEMORY USED:  2385 WORDS  ( 10 PAGES)
DYNAMIC MEMORY:  3104 WORDS  ( 11 PAGES)
ELAPSED TIME:  00:00:28
,[47,20]RED.LIS/-SP/CRF=[47,30]RED
RED        CREATED BY  MACRO  ON 16-JAN-78 AT 19:02	PAGE 1

SYMBOL CROSS REFERENCE                                  CREF         

SYMBOL	VALUE		REFERENCES

AM    	= 000033	#1-113      1-132      1-165     
CNTNXT	  000256 R	#1-172      1-181      1-185     
CNTSCN	  000246 R	#1-170      1-188      1-191     
COTSCN	  000236 R	#1-168      1-174     
COUNT 	  002336 R	*1-214     *1-221     #1-423     
CR    	= 000015	#1-111      1-130      1-163     
CR$RED	= 000564 RG	#1-226     
EFN1  	= 000001	#1-108      1-358      1-366      1-373      1-380      1-397      1-405      1-407      1-409     
                         1-415      1-418     
EF.PR1	= ******  GX	 1-118     
EXIT  	= 000463	#1-106      1-248     
EXITA 	  000704 R	 1-245     #1-248     
EXITMS	  000702 R	 1-121     #1-247      1-259      1-266      1-270      1-312     
FNDBC 	  000120 R	 1-129     #1-145     
FNDBTH	  000352 R	 1-184     #1-192     
FNDNEW	  000330 R	 1-169     #1-187     
FNDOLD	  000304 R	 1-171     #1-180     
F11NM 	  002356 R	 1-218     #1-425     
F11RQ 	  002340 R	 1-216     *1-241      1-242     #1-424     
GETVAL	  001224 R	 1-148      1-158     #1-325     
HNRBF 	  001464 R	 1-358     #1-360      1-364     
HNRDEV	  001470 R	#1-361     
HNRMSG	  001442 R	 1-246     #1-358     
HNRSZ 	= 000036	 1-358     #1-364     
IDVERR	  002160 R	 1-311     #1-407     
INCMS 	  001756 R	#1-392      1-395      1-407