lkml.org 
[lkml]   [2006]   [Jun]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Fix for Bug in PI exit code

* Dinakar Guniguntala <dino@in.ibm.com> wrote:

> We were seeing oopses like below a lot when using PI mutexes

> ===============================================================================
> After a lot of debugging we found that this is caused due to the following race.
> PM is a PI mutex, A and B are RT threads
>
> Thread A (RT) Thread B (RT)
> |
> v
> pthread_mutex_lock (PM) |
> (glibc) got mutex v
> do work pthread_mutex_lock (PM)
> rt_mutex_timed_lock
>
> EINTR EINTR (Process gets aborted)
>
> do_exit lock(pi_mutex->lock->wait_lock)
> exit_pi_state_list clear_waiters
> lock(hb->lock)
> pi_state->owner = NULL unlock(pi_mutex->lock->wait_lock)
> rt_mutex_unlock(pi_mutex) lock(hb->lock) (blocks)
> unlock(hb->lock) unblock -> free_pi_state
> continue exit processing doesn't expect pi_state->owner to be NULL
> Panic
>
> The patch attached below seems to make this problem go away. This has
> been stress tested quite a bit in the past 24 hours. Does it look sane
> to you ??

yeah, makes sense. Thanks, applied.

Ingo
-
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/

\
 
 \ /
  Last update: 2006-06-10 10:26    [W:0.041 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site