summaryrefslogtreecommitdiffstats
path: root/sys/vm
diff options
context:
space:
mode:
authordyson <dyson@FreeBSD.org>1996-03-19 05:13:22 +0000
committerdyson <dyson@FreeBSD.org>1996-03-19 05:13:22 +0000
commit1fa4d692594eafbf8e84846f170b918ee0afc781 (patch)
tree8061bebe5a673fb545013ff249887aadb288d51e /sys/vm
parentb10555454e573b2dcc7c0d03059ffa2ad6a30b8f (diff)
downloadFreeBSD-src-1fa4d692594eafbf8e84846f170b918ee0afc781.zip
FreeBSD-src-1fa4d692594eafbf8e84846f170b918ee0afc781.tar.gz
Fix the problem that unmounting filesystems that are backed by a VMIO
device have reference count problems. We mark the underlying object ono-persistent, and account for the reference count that the VM system maintainsfor the special device close. This should fix the removable device problem.
Diffstat (limited to 'sys/vm')
-rw-r--r--sys/vm/vnode_pager.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/vm/vnode_pager.c b/sys/vm/vnode_pager.c
index 4edbd35..773c5f6 100644
--- a/sys/vm/vnode_pager.c
+++ b/sys/vm/vnode_pager.c
@@ -38,7 +38,7 @@
* SUCH DAMAGE.
*
* from: @(#)vnode_pager.c 7.5 (Berkeley) 4/20/91
- * $Id: vnode_pager.c,v 1.57 1995/12/17 23:29:56 dyson Exp $
+ * $Id: vnode_pager.c,v 1.58 1996/01/19 04:00:31 dyson Exp $
*/
/*
@@ -143,7 +143,10 @@ vnode_pager_alloc(handle, size, prot, offset)
* And an object of the appropriate size
*/
object = vm_object_allocate(OBJT_VNODE, size);
- object->flags = OBJ_CANPERSIST;
+ if (vp->v_type == VREG)
+ object->flags = OBJ_CANPERSIST;
+ else
+ object->flags = 0;
/*
* Hold a reference to the vnode and initialize object data.
OpenPOWER on IntegriCloud