diff options
author | peter <peter@FreeBSD.org> | 2004-03-06 00:44:59 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2004-03-06 00:44:59 +0000 |
commit | 8ac8c686e16a76e06dbe87eb539681314efc14ea (patch) | |
tree | 1755ce66c3a499579e9b25a564a970a32df71980 /sys | |
parent | 17cd066bca53bda0b440e0e6308d8101ec0e30fd (diff) | |
download | FreeBSD-src-8ac8c686e16a76e06dbe87eb539681314efc14ea.zip FreeBSD-src-8ac8c686e16a76e06dbe87eb539681314efc14ea.tar.gz |
Add a missing part of jhb's previous commit. It looks like he had a
patch chunk rejected that he missed. This would manifest as a lock
assertion panic at boot (Giant not locked in kern_fork.c).
Obtained from: jhb
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/kern_fork.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c index 8907ed0..f516b3b 100644 --- a/sys/kern/kern_fork.c +++ b/sys/kern/kern_fork.c @@ -471,9 +471,13 @@ again: ke2 = FIRST_KSE_IN_KSEGRP(kg2); /* Allocate and switch to an alternate kstack if specified. */ - if (pages != 0) + if (pages != 0) { + mtx_lock(&Giant); vm_thread_new_altkstack(td2, pages); + mtx_unlock(&Giant); + } + mtx_lock(&Giant); /* XXX: for VREF() */ PROC_LOCK(p2); PROC_LOCK(p1); |