From b94a58f986e2b9d65813231bfb1bed398f4d3f6a Mon Sep 17 00:00:00 2001 From: kib Date: Thu, 30 May 2013 19:51:33 +0000 Subject: Assert that OBJ_TMPFS flag on the vm object for the tmpfs node is cleared when the tmpfs node is going away. Tested by: bdrewery, pho --- sys/fs/tmpfs/tmpfs_subr.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sys/fs/tmpfs') diff --git a/sys/fs/tmpfs/tmpfs_subr.c b/sys/fs/tmpfs/tmpfs_subr.c index e751331..ed6bff0 100644 --- a/sys/fs/tmpfs/tmpfs_subr.c +++ b/sys/fs/tmpfs/tmpfs_subr.c @@ -314,6 +314,8 @@ tmpfs_free_node(struct tmpfs_mount *tmp, struct tmpfs_node *node) TMPFS_LOCK(tmp); tmp->tm_pages_used -= uobj->size; TMPFS_UNLOCK(tmp); + KASSERT((uobj->flags & OBJ_TMPFS) == 0, + ("leaked OBJ_TMPFS node %p vm_obj %p", node, uobj)); vm_object_deallocate(uobj); } break; -- cgit v1.1