From: Esben Nielsen <simlo@phys.au.dk>
To: david singleton <dsingleton@mvista.com>
Cc: robustmutexes@lists.osdl.org, Ingo Molnar <mingo@elte.hu>,
linux-kernel@vger.kernel.org
Subject: Re: robust futex heap support patch
Date: Mon, 5 Dec 2005 23:30:16 +0100 (MET) [thread overview]
Message-ID: <Pine.OSF.4.05.10512052144530.26388-100000@da410.phys.au.dk> (raw)
In-Reply-To: <2F3CDB0C-5E50-11DA-8242-000A959BB91E@mvista.com>
Hi,
I got a little time to look at your current patch (2.6.14-rt21-rf8).
I noticed a problem in futex_wake_robust(). You have a "goto retry" to
solve the following situation:
Task A Task B
takes futex in userspace
Tries to take mutex and sets the
waiting bit in user space
releases futex, notices task B
calls kernel and enters
futex_wake_robust()
retry:
if not owner in rt_mutex
goto retry;
Calls kernel
Makes A owner in rt_mutex
blocks
Leaves retry-loop and
completes the futex wake
operation as normally.
However, if Task A is RT on a UP machine it will go on in the retry loop
forever. Task B will never get the CPU to complete it's kernel-call.
You have probably by manipulating the userspace flag from within the
rt_mutex code :-(
Esben
On Fri, 25 Nov 2005, david singleton wrote:
> There is a new patch, patch-2.6.14-rt15-rf1, that adds support for
> robust and priority inheriting
> pthread_mutexes on the 'heap'.
>
> The previous patches only supported either file based pthread_mutexes
> or mmapped anonymous memory based pthread_mutexes. This patch allows
> pthread_mutexes
> to be 'malloc'ed while using the PTHREAD_MUTEX_ROBUST_NP attribute
> or PTHREAD_PRIO_INHERIT attribute.
>
> The patch can be found at:
>
> http://source.mvista.com/~dsingleton
>
> David
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
>
next prev parent reply other threads:[~2005-12-05 22:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-11-26 7:42 david singleton
2005-11-26 13:31 ` Ingo Molnar
2005-11-26 20:51 ` david singleton
2005-12-05 22:30 ` Esben Nielsen [this message]
2005-12-06 4:51 ` david singleton
2005-12-06 14:06 ` Esben Nielsen
2005-12-06 15:23 ` david singleton
2005-12-07 1:23 ` Randy.Dunlap
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=Pine.OSF.4.05.10512052144530.26388-100000@da410.phys.au.dk \
--to=simlo@phys.au.dk \
--cc=dsingleton@mvista.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=robustmutexes@lists.osdl.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®