Revert "kernel/kcmp.c: Use new infrastructure to fix deadlocks in execve"
This reverts commit 0cd9783686
which is
commit 454e3126cb842388e22df6b3ac3da44062c00765 upstream.
It breaks the API and we don't need it right now in the 5.4 tree.
Bug: 161946584
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I2a8282c4bc97e97debad023bf098dd97fd02b072
This commit is contained in:
parent
5bf86c2bf5
commit
70187595b8
@ -173,8 +173,8 @@ SYSCALL_DEFINE5(kcmp, pid_t, pid1, pid_t, pid2, int, type,
|
||||
/*
|
||||
* One should have enough rights to inspect task details.
|
||||
*/
|
||||
ret = kcmp_lock(&task1->signal->exec_update_mutex,
|
||||
&task2->signal->exec_update_mutex);
|
||||
ret = kcmp_lock(&task1->signal->cred_guard_mutex,
|
||||
&task2->signal->cred_guard_mutex);
|
||||
if (ret)
|
||||
goto err;
|
||||
if (!ptrace_may_access(task1, PTRACE_MODE_READ_REALCREDS) ||
|
||||
@ -229,8 +229,8 @@ SYSCALL_DEFINE5(kcmp, pid_t, pid1, pid_t, pid2, int, type,
|
||||
}
|
||||
|
||||
err_unlock:
|
||||
kcmp_unlock(&task1->signal->exec_update_mutex,
|
||||
&task2->signal->exec_update_mutex);
|
||||
kcmp_unlock(&task1->signal->cred_guard_mutex,
|
||||
&task2->signal->cred_guard_mutex);
|
||||
err:
|
||||
put_task_struct(task1);
|
||||
put_task_struct(task2);
|
||||
|
Loading…
Reference in New Issue
Block a user