MONITOR(8S) — MAINTENANCE COMMANDS
NAME
monitor − system ROM monitor
SYNOPSIS
L1 -A BREAK
DESCRIPTION
The CPU board of the Sun workstation contains an EPROM (or set of EPROMs), called the monitor, that controls the system during startup. The monitor tests the system before attempting to boot UNIX. If you interrupt the boot procedure, by holding down L1 while typing a or A on the workstation keyboard (or BREAK if the console is a dumb terminal), the monitor issues the prompt:
>
and accepts commands interactively.
COMMANDS
a[n] [action]...(Sun-2 and Sun-3 only)
Open A-register (cpu address register) n, and perform indicated actions. The number n can be any value from 0 to 7, inclusive. The default value is 0. A hexadecimal action argument assigns the value you supply to the register n. A non-hex action terminates command input.
b [!] [device[(c,u,p)]] [pathname] [arguments_list]
b[?]
Reset appropriate parts of the system and bootstrap a program. A ! (preceeding the device argument) prevents the system reset from occurring. Programs can be loaded from various devices (such as a disk, tape or Ethernet). b with no arguments will cause a default boot, either from a disk, or from an Ethernet controller. b? displays all boot devices and their device arguments.
device is one of:
ieIntel Ethernet
leLance Ethernet
sdSCSI disk
stSCSI 1/4" tape
mtTape Master 9-track 1/2" tape
xdXylogics 7053 disk
xtXylogics 1/2" tape
xyXylogics 440/450 disk
cIs a controller number (0 if only one controller),
uis a unit number (0 if only one driver), and
pis a partition.
pathnamea pathname for a program such as /stand/diag. /vmunix is the default.
arguments_list
a list of up to seven arguments to pass to the program being booted.
c[virtual_address]
Resume execution of a program. When given, virtual_address is the address at which execution will resume. The default is the current PC. Registers are restored to the values shown by the a, d, and r commands (for Sun-2 and Sun-3 systems), or by the d and r commands (for Sun-4).
d[window_number](Sun-4 only)
Display (dump) the state of the processor. The processor state is observable only after:
•An unexpected trap was encountered.
•A user program dropped into the monitor (by calling abortent).
•The user manually entered the monitor by typing L1-A or BREAK.
The display consists of the following:
•The special registers: PSR, PC, nPC, TBR, WIM and Y
•Eight global registers, and
•24 window registers (8 in, 8 local, and 8 out), corresponding to one of the 7 available windows. If a Floating-Point Unit is on board, its status register along with its 32 floating-point registers are also shown.
window_number
Display the indicated window_number, which can be any value between 0 and 6, inclusive. If no window is specified and the PSR’s current window pointer contains a valid window number, registers from the window that was active just prior to entry into the monitor are displayed. Otherwise, registers from window 0 are displayed.
d[n][action]...(Sun-2 and Sun-3 only)
Open D-register (cpu data register) n, and perform indicated actions. The number n can be any value from 0 to 7, inclusive. The default is 0. See the a command for a description of action.
e[virtual_address][action] ...
Open the 16 bit word at virtual_address (default zero) in the address space defined by the s command. See the a command for a description of action.
fvirtual_address1 virtual_address2 pattern [size](Sun-3 and Sun-4 only)
Fill the bytes, words or long words from virtual_address1 (lower) to virtual_address2 (higher) with the constant, pattern. The size argument can take one of the follwoing values
bbyte format (the default)
wword format
llong word format
For example, the following command fills the address block from 0x1000 to 0x2000 with the word pattern, 0xABCD:
f 1000 2000 ABCD W
g [vector] [argument]
g [virtual_address] [argument]
Goto (jump to) a predetermined or default routine (first form), or to a user-specified routine (second form). The value of argument is passed to the routine. If the vector or virtual_address argument is omitted, the value in the PC is used as the address to jump to.
To set up a predetermined routine to jump to, a user program must, prior to executing the monitor’s g command, set the variable ∗romp->v_vector_cmd to be equal to the virtual address of the desired routine. Predetermined routines need not necessarily return control to the monitor.
The default routine, defined by the monitor, prints the user-supplied vector according to the format supplied in argument. This format can be one of:
%xhexadecimal
%ddecimal
g0 When the monitor is running as a result of UNIX being interrupted, force a panic and produce a crash dump.
g4When the monitor is running as a result of UNIX being interrupted, force a kernel stack trace.
h(Sun-3 and Sun-4 only)
Display the help menu for monitor commands and their descriptions.
i [cache_data_offset] [action]...(Sun-4 only)
Modify cache data RAM command. Display and/or modify one or more of the cache data addresses. See the a command for a description of action.
j [cache_tag_offset] [action]...(Sun-4 only)
Modify cache tag RAM command. Display and/or modify the contents of one or more of the cache tag addresses. See the a command for a description of action.
k[reset_level]
Reset the system. If reset_level is:
0(Sun-2 and Sun-3) CPU reset only. This is the default.
0(Sun-4) Reset the VME-bus, interrupt register and video monitor.
1Software reset.
2Power-on reset. Resets and clears the memory. Runs the EPROM-based diagnostic self test, which can take several minutes, depending upon how much memory is being tested.
kb Display the system banner.
l[virtual_address][action]...
Open the long word (32 bit) at memory address virtual_address (default zero) in the address space defined by the s command (below). See the a command for a description of action.
m[virtual_address][action]...
Open the segment map entry that maps virtual_address (default zero) in the address space defined by the s command. See the a command for a description of action.
o[virtual_address][action]...
Open the byte location specified by virtual_address (default zero) in the address space defined by the s command. See the a command for a description of action.
p[virtual_address][action]...
Open the page map entry that maps virtual_address (default zero) in the address space defined by the s command. See the a command for a description of action.
q[eeprom_offset][action]...(Sun-3 and Sun-4 only)
Open the EEPROM eeprom_offset (default zero) in the EEPROM address space. All addresses are referenced from the beginning or base of the EEPROM in physical address space, and a limit check is performed to insure that no address beyond the EEPROM physical space is accessed. This command is used to display and/or modify configuration parameters, such as: the amount of memory to test during self test, whether to display a standard or custom banner, if a serial port (A or B) is to be the system console, etc. See the a command for a description of action.
r[register_number][action]... (Sun-2 and Sun-3 only)
Display and/or modify the register indicated. register_number can be one of:
CA68020 Cache Address Register
CC68020 Cache Control Register
CX68020 System and User Context
DFDestination Function code
IS68020 Interrupt Stack Pointer
MS68020 Master Stack Pointer
PCProgram Counter
SC68010 System Context
SFSource Function code
SRStatus Register
SS68010 Supervisor Stack Pointer
UC68010 User Context
USUser Stack Pointer
VBVector Base
Alterations to these registers (except SC and UC) do not take effect until the next c command is executed. See the a command for a description of action.
r[register_number](Sun-4 only)
r[register_type]
r[w window_number]
Display and/or modify one or more of the IU or FPU registers.
A hexadecimal register_number can be one of:
0x00—0x0fwindow(0,i0)—window(0,i7), window(0,i0)—window(0,i7)
0x16—0x1fwindow(1,i0)—window(1,i7), window(1,i0)—window(1,i7)
0x20—0x2fwindow(2,i0)—window(2,i7), window(2,i0)—window(2,i7)
0x30—0x3fwindow(3,i0)—window(3,i7), window(3,i0)—window(3,i7)
0x40—0x4fwindow(4,i0)—window(4,i7), window(4,i0)—window(4,i7)
0x50—0x5fwindow(5,i0)—window(5,i7), window(5,i0)—window(5,i7)
0x60—0x6fwindow(6,i0)—window(6,i7), window(6,i0)—window(6,i7)
0x70—0x77g0, g1, g2, g3, g4, g5, g6, g7
0x78—0x7dPSR, PC, nPC, WIM, TBR, Y
0x7e—0x9eFSR, f0—f31
Register numbers can only be displayed after an unexpected trap, a user program has entered the monitor using the abortent function, or the user has entered the monitor by manually typing L1-A or BREAK.
If a register_type is given, the first register of the indicated type is displayed. register_type can be one of:
ffloating-point
gglobal
sspecial
If w and a window_number (0—6) are given, the first in-register within the indicated window is displayed. If window_number is omitted, the window that was active just prior to entering the monitor is used. If the PSR’s current window pointer is invalid, window 0 is used.
s[code](Sun-2 and Sun-3 only)
Set or query the address space to be used by subsequent memory access commands. code is one of:
0undefined
1user data space
2user program space
3user control space
4undefined
5supervisor data space
6supervisor program space
7supervisor control space
If code is omitted, s displays the current address space.
s[asi](Sun-4 only)
Set or display the Address Space Identifier. With no argument, s displays the current Address Space Identifier. The asi value can be one of:
0x2control space
0x3segment table
0x4Page table
0x8user instruction
0x9supervisor instruction
0xauser data
0xbsupervisor data
0xcflush segment
0xdflush page
0xeflush context
0xfcache data
t[program](Sun-3 only)
Trace the indicated standalone program. Works only with programs that do not affect interrupt vectors.
u [echo]
u [port] [options] [baud_rate]
u [u] [virtual_address]
With no arguments, display the current I/O device characteristics including: current input device, current output device, BAUD rates for serial ports A and B, an input-to-output echo indicator, and virtual addresses of mapped UART devices. With arguments, set or configure the current I/O device. With the u argument (uu...), set the I/O device to be the virtual_address of a UART device currently mapped.
echoCan be either e to enable input to be echoed to the output device, or ne, to indicate that input is not echoed.
portAssign the indicated port to be the current I/O device. port can be one of:
aserial port A
bserial port B
kthe workstation keyboard
sthe workstation screen
baud_rate
Any legal BAUD rate.
options can be any combination of:
iinput
ooutput
uUART
eecho input to output
nedo not echo input
rreset indicated serial port (a and b ports only)
If either a or b is supplied, and no options are given, the serial port is assigned for both input and output. If k is supplied with no options, it is assigned for input only. If s is supplied with no options, it is assigned for output only.
v virtual_address1 virtual_address2 [size](Sun-3 and Sun-4 only)
Display the contents of virtual_address1 (lower) virtual_address2 (higher) in the format specified by size:
bbyte format (the default)
wword format
llong word format
Enter return to pause for viewing; enter another return character to resume the display. To terminate the display at any time, press the space bar.
For example, the following command displays the contents of virtual address space from address 0x1000 to 0x2000 in word format:
v 1000 2000 W
w[virtual_address][argument](Sun-3 and Sun-4 only)
Set the execution vector to a predetermined or default routine. Pass virtual_address and argument to that routine.
To set up a predetermined routine to jump to, a user program must, prior to executing the monitor’s w command, set the variable ∗romp->v_vector_cmd to be equal to the virtual address of the desired routine. Predetermined routines need not necessarily return control to the monitor.
The default routine, defined by the monitor, prints the user-supplied vector according to the format supplied in argument. This format can be one of:
%xhexadecimal
%ddecimal
x(Sun-3 and Sun-4 only)
Display a menu of extended tests. These diagnostics permit additional testing of such things as the I/O port connectors, video memory, workstation memory and keyboard, and boot device paths.
yc context_number(Sun-4 only)
yp|scontext_number virtual_address
Flush the indicated context, context page, or context segment. c flushes context context_number. p flushes the page beginning at virtual_address within context context_number. s flushes the segment beginning at virtual_address within context context_number.
z[virtual_address](Sun-3 only)
Set a breakpoint at virtual_address in the address space selected by the s command.
Sun Release 3.2 — Last change: 3 June 1987