Skip to content

Commit

Permalink
mm/vmscan: push lruvec pointer into putback_inactive_pages()
Browse files Browse the repository at this point in the history
As zone_reclaim_stat is now located in the lruvec, we can reach it
directly.

Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
Cc: Mel Gorman <mel@csn.ul.ie>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Acked-by: Hugh Dickins <hughd@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Konstantin Khlebnikov authored and Linus Torvalds committed May 29, 2012
1 parent 95d918f commit 27ac81d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mm/vmscan.c
Original file line number Diff line number Diff line change
Expand Up @@ -1155,11 +1155,11 @@ static int too_many_isolated(struct zone *zone, int file,
}

static noinline_for_stack void
putback_inactive_pages(struct mem_cgroup_zone *mz,
putback_inactive_pages(struct lruvec *lruvec,
struct list_head *page_list)
{
struct zone_reclaim_stat *reclaim_stat = get_reclaim_stat(mz);
struct zone *zone = mz->zone;
struct zone_reclaim_stat *reclaim_stat = &lruvec->reclaim_stat;
struct zone *zone = lruvec_zone(lruvec);
LIST_HEAD(pages_to_free);

/*
Expand Down Expand Up @@ -1278,7 +1278,7 @@ shrink_inactive_list(unsigned long nr_to_scan, struct mem_cgroup_zone *mz,
nr_reclaimed);
}

putback_inactive_pages(mz, &page_list);
putback_inactive_pages(lruvec, &page_list);

__mod_zone_page_state(zone, NR_ISOLATED_ANON + file, -nr_taken);

Expand Down

0 comments on commit 27ac81d

Please sign in to comment.