public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug nptl/17013] New: pthread_cond_broadcast could call lll_unlock() twice, breaking the shared data
@ 2014-06-03 22:26 hideaki.kimura at gmail dot com
  2014-06-04  7:01 ` [Bug nptl/17013] " siddhesh at redhat dot com
  2014-06-04 17:55 ` hideaki.kimura at gmail dot com
  0 siblings, 2 replies; 3+ messages in thread
From: hideaki.kimura at gmail dot com @ 2014-06-03 22:26 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=17013

            Bug ID: 17013
           Summary: pthread_cond_broadcast could call lll_unlock() twice,
                    breaking the shared data
           Product: glibc
           Version: 2.18
            Status: NEW
          Severity: normal
          Priority: P2
         Component: nptl
          Assignee: unassigned at sourceware dot org
          Reporter: hideaki.kimura at gmail dot com
                CC: drepper.fsp at gmail dot com

This reports an already-fixed bug that was in glibc 2.18 and 2.19.
The fix will be in the upcoming glibc 2.20, but many linux distros would employ
it much later.

For helping backport request in individual linux distros, I'd like to put
relevant information here.

An example error case I hit:
  - Several waitors wait on pthread_cond_wait with holding mutex.
  - One signal-er calls broadcast with holding mutex
  - The thread that invoked pthread_cond_broadcast occasionally hangs.
When I attach gdb, the hanging thread is waiting at lll_lock_wait() even though
there are no concurrent threads.

According to the commit history, it was caused by a commit on Feb 2013;
commit 8313cb997d2d("FUTEX_*_REQUEUE_PI support for
non-x86 code").

Then, it was fixed by this commit on Apr 2014;
https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=8f630cca5c36941db1cb48726016bbed80ec1041

So, the affected versions of glibc should be 2.18 and 2.19.

Yang/Siddhesh, does it sound right?

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug nptl/17013] pthread_cond_broadcast could call lll_unlock() twice, breaking the shared data
  2014-06-03 22:26 [Bug nptl/17013] New: pthread_cond_broadcast could call lll_unlock() twice, breaking the shared data hideaki.kimura at gmail dot com
@ 2014-06-04  7:01 ` siddhesh at redhat dot com
  2014-06-04 17:55 ` hideaki.kimura at gmail dot com
  1 sibling, 0 replies; 3+ messages in thread
From: siddhesh at redhat dot com @ 2014-06-04  7:01 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=17013

Siddhesh Poyarekar <siddhesh at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |WAITING
                 CC|                            |siddhesh at redhat dot com

--- Comment #1 from Siddhesh Poyarekar <siddhesh at redhat dot com> ---
You can ask individual distributions to backport the fix.  I can backport it to
the upstream 2.18 and 2.19 branches, but that won't help.

I've marked the bug as WAITING to know if you want to pursue fixing this in the
upstream stable branches.  What you really need though is to create bugs in the
distribution you use, asking to backport this fix.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug nptl/17013] pthread_cond_broadcast could call lll_unlock() twice, breaking the shared data
  2014-06-03 22:26 [Bug nptl/17013] New: pthread_cond_broadcast could call lll_unlock() twice, breaking the shared data hideaki.kimura at gmail dot com
  2014-06-04  7:01 ` [Bug nptl/17013] " siddhesh at redhat dot com
@ 2014-06-04 17:55 ` hideaki.kimura at gmail dot com
  1 sibling, 0 replies; 3+ messages in thread
From: hideaki.kimura at gmail dot com @ 2014-06-04 17:55 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=17013

--- Comment #2 from Hideaki Kimura <hideaki.kimura at gmail dot com> ---
(In reply to Siddhesh Poyarekar from comment #1)
> You can ask individual distributions to backport the fix.  I can backport it
> to the upstream 2.18 and 2.19 branches, but that won't help.
> 
> I've marked the bug as WAITING to know if you want to pursue fixing this in
> the upstream stable branches.  What you really need though is to create bugs
> in the distribution you use, asking to backport this fix.

Yes, I did file a backport request to Fedora, pointing to this ticket.
  https://bugzilla.redhat.com/show_bug.cgi?id=1104400
I'm in the course of doing it to other linux distro, probably Ubuntu.

If you backport it to upstream glibc 2.18/2.19, I guess it will help the distro
maintainers (not quite sure as I don't know how distro maintainers retrieve
patches to glibc).

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-06-04 17:55 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-03 22:26 [Bug nptl/17013] New: pthread_cond_broadcast could call lll_unlock() twice, breaking the shared data hideaki.kimura at gmail dot com
2014-06-04  7:01 ` [Bug nptl/17013] " siddhesh at redhat dot com
2014-06-04 17:55 ` hideaki.kimura at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).