[U-Boot-Users] ARM exception vectors -- relocating

Curt Brune curt at cucy.com
Tue Jul 6 19:27:30 CEST 2004


I have a question about relocating the exception vectors for the ARM
platform.  I am working with cpu/arm720t/start.S and want to use
interrupts, but I think I see a problem with the code as it stands
now.  Consider the following scenario:

1. power on, cpu starts executing from address 0x0, which is located
   in flash.

2. memsetup.S configures 8MB SRAM to begin at address 0x0 and remaps
   flash to address 0x01000000.

3. back in start.S u-boot is relocated(copied) from flash to TEXT_BASE
   = 0x007d0000.

Now the exception vectors are sitting in SRAM @ 0x007d0000 and in
flash @ 0x0100000 -- if I want to use interrupts, however, the
exception vectors need to be in SRAM at address 0x0.

Currently I have added an additional relocation step to start.S that
explicitly copies the vectors from flash to 0x0 (in SRAM) if TEXT_BASE
is not equal 0x0 (if TEXT_BASE is equal to 0x0 there is no problem).

Question: Is start.S the correct place to put this, perhaps bracketed
with "#ifdef CONFIG_USE_IRQ/#endif"?  It seems like a global problem
that all arm720t boards that use interrupts would have.  Or is
memsetup.S a better place for this?




 Curt Brune           | Phone   1.650.380.2528 |     Managing Principal
 curt at cucy.com        | WWW       www.cucy.com |           Cucy Systems
             Cucy Systems -- Software. Integration. Training.

More information about the U-Boot mailing list