Google
 

Trailing-Edge - PDP-10 Archives - BB-JR93N-BB_1990 - 10,7/unsmon/saxprm.mac
There are 4 other files named saxprm.mac in the archive. Click here to see a list.
UNIVERSAL SAXPRM - SA10 PARAMETER FILE - V5
SUBTTL	JOSEPH A. DZIEDZIC/JAD (DEC) & JEFF GUNTER/JEG (ADP)	17-APRIL-90

	SEARCH	F, S, DEVPRM

;THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED
;  OR COPIED ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
;
;COPYRIGHT (c) DIGITAL EQUIPMENT CORPORATION 1987,1988,1990.
;ALL RIGHTS RESERVED.

.CPYRT<1987,1990>,.
	SUBTTL	MACRO DEFINITIONS

;MACRO TO DEFINE SA10 DEVICE DRIVER DISPATCH TABLE

DEFINE	SAXDSP(PFX),<
	XWD	0,0		;;LINK WORD
	.LINK	.LKSAX, .-1	;;FILL IN THE LINK WORD
	IFIW	PFX'CFS		;;SPECIAL AUTOCONFIGURATION ROUTINE
	IFIW	PFX'DSP		;;DRIVER DISPATCH TABLE
>; END DEFINE SAXDSP

;DISPATCH TABLE OFFSETS

SADLNK==:0			;LINK TO NEXT DRIVER
SADCFS==:1			;AUTOCONFIGURE ENTRY POINT
SADDSP==:2			;DRIVER DISPATCH
	SUBTTL	RANDOM HARDWARE SYMBOLS

;DEVICE ADDRESS FIELD IS 8 BITS WIDE.  THIS FIELD IS SUB-DIVIDED INTO THE
;CONTROL UNIT ADDRESS FIELD AND THE UNIT ADDRESS FIELD.  BY DEFAULT, THE
;WIDTH OF THE CONTROL UNIT ADDRESS FIELD IS 4.

WIDCUA==4		;WIDTH OF CONTROL UNIT ADDRESS SUB-FIELD
WIDUNA==^D8-WIDCUA	;WIDTH OF UNIT ADDRESS SUB-FIELD

MAXCUS==1_WIDCUA	;MAXIMUM NUMBER OF CONTROL UNITS
MAXUNS==1_WIDUNA	;MAXIMUM NUMBER OF SLAVE UNITS
	SUBTTL SA10 DEFINITIONS

;SA10 HARDWARE FORMATS

SCHNUM==4		;NUMBER OF SUBCHANNELS

;SA10 CONO BITS

SO.RES==1B18		;RESET THE SA10
SO.CME==1B19		;CLEAR MEMORY ERRORS
SO.CLK==1B26		;SA10 CLOCK CONTROL

;BITS 27-29 ARE THE FUNCTION TO BE PERFORMED FOR THE SUBCHANNEL
;SPECIFIED IN BITS 31-32

SO.NOP==0B29		;NOP
SO.RCH==3B29		;RESET SUBCHANNEL (SO.SET NORMALLY OFF)
SO.GO==4B29		;GO FLAG
SO.SRQ==5B29		;STATUS REQUEST FLAG
SO.STS==6B29		;STATUS FLAG
SO.ENB==7B29		;INTERRUPT ENABLE

SO.SET==1B30		;SET FLAG SPECIFIED IN BITS 27-29
SO.CLR==0B30		;CLEAR FLAG SPECIFIED IN BITS 27-29

SO.CHN==1B32		;CHANNEL SELECT (MULTIPLY BY SUBCHANNEL NUMBER)


SO.HLT==2B29+SO.SET	;SIMULATE HALT I/O INSTRUCTION

SO.SRS==SO.RCH+SO.SET	;SELECTIVE RESET (USED AFTER MEMORY ERRORS)

SO.SDR==SO.NOP		;SELECT DIAGNOSTIC READ
SO.DT0==0B32		;READ SA10 REGISTER 0 (CHAN NUM,,CBUS+MICRO PC)
SO.DT1==1B32		;READ SA10 REG 1 (MEMORY ADDRESS)
SO.DT2==2B32		;READ SA10 REG 2 (CHAN NUM,,MEMORY BUF LH)
SO.DT3==3B32		;READ SA10 REG 3 (PARITY,,MEMORY BUF RH)
SO.DT4==4B32		;READ SA10 REG 4 (CLOCK RUN+MEM BUSY,,SAME AS CONI DATA)
SO.DT5==5B32		;READ SA10 REG 5 (MU0,MU1,,MISC BITS)

;SA10 CONI BITS

SI.SAX==1B17		;BIT WIRED TO ALWAYS-ON IF THIS IS AN SA10
SI.PIR==1B18		;PI REQUEST
SI.PAR==1B19		;MEMORY PARITY ERROR
SI.NXM==1B20		;NON-EXISTENT MEMORY
SI.ENB==1B21		;INTERRUPT ENABLE (SHIFT RIGHT BY SUBCHANNEL NUMBER)
SI.GO==1B25		;GO FLAG	  (SHIFT RIGHT BY SUBCHANNEL NUMBER)
SI.STS==1B29		;STATUS FLAG	  (SHIFT RIGHT BY SUBCHANNEL NUMBER)
SI.AST==17B32		;ALL STATUS FLAGS
SI.PIA==7B35		;PI-ASSIGNMENT

;CHANNEL LOGOUT AREA

.CLICW==0		;INITIAL CCW
.CLCSW==1		;CHANNEL STATUS
.CLECW==2		;ENDING CCW
.CLRSV==3		;RESERVED FOR CHANNEL'S USE IN BLOCK MULTIPLEX MODE
.CLLEN==:4		;LENGTH OF CHANNEL LOGOUT AREA

;USEFUL MICROINSTRUCTIONS FOR DETERMINING SA10 BASE ADDRESS

SA.BA1==43700		;XANC CA,MAGIC,0,LOAD - PUTS BASE ADR IN CA
SA.BA2==42260		;XANC CA,INCR,0,STWRD - PUTS CA IN MA
	SUBTTL	CHANNEL PROGRAM FORMAT

;CHANNEL PROGRAMS GET BUILT OUT OF CORE FROM A NON-ZERO SECTION:

MS.SAX==MS.MEM		;SECTION TO USE FOR SA10 MEMORY CHUNKS

;SA10 CHANNEL PROGRAM FORMATS

	TIC==1B1		;TRANSFER-IN-CHANNEL (IE: CHANNEL JUMP)
	BMXTIC==1B1+1B0		;TIC REQUESTING BLOCK-MUX MODE (IN BASE BLOCK)
	BMXEND==1B0		;BLOCK-MUX HALT (DOESN'T STOP SUBCHAN AS A WHOLE)

;DEVICE COMMAND WORD FORMAT (DVW)

;	0-7		FLAGS

	F.NMT==1B0	;NO MEMORY TRANSFER
	F.XEC==1B2	;HALT (=0) / EXECUTE (=1)
	F.CC==1B3	;COMMAND CHAINING
	F.WORD==0B4	;WORD MODE
	F.BYTE==1B4	;BYTE MODE
	F.NAT==1B1	;NATURAL MODE (F.XEC MUST BE ON TO DISTINGUISH
			;FROM TIC)
	F.TAPC==1B1+1B4	;"TAPE COMPATIBILITY" MODE
	F.PCI==1B5	;PROGRAM CONTROLLED INTERRUPT
	F.SLI==1B6	;SUPPRESS LENGTH INDICATION
	F.OFP==1B7	;OFFSET BYTE POSITION - START BYTE TRANSFER
			; AT BIT 16 (THIRD BYTE IN WORD)

;	8-15	DEVICE COMMAND - DEPENDS ON DEVICE TYPE

	DVSDVC==^D8	;SIZE OF DEVICE COMMAND FIELD
	DVNDVC==^D15	;RIGHTMOST BIT OF DEVICE COMMAND FIELD

;	16-23	DEVICE ADDRESS - IDENTIFIES DEVICE TO USE

	DVSDVA==^D8	;SIZE OF DEVICE ADDRESS FIELD
	DVNDVA==^D23	;RIGHTMOST BIT OF DEVICE ADDRESS FIELD

;	BITS 24-35 - THESE BITS ARE IGNORED AND THUS CAN BE USED BY SOFTWARE

;DATA CHAIN WORD FORMAT (DCW)

;	0	IF BIT 0 IS OFF, THEN CHAIN TO NEXT DCW (NEXT WORD IN MEMORY)
	DC.END==1B0	;ELSE THIS IS THE END OF THE CHAIN

;	1-DCNSIZ	NEGATIVE WORD OR BYTE COUND

	DCSSIZ==^D11	;SIZE OF COUNT FIELD
	DCNSIZ==^D11	;RIGHTMOST BIT OF COUNT FIELD

;	(36-DCNADR)-35	ADDRESS OF FIRST WORD TO TRANSFER

	DCSADR==^D24	;SIZE OF ADDRESS FIELD
	DCNADR==^D35	;RIGHTMOST BIT OF ADDRESS FIELD
;SENSE CHANNEL PROGRAM OFFSETS (USED MOSTLY DURING AUTOCONFIGURE):

	.ORG	0	;OFFSETS FROM ZERO
SNSNOP:!BLOCK	1	;CHAINED NO-OP TO FLUSH STACKED STATUS
SNSDVW:!BLOCK	1	;DEVICE COMMAND WORD
SNSDCW:!BLOCK	1	;DATA CHAN WORD
SNSHLT:!BLOCK	1	;THE HALT TO TERMINATE THE CHANNEL PROGRAM
SNSDAT:!BLOCK	SNSWDS	;THE SENSE DATA ITSELF
SNSLEN:!		;LENGTH OF SENSE CHANNEL PROGRAM
	.ORG
;FORMAT OF ENTRIES IN DEVICE LIST

DVLMAX==^D16*^D16	;SIZE OF ENTIRE DEVL AREA
			;(16 KONS TIMES 16 UNITS PER KON)
	SASDLD==8	;SIZE OF DEVICE ADDRESS FIELD
	SANDLD==7	;RIGHTMOST BIT

	SASDLO==4	;SIZE OF OPCODE FIELD
	SANDLO==^D11	;RIGHTMOST BIT
	  DL.STA==15	;START DEVICE
	  DL.WAT==16	;WAITING FOR DEVICE
	  DL.TRM==17	;TERMINATED DEVICE
	  DL.END==0	;END OF LIST

	SASDLC==^D24	;SIZE OF ADDRESS FIELD
	SANDLC==^D35	;RIGHTMOST BIT
	SUBTTL	CHANNEL STATUS WORD FORMATS

;GENERAL STATUS

;BITS 0-1 ARE STATUS TYPE

CSSTYP==2		;SIZE OF STATUS TYPE FIELD
CSNTYP==^D1		;RIGHTMOST BIT

S.END==0		;ENDING STATUS
S.ISEL==1		;INITIAL SELECTION STATUS
S.ASY==2		;ASYNCHRONOUS STATUS
S.DUM==3		;DUMMY STATUS

;BITS 2-7 ARE CONTROL UNIT STATUS

S.SE==1B2		;SELECT ERROR (NO DEVICE RESPONDED)
S.BIPE==1B3		;BUS IN PARITY ERROR
S.CTLE==1B4		;CONTROL ERROR
S.LE==1B6		;LENGTH ERROR
S.PCI==1B7		;PCI FLAG

;BITS 8-15 ARE DEVICE STATUS

S.ATN==1B8		;ATTENTION
S.SM==1B9		;STATUS MODIFIER
S.CUE==1B10		;CONTROL UNIT END
S.BUSY==1B11		;BUSY
S.CE==1B12		;CHANNEL END
S.DE==1B13		;DEVICE END
S.UC==1B14		;UNIT CHECK
S.UE==1B15		;UNIT EXCEPTION

;BITS 16-23 IDENTIFY THE DEVICE THAT CAUSED THE INTERRUPT

CSSKON==WIDCUA		;SIZE OF CONTROLLER FIELD IN CHANNEL STATUS WORD
CSNKON==^D23-WIDUNA	;RIGHTMOST BIT

CSSUNI==WIDUNA		;SIZE OF UNIT FIELD IN CHANNEL STATUS WORD
CSNUNI==^D23		;RIGHTMOST BIT
	SUBTTL	RANDOM HARDWARE SYMBOLS

;DEVICE ADDRESS FIELD IS 8 BITS WIDE.  THIS FIELD IS SUB-DIVIDED INTO THE
;CONTROL UNIT ADDRESS FIELD AND THE UNIT ADDRESS FIELD.  BY DEFAULT, THE
;WIDTH OF THE CONTROL UNIT ADDRESS FIELD IS 4.

WIDCUA==4		;WIDTH OF CONTROL UNIT ADDRESS SUB-FIELD
WIDUNA==^D8-WIDCUA	;WIDTH OF UNIT ADDRESS SUB-FIELD

MAXCUS==1_WIDCUA	;MAXIMUM NUMBER OF CONTROL UNITS
MAXUNS==1_WIDUNA	;MAXIMUM NUMBER OF SLAVE UNITS
	SUBTTL	THE END

	END