Commit ce2c6b53 authored by Thomas Gleixner's avatar Thomas Gleixner Committed by Linus Torvalds

[PATCH] futex: Apply recent futex fixes to futex_compat

The recent fixups in futex.c need to be applied to futex_compat.c too.  Fixes
a hang reported by Olaf.
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Cc: Olaf Hering <olh@suse.de>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 2b8de5f5
...@@ -39,7 +39,7 @@ void compat_exit_robust_list(struct task_struct *curr) ...@@ -39,7 +39,7 @@ void compat_exit_robust_list(struct task_struct *curr)
{ {
struct compat_robust_list_head __user *head = curr->compat_robust_list; struct compat_robust_list_head __user *head = curr->compat_robust_list;
struct robust_list __user *entry, *pending; struct robust_list __user *entry, *pending;
unsigned int limit = ROBUST_LIST_LIMIT, pi; unsigned int limit = ROBUST_LIST_LIMIT, pi, pip;
compat_uptr_t uentry, upending; compat_uptr_t uentry, upending;
compat_long_t futex_offset; compat_long_t futex_offset;
...@@ -59,10 +59,10 @@ void compat_exit_robust_list(struct task_struct *curr) ...@@ -59,10 +59,10 @@ void compat_exit_robust_list(struct task_struct *curr)
* if it exists: * if it exists:
*/ */
if (fetch_robust_entry(&upending, &pending, if (fetch_robust_entry(&upending, &pending,
&head->list_op_pending, &pi)) &head->list_op_pending, &pip))
return; return;
if (upending) if (upending)
handle_futex_death((void *)pending + futex_offset, curr, pi); handle_futex_death((void *)pending + futex_offset, curr, pip);
while (compat_ptr(uentry) != &head->list) { while (compat_ptr(uentry) != &head->list) {
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment