linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mel Gorman <mgorman@techsingularity.net>
To: Andrew Morton <akpm@linux-foundation.org>, Linux-MM <linux-mm@kvack.org>
Cc: Johannes Weiner <hannes@cmpxchg.org>,
	Minchan Kim <minchan@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Mel Gorman <mgorman@techsingularity.net>
Subject: [PATCH 4/4] mm: move most file-based accounting to the node -fix
Date: Wed, 13 Jul 2016 11:00:04 +0100	[thread overview]
Message-ID: <1468404004-5085-5-git-send-email-mgorman@techsingularity.net> (raw)
In-Reply-To: <1468404004-5085-1-git-send-email-mgorman@techsingularity.net>

As noted by Johannes Weiner, NR_ZONE_WRITE_PENDING gets decremented twice
during migration instead of a dec(old) -> inc(new) cycle as intended.

This is a fix to mmotm patch
mm-move-most-file-based-accounting-to-the-node.patch

Note that it'll cause a conflict with
mm-vmstat-remove-zone-and-node-double-accounting-by-approximating-retries.patch
but that the resolution is trivial.

Signed-off-by: Mel Gorman <mgorman@techsingularity.net>
---
 mm/migrate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/migrate.c b/mm/migrate.c
index c77997dc6ed7..ed0268268e93 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -515,7 +515,7 @@ int migrate_page_move_mapping(struct address_space *mapping,
 			__dec_node_state(oldzone->zone_pgdat, NR_FILE_DIRTY);
 			__dec_zone_state(oldzone, NR_ZONE_WRITE_PENDING);
 			__inc_node_state(newzone->zone_pgdat, NR_FILE_DIRTY);
-			__dec_zone_state(newzone, NR_ZONE_WRITE_PENDING);
+			__inc_zone_state(newzone, NR_ZONE_WRITE_PENDING);
 		}
 	}
 	local_irq_enable();
-- 
2.6.4

  parent reply	other threads:[~2016-07-13 10:01 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-13 10:00 [PATCH 0/4] Follow-up fixes to node-lru series v1 Mel Gorman
2016-07-13 10:00 ` [PATCH 1/4] mm, vmscan: Have kswapd reclaim from all zones if reclaiming and buffer_heads_over_limit -fix Mel Gorman
2016-07-13 13:10   ` Johannes Weiner
2016-07-14  1:22   ` Minchan Kim
2016-07-13 10:00 ` [PATCH 2/4] mm: vmstat: account per-zone stalls and pages skipped during reclaim -fix Mel Gorman
2016-07-13 13:10   ` Johannes Weiner
2016-07-14 14:45   ` Vlastimil Babka
2016-07-13 10:00 ` [PATCH 3/4] mm, page_alloc: fix dirtyable highmem calculation Mel Gorman
2016-07-13 13:15   ` Johannes Weiner
2016-07-14 15:22   ` Vlastimil Babka
2016-07-13 10:00 ` Mel Gorman [this message]
2016-07-13 13:16   ` [PATCH 4/4] mm: move most file-based accounting to the node -fix Johannes Weiner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1468404004-5085-5-git-send-email-mgorman@techsingularity.net \
    --to=mgorman@techsingularity.net \
    --cc=akpm@linux-foundation.org \
    --cc=hannes@cmpxchg.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=minchan@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).