Trailing-Edge
-
PDP-10 Archives
-
BB-D351B-SM
-
sources/initup.p11
There are 2 other files named initup.p11 in the archive. Click here to see a list.
.SBTTL INITUP - INITIALIZATION FOR THE DUP11S
;
; THIS ONCE-ONLY SUBROUTINE IS CALLED FROM CHECK11 FOR EACH
; DUP11.
; AFTER CHECK11 HAS FINISHED, THIS SUBROUTINE IS OVERLAYED BY
; FREE STORAGE.
;
.REPT 0
COPYRIGHT (c) 1980, 1979
DIGITAL EQUIPMENT CORPORATION, maynard, mass.
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.
.ENDR
;
;
; REVISION HISTORY
;
; 3(001) BS CHANGE LABEL THAT INDICATES BEGINNING OF KMC MICROCODE
;
;
VINTUP=001
;
VEDIT=VEDIT+VINTUP
;
;
;
.EVEN
.IF NE,CHOWNR
;
; IF WE ARE DOING OWNER RECORDING, BE SURE FREE STORAGE STARTS
; ON A MULTIPLE OF 100 OCTAL BYTES FOR READABILITY
;
ZZ=.&77
.IF NE,ZZ
.=<.!77>+1
.ENDC ;.IF NE,ZZ
.ENDC ;.IF NE,CHOWNR
FIRZER: ;FIRST LOCATION OF FREE STORAGE
;
;
; SUBROUTINE CALLED BY CHECK11 TO CHECK THE DUP11
;
CKAUP1: MOV R1,-(SP) ;SAVE R1
MOV R2,-(SP) ;SAVE R2
MOV R3,-(SP) ;SAVE R3
MOV R4,-(SP) ;SAVE R4
11$: MOV NDQ11S,R4 ;GET NUMBER OF THIS DUP11
CMP #NLINES,R4 ;TOO MANY?
BNE 12$ ;NO.
JSR R0,CKTCRL ;YES.
.ASCIZ \ Too many DUP11 lines \
.EVEN
BR 13$ ;IGNORE EXTRA LINES
;
; HERE WHEN WE CAN USE THIS DUP11 LINE.
;
12$: ASL R4 ;LINE NUMBER * 2
MOV 0(R0),DQCSR(R4) ;REMEMBER CSR ADDRESS
MOV 2(R0),DQVEC(R4) ;REMEMBER VECTOR ADDRESS
INC NDQ11S ;INCREMENT NUMBER OF DQ11S
13$: MOV (SP)+,R4 ;RESTORE R4
MOV (SP)+,R3 ;RESTORE R3
MOV (SP)+,R2 ;RESTORE R2
MOV (SP)+,R1 ;RESTORE R1
RTS PC ;RETURN TO CALLER
;
; SUBROUTINE CALLED BY CHECK11 TO CHECK THE DMC11
;
.IF DF,FT2020 ;IF ON A 2020
CKAMC1:
SAVE <R1,R2,R3,R4> ;SAVE SOME REGISTERS
MOV DMCSR,R4 ;ALREADY HAVE ONE?
BNE 10$ ;YES
MOV 0(R0),DMCSR ;SAVE CSR
MOV 2(R0),DMCVEC ;SAVE INTERRUPT VECTOR ADDRESS
10$: RESTORE <R4,R3,R2,R1>
RTS PC
.ENDC ;END IF DF,FT2020
;
; SUBROUTINE CALLED BY CHECK11 TO CHECK THE KMC11S
;
CKAMD1: MOV R1,-(SP) ;SAVE R1
MOV R2,-(SP) ; AND R2
MOV R3,-(SP) ; AND R3
MOV R4,-(SP) ; AND R4
.IF NE,FT.KMC
MOV NKMCS,R4 ;NUMBER OF KMC11S ALREADY
CMP #<NLINES/4>,R4 ;TOO MANY?
BNE 11$ ;NO.
JSR R0,CKTCRL
.ASCIZ \ too many KMC11 microprocessors\
.EVEN
BR 13$
;
;
; HERE IF THERE ARE NOT TOO MANY KMC11S
;
11$: ASL R4 ;KMC11 NUMBER * 2
MOV 0(R0),R3 ;POINT TO CSR
MOV #MD.CLR,(R3) ;CLEAR MICROPROCESSOR
CLR (R3) ;TURN OFF CLEAR BIT
CLR 2(R3) ;CLEAR SEL 2
CLR 4(R3) ;CLEAR SEL 4
CLR 6(R3) ;CLEAR SEL 6
MOV #MD.RMO,(R3) ;SELECT CRAM
MOV 6(R3),R1 ;FETCH LOCATION 0
CMP #<B15+B8>,R1 ;BRANCH TO ZERO?
BNE 14$ ;NO, CRAM NOT LOADED.
MOV #1,4(R3) ;LOCATION 1
MOV #MD.RMO,(R3) ;SELECT CRAM
MOV 6(R3),R1 ;FETCH LOCATION 1
CMP #1,R1 ;CORRECT VERSION NUMBER?
BNE 14$ ;NO, FAIL.
INC NKMCS ;YES, WE HAVE A KMC11
MOV 0(R0),MDCSR(R4) ;REMEMBER CSR ADDRESS
MOV 2(R0),MDVEC(R4) ; AND VECTOR ADDRESS
MOV #MHCODE-10,R1 ;START OF VERSION NUMBER
MOV #MDVER,R2 ;PLACE TO PUT IT
MOV #4,R3 ;LENGTH OF VERSION NUMBER
12$: MOV (R1)+,(R2)+ ;COPY VERSION NUMBER
SOB R3,12$ ; ... ALL OF IT.
.ENDC ;.IF NE,FT.KMC
13$: MOV (SP)+,R4 ;RESTORE R4
MOV (SP)+,R3 ; AND R3
MOV (SP)+,R2 ; AND R2
MOV (SP)+,R1 ; AND R1
RTS PC ;RETURN TO CALLER
;
; ERROR TYPEOUTS FOR KMC11
;
14$: JSR R0,CKTCRL
.ASCIZ /? KMC11 microcode is invalid /
.EVEN
BIS #CKFERR,CHKFLG ;FLAG AN ERROR
BR 13$
;