diff options
author | Doug Rabson <dfr@FreeBSD.org> | 2000-10-03 08:03:03 +0000 |
---|---|---|
committer | Doug Rabson <dfr@FreeBSD.org> | 2000-10-03 08:03:03 +0000 |
commit | c7031436383818d63e2515a70d7e8390df192c34 (patch) | |
tree | fdf3eb52c0f7b5122f7d9807687078a9dd789424 /sys/powerpc/aim | |
parent | 05f976924e01deb29435c508772004924571fd04 (diff) | |
download | src-c7031436383818d63e2515a70d7e8390df192c34.tar.gz src-c7031436383818d63e2515a70d7e8390df192c34.zip |
Clear pcb_schednest in cpu_fork() for the child process. This is
is necessary since the child's call stack only includes one recursive
hold of sched_lock.
Notes
Notes:
svn path=/head/; revision=66573
Diffstat (limited to 'sys/powerpc/aim')
-rw-r--r-- | sys/powerpc/aim/vm_machdep.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/powerpc/aim/vm_machdep.c b/sys/powerpc/aim/vm_machdep.c index 3831d67658c6..f706590ed384 100644 --- a/sys/powerpc/aim/vm_machdep.c +++ b/sys/powerpc/aim/vm_machdep.c @@ -210,6 +210,13 @@ cpu_fork(p1, p2, flags) up->u_pcb.pcb_context[2] = (u_long) p2; /* s2: a0 */ up->u_pcb.pcb_context[7] = (u_int64_t)switch_trampoline; /* ra: assembly magic */ + + /* + * Clear the saved recursion count for sched_lock + * since the child needs only one count which is + * released in switch_trampoline. + */ + up->u_pcb.pcb_schednest = 0; } } |