.enabl lc ;Enable lower case characters .mcall .module .module SY,VERSION=1,COMMENT=,AUDIT=YES ;25-Jan-86 ; 25-Jan-86 JEC: 1) Updated to RT-11 V5.2 macros; 2) Modified the date ; setting installation code - If the date word in RMON is al- ; ready set (non-zero) then do not load it with saved date ; word (so date will not be changed on a soft re-boot); 3) ; Added "SET SY [NO]FORCE" to return to the previous code (to ; always set the date word of bootstrap); and 4) For J11-chip ; based systems, added a NOP in the code that tests for the ; cache CSR to be sure that the trap does not occur after the ; branch. ; ; Modified by: ; ; Jim Crapuchettes ; Omnex Corporation ; 2483 Old Middlefield Way ; Mountain View, Calif. 94043 ; (415) 966-8400 ;.TITLE SY V04.00 SYSTEM OPTION HANDLER ;.IDENT /V04.00/ ;.ENABL LC ; ; COPYRIGHT (c) 1979 BY ; 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. .sbttl Macros and Definitions .mcall .DRDEF, .DATE .DRDEF XX,0,0,0,0,0 CHECSR = 177746 rmon = 54 ;Pointer to bottom of monitor ; System database offset definitions $date = 262 ;Current date value config = 300 ;Monitor configuration word FBMON$ = 1 SLKMO$ = 2 HWDSP$ = 4 BATCH$ = 10 SLEDI$ = 20 CLK50$ = 40 HWFPU$ = 100 FJOB$ = 200 GTLNK$ = 400 USR$ = 1000 QUEUE$ = 2000 LSI11$ = 4000 KT11$ = 10000 LKCS$ = 20000 KW11P$ = 40000 CLOCK$ = 100000 confg2 = 370 ;Monitor configuration word 2 sysgen = 372 ;System Generation options word .SBTTL Installation code ;+ ; ; This code is executed during attempted installation of this handler. It ; always fails to install, since it is not a real handler, but in the pro- ; cess sets the system date and enables or disables processor cache (if it ; exists). ; ;- .asect . = 200 .enabl lsb mov @#rmon,r0 ;Point to base of RMON mov (pc)+,r1 ;Get the last date saved SYDATE: .word 0 ;{Date stored by SET SY [NO]DATE} ; Test if the system date word is already set (it will be non-zero if it is ; already set). This can occur due to a BOOT or INSTALL command from the ; user. If it is already set, do not change it unless a "SET SY FORCE" has ; been executed (the default is NOFORCE). tst $date(r0) ;Has date already been set? f.date: bne noforc ; Yes, don't set is again! mov r1,$date(r0) ;Set the system date word noforc: mov #CHECSR,r0 ;Point to cache control CSR tst @r0 ;Does the CSR exist? nop ;(Make time for 11/73 bus trap) bcs 10$ ; No, don't do anything mov (pc)+,@r0 ;Load it with enable/disable bits: CHESWT: .word 0 ; 0 to enable, 14 to disable 10$: sec ;Never INSTALL this handler! return .dsabl lsb .SBTTL SET Options ; The following SET options are implemented: ; ; CACHE Leave processor cache enabled on bootstrap. ; NOCACHE Disable processor cache on bootstrap. ; ; DATE Set date saved in handler for next bootstrap to current date. ; NODATE Set date saved in handler for next bootstrap to zero. ; ; FORCE On bootstrap, always set system date from saved date. ; NOFORCE On bootstrap, set system date from date saved only if system ; date has NOT been set. ; ; Note: Setting NODATE and FORCE will reset the date word to 0 (no date set) ; on a soft bootstrap (BOOT command). .enabl lsb .drset CACHE,-1,O.CACH,NO .drset DATE,-1,O.DATE,NO .drset FORCE,,O.FORC,NO O.CACH: clr r3 ;Entry point for 'CACHE', br 10$ ; go set to ENABLE cache mov #14,r3 ;Entry point to 'NOCACHE', set DISABLE 10$: mov r3,@#CHECSR ;Set up cache now mov r3,cheswt ; and set up for reboot return O.DATE: br 20$ ;'DATE' - Go get the date to set nop clr r0 ;'NODATE' - Use zero for date (no br 30$ ; date) and go store it for boot 20$: .date ;Get current system date word value 30$: mov r0,SYDATE ;Store date value (or 0) for next boot return O.FORC: mov (pc)+,r3 ;'FORCE' - Replace BNE with NOP nop mov r3,f.date ;'NOFORCE' - BNE around date setting return .dsabl lsb .SBTTL Driver entry .DRBEG XX XXINT:: .DREND XX .end