aboutsummaryrefslogtreecommitdiff
path: root/sys/vm/vm_pageout.c
diff options
context:
space:
mode:
authorMark Johnston <markj@FreeBSD.org>2019-09-01 22:22:43 +0000
committerMark Johnston <markj@FreeBSD.org>2019-09-01 22:22:43 +0000
commit08cfa56ea35b32be96f439c74fe6677653401e6e (patch)
tree75f59db43c15eed1be07f25f47e4f12b86a8d507 /sys/vm/vm_pageout.c
parent63cdd18e406a630d44f084697581f658a17163e0 (diff)
Notes
Diffstat (limited to 'sys/vm/vm_pageout.c')
-rw-r--r--sys/vm/vm_pageout.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/vm/vm_pageout.c b/sys/vm/vm_pageout.c
index dfe40e9c724d5..90924b40c4f92 100644
--- a/sys/vm/vm_pageout.c
+++ b/sys/vm/vm_pageout.c
@@ -1871,9 +1871,12 @@ vm_pageout_lowmem(void)
/*
* We do this explicitly after the caches have been
- * drained above.
+ * drained above. If we have a severe page shortage on
+ * our hands, completely drain all UMA zones. Otherwise,
+ * just prune the caches.
*/
- uma_reclaim();
+ uma_reclaim(vm_page_count_min() ? UMA_RECLAIM_DRAIN_CPU :
+ UMA_RECLAIM_TRIM);
return (true);
}
return (false);