Skip to contentSkip to conversation

ia64: fix ptrace inside a namespace

PATCH NAK [email protected] 2 participants 2 messages Feb 5, 2008 ptrace support

lore
Share & tools
lore
#0 lore raw

PATCH 4/4 ia64: fix ptrace inside a namespace

From: Pavel Emelyanov <[email protected]>

The ia64 has its own sys_ptrace implementation and it was overlooked when the pid namespaces patches were sent.

Use find_task_by_vpid() in it.

Cc "Eric W. Biederman" <[email protected]>
Cc "Luck, Tony" <[email protected]>

---

 arch/ia64/kernel/ptrace.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/ia64/kernel/ptrace.c renamed from arch/ia64/kernel/ptrace.c~ia64-fix-ptrace-inside-a-namespace +1 -1
diff -puN arch/ia64/kernel/ptrace.c~ia64-fix-ptrace-inside-a-namespace arch/ia64/kernel/ptrace.c
@@ -1437,7 +1437,7 @@ sys_ptrace (long request, pid_t pid, uns
 	ret = -ESRCH;
 	read_lock(&tasklist_lock);
 	{
-		child = find_task_by_pid(pid);
+		child = find_task_by_vpid(pid);
 		if (child) {
 			if (peek_or_poke)
 				child = find_thread_for_addr(child, addr);

_

#1 lore raw
Quoted 6 lines · On Mon, Feb 04, 2008 at 11:43:04PM -0800, [email protected] wrote:

From: Pavel Emelyanov <[email protected]>

The ia64 has its own sys_ptrace implementation and it was overlooked when the pid namespaces patches were sent.

Use find_task_by_vpid() in it

The plan is to kill this code entirely and make ia64 look like other ptrace implementations. Please double check this doesn't cause merge issues with the hopefully pending rewrite of the ia64 ptrace code.