[Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Paolo Gai
Dear all, First of all, I would like to thank Philippe for the long and exaustive reply to my previous post about the scheduling example. I'm now trying the POSIX skin to write a very simple example using real-time priorities, RR and FIFO scheduling. The idea is that a high priority task cr

[Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Paolo Gai
Dear all, First of all, I would like to thank Philippe for the long and exaustive reply to my previous post about the scheduling example. I'm now trying the POSIX skin to write a very simple example using real-time priorities, RR and FIFO scheduling. The idea is that a high priority task cr

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Ulrich Schwab
On Friday 09 December 2005 15:33, Paolo Gai wrote: > Dear all, > > First of all, I would like to thank Philippe for the long and exaustive > reply to my previous post about the scheduling example. > > I'm now trying the POSIX skin to write a very simple example using > real-time priorities, RR and

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Gilles Chanteperdrix
Ulrich Schwab wrote: > On Friday 09 December 2005 15:33, Paolo Gai wrote: > > Dear all, > > > > First of all, I would like to thank Philippe for the long and exaustive > > reply to my previous post about the scheduling example. > > > > I'm now trying the POSIX skin to write a very simple exa

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Paolo Gai
Dear Gilles, Thanks again for the answer... Gilles Chanteperdrix wrote: [...] What happens for certain is that the access to stdout buffer, when compiling with the -D_REENTRANT flag, is serialized with a GNU libc POSIX mutex. This account for the consistent behaviour between GNU libc libpthrea

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Gilles Chanteperdrix
Paolo Gai wrote: > Gilles Chanteperdrix wrote: > >Working around this issue means using calls to unlocked versions of libc > >functions protected with Xenomai POSIX mutexes, such as, for example, > >myputs and myputchar (sufficient for Paolo example) defined as : > >[...] > > > > > Ok! I

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-10 Thread Paolo Gai
Gilles Chanteperdrix wrote: Paolo Gai wrote: > Gilles Chanteperdrix wrote: > >Working around this issue means using calls to unlocked versions of libc > >functions protected with Xenomai POSIX mutexes, such as, for example, > >myputs and myputchar (sufficient for Paolo example) defined as : > >[

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-10 Thread Paolo Gai
Ok, after having clicked ion the send button, I also discovered that NPTL uses INHERIT_SCHED by default in the pthread attributes http://sources.redhat.com/bugzilla/show_bug.cgi?id=145 I added it to the original examples, and I obtained the following (basically it is similar to the Case 1 depic

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-11 Thread Gilles Chanteperdrix
Paolo Gai wrote: > (...) > 1) why do i get "pthread_setschedparam failed: Success" ?? Why the > policy is not changed (am I still calling the Linux functions?) That one is a bug, fixed in the repository: it was due to the fact that PTHREAD_EXPLICIT_SCHED had different values in /usr/include/pt

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Ulrich Schwab
On Friday 09 December 2005 15:33, Paolo Gai wrote: > Dear all, > > First of all, I would like to thank Philippe for the long and exaustive > reply to my previous post about the scheduling example. > > I'm now trying the POSIX skin to write a very simple example using > real-time priorities, RR and

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Gilles Chanteperdrix
Ulrich Schwab wrote: > On Friday 09 December 2005 15:33, Paolo Gai wrote: > > Dear all, > > > > First of all, I would like to thank Philippe for the long and exaustive > > reply to my previous post about the scheduling example. > > > > I'm now trying the POSIX skin to write a very simple exa

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Paolo Gai
Dear Gilles, Thanks again for the answer... Gilles Chanteperdrix wrote: [...] What happens for certain is that the access to stdout buffer, when compiling with the -D_REENTRANT flag, is serialized with a GNU libc POSIX mutex. This account for the consistent behaviour between GNU libc libpthrea

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-09 Thread Gilles Chanteperdrix
Paolo Gai wrote: > Gilles Chanteperdrix wrote: > >Working around this issue means using calls to unlocked versions of libc > >functions protected with Xenomai POSIX mutexes, such as, for example, > >myputs and myputchar (sufficient for Paolo example) defined as : > >[...] > > > > > Ok! I

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-10 Thread Paolo Gai
Gilles Chanteperdrix wrote: Paolo Gai wrote: > Gilles Chanteperdrix wrote: > >Working around this issue means using calls to unlocked versions of libc > >functions protected with Xenomai POSIX mutexes, such as, for example, > >myputs and myputchar (sufficient for Paolo example) defined as : > >[

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-10 Thread Paolo Gai
Ok, after having clicked ion the send button, I also discovered that NPTL uses INHERIT_SCHED by default in the pthread attributes http://sources.redhat.com/bugzilla/show_bug.cgi?id=145 I added it to the original examples, and I obtained the following (basically it is similar to the Case 1 depic

Re: [Xenomai-help] Xenomai 2.0.1 - Posix Skin - realtime priorities - what I'm doing wrong?

2005-12-11 Thread Gilles Chanteperdrix
Paolo Gai wrote: > (...) > 1) why do i get "pthread_setschedparam failed: Success" ?? Why the > policy is not changed (am I still calling the Linux functions?) That one is a bug, fixed in the repository: it was due to the fact that PTHREAD_EXPLICIT_SCHED had different values in /usr/include/pt