From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11094 invoked by alias); 1 Apr 2007 15:25:18 -0000 Received: (qmail 11066 invoked by uid 22791); 1 Apr 2007 15:25:16 -0000 X-Spam-Check-By: sourceware.org Received: from main.gmane.org (HELO ciao.gmane.org) (80.91.229.2) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 01 Apr 2007 16:25:13 +0100 Received: from list by ciao.gmane.org with local (Exim 4.43) id 1HY1vU-00083u-1h for ecos-discuss@sources.redhat.com; Sun, 01 Apr 2007 17:25:04 +0200 Received: from grante.dsl.visi.com ([208.42.141.248]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 01 Apr 2007 17:25:04 +0200 Received: from grante by grante.dsl.visi.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 01 Apr 2007 17:25:04 +0200 To: ecos-discuss@sources.redhat.com From: Grant Edwards Date: Sun, 01 Apr 2007 15:25:00 -0000 Message-ID: References: User-Agent: slrn/0.9.8.1 (Linux) X-IsSubscribed: yes Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: [ECOS] Re: Placing data at an absolute address X-SW-Source: 2007-04/txt/msg00002.txt.bz2 On 2007-04-01, Laurie Gellatly 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