Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-16 Thread Jan Kiszka
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2011-07-15 15:10, Jan Kiszka wrote: But... right now it looks like we found our primary regression: nucleus/shadow: shorten the uninterruptible path to secondary mode. It opens a short windows during relax where the migrated task may be active

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-16 Thread Jan Kiszka
On 2011-07-16 10:52, Philippe Gerum wrote: On Sat, 2011-07-16 at 10:13 +0200, Jan Kiszka wrote: On 2011-07-15 15:10, Jan Kiszka wrote: But... right now it looks like we found our primary regression: nucleus/shadow: shorten the uninterruptible path to secondary mode. It opens a short windows

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-16 Thread Philippe Gerum
On Sat, 2011-07-16 at 11:15 +0200, Jan Kiszka wrote: On 2011-07-16 10:52, Philippe Gerum wrote: On Sat, 2011-07-16 at 10:13 +0200, Jan Kiszka wrote: On 2011-07-15 15:10, Jan Kiszka wrote: But... right now it looks like we found our primary regression: nucleus/shadow: shorten the

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-16 Thread Jan Kiszka
On 2011-07-16 11:56, Philippe Gerum wrote: On Sat, 2011-07-16 at 11:15 +0200, Jan Kiszka wrote: On 2011-07-16 10:52, Philippe Gerum wrote: On Sat, 2011-07-16 at 10:13 +0200, Jan Kiszka wrote: On 2011-07-15 15:10, Jan Kiszka wrote: But... right now it looks like we found our primary

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-15 Thread Gilles Chanteperdrix
On 07/14/2011 10:57 PM, Jan Kiszka wrote: On 2011-07-13 21:12, Gilles Chanteperdrix wrote: On 07/13/2011 09:04 PM, Jan Kiszka wrote: On 2011-07-13 20:39, Gilles Chanteperdrix wrote: On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-15 Thread Jan Kiszka
On 2011-07-15 14:30, Gilles Chanteperdrix wrote: On 07/14/2011 10:57 PM, Jan Kiszka wrote: On 2011-07-13 21:12, Gilles Chanteperdrix wrote: On 07/13/2011 09:04 PM, Jan Kiszka wrote: On 2011-07-13 20:39, Gilles Chanteperdrix wrote: On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-14 Thread Jan Kiszka
On 2011-07-13 21:12, Gilles Chanteperdrix wrote: On 07/13/2011 09:04 PM, Jan Kiszka wrote: On 2011-07-13 20:39, Gilles Chanteperdrix wrote: On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-13 Thread Gilles Chanteperdrix
On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57 PM, Jan Kiszka wrote: xnlock_put_irqrestore(nklock, s);

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-13 Thread Jan Kiszka
On 2011-07-13 20:39, Gilles Chanteperdrix wrote: On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57 PM, Jan Kiszka wrote:

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-13 Thread Gilles Chanteperdrix
On 07/13/2011 09:04 PM, Jan Kiszka wrote: On 2011-07-13 20:39, Gilles Chanteperdrix wrote: On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-13 Thread Philippe Gerum
On Wed, 2011-07-13 at 20:39 +0200, Gilles Chanteperdrix wrote: On 07/12/2011 07:43 PM, Jan Kiszka wrote: On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57 PM, Jan Kiszka wrote:

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59 PM, Jan Kiszka wrote: On 2011-07-11 21:51, Gilles Chanteperdrix wrote: On 07/11/2011 09:16

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59 PM, Jan Kiszka wrote: On 2011-07-11

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 12:59, Gilles Chanteperdrix wrote: On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 01:00 PM, Jan Kiszka wrote: On 2011-07-12 12:59, Gilles Chanteperdrix wrote: On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 13:04, Gilles Chanteperdrix wrote: On 07/12/2011 01:00 PM, Jan Kiszka wrote: On 2011-07-12 12:59, Gilles Chanteperdrix wrote: On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12 PM, Jan Kiszka wrote: On 2011-07-11

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 01:06 PM, Jan Kiszka wrote: On 2011-07-12 13:04, Gilles Chanteperdrix wrote: On 07/12/2011 01:00 PM, Jan Kiszka wrote: On 2011-07-12 12:59, Gilles Chanteperdrix wrote: On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12 08:41, Gilles Chanteperdrix wrote: On 07/11/2011 10:12

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 13:08, Gilles Chanteperdrix wrote: On 07/12/2011 01:06 PM, Jan Kiszka wrote: On 2011-07-12 13:04, Gilles Chanteperdrix wrote: On 07/12/2011 01:00 PM, Jan Kiszka wrote: On 2011-07-12 12:59, Gilles Chanteperdrix wrote: On 07/12/2011 09:22 AM, Jan Kiszka wrote: On 2011-07-12

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 01:10 PM, Jan Kiszka wrote: On 2011-07-12 13:08, Gilles Chanteperdrix wrote: On 07/12/2011 01:06 PM, Jan Kiszka wrote: On 2011-07-12 13:04, Gilles Chanteperdrix wrote: On 07/12/2011 01:00 PM, Jan Kiszka wrote: On 2011-07-12 12:59, Gilles Chanteperdrix wrote: On 07/12/2011 09:22

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 13:26, Gilles Chanteperdrix wrote: On 07/12/2011 01:10 PM, Jan Kiszka wrote: On 2011-07-12 13:08, Gilles Chanteperdrix wrote: On 07/12/2011 01:06 PM, Jan Kiszka wrote: On 2011-07-12 13:04, Gilles Chanteperdrix wrote: On 07/12/2011 01:00 PM, Jan Kiszka wrote: On 2011-07-12

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 13:56, Jan Kiszka wrote: However, this parallel unsynchronized execution of the gatekeeper and its target thread leaves an increasingly bad feeling on my side. Did we really catch all corner cases now? I wouldn't guarantee that yet. Specifically as I still have an obscure crash

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 01:58 PM, Jan Kiszka wrote: On 2011-07-12 13:56, Jan Kiszka wrote: However, this parallel unsynchronized execution of the gatekeeper and its target thread leaves an increasingly bad feeling on my side. Did we really catch all corner cases now? I wouldn't guarantee that yet.

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 14:06, Gilles Chanteperdrix wrote: On 07/12/2011 01:58 PM, Jan Kiszka wrote: On 2011-07-12 13:56, Jan Kiszka wrote: However, this parallel unsynchronized execution of the gatekeeper and its target thread leaves an increasingly bad feeling on my side. Did we really catch all

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Philippe Gerum
On Tue, 2011-07-12 at 14:57 +0200, Jan Kiszka wrote: On 2011-07-12 14:13, Jan Kiszka wrote: On 2011-07-12 14:06, Gilles Chanteperdrix wrote: On 07/12/2011 01:58 PM, Jan Kiszka wrote: On 2011-07-12 13:56, Jan Kiszka wrote: However, this parallel unsynchronized execution of the gatekeeper

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 17:48, Philippe Gerum wrote: On Tue, 2011-07-12 at 14:57 +0200, Jan Kiszka wrote: On 2011-07-12 14:13, Jan Kiszka wrote: On 2011-07-12 14:06, Gilles Chanteperdrix wrote: On 07/12/2011 01:58 PM, Jan Kiszka wrote: On 2011-07-12 13:56, Jan Kiszka wrote: However, this parallel

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 02:57 PM, Jan Kiszka wrote: xnlock_put_irqrestore(nklock, s); xnpod_schedule(); } @@ -1036,6 +1043,7 @@ redo: * to process this signal anyway. */ if (rthal_current_domain == rthal_root_domain) { +

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57 PM, Jan Kiszka wrote: xnlock_put_irqrestore(nklock, s); xnpod_schedule(); } @@ -1036,6 +1043,7 @@ redo: * to process this signal anyway. */ if

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Gilles Chanteperdrix
On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57 PM, Jan Kiszka wrote: xnlock_put_irqrestore(nklock, s); xnpod_schedule(); } @@ -1036,6 +1043,7 @@ redo: * to process this

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-12 Thread Jan Kiszka
On 2011-07-12 19:38, Gilles Chanteperdrix wrote: On 07/12/2011 07:34 PM, Jan Kiszka wrote: On 2011-07-12 19:31, Gilles Chanteperdrix wrote: On 07/12/2011 02:57 PM, Jan Kiszka wrote: xnlock_put_irqrestore(nklock, s); xnpod_schedule(); } @@

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Gilles Chanteperdrix
On 07/08/2011 06:29 PM, GIT version control wrote: @@ -2528,6 +2534,22 @@ static inline void do_taskexit_event(struct task_struct *p) magic = xnthread_get_magic(thread); xnlock_get_irqsave(nklock, s); + + gksched = thread-gksched; + if (gksched) { +

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Jan Kiszka
On 2011-07-11 20:53, Gilles Chanteperdrix wrote: On 07/08/2011 06:29 PM, GIT version control wrote: @@ -2528,6 +2534,22 @@ static inline void do_taskexit_event(struct task_struct *p) magic = xnthread_get_magic(thread); xnlock_get_irqsave(nklock, s); + +gksched =

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Jan Kiszka
On 2011-07-11 21:10, Jan Kiszka wrote: On 2011-07-11 20:53, Gilles Chanteperdrix wrote: On 07/08/2011 06:29 PM, GIT version control wrote: @@ -2528,6 +2534,22 @@ static inline void do_taskexit_event(struct task_struct *p) magic = xnthread_get_magic(thread);

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Gilles Chanteperdrix
On 07/11/2011 09:16 PM, Jan Kiszka wrote: On 2011-07-11 21:10, Jan Kiszka wrote: On 2011-07-11 20:53, Gilles Chanteperdrix wrote: On 07/08/2011 06:29 PM, GIT version control wrote: @@ -2528,6 +2534,22 @@ static inline void do_taskexit_event(struct task_struct *p) magic =

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Jan Kiszka
On 2011-07-11 21:51, Gilles Chanteperdrix wrote: On 07/11/2011 09:16 PM, Jan Kiszka wrote: On 2011-07-11 21:10, Jan Kiszka wrote: On 2011-07-11 20:53, Gilles Chanteperdrix wrote: On 07/08/2011 06:29 PM, GIT version control wrote: @@ -2528,6 +2534,22 @@ static inline void

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Gilles Chanteperdrix
On 07/11/2011 09:59 PM, Jan Kiszka wrote: On 2011-07-11 21:51, Gilles Chanteperdrix wrote: On 07/11/2011 09:16 PM, Jan Kiszka wrote: On 2011-07-11 21:10, Jan Kiszka wrote: On 2011-07-11 20:53, Gilles Chanteperdrix wrote: On 07/08/2011 06:29 PM, GIT version control wrote: @@ -2528,6 +2534,22

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Jan Kiszka
On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59 PM, Jan Kiszka wrote: On 2011-07-11 21:51, Gilles Chanteperdrix wrote: On 07/11/2011 09:16 PM, Jan Kiszka wrote: On 2011-07-11 21:10, Jan Kiszka wrote: On 2011-07-11 20:53, Gilles Chanteperdrix wrote: On 07/08/2011 06:29

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Gilles Chanteperdrix
On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59 PM, Jan Kiszka wrote: On 2011-07-11 21:51, Gilles Chanteperdrix wrote: On 07/11/2011 09:16 PM, Jan Kiszka wrote: On 2011-07-11 21:10, Jan Kiszka wrote: On 2011-07-11 20:53, Gilles

Re: [Xenomai-core] [Xenomai-git] Jan Kiszka : nucleus: Fix race between gatekeeper and thread deletion

2011-07-11 Thread Jan Kiszka
On 2011-07-11 22:09, Gilles Chanteperdrix wrote: On 07/11/2011 10:06 PM, Jan Kiszka wrote: On 2011-07-11 22:02, Gilles Chanteperdrix wrote: On 07/11/2011 09:59 PM, Jan Kiszka wrote: On 2011-07-11 21:51, Gilles Chanteperdrix wrote: On 07/11/2011 09:16 PM, Jan Kiszka wrote: On 2011-07-11