From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752769AbcGMKBX (ORCPT ); Wed, 13 Jul 2016 06:01:23 -0400 Received: from outbound-smtp07.blacknight.com ([46.22.139.12]:59722 "EHLO outbound-smtp07.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751342AbcGMKAU (ORCPT ); Wed, 13 Jul 2016 06:00:20 -0400 From: Mel Gorman To: Andrew Morton , Linux-MM Cc: Johannes Weiner , Minchan Kim , LKML , Mel Gorman Subject: [PATCH 4/4] mm: move most file-based accounting to the node -fix Date: Wed, 13 Jul 2016 11:00:04 +0100 Message-Id: <1468404004-5085-5-git-send-email-mgorman@techsingularity.net> X-Mailer: git-send-email 2.6.4 In-Reply-To: <1468404004-5085-1-git-send-email-mgorman@techsingularity.net> References: <1468404004-5085-1-git-send-email-mgorman@techsingularity.net> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 --- 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 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf0-f69.google.com (mail-lf0-f69.google.com [209.85.215.69]) by kanga.kvack.org (Postfix) with ESMTP id 7FD196B0262 for ; Wed, 13 Jul 2016 06:00:15 -0400 (EDT) Received: by mail-lf0-f69.google.com with SMTP id p41so29628185lfi.0 for ; Wed, 13 Jul 2016 03:00:15 -0700 (PDT) Received: from outbound-smtp08.blacknight.com (outbound-smtp08.blacknight.com. [46.22.139.13]) by mx.google.com with ESMTPS id e8si24962wjy.122.2016.07.13.03.00.07 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Jul 2016 03:00:07 -0700 (PDT) Received: from mail.blacknight.com (pemlinmail05.blacknight.ie [81.17.254.26]) by outbound-smtp08.blacknight.com (Postfix) with ESMTPS id F1F621C2050 for ; Wed, 13 Jul 2016 11:00:06 +0100 (IST) From: Mel Gorman Subject: [PATCH 4/4] mm: move most file-based accounting to the node -fix Date: Wed, 13 Jul 2016 11:00:04 +0100 Message-Id: <1468404004-5085-5-git-send-email-mgorman@techsingularity.net> In-Reply-To: <1468404004-5085-1-git-send-email-mgorman@techsingularity.net> References: <1468404004-5085-1-git-send-email-mgorman@techsingularity.net> Sender: owner-linux-mm@kvack.org List-ID: To: Andrew Morton , Linux-MM Cc: Johannes Weiner , Minchan Kim , LKML , Mel Gorman 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 --- 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 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org