From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: rpm@xenomai.org
Cc: xenomai-core <xenomai@xenomai.org>
Subject: Re: [Xenomai-core] Summary: Xenomai 2.3.2 and 2.4 lock-ups and OOPSes
Date: Fri, 7 Sep 2007 20:53:52 +0200 [thread overview]
Message-ID: <18145.40512.345477.578858@domain.hid> (raw)
In-Reply-To: <1189169200.26986.52.camel@domain.hid>
Philippe Gerum wrote:
> On Fri, 2007-09-07 at 11:27 +0200, Peter Soetens wrote:
> > Just in case you hooked off the long discussion about the issues we found from
> > Xenomai 2.3.2 on:
> >
> > o We are using the xeno_native skin, create Xeno tasks and semaphores, but
> > have strong indications that the crashes are caused by the memory allocation
> > scheme of Xenomai in combination with task creation/deletion
> > o We found two ways to break Xenomai, causing a 'Killed' (rt_task_delete)
> > and causing an OOPS (rt_task_join).
> > o They happen on 2.6.20 and 2.6.22 kernels
> > o On the 2.3 branch, r2429 works, r2433 causes the faults. The patch is
> > small, and in the ChangLog:
> >
> > 2007-05-11 Philippe Gerum <rpm@xenomai.org>
> >
> > * include/nucleus/heap.h (xnfreesafe): Use xnpod_current_p() when
> > checking for deferral.
> >
> > * include/nucleus/pod.h (xnpod_current_p): Give exec mode
> > awareness to this predicate, checking for primary/secondary mode
> > of shadows.
> >
> > 2007-05-11 Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
> >
> > * ksrc/skins: Always defer thread memory release in deletion hook
> > by calling xnheap_schedule_free() instead of xnfreesafe().
> >
> > o We reverted this patch on HEAD of the 2.3 branch, but got -ENOMEM errors
> > during Xenomai resource allocations, indicating that later changes depend on
> > this patch. So we use clean HEAD again further on to find the causes:
> > o A first test (in Orocos) creates one thread, two semaphores, lets it wait
> > on them and cleans up the thread.
>
> Please point me at the actual Orocos test code that breaks, with the
> hope to get a fairly standalone test case from it; if you do have a
> standalone test case already, this would be even better. I intend to
> address this issue asap.
Before you have a piece of code that causes the crash, I gave a look at
the code involved. The only suspicious thing I see is that the correct
working of native skins thread termination depends on the execution
order of the two deletion hooks, the one in task.c and the one in
syscall.c. As a matter of fact, if the one in task.c is executed before
the one in syscall.c, the task magic is changed and xnshadow_unmap will
never be called. I suspect this is true for all skins, but I do not know
if this could cause a crash.
--
Gilles Chanteperdrix.
next prev parent reply other threads:[~2007-09-07 18:53 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-07 9:27 [Xenomai-core] Summary: Xenomai 2.3.2 and 2.4 lock-ups and OOPSes Peter Soetens
2007-09-07 12:46 ` Philippe Gerum
2007-09-07 18:53 ` Gilles Chanteperdrix [this message]
2007-09-07 19:07 ` Gilles Chanteperdrix
2007-09-13 8:06 ` Peter Soetens
2007-09-13 8:22 ` Peter Soetens
2007-09-13 12:49 ` Philippe Gerum
2007-09-15 18:52 ` [Xenomai-core] [FIX] " Philippe Gerum
2007-09-16 17:49 ` Gilles Chanteperdrix
2007-09-16 19:31 ` Philippe Gerum
2007-09-17 12:55 ` Peter Soetens
2007-09-17 13:59 ` Peter Soetens
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=18145.40512.345477.578858@domain.hid \
--to=gilles.chanteperdrix@xenomai.org \
--cc=rpm@xenomai.org \
--cc=xenomai@xenomai.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.