aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/futex.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/futex.c')
-rw-r--r--kernel/futex.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/kernel/futex.c b/kernel/futex.c
index 9d260e838cff..4b6770e9806d 100644
--- a/kernel/futex.c
+++ b/kernel/futex.c
@@ -389,7 +389,7 @@ static struct task_struct * futex_find_get_task(pid_t pid)
389{ 389{
390 struct task_struct *p; 390 struct task_struct *p;
391 391
392 read_lock(&tasklist_lock); 392 rcu_read_lock();
393 p = find_task_by_pid(pid); 393 p = find_task_by_pid(pid);
394 if (!p) 394 if (!p)
395 goto out_unlock; 395 goto out_unlock;
@@ -403,7 +403,7 @@ static struct task_struct * futex_find_get_task(pid_t pid)
403 } 403 }
404 get_task_struct(p); 404 get_task_struct(p);
405out_unlock: 405out_unlock:
406 read_unlock(&tasklist_lock); 406 rcu_read_unlock();
407 407
408 return p; 408 return p;
409} 409}
@@ -1624,7 +1624,7 @@ sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr,
1624 struct task_struct *p; 1624 struct task_struct *p;
1625 1625
1626 ret = -ESRCH; 1626 ret = -ESRCH;
1627 read_lock(&tasklist_lock); 1627 rcu_read_lock();
1628 p = find_task_by_pid(pid); 1628 p = find_task_by_pid(pid);
1629 if (!p) 1629 if (!p)
1630 goto err_unlock; 1630 goto err_unlock;
@@ -1633,7 +1633,7 @@ sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr,
1633 !capable(CAP_SYS_PTRACE)) 1633 !capable(CAP_SYS_PTRACE))
1634 goto err_unlock; 1634 goto err_unlock;
1635 head = p->robust_list; 1635 head = p->robust_list;
1636 read_unlock(&tasklist_lock); 1636 rcu_read_unlock();
1637 } 1637 }
1638 1638
1639 if (put_user(sizeof(*head), len_ptr)) 1639 if (put_user(sizeof(*head), len_ptr))
@@ -1641,7 +1641,7 @@ sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr,
1641 return put_user(head, head_ptr); 1641 return put_user(head, head_ptr);
1642 1642
1643err_unlock: 1643err_unlock:
1644 read_unlock(&tasklist_lock); 1644 rcu_read_unlock();
1645 1645
1646 return ret; 1646 return ret;
1647} 1647}