aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m68k/ifpsp060/isp.doc
diff options
context:
space:
mode:
Diffstat (limited to 'arch/m68k/ifpsp060/isp.doc')
-rw-r--r--arch/m68k/ifpsp060/isp.doc218
1 files changed, 218 insertions, 0 deletions
diff --git a/arch/m68k/ifpsp060/isp.doc b/arch/m68k/ifpsp060/isp.doc
new file mode 100644
index 000000000000..5a90fded3f0b
--- /dev/null
+++ b/arch/m68k/ifpsp060/isp.doc
@@ -0,0 +1,218 @@
1~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2MOTOROLA MICROPROCESSOR & MEMORY TECHNOLOGY GROUP
3M68000 Hi-Performance Microprocessor Division
4M68060 Software Package
5Production Release P1.00 -- October 10, 1994
6
7M68060 Software Package Copyright © 1993, 1994 Motorola Inc. All rights reserved.
8
9THE SOFTWARE is provided on an "AS IS" basis and without warranty.
10To the maximum extent permitted by applicable law,
11MOTOROLA DISCLAIMS ALL WARRANTIES WHETHER EXPRESS OR IMPLIED,
12INCLUDING IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE
13and any warranty against infringement with regard to the SOFTWARE
14(INCLUDING ANY MODIFIED VERSIONS THEREOF) and any accompanying written materials.
15
16To the maximum extent permitted by applicable law,
17IN NO EVENT SHALL MOTOROLA BE LIABLE FOR ANY DAMAGES WHATSOEVER
18(INCLUDING WITHOUT LIMITATION, DAMAGES FOR LOSS OF BUSINESS PROFITS,
19BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, OR OTHER PECUNIARY LOSS)
20ARISING OF THE USE OR INABILITY TO USE THE SOFTWARE.
21Motorola assumes no responsibility for the maintenance and support of the SOFTWARE.
22
23You are hereby granted a copyright license to use, modify, and distribute the SOFTWARE
24so long as this entire notice is retained without alteration in any modified and/or
25redistributed versions, and that such modified versions are clearly identified as such.
26No licenses are granted by implication, estoppel or otherwise under any patents
27or trademarks of Motorola, Inc.
28~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2968060 INTEGER SOFTWARE PACKAGE (Kernel version)
30------------------------------------------------
31
32The file isp.sa contains the 68060 Integer Software Package.
33This package is essentially an exception handler that can be
34integrated into an operating system to handle the "Unimplemented
35Integer Instruction" exception vector #61.
36This exception is taken when any of the integer instructions
37not hardware implemented on the 68060 are encountered. The
38isp.sa provides full emulation support for these instructions.
39
40The unimplemented integer instructions are:
41 64-bit divide
42 64-bit multiply
43 movep
44 cmp2
45 chk2
46 cas (w/ a misaligned effective address)
47 cas2
48
49Release file format:
50--------------------
51The file isp.sa is essentially a hexadecimal image of the
52release package. This is the ONLY format which will be supported.
53The hex image was created by assembling the source code and
54then converting the resulting binary output image into an
55ASCII text file. The hexadecimal numbers are listed
56using the Motorola Assembly Syntax assembler directive "dc.l"
57(define constant longword). The file can be converted to other
58assembly syntaxes by using any word processor with a global
59search and replace function.
60
61To assist in assembling and linking this module with other modules,
62the installer should add a symbolic label to the top of the file.
63This will allow calling routines to access the entry points
64of this package.
65
66The source code isp.s has also been included but only for
67documentation purposes.
68
69Release file structure:
70-----------------------
71
72(top of module)
73 -----------------
74 | | - 128 byte-sized section
75 (1) | Call-Out | - 4 bytes per entry (user fills these in)
76 | | - example routines in iskeleton.s
77 -----------------
78 | | - 8 bytes per entry
79 (2) | Entry Point | - user does a "bra" or "jmp" to this address
80 | |
81 -----------------
82 | | - code section
83 (3) ~ ~
84 | |
85 -----------------
86(bottom of module)
87
88The first section of this module is the "Call-out" section. This section
89is NOT INCLUDED in isp.sa (an example "Call-out" section is provided at
90the end of the file iskeleton.s). The purpose of this section is to allow
91the ISP routines to reference external functions that must be provided
92by the host operating system. This section MUST be exactly 128 bytes in
93size. There are 32 fields, each 4 bytes in size. Each field corresponds
94to a function required by the ISP (these functions and their location are
95listed in "68060ISP call-outs" below). Each field entry should contain
96the address of the corresponding function RELATIVE to the starting address
97of the "call-out" section. The "Call-out" section must sit adjacent to the
98isp.sa image in memory.
99
100The second section, the "Entry-point" section, is used by external routines
101to access the functions within the ISP. Since the isp.sa hex file contains
102no symbol names, this section contains function entry points that are fixed
103with respect to the top of the package. The currently defined entry-points
104are listed in section "68060 ISP entry points" below. A calling routine
105would simply execute a "bra" or "jmp" that jumped to the selected function
106entry-point.
107
108For example, if the 68060 hardware took a "Unimplemented Integer Instruction"
109exception (vector #61), the operating system should execute something
110similar to:
111
112 bra _060ISP_TOP+128+0
113
114(_060ISP_TOP is the starting address of the "Call-out" section; the "Call-out"
115section is 128 bytes long; and the Unimplemented Integer ISP handler entry
116point is located 0 bytes from the top of the "Entry-point" section.)
117
118The third section is the code section. After entering through an "Entry-point",
119the entry code jumps to the appropriate emulation code within the code section.
120
12168060ISP call-outs: (details in iskeleton.s)
122--------------------
1230x000: _060_real_chk
1240x004: _060_real_divbyzero
1250x008: _060_real_trace
1260x00c: _060_real_access
1270x010: _060_isp_done
128
1290x014: _060_real_cas
1300x018: _060_real_cas2
1310x01c: _060_real_lock_page
1320x020: _060_real_unlock_page
133
1340x024: (Motorola reserved)
1350x028: (Motorola reserved)
1360x02c: (Motorola reserved)
1370x030: (Motorola reserved)
1380x034: (Motorola reserved)
1390x038: (Motorola reserved)
1400x03c: (Motorola reserved)
141
1420x040: _060_imem_read
1430x044: _060_dmem_read
1440x048: _060_dmem_write
1450x04c: _060_imem_read_word
1460x050: _060_imem_read_long
1470x054: _060_dmem_read_byte
1480x058: _060_dmem_read_word
1490x05c: _060_dmem_read_long
1500x060: _060_dmem_write_byte
1510x064: _060_dmem_write_word
1520x068: _060_dmem_write_long
153
1540x06c: (Motorola reserved)
1550x070: (Motorola reserved)
1560x074: (Motorola reserved)
1570x078: (Motorola reserved)
1580x07c: (Motorola reserved)
159
16068060ISP entry points:
161-----------------------
1620x000: _060_isp_unimp
163
1640x008: _060_isp_cas
1650x010: _060_isp_cas2
1660x018: _060_isp_cas_finish
1670x020: _060_isp_cas2_finish
1680x028: _060_isp_cas_inrange
1690x030: _060_isp_cas_terminate
1700x038: _060_isp_cas_restart
171
172Integrating cas/cas2:
173---------------------
174The instructions "cas2" and "cas" (when used with a misaligned effective
175address) take the Unimplemented Integer Instruction exception. When the
176060ISP is installed properly, these instructions will enter through the
177_060_isp_unimp() entry point of the ISP.
178
179After the 060ISP decodes the instruction type and fetches the appropriate
180data registers, and BEFORE the actual emulated transfers occur, the
181package calls either the "Call-out" _060_real_cas() or _060_real_cas2().
182If the emulation code provided by the 060ISP is sufficient for the
183host system (see isp.s source code), then these "Call-out"s should be
184made, by the system integrator, to point directly back into the package
185through the "Entry-point"s _060_isp_cas() or _060_isp_cas2().
186
187One other necessary action by the integrator is to supply the routines
188_060_real_lock_page() and _060_real_unlock_page(). These functions are
189defined further in iskeleton.s and the 68060 Software Package Specification.
190
191If the "core" emulation routines of either "cas" or "cas2" perform some
192actions which are too system-specific, then the system integrator must
193supply new emulation code. This new emulation code should reside within
194the functions _060_real_cas() or _060_real_cas2(). When this new emulation
195code has completed, then it should re-enter the 060ISP package through the
196"Entry-point" _060_isp_cas_finish() or _060_isp_cas2_finish().
197To see what the register state is upon entering _060_real_cas() or
198_060_real_cas2() and what it should be upon return to the package through
199_060_isp_cas_finish() or _060_isp_cas2_finish(), please refer to the
200source code in isp.s.
201
202Miscellaneous:
203--------------
204
205_060_isp_unimp:
206----------------
207- documented in 2.2 in spec.
208- Basic flow:
209 exception taken ---> enter _060_isp_unimp --|
210 |
211 |
212 may exit through _060_real_itrace <----|
213 or |
214 may exit through _060_real_chk <----|
215 or |
216 may exit through _060_real_divbyzero <----|
217 or |
218 may exit through _060_isp_done <----|