Fix the act_scan_laundry_weight mechanism.

r292392 modified the active queue scan to weigh clean pages differently
from dirty pages when attempting to meet the inactive queue target. When
r306706 was merged into the PQ_LAUNDRY branch, this mechanism was
broken. Fix it by scalaing the correct page shortage variable.

Reviewed by:	alc, kib
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D13423
This commit is contained in:
markj 2017-12-09 15:47:26 +00:00
parent b0e68228fd
commit 3479530814

View File

@ -1393,7 +1393,7 @@ vm_pageout_scan(struct vm_domain *vmd, int pass)
inactq_shortage = vm_cnt.v_inactive_target - (vm_cnt.v_inactive_count +
vm_cnt.v_laundry_count / act_scan_laundry_weight) +
vm_paging_target() + deficit + addl_page_shortage;
page_shortage *= act_scan_laundry_weight;
inactq_shortage *= act_scan_laundry_weight;
pq = &vmd->vmd_pagequeues[PQ_ACTIVE];
vm_pagequeue_lock(pq);