summaryrefslogtreecommitdiff
path: root/sys/kern/kern_sched.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/kern_sched.c')
-rw-r--r--sys/kern/kern_sched.c16
1 files changed, 0 insertions, 16 deletions
diff --git a/sys/kern/kern_sched.c b/sys/kern/kern_sched.c
index 278eba2..1d79937 100644
--- a/sys/kern/kern_sched.c
+++ b/sys/kern/kern_sched.c
@@ -150,26 +150,10 @@ sched_switch(struct trapframe *tf)
struct pcb *pcbp;
struct proc *next_td, *td;
bool use_current = true;
- bool inexec;
ci = this_cpu();
td = ci->curtd;
- if (td != NULL) {
- inexec = ISSET(td->flags, PROC_INEXEC);
-
- /*
- * If both PROC_INEXEC and PROC_EXEC are set,
- * an exec is in progress. However, if PROC_INEXEC is
- * unset and PROC_EXEC is set, an exec has completed
- * and we can unset PROC_EXEC and copy the new trapframe.
- */
- if (ISSET(td->flags, PROC_EXEC) && !inexec) {
- memcpy(tf, &td->tf, sizeof(*tf));
- td->flags &= ~PROC_EXEC;
- }
- }
-
/*
* Get the next thread and use it only if it isn't
* in the middle of an exit, exec, or whatever.