Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/arm/arm32 Don't use the pcb anymore since the user ...



details:   https://anonhg.NetBSD.org/src/rev/4d0e927bed60
branches:  trunk
changeset: 763927:4d0e927bed60
user:      matt <matt%NetBSD.org@localhost>
date:      Thu Apr 07 10:07:11 2011 +0000

description:
Don't use the pcb anymore since the user read-only thread and process id
value is now grabbed from l_private.

diffstat:

 sys/arch/arm/arm32/sys_machdep.c |  15 ++++++---------
 1 files changed, 6 insertions(+), 9 deletions(-)

diffs (37 lines):

diff -r 6f4c4fc555f5 -r 4d0e927bed60 sys/arch/arm/arm32/sys_machdep.c
--- a/sys/arch/arm/arm32/sys_machdep.c  Thu Apr 07 10:03:47 2011 +0000
+++ b/sys/arch/arm/arm32/sys_machdep.c  Thu Apr 07 10:07:11 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sys_machdep.c,v 1.11 2010/07/07 01:20:49 chs Exp $     */
+/*     $NetBSD: sys_machdep.c,v 1.12 2011/04/07 10:07:11 matt Exp $    */
 
 /*
  * Copyright (c) 1995-1997 Mark Brinicombe.
@@ -41,7 +41,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sys_machdep.c,v 1.11 2010/07/07 01:20:49 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_machdep.c,v 1.12 2011/04/07 10:07:11 matt Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -115,14 +115,11 @@
 cpu_lwp_setprivate(lwp_t *l, void *addr)
 {
 #ifdef _ARM_ARCH_6
-       struct pcb *pcb;
-
-       pcb = lwp_getpcb(l);
-       kpreempt_disable();
-       pcb->pcb_un.un_32.pcb32_user_pid_ro = (u_int)addr;
-       if (l == curlwp)
+       if (l == curlwp) {
+               kpreempt_disable();
                __asm("mcr p15, 0, %0, c13, c0, 3" : : "r" (addr));
-       kpreempt_enable();
+               kpreempt_enable();
+       }
        return 0;
 #else
        return ENOSYS;



Home | Main Index | Thread Index | Old Index