source: trunk/libs/newlib/src/libgloss/hp74x/README @ 653

Last change on this file since 653 was 444, checked in by satin@…, 7 years ago

add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc

File size: 5.3 KB
Line 
1*** Registers
2        GR0     *always zero
3        GR1     scratch
4        GR2     normal return register
5        GR27    Global Data Pointer (Must be set in crt0)
6        GR30    SP stack pointer
7        GR31    milicode return pointer
8
9        SR*     Space registers
10
11        CR24-31 Temporary Control Registers
12        CR14    Vector Table Register (like VBR on an m68020)
13        CR0     Put in a count, causes exception when decremented to 0.
14
15FORTH's magic number is 031240
16
17***
18    Series 700/800
19      The following options are also supported:
20
21           -snnn          set the initial system load (ISL) start address to
22                          nnn in the volume label.  This is useful when
23                          building boot media for Series 700/800 systems.
24
25           -lnnn          specifies the length in bytes of the ISL code in
26                          the LIF volume.
27
28           -ennn          set the ISL entry point to nnn bytes from the
29                          beginning of the ISL.  For example, specifying -
30                          e3272 means that the ISL entry point is 3272
31                          (decimal) bytes from the beginning of the ISL
32                          object module.
33
34           -Knnn          forces the directory start location to be the
35                          nearest multiple of nnn x 1024 bytes from the
36                          beginning of the volume.  This is necessary for
37                          booting Series 700/800 systems from LIF media.
38
39           -n xxx         Sets the volume name to be xxx.
40        lifinit -v64000000 -d64 -nISL10 -K2 -s4096 -l61440 -e5336 this_lif
41
42# lifcp --
43#       -r      Forces RAW mode copying. (file type BIN (-23951))
44#       -T      Sets the file type of the directory entry.
45#       -Knnn   forces each file copied in to begin on a nnn x
46#               1024-byte boundary from the beginning of the volume
47#       Note: the word echoed below MUST be 10 characters exactly.
48#
49        (echo "FORTH    ") | lifcp -r -T-030001 -K2 - this_lif:AUTO     
50
51
52#
53# somxtract infile outfile --
54#       converts a series 800 file *only* into a raw image
55
56It turns out the native cc and our current gcc produce series 700
57output, so in this case it runs till if fills up the hard disk.
58
59*** rombootlf5 is a FORTH interpreter in a "boot" image. (it won't run on
60the HP742 board)
61
62lifls -l rombootlf5
63volume ISL10 data size 249984 directory size 8 94/04/20 10:26:36
64filename   type   start   size     implement  created
65===============================================================
66ISL        -12800 16      240      0          94/04/20 10:26:36
67HPUX       -12928 256     496      0          94/04/20 10:26:37
68 IOMAP      -12960 752     1504     0          94/04/20 10:26:37
69AUTO       -12289 2256    1        0          94/04/20 10:26:38
70FORTH      -12960 2264    208      0          94/04/20 10:26:38
71HPFORTH    ASCII  2472    420      0          94/04/20 10:26:38
72BOOTROM    ASCII  2896    3849     0          94/04/20 10:26:40
73PAD1       -12290 6752    1172     0          94/04/20 10:26:40
74
75*** The ISL is only needed when booting the raw hardware. As we're runing
76on a monitor (barely) all we need is a crt0 that initiallizes the GR27
77Global Data Pointer and zero's bss.
78
79*** Initial Program Load
80--------------------
81From page 11-56, architecture book.
820x00000000 +------------------------------------+ 0
83           |    LIF_MAGIC       |               |
840x00000004 +------------------------------------+ 4
85           |                                    |
860x000000F0 +------------------------------------+ 240
87           |            IPL_ADDR                |
880x000000F4 +------------------------------------+ 244
89           |            IPL_SIZE                |
900x000000F8 +------------------------------------+ 248
91           |            IPL_ENTRY               |
920x000000FC +------------------------------------+ 252
93           |                                    |
94IPL_ADDR   +------------------------------------+ IPL_ADDR
95           |        Position Independant        |
96           |            IPL Code                |
97           |    (including IPL_CHECKSUM)        |
98           +------------------------------------+ IPL_ADDR + IPL_SIZE
99           |                                    |
100           +------------------------------------+
101
102IPL_ADDR        2 Kbyte aligned, nonzero
103IPL_SIZE        Multiple of 2Kbytes, <= 256 Kbytes
104IPL_ENTRY       Word aligned, less than IPL_SIZE
105
106Loads at IPL_START
107
108This is based on Cobra/Coral hardware:
109      LED register at 0xf080024
110      I/O status register at 0xf0800000
111      EEPROM at 0xf0810000 (LAN ID begins at byte 0)
112
113Here's a dump of the LIF volume header using "xd" (od with hex output)
114
115*
11600000f0 0000 1000 0000 9800 0000 0000 0000 0000
117                       ^^^^
118                This is the size
119*
1200000800 5445 5354 2020 2020 2020 a271 0000 0010
121        ^^^^ ^^^^ ^^^^ ^^^^ ^^^^           ^^^^<-- this is the ipl offset
122        this is the vol name     ^^^^<- this is the type
123
1240000810 0000 0098 9407 1919 1426 8001 0000 0000
125             ^^^^
126        This is the ipl size
127
128Interupts
129---------
130The vector table is access by %iva (%cr14). The address here must be a
131multiple of 2048. The indexes are:
1321       high-priority
1332       power failure
1343       recovery counter
1354       external interrupt
1365       low-priority machine check
1376       instruction TLB miss/instruction page fault
1387       instruction memory protection
1398       illegal instruction
1409       break instruction
14110      priviledged operation
14211      priviledged register
14312      overflow
14413      conditional
14514      assist exception
14615      data TLB miss fault/data page fault
14716      non access instruction TLB miss fault
14817      non access page TLB miss fault/non access data page fault
14918      data memory protection/unaligned data reference
15019      data memory break
15120      TLB dirty bit
15221      page reference
15322      assist emulation
15423      higher-priority transfer
15524      lower-priority transfe
15625      taken branch
Note: See TracBrowser for help on using the repository browser.