[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-id: <4756382D.4040904@sun.com>
Date: Wed, 05 Dec 2007 15:33:33 +1000
From: David Holmes - Sun Microsystems <David.Holmes@....com>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Steven Rostedt <rostedt@...dmis.org>, Ingo Molnar <mingo@...e.hu>,
Thomas Gleixner <tglx@...utronix.de>,
LKML <linux-kernel@...r.kernel.org>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH -v2] fix for futex_wait signal stack corruption
Linus Torvalds said the following on 5/12/07 01:41 PM:
> So here's a question for David Holmes: What caused you to actually notice
> this behaviour? Can this actually be seen in real life usage?
We observed an application "hang" that turned out to be caused by a
clock mismatch between that used with the pthread_cond_t and that used
to convert a relative wait time to an absolute one. When the program ran
in the foreground and hung I used ctrl-Z to suspend it then "bg" to
background it. As soon as I did that the application became unstuck.
While this was observed with process control signals, my concern was
that other signals might cause pthread_cond_timedwait to return
immediately in the same way. The test program allows for SIGUSR1 and
SIGRTMIN testing as well, but these other signals did not cause the
immediate return. But it would seem from Steven's analysis that this is
just a fortuitous result. If I understand things correctly, any
interruption of pthread_cond_timedwait by a signal, could result in
waiting until an arbitrary time - depending on how the stack value was
corrupted. Is that correct?
Thanks,
David Holmes
Senior Java Technologist
Java SE VM Real-time and Embedded Group
---------------------------------------
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists