Google
 

Trailing-Edge - PDP-10 Archives - bb-bt99e-bb - qsrt10.c09
There is 1 other file named qsrt10.c09 in the archive. Click here to see a list.
 INS 17/10	;09C1
		INTERN	I$MSTR		;ROUTINE TO HANDLE MONITOR STR MOUNTED MSG
 INS 15/22	;09C2
	SUBTTL	I$SLBT - Set label type for a magtape drive


	;**;[1224] ADD ROUTINE I$SLBT FOLLOWING I$GDEN	13-AUG-84 /DPM
	; Here on a call from QSRMDA's reassign code to set the label type
	; of a drive before we give it away.
	; Call:	MOVE	S1, sixbit unit name
	;	MOVE	S2, label type code
	;	PUSHJ	P,I$SLBT
	;
	I$SLBT::PUSHJ	P,.SAVE1		;SAVE P1
		MOVE	P1,[3,,TF]		;SET UP UUO
		MOVEI	TF,.TFLBL+.TFSET	;FUNCTION CODE TO SET LABEL TYPE
		TAPOP.	P1,			;SET THE LABEL TYPE
		  $RETF				;SHOULDN'T FAIL
		$RETT				;RETURN
 INS 1/23	;09C3
	SUBTTL	I$MSTR - PROCESS MONITOR STRUCTURE MOUNTED MSG

	;This routine extracts each unit from the .IPCST message and kicks
	;PULSAR to recognize labels on the device. If the UCB for the unit
	;doesn't exist, one is created. The UC.FRC bit is lit in the UCB
	;indicating that the volume(s) is/are being by mounted someone other
	;than PULSAR.

	;CALL: 	M/ The message address

	;RET: 	True always

	I$MSTR:	PUSHJ	P,.SAVE3		;[1217] SAVE P1-P3
		HLRZ	P2,.IPCS0(M)		;[1217] GET LENGTH OF MSG
		CAIGE	P2,3			;[1217] MUST CONTAIN AT LEAST STR AND UNIT
		$RETT				;[1217] IGNORE IF TOO SHORT
		MOVNI	P2,-2(P2)		;[1217] BUILD AOBJN
		HRLI	P2,.IPCS2(M)		;[1217]   PTR TO PICK UP
		MOVSS	P2			;[1217]     UNITS IN MESSAGE
	MSTR.1:	SKIPN	P1,(P2)			;[1217] GET SIXBIT UNIT NAME
		  $STOP	(MUN,<Missing unit name in .IPCST message>) ;[1217] SO THERE!
		MOVE	S1,P1			;[1217] GET UNIT NAME IN S1
		PUSHJ	P,D$GUCB##		;[1217] GO SEE IF UCB EXISTS
		JUMPT	MSTR.3			;[1217] UCB EXISTS, GO KICK PULSAR
		MOVE	S1,UCBQUE##		;[1217] NO UCB, CREATE ONE
		MOVX	S2,UCBLEN		;[1217] FOR THIS UNIT.
		PUSHJ	P,L%CENT		;[1217]
		MOVE	S1,S2			;[1217] GET THE ADDRESS OF UCB
		MOVE	P3,S1			;[1217] SAVE ACROSS NEXT CALL
		MOVEM	P1,.UCBNM(S1)		;[1217] STORE UNIT NAME IN UCB
		PUSHJ	P,I$GATR		;[1217] GO FILL IN SPECIFICS
		MOVE	S1,P3			;[1217] GET UCB ADDRESS BACK
		PUSHJ	P,D$INCA##		;[1217] UPDATE 'A' MATRIX
		MOVE	S1,P3			;[1217] GET UCB ADDRESS AGAIN

	MSTR.3:	MOVX	S2,UC.AVR!UC.AVA	;[1217] THIS DEVICE IS AVAILABLE AND
		IORM	S2,.UCBS0(S1)		;[1217] WE'RE GOING TO READ LABELS!
		MOVX	S2,U1.FRC		;[1217] GET 'FORCED MOUNT' BIT
		IORM	S2,.UCBS1(S1)		;[1217] LITE IN SECOND UCB STATUS WORD
		MOVE	S1,P1			;[1217] GET SIXBIT UNIT NAME AGAIN
		PUSHJ	P,D$SREC##		;[1217] SEND RECOGNIZE MSG TO PULSAR
		AOBJN	P2,MSTR.1		;[1217] LOOP FOR ALL UNITS IN MSG
		$RETT				;[1217] RETURN AND WAIT FOR PULSAR ACK
 INS 23/24	;09C4
		SKIPE	.UCBVL(P2)		;UNIT PART OF A MOUNTED STRUCTURE?
		$RETT				;YES--JUST RECOGNIZE IS REDUNDANT
 SUM 32661