]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mm: vmscan: convert global reclaim to per-memcg LRU lists
authorJohannes Weiner <jweiner@redhat.com>
Fri, 13 Jan 2012 01:18:06 +0000 (17:18 -0800)
committerJerry Snitselaar <jerry.snitselaar@oracle.com>
Sun, 7 Oct 2012 06:04:47 +0000 (23:04 -0700)
commit4d224cb4d8cb3b05a92307aac0ec9c983489719d
treecb47d796a87ca030e2c925ba7633351eb6b0b999
parent993d208d4e7f3fb65c5bcb8bcf94193158ade99e
mm: vmscan: convert global reclaim to per-memcg LRU lists

commit b95a2f2d486d0d768a92879c023a03757b9c7e58 upstream - WARNING: this is a substitute patch.

Stable note: Not tracked in Bugzilla. This is a partial backport of an
upstream commit addressing a completely different issue
that accidentally contained an important fix. The workload
this patch helps was memcached when IO is started in the
background. memcached should stay resident but without this patch
it gets swapped. Sometimes this manifests as a drop in throughput
but mostly it was observed through /proc/vmstat.

Commit [246e87a9: memcg: fix get_scan_count() for small targets] was meant
to fix a problem whereby small scan targets on memcg were ignored causing
priority to raise too sharply. It forced scanning to take place if the
target was small, memcg or kswapd.

From the time it was introduced it caused excessive reclaim by kswapd
with workloads being pushed to swap that previously would have stayed
resident. This was accidentally fixed in commit [b95a2f2d: mm: vmscan:
convert global reclaim to per-memcg LRU lists] by making it harder for
kswapd to force scan small targets but that patchset is not suitable for
backporting. This was later changed again by commit [90126375: mm/vmscan:
push lruvec pointer into get_scan_count()] into a format that looks
like it would be a straight-forward backport but there is a subtle
difference due to the use of lruvecs.

The impact of the accidental fix is to make it harder for kswapd to force
scan small targets by taking zone->all_unreclaimable into account. This
patch is the closest equivalent available based on what is backported.

Signed-off-by: Mel Gorman <mgorman@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 4d01a2e38a9c27d3de083ecc561b32b6a55fc7eb)

Signed-off-by: Jerry Snitselaar <jerry.snitselaar@oracle.com>
mm/vmscan.c