The commit is pushed to "branch-rh7-3.10.0-229.7.2.vz7.9.x-ovz" and will appear 
at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-229.7.2.vz7.9.10
------>
commit 8a5c219c8107c30f19d7f0ec0c3b0c016dafb637
Author: Vladimir Davydov <vdavy...@virtuozzo.com>
Date:   Wed Nov 18 17:05:33 2015 +0400

    tcache: account reclaimed pages to scan_control->nr_reclaimed
    
    Tcache pages might constitute a substantial portion of the total number
    of pages reclaimed. Since they are freed immediately, we should count
    them to scan_control->nr_reclaimed to avoid premature scan->priority
    drops and resulting overreclaim.
    
    Signed-off-by: Vladimir Davydov <vdavy...@virtuozzo.com>
---
 mm/tcache.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/mm/tcache.c b/mm/tcache.c
index ce5b0ed..e8ffa91 100644
--- a/mm/tcache.c
+++ b/mm/tcache.c
@@ -17,6 +17,7 @@
 #include <linux/completion.h>
 #include <linux/shrinker.h>
 #include <linux/vmstat.h>
+#include <linux/swap.h>
 #include <linux/cleancache.h>
 
 /* cleancache_put_page is called from atomic context */
@@ -808,6 +809,8 @@ static unsigned long tcache_shrink_scan(struct shrinker 
*shrink,
                }
                sc->nr_to_scan--;
        }
+       if (current->reclaim_state)
+               current->reclaim_state->reclaimed_slab += nr_reclaimed;
        return nr_reclaimed;
 }
 
_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

Reply via email to