projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d359b54
)
[PATCH] sys_get_robust_list(): don't take tasklist_lock
author
Oleg Nesterov
<
[email protected]
>
Fri, 29 Sep 2006 09:00:55 +0000
(
02:00
-0700)
committer
Linus Torvalds
<
[email protected]
>
Fri, 29 Sep 2006 16:18:18 +0000
(09:18 -0700)
use rcu locks for find_task_by_pid().
Signed-off-by: Oleg Nesterov <
[email protected]
>
Cc: Ingo Molnar <
[email protected]
>
Cc: Thomas Gleixner <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
kernel/futex.c
patch
|
blob
|
history
diff --git
a/kernel/futex.c
b/kernel/futex.c
index ca8ef11feb6586ce41a825f9c37b791028ed9024..4b6770e9806d0c080ef5f9bd542ddb778ddbcff2 100644
(file)
--- a/
kernel/futex.c
+++ b/
kernel/futex.c
@@
-1624,7
+1624,7
@@
sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr,
struct task_struct *p;
ret = -ESRCH;
- r
ead_lock(&tasklist_lock
);
+ r
cu_read_lock(
);
p = find_task_by_pid(pid);
if (!p)
goto err_unlock;
@@
-1633,7
+1633,7
@@
sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr,
!capable(CAP_SYS_PTRACE))
goto err_unlock;
head = p->robust_list;
- r
ead_unlock(&tasklist_lock
);
+ r
cu_read_unlock(
);
}
if (put_user(sizeof(*head), len_ptr))
@@
-1641,7
+1641,7
@@
sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr,
return put_user(head, head_ptr);
err_unlock:
- r
ead_unlock(&tasklist_lock
);
+ r
cu_read_unlock(
);
return ret;
}