Linker Script Initialized Data

Brett Swimley brett.swimley at aedbozeman.com
Tue Jan 6 17:07:50 UTC 2004


Hi All-

My desire is to have a copy of initialized data that my BSP can copy to 
the "working" data area at run time.  I'm downloading via BDM to a 
target system, and have to download the entire executible each time due 
to not having variables re-initialized to default values.  I'd like to 
not have to dedicate a block of memory for this, but link the sections 
contiguously, only allocating a separate section for the "src" of the 
initialized data.

I'm trying to follow the concepts listed on the following page:

http://www.rtems.com/onlinedocs/doc-current/share/rtems/html/bsp_howto/bsp_howto00022.html

but I'm not convinced that things are working correctly.

FWIW, I load my .text section first, then .data, then .bss.  All going 
into the ram memory section (similar to the gen68340 linker script).  Is 
there a way to confirm that the objcopy command is doing what is 
expected? Do I need to change my linker script to rearrange how sections 
are loaded?

Can I accomplish the same thing just by making some changes in the 
linkcmds file?

Any help or advice is appreciated.

Regards,

Brett

-- 
Brett Swimley
Advanced Electronic Designs
brett.swimley at aedbozeman.com
ph: 406-585-8892 fax: 406-585-8893






More information about the users mailing list