On 14/05/07, M. Koehrer <[EMAIL PROTECTED]> wrote:
> HI all,
>
> thanks for all the responses.
> Using mutexes instead of semaphores actually solves the issue.
> However, the API documentation of rt_sem_create() is a little bit confusing 
> here.
> The "mode" parameter of rt_sem_create() may contain "S_PRIO" which
> "makes tasks pend in priority order on the semaphore".
> I interpret this that it works actually the very same as with mutexes. 
> However, it
> is implemented that sem_v directly triggers a waiting task (even if it is low 
> prio).

So what's wrong here? It triggers a waiter with the highest priority
amongst _other waiters_ and in your case it's "L" (if I remember
abreviations correctly) - there are no other waiters in your case btw.
Waking up a sleeper really means - a resource is now yours.

How would the system know that your high-priority task which calls
rt_sem_v() / which means - I'm finished with a resource) / will call
rt_sem_p() as the very next step :o)


-- 
Best regards,
Dmitry Adamushko

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

Reply via email to