This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Confusion re: hal_vsr_table



On 15-May-2001 Jeff Lasslett wrote:
> Greetings,
> 
>       I am in the process of getting redboot to run from flash on
> custom hardware.  The custom hardware is built around an MPC850 &
> so I am porting the Motorola MBX development board platform.  I got
> my ecos sources out of CVS within the last three months.
> 
> Everything seems fine until global constructors are called
> (cyg_hal_invoke_constructors).  A constructor is called that is supposed
> to be at 0x304C but I found no code at this address.  My map file says that
> something was supposed to be there though.  Here's a bit of my map file:-
> 
>  .text.__static_initialization_and_destruction_0
>                 0x00003014       0x38
> //C/programming/redhat/ecos/ecos_build/redboot_install/lib/extras.o
> 
> .text._GLOBAL_.I.49000.__C_programming_redhat_ecos_packages_io_common_curren
> t_src_ioinit.cxx2J8s4d
>                 0x0000304c       0x2c
> //C/programming/redhat/ecos/ecos_build/redboot_install/lib/extras.o
>  .text.serial_init
>                 0x00003078       0xc4
> //C/programming/redhat/ecos/ecos_build/redboot_install/lib/extras.o
> 
> After a bit more investigating I found that the 'hal_vsr_table' is located
> at 0x3000.  The hal_mon_init macro initialises the hal_vsr_table, wiping
> out whatever was at 0x3000 before.
> The trouble is that this is FLASH memory on my board
> (there are actually SRAM chips there at the moment but it will be
> FLASH soon enough) so if hal_vsr_table needs initialising then it can't
> be located at this address (unless I change where flash & sram are
> mapped in the 850's address range.  Is this what I need to do?).
> 
> I'm confused.  I want to get redboot to run from flash.  Where am I
> supposed to located the hal_vsr_table?  I can see in the linker script
> that it is located at 0x3000.  Can I move it?  Am I supposed too?

The location of the VSR table is wholy dependent on your memory map.  The
Motorola MBX board has DRAM at 0x00000000, thus we put the VSR at a well-known
address within that section.

You should look carefully at the memory map/layout for your system.  These
are primarily controlled via the MLT (Memory Layout Tool), but the manifestation
is in the "mlt_XXX.ldi" files (if you don't have MLT available).


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]