Startup Code Example - Intel i960 Jx Developer's Manual

Microprocessor
Table of Contents

Advertisement

After initialization, the software is responsible for copying data structures from ROM into RAM.
The processor is then reinitialized with a new PRCB which contains the base addresses of the new
data structures in RAM.
Reinitialization is required to relocate any of the data structures listed below, since the processor
caches the pointers to the structures.
The processor caches the following pointers during its initialization. To modify these data
structures, a software re-initialization is needed.
Interrupt Table Address
Fault Table Address
System Procedure Table Address
Control Table Address
12.5

Startup Code Example

After initialization is complete, user start-up code typically copies initialized data structures from
ROM to RAM, reinitializes the processor, sets up the first stack frame, changes the execution state
to non-interrupted and calls the _main routine. This section presents an example start-up routine
and associated header file. This simplified start-up file can be used as a basis for more complete
initialization routines.
The examples in this section are useful for creating and evaluating startup code. The following lists
the example's number, name and page.
Example 12-3. Initialization Header File (init.h) (pg. 12-24)
Example 12-4., Startup Routine (init.s) (pg. 12-25)
Example 12-5., High-Level Startup Code (initmain.c) (pg. 12-28)
Example 12-6., Control Table (ctltbl.c) (pg. 12-29)
Example 12-7., Initialization Boot Record File (rom_ibr.c) (pg. 12-30)
Example 12-8., Linker Directive File (init.ld) (pg. 12-31)
Example 12-9., Makefile (pg. 12-33)
INITIALIZATION AND SYSTEM REQUIREMENTS
12
12-23

Advertisement

Table of Contents
loading

Table of Contents