mm/page_alloc.c: fix wrong initialization when sysctl_min_unmapped_ratio changes
authorJoonsoo Kim <iamjoonsoo.kim@lge.com>
Wed, 10 Aug 2016 23:27:46 +0000 (16:27 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 10 Aug 2016 23:40:56 +0000 (16:40 -0700)
Before resetting min_unmapped_pages, we need to initialize
min_unmapped_pages rather than min_slab_pages.

Fixes: a5f5f91da6 (mm: convert zone_reclaim to node_reclaim)
Link: http://lkml.kernel.org/r/1470724248-26780-1-git-send-email-iamjoonsoo.kim@lge.com
Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Acked-by: Mel Gorman <mgorman@techsingularity.net>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Minchan Kim <minchan@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/page_alloc.c

index ee744fa3b93d50a9215daf43966cc97f957c77a4..9a92718b1103aae45f8b0f68e7be7431f98a5f5c 100644 (file)
@@ -6854,7 +6854,7 @@ int sysctl_min_unmapped_ratio_sysctl_handler(struct ctl_table *table, int write,
                return rc;
 
        for_each_online_pgdat(pgdat)
-               pgdat->min_slab_pages = 0;
+               pgdat->min_unmapped_pages = 0;
 
        for_each_zone(zone)
                zone->zone_pgdat->min_unmapped_pages += (zone->managed_pages *