summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/vm/vm_meter.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/vm/vm_meter.c b/sys/vm/vm_meter.c
index 709f9b5..7d9dd96 100644
--- a/sys/vm/vm_meter.c
+++ b/sys/vm/vm_meter.c
@@ -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) {
OpenPOWER on IntegriCloud