summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authordillon <dillon@FreeBSD.org>2002-02-26 20:33:41 +0000
committerdillon <dillon@FreeBSD.org>2002-02-26 20:33:41 +0000
commit996781f17a00793462f9b311d5f8e7a458679909 (patch)
tree7ede0e88befde8b862a573c1bafc540a03a87d83 /sys/kern
parent118717618343ff3fc9166354457e2ab28cb86fbe (diff)
downloadFreeBSD-src-996781f17a00793462f9b311d5f8e7a458679909.zip
FreeBSD-src-996781f17a00793462f9b311d5f8e7a458679909.tar.gz
revert last commit temporarily due to whining on the lists.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_fork.c9
-rw-r--r--sys/kern/kern_switch.c7
2 files changed, 1 insertions, 15 deletions
diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c
index d13442c..69071a1 100644
--- a/sys/kern/kern_fork.c
+++ b/sys/kern/kern_fork.c
@@ -777,19 +777,12 @@ fork_exit(callout, arg, frame)
td->td_kse->ke_oncpu = PCPU_GET(cpuid);
/*
- * Setup the sched_lock state so that we can release it. If
- * MACHINE_CRITICAL_ENTER is set by the MD architecture, the
- * trampoline returns with the critical section pre-set.
- * XXX note: all architectures should do this, because this code
- * improperly assumes that a critical section == hard interrupt
- * disablement on entry, which is not necessarily true.
+ * Setup the sched_lock state so that we can release it.
*/
sched_lock.mtx_lock = (uintptr_t)td;
sched_lock.mtx_recurse = 0;
-#ifndef MACHINE_CRITICAL_ENTER
td->td_critnest = 1;
td->td_savecrit = CRITICAL_FORK;
-#endif
CTR3(KTR_PROC, "fork_exit: new proc %p (pid %d, %s)", p, p->p_pid,
p->p_comm);
if (PCPU_GET(switchtime.sec) == 0)
diff --git a/sys/kern/kern_switch.c b/sys/kern/kern_switch.c
index 44c9e5d..bd9c4bf 100644
--- a/sys/kern/kern_switch.c
+++ b/sys/kern/kern_switch.c
@@ -69,11 +69,6 @@ setrunqueue(struct thread *td)
runq_add(&runq, td->td_kse);
}
-/*
- * XXX temporary until these routines are moved fully into MD areas
- */
-#ifndef MACHINE_CRITICAL_ENTER
-
/* Critical sections that prevent preemption. */
void
critical_enter(void)
@@ -99,8 +94,6 @@ critical_exit(void)
td->td_critnest--;
}
-#endif
-
/*
* Clear the status bit of the queue corresponding to priority level pri,
* indicating that it is empty.
OpenPOWER on IntegriCloud