From: Jeff Dike <[email-masked]>

This fixes write_ldt_entry to treat userspace_pid as an array.

Signed-off-by: Jeff Dike <[email-masked]>
Cc: Paolo 'Blaisorblade' Giarrusso <[email-masked]>
Signed-off-by: Andrew Morton <[email-masked]>
---

 arch/um/sys-i386/ldt.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff -puN arch/um/sys-i386/ldt.c~uml-fix-a-ptrace-call arch/um/sys-i386/ldt.c
--- 25/arch/um/sys-i386/ldt.c~uml-fix-a-ptrace-call	2005-05-02 19:01:40.000000000 -0700
+++ 25-akpm/arch/um/sys-i386/ldt.c	2005-05-02 19:01:40.000000000 -0700
@@ -25,7 +25,7 @@ int sys_modify_ldt_tt(int func, void __u
 #endif
 
 #ifdef CONFIG_MODE_SKAS
-extern int userspace_pid;
+extern int userspace_pid[];
 
 #include "skas_ptrace.h"
 
@@ -56,7 +56,8 @@ int sys_modify_ldt_skas(int func, void _
 	ldt = ((struct ptrace_ldt) { .func	= func,
 				     .ptr	= buf,
 				     .bytecount = bytecount });
-	res = ptrace(PTRACE_LDT, userspace_pid, 0, (unsigned long) &ldt);
+#warning Need to look up userspace_pid by cpu
+	res = ptrace(PTRACE_LDT, userspace_pid[0], 0, (unsigned long) &ldt);
 	if(res < 0)
 		goto out;
 
_