From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: "Landau, Bracha" <BLandau@domain.hid>
Cc: "xenomai@xenomai.org" <xenomai@xenomai.org>
Subject: Re: [Xenomai-help] pthread_mutex_lock returns 1
Date: Tue, 30 Jun 2009 10:18:13 +0200 [thread overview]
Message-ID: <4A49CA45.8000501@domain.hid> (raw)
In-Reply-To: <065A7D06F7D4E546A18E80E08D066E181189FBBFD4@domain.hid>
Landau, Bracha wrote:
> Thanks for your help.
>
> I tried to put in "printk"s in the kernel implementation of the
> xenomai pthread_mutex_lock, and it did not work. Neither did
> xnprintf. I did this in order to find out what is the exact cause of
> the error; generally adding printk's in the kernel implementation of
> functions did work, but on this one it didn't.
That is because the implementation of the pthread_mutex_lock service is
in ksrc/skins/posix/syscall.c, and calls pse51_mutex_timedlock_break in
ksrc/skins/posix/mutex.c, pthread_mutex_lock implementation in
ksrc/skins/posix/mutex.c is only for kernel-space users. We had to split
this for correct handling of Linux signals.
>
> Is there any way to discern what exactly the problem is? This code
> was working on earlier versions of Xenomai (2.2) and did not generate
> an error on this instance of calling pthread_mutex_lock.
Ok, I have checked, 2.2 already had the pshared attribute, so I think
your issue is the other one (calling phtread_mutex services from non
real-time threads). Or maybe some other undocumented reason, which you
should find by adding printks... :-)
> This e-mail is confidential, the property of NDS Ltd and intended for
> the addressee only. Any dissemination, copying or distribution of
> this message or any attachments by anyone other than the intended
> recipient is strictly prohibited.
Did I tell you that I found these footers stupid?
--
Gilles
next prev parent reply other threads:[~2009-06-30 8:18 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-29 14:22 [Xenomai-help] pthread_mutex_lock returns 1 Landau, Bracha
2009-06-29 14:32 ` Gilles Chanteperdrix
2009-06-30 7:24 ` Landau, Bracha
2009-06-30 7:53 ` Gilles Chanteperdrix
2009-06-30 7:56 ` Landau, Bracha
2009-06-30 8:05 ` Gilles Chanteperdrix
2009-06-30 8:18 ` Gilles Chanteperdrix [this message]
2009-07-01 8:31 ` Landau, Bracha
2009-07-01 8:50 ` Gilles Chanteperdrix
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=4A49CA45.8000501@domain.hid \
--to=gilles.chanteperdrix@xenomai.org \
--cc=BLandau@domain.hid \
--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.