This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
Re: Placing data at an absolute address
- From: Grant Edwards <grante at visi dot com>
- To: ecos-discuss at sources dot redhat dot com
- Date: Sun, 1 Apr 2007 15:24:54 +0000 (UTC)
- Subject: [ECOS] Re: Placing data at an absolute address
- References: <c09652430703260839y25bd4dc7o596d7f6957404133@mail.gmail.com> <OBEELMDOHGDFDEMJCJCJCEPCLLAA.laurie.gellatly@netic.com>
On 2007-04-01, Laurie Gellatly <laurie.gellatly@netic.com> wrote:
> For our eCos application, I'd like to place the MAC address at
> a particular address in flash and have it loaded as part of
> storing Redboot into the flash. At production time, a script
> would be run that finds that address section in redboot.elf
> and updates it before it is stored into the next unit. Finding
> the section in the elf is not the hard bit. I've tried adding
> a new section on the gcc command line and adding a variable
> into the C source which almost works except the section size
> is of length 0. How can I make the section 6 bytes long or is
> there a better way to do this whole thing?
You can use objcopy to add a new section from the command line.
--
Grant Edwards grante Yow! Was my SOY LOAF left
at out in th'RAIN? It tastes
visi.com REAL GOOD!!
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss