Google
 

Trailing-Edge - PDP-10 Archives - bb-kl11c-bm_tops20_v6_1_atpch1_16 - autopatch/mountr.c16
There are no other files named mountr.c16 in the archive.
 INS 1/1	;16C1

 REP 7/2	;16C2
		MTRMAN==334		;Maintenance edit level
 WIT
		MTRMAN==335		;Maintenance edit level
 INS 463/4	;16C3

	335	5.1245		Dec-5-86
		Remember how many dismounts are currently being performed on a
	structure so that if a cancel for a dismount request is given and if there are
	no more dismounts for that structure pending, MOUNTR can reset
	the structure status back to its previous state prior to the dismount.
	This edit must be accompanied by MTRMAC edit 41.  MOUNTR must be rebuild.
 REP 130/123	;16C4
		TXNE Q1,STR%EP		;Is structure exclusive due to port operation?
		CALL [MOVE T1,STRALI(STR) ;Get the alias
		      TMCT <%4CStructure is exclusive due to port operation%_>
		      RET]
 WIT
	;**;[335]At SHW4:+5L replace 3 lines with 4 lines  JYCW  12/5/86
		TXNE Q1,STR%UD		;[335]Is structure unavail due to dismount?
		TMCT <%4CStructure is set unavailable due to dismount%_> ;[335]
		TXNE Q1,STR%EP		;[335]Is str exclusive due to port operation?
		TMCT <%4CStructure is exclusive due to port operation%_> ;[335]
 INS 29/148	;16C5
	;**;[335]At STRSET:+18L add 1 line  JYCW  12/5/86
		AOS STRNDM(STR)		;[335]Up the # of dismount requests
 REP 102/148	;16C6
	;Returns +1 always through DISREF
 WIT
	;Returns +1 always through STSTBK
 REP 109/148	;16C7
		CALLRET DISREF		;Set structure back to previous state
	SUBTTL DISREF - Set STR back to previous state, before the DISMOUNT.
	;Accepts STR/structure status block address
	;	 RSB/Request status block
	;Returns +1 always

	DISREF:	SETZRO STR%UD,STRFL1(STR) ;Say all done with dismount	
		MOVEI T1,RSBSTA(RSB)	;Get SIXBIT alias
		MOVE T2,[POINT 7,MSTAL]	;This is place to store 7-bit
		CALL SIXSEV		;CONVERT IT
		MOVE T1,STRFLG(STR)	;Get structure status
		TXNN T1,MS%DIS		;Was it originally unavailable?
		JRST DISRE2		;It was available so set it 
		CALL STRUNA		;Set str unavailable
		CALL DISFA1		;Can not set structure unavailable
	DISRE1: ABTRET (MREQ23,ABT%OP)  ;abort the request

	DISRE2:	CALL STRAVA		;Set it available
		CALL DISFA1		;Can not set structure unavailable
		CALLRET DISRE1		;Everything back to previous, join common exit
 WIT
	;**;[335]At STRREF:+5L replace 1 line with 2  JYCW  12/5/86
		CALL STSTBK		;[335]Set structure back to previous state
		ABTRET (MREQ23,ABT%OP)  ;[335] and abort the request
	;**;[335]At DISREF:+0 rename the routine to STSTBK 
	SUBTTL STSTBK - Set STR back to previous state, before the DISMOUNT.
	;Accepts STR/structure status block address

	;Returns +1 always

	STSTBK:	SOSE STRNDM(STR)	;[335]One less, any more dismounts?
		JRST STSTB1		;[335]Yes, better not set it back yet.
		SETZRO STR%UD,STRFL1(STR) ;[335]Say all done with dismount	
		MOVEI T1,RSBSTA(RSB)	;[335]Get SIXBIT alias
		MOVE T2,[POINT 7,MSTAL]	;[335]This is place to store 7-bit
		CALL SIXSEV		;[335]CONVERT IT
		MOVE T1,STRFLG(STR)	;[335]Get structure status
		TXNN T1,MS%DIS		;[335]Was it originally unavailable?
		JRST STSTB2		;[335]It was available so set it 
		CALL STRUNA		;[335]Set str unavailable
		CALL DISFA1		;[335]Can not set structure unavailable

	STSTB1: RET			;[335]Common exit point

	STSTB2:	CALL STRAVA		;[335]Set it available
		CALL DISFA1		;[335]Can not set structure unavailable
		CALLRET STSTB1		;[335]Back to previous, join common exit
 REP 20/151	;16C8
		  CALLRET DISREF]	;Abort the disk request and return
 WIT
	;**;[335]At SCREQ2:+9L replace 1 line with 2  JYCW  12/5/86
		  CALL STSTBK		;[335] Abort the disk request and return
		  ABTRET (MREQ23,ABT%OP)] ;[335] and abort the request
 REP 42/174	;16C9
		ABTREQ (MREQX1)		;OK, KILL IT
		CALL WORCAN		;TELL OPERATOR REQUEST WAS CANCELED
		RETSKP
 WIT
	;**;[335]At TCITN1:+11L add 1 line  JYCW 12/5/86
		CALL CHKDSM		;[335]Check to see if we a doing a str dismount
		ABTREQ (MREQX1)		;OK, KILL TI
		CALL WORCAN		;TELL OPERATOR REQUEST WAS CANCELED
		RETSKP

	;**;[335]At TELMON:-1L add 8 lines  JYCW 12/5/86
	;CHKDSM - Call only by TCITN to set the structure back to its previous
	;	  state if we are canceling a dismount request. 
	;Accepts RSB/Request Status Block
	;Returns +1 always
	CHKDSM:	LOAD T1,RSBTYP		;[335]Get the request type
		CAIE T1,.DSMST		;[335]Dismount str request?
		JRST CHKDS1		;[335]No, all done
		MOVE T1,RSBSTA(RSB)	;[335]Get structure alias
		MOVE T2,RSBSTN(RSB)	;[335]Get structure name
		SETZ T4,		;[335]No unique code
		CALL MATCHS		;[335]Get SSB in STR
		 SKIPA			;[335]Not there
		CALL STSTBK		;[335]Set str back to its previous state
	CHKDS1:	RET


 SUM 115033