Explorar o código

signals: send_sigqueue: don't take rcu lock

lock_task_sighand() was changed, send_sigqueue() doesn't need rcu_read_lock()
any longer.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Cc: Roland McGrath <roland@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Oleg Nesterov %!s(int64=17) %!d(string=hai) anos
pai
achega
5c193e8871
Modificáronse 1 ficheiros con 0 adicións e 4 borrados
  1. 0 4
      kernel/signal.c

+ 0 - 4
kernel/signal.c

@@ -1311,8 +1311,6 @@ int send_sigqueue(int sig, struct sigqueue *q, struct task_struct *p)
 	 * We return -1, when the task is marked exiting, so
 	 * We return -1, when the task is marked exiting, so
 	 * posix_timer_event can redirect it to the group leader
 	 * posix_timer_event can redirect it to the group leader
 	 */
 	 */
-	rcu_read_lock();
-
 	if (!likely(lock_task_sighand(p, &flags)))
 	if (!likely(lock_task_sighand(p, &flags)))
 		goto out_err;
 		goto out_err;
 
 
@@ -1323,8 +1321,6 @@ int send_sigqueue(int sig, struct sigqueue *q, struct task_struct *p)
 
 
 	unlock_task_sighand(p, &flags);
 	unlock_task_sighand(p, &flags);
 out_err:
 out_err:
-	rcu_read_unlock();
-
 	return ret;
 	return ret;
 }
 }