On 22/12/06, Gilles Chanteperdrix <[EMAIL PROTECTED]> wrote:

In absence of a better solution, I would recommend to use the "fault_vm"
 function after each fork.

But it's not safe. It doesn't stop any other rt threads (if there are
a few in this app.) from touching the wp-pages (it's not only about
stacks after all) in the mean time. So fault_vm() only increases the
probability of not-crashing but doesn't eliminate it completely.

So all the contextes have to be blocked starting from the moment
fork() is about to be called and till the moment a subsequent
fault_vm() is done.
It's ugly and that suggests fork() is not ok here at all.

And btw, vfork() should be a funny thing being called from
multi-threaded app. It blocks a calling context and borrows its
address space while other threads are continuing to run, well, with
the same context (maybe it's handled somehow, have to check).



--
                                                 Gilles Chanteperdrix


--
Best regards,
Dmitry Adamushko

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to