root_thread_exit in pSOS skin
I'm trying to use Xenomai over a Linux machine, in particular I'm trying to emulate a pSOS system by using the demo satch (executable satch_uvm). I see that root_thread_exit is never called.
How I have to do to get root_thread_exit called? I'd like to use this function to remove a pipe created in root_thread_init.
Regards
Quoted 6 lines · d p
I'm trying to use Xenomai over a Linux machine, in particular I'm trying to emulate a pSOS system by using the demo satch (executable
satch_uvm). I see thatroot_thread_exitis never called.How I have to do to get
root_thread_exitcalled? I'd like to use this function to remove a pipe created inroot_thread_init.
root_thread_exit maps to __xeno_user_exit [1], and that should get called by the UVM main function [2].
Jan
[1]http://www.rts.uni-hannover.de/xenomai/lxr/source/include/nucleus/types.h#L129 [2]http://www.rts.uni-hannover.de/xenomai/lxr/source/include/asm-uvm/system.h#L406
Quoted 3 lines · Jan Kiszka
root_thread_exitmaps to__xeno_user_exit[1], and that should get called by the UVM main function [2].
OK, but I put a xnprintf in root_thread_exit and I never saw this print. I stop the emulation with CTRL+C.
Regards
Quoted 9 lines · d p
Quoted 3 lines · Jan Kiszka
root_thread_exitmaps to__xeno_user_exit[1], and that should get called by the UVM main function [2].OK, but I put a xnprintf in
root_thread_exitand I never saw this print. I
stop the emulation with CTRL+C.
Yeah, that correlates very well with the endless loop a few line above in [2]...
In fact, I don't see how you should be able to install cleanup code this way under the UVM. Maybe replacing the for loop with something like this helps
while (uvm_thread_idle(&uvm_irqlock) >= 0)
/* empty loop */;
but I'm leaving terra firma right now (never worked with the UVM).
Jan