Source-Changes-HG archive

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

[src/trunk]: src/sys/kern Revert incomplete (and possibly incorrect) sys_sa_p...



details:   https://anonhg.NetBSD.org/src/rev/cc09766b88bb
branches:  trunk
changeset: 584092:cc09766b88bb
user:      christos <christos%NetBSD.org@localhost>
date:      Wed Sep 07 23:31:06 2005 +0000

description:
Revert incomplete (and possibly incorrect) sys_sa_preempt implementation
that I committed accidentally with the 64 bit inode changes.

diffstat:

 sys/kern/kern_sa.c |  33 ++++-----------------------------
 1 files changed, 4 insertions(+), 29 deletions(-)

diffs (55 lines):

diff -r 07414311065f -r cc09766b88bb sys/kern/kern_sa.c
--- a/sys/kern/kern_sa.c        Wed Sep 07 23:24:54 2005 +0000
+++ b/sys/kern/kern_sa.c        Wed Sep 07 23:31:06 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_sa.c,v 1.64 2005/09/05 21:52:38 yamt Exp $        */
+/*     $NetBSD: kern_sa.c,v 1.65 2005/09/07 23:31:06 christos Exp $    */
 
 /*-
  * Copyright (c) 2001, 2004, 2005 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.64 2005/09/05 21:52:38 yamt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.65 2005/09/07 23:31:06 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -701,34 +701,9 @@
 int
 sys_sa_preempt(struct lwp *l, void *v, register_t *retval)
 {
-       struct sys_sa_preempt_args /* {
-               syscallarg(lwpid_t) sa_id;
-       } */ *uap = v;
-       int target_lid;
-       struct proc *p = l->l_proc;
-       struct lwp *t;
 
-       target_lid = SCARG(uap, sa_id);
-
-       LIST_FOREACH(t, &p->p_lwps, l_sibling)
-               if (t->l_lid == target_lid)
-                       break;
-
-       if (t == NULL)
-               return ESRCH;
-
-       /* XXX: Not correct, but the best we can do for now */
-       if (t != l && t->l_stat == LSONPROC && l->l_cpu != t->l_cpu) {
-#ifdef DIAGNOSTIC
-               printf("reschedule %d\n", t->l_lid);
-#endif
-               need_resched(t->l_cpu);
-#ifndef DIAGNOSTIC
-       } else {
-               printf("can't reschedule %d\n", t->l_lid);
-#endif
-       }
-       return 0;
+       /* XXX Implement me. */
+       return (ENOSYS);
 }
 
 



Home | Main Index | Thread Index | Old Index