[Xenomai] [PATCH] boilerplate: do not call xenomai_init 2 times

Philippe Gerum rpm at xenomai.org
Thu Dec 15 15:47:33 CET 2016


On 12/15/2016 12:47 PM, Ronny Meeus wrote:
> bootstrap.o is linked to the application code.
> In case the execution of the static constructors is postponed
> in the applicaion and the auto-init feature is used, the
> xenomai_init is called 2 times:
> - once in the path of the wrap_main
> - later in the context of the static constructor
> 

Why do you keep the auto-init feature on, given that you already control
the early init code by postponing the execution of the C++ ctors? I
would rather expect something like:

- build with no-auto-init
- call xenomai_init() manually from your entry point to activate the
Xenomai services when you see fit.
- call the ctor init chain.

-- 
Philippe.



More information about the Xenomai mailing list