1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-18 10:35:55 +00:00

When counting vm totals, skip unreferenced objects, including

vnodes representing mounted file systems.

Reviewed by:	alc
MFC after:	3 days
This commit is contained in:
Ruslan Ermilov 2006-11-20 00:16:00 +00:00
parent d4593bb04f
commit 276096bb3e
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=164429

View File

@ -212,6 +212,13 @@ vmtotal(SYSCTL_HANDLER_ARGS)
*/
continue;
}
if (object->ref_count == 0) {
/*
* Also skip unreferenced objects, including
* vnodes representing mounted file systems.
*/
continue;
}
totalp->t_vm += object->size;
totalp->t_rm += object->resident_page_count;
if (object->flags & OBJ_ACTIVE) {