[PATCH] Use linker set for system initialization
Sebastian Huber
sebastian.huber at embedded-brains.de
Fri Dec 11 06:32:41 UTC 2015
On 11/12/15 06:17, Chris Johns wrote:
> On 12/10/15 19:14, Sebastian Huber wrote:
>> Make rtems_initialize_data_structures(),
>> rtems_initialize_before_drivers() and rtems_initialize_device_drivers()
>> static.
>
> Is this needed or is this something you can now do so why not?
They are not longer part of the API and it can be done now.
>
> The only reason I ask is the trace linker needs external symbols to
> work and they are interesting symbols. Static symbols cannot be
> remapped by gld.
I think tracing is not really interesting in the system startup
sequence. It is single threaded with interrupts disabled. So, in case
there is a problem, a classic debugger should be sufficient.
The general pattern for the system initialization via the linker set is:
static void constructor(void)
{
...
}
RTEMS_SYSINIT_ITEM(
constructor,
RTEMS_SYSINIT_XYZ,
RTEMS_SYSINIT_ORDER_MIDDLE
);
void some_public_api_func(void)
{
...
}
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber at embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
More information about the devel
mailing list