summaryrefslogtreecommitdiffstats
path: root/sys/fs
diff options
context:
space:
mode:
authorgreen <green@FreeBSD.org>2004-03-14 15:57:45 +0000
committergreen <green@FreeBSD.org>2004-03-14 15:57:45 +0000
commitda8d4a51f130bd372b64e24e44af742385d8caa2 (patch)
tree7475a244fdc1242ce72ad9a053734abbab36c37a /sys/fs
parent7a8abdd5851f73150df1c9c9e3a50ad62060d5c1 (diff)
downloadFreeBSD-src-da8d4a51f130bd372b64e24e44af742385d8caa2.zip
FreeBSD-src-da8d4a51f130bd372b64e24e44af742385d8caa2.tar.gz
When taking event callbacks (like process_exit) out from under Giant, those
which do not lock Giant themselves will be exposed. Unbreak pfs_exit().
Diffstat (limited to 'sys/fs')
-rw-r--r--sys/fs/pseudofs/pseudofs_vncache.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/fs/pseudofs/pseudofs_vncache.c b/sys/fs/pseudofs/pseudofs_vncache.c
index 31b60e1..49258ab 100644
--- a/sys/fs/pseudofs/pseudofs_vncache.c
+++ b/sys/fs/pseudofs/pseudofs_vncache.c
@@ -222,6 +222,7 @@ pfs_exit(void *arg, struct proc *p)
{
struct pfs_vdata *pvd, *prev;
+ mtx_lock(&Giant);
mtx_lock(&pfs_vncache_mutex);
/*
* The double loop is necessary because vgone() indirectly
@@ -239,6 +240,7 @@ pfs_exit(void *arg, struct proc *p)
break;
}
mtx_unlock(&pfs_vncache_mutex);
+ mtx_unlock(&Giant);
}
/*
OpenPOWER on IntegriCloud