Messages in this thread | | | Date | Sat, 9 May 2009 20:59:06 +0200 | From | Oleg Nesterov <> | Subject | Re: [PATCH 1/2] CRED: Rename cred_exec_mutex to reflect that it's a guard against ptrace |
| |
Sorry for delay,
On 05/08, David Howells wrote: > > @@ -185,10 +185,11 @@ int ptrace_attach(struct task_struct *task) > if (same_thread_group(task, current)) > goto out; > > - /* Protect exec's credential calculations against our interference; > - * SUID, SGID and LSM creds get determined differently under ptrace. > + /* Protect the target's credential calculations against our > + * interference; SUID, SGID and LSM creds get determined differently > + * under ptrace. > */ > - retval = mutex_lock_interruptible(&task->cred_exec_mutex); > + retval = mutex_lock_interruptible(&task->cred_guard_mutex); > if (retval < 0) > goto out; > > @@ -232,7 +233,7 @@ repeat: > bad: > write_unlock_irqrestore(&tasklist_lock, flags); > task_unlock(task); > - mutex_unlock(&task->cred_exec_mutex); > + mutex_unlock(&task->cred_guard_mutex);
This rename is obviously fine, but conflicts with ptrace-do-not-use-task_lock-for-attach.patch in -mm tree:
-bad: - write_unlock_irqrestore(&tasklist_lock, flags); - task_unlock(task); +unlock_tasklist: + write_unlock_irq(&tasklist_lock); +unlock_creds: mutex_unlock(&task->cred_exec_mutex); out: return retval;
Hmm. Ingo's "rename ptrace_may_access => ptrace_access_check" conflicts with my patch too.
Andrew, Roland, I guess I should re-send
ptrace-ptrace_attach-check-pf_kthread-exit_state-instead-of-mm.patch ptrace-cleanup-check-set-of-pt_ptraced-during-attach.patch ptrace-do-not-use-task_lock-for-attach.patch
patches?
Oleg.
| |