This is the mail archive of the
mailing list for the eCos project.
Re: Different section placement for kernel and application
- From: Grant Edwards <grant dot b dot edwards at gmail dot com>
- To: ecos-discuss at sources dot redhat dot com
- Date: Thu, 27 Jan 2011 18:24:31 +0000 (UTC)
- Subject: [ECOS] Re: Different section placement for kernel and application
- References: <2815371.163.1296147619546.JavaMail.neratec@martin-lucid32> <917898.171.1296149053545.JavaMail.neratec@martin-lucid32>
On 2011-01-27, Martin R??sch <email@example.com> wrote:
> I'm trying to figure out how to run the eCos kernel from ROM and run
> the application (the main() function) from RAM on the STM32 Eval
> Board. Is it possible to place the text, data and rodata sections
> from the target library to a different memory address (i.e. flash)
> than the sections of the application in the image?
No, that's not possible in any general/useful sense without major
changes to the way eCos is designed and built.
The way eCos is built there is no logical separation between the
kernel and the application. They're both just C/C++ functions that
are linked together to form a single executable ELF file.
In theory, you could apply section attributes to all of the kernel
functions (or all of the application functions) so that you could
separate them at link time into different output sections. But, that
wouldn't really be useful, since the linkage between the two output
would require that they always be updated together in the target
I _suspect_ what you're really asking about is some sort of
position-independent API between kernel, libraries, and application so
that you can update one without updating the others -- something akin
to the Unix syscall API or the Unix shared library mechanism that
allows kernel, application, and libraries to be changed independently.
Grant Edwards grant.b.edwards Yow! Is this going to
at involve RAW human ecstasy?
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss