From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CD950C433DF for ; Thu, 2 Jul 2020 11:29:02 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 78A96208D5 for ; Thu, 2 Jul 2020 11:29:02 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 78A96208D5 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id B413F6B0010; Thu, 2 Jul 2020 07:29:01 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id AF0306B0022; Thu, 2 Jul 2020 07:29:01 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A05576B0024; Thu, 2 Jul 2020 07:29:01 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0211.hostedemail.com [216.40.44.211]) by kanga.kvack.org (Postfix) with ESMTP id 8ADEF6B0010 for ; Thu, 2 Jul 2020 07:29:01 -0400 (EDT) Received: from smtpin05.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 231E51EE6 for ; Thu, 2 Jul 2020 11:29:01 +0000 (UTC) X-FDA: 76992914082.05.birds94_1615fdb26e88 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin05.hostedemail.com (Postfix) with ESMTP id EBB9318014EAB for ; Thu, 2 Jul 2020 11:29:00 +0000 (UTC) X-HE-Tag: birds94_1615fdb26e88 X-Filterd-Recvd-Size: 3410 Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by imf36.hostedemail.com (Postfix) with ESMTP for ; Thu, 2 Jul 2020 11:28:59 +0000 (UTC) IronPort-SDR: cGyU8EO00WGxSCBpsI8b2+crjwJyOLoG4FUl6JwNpL5e/PlqHNZ8cwj9l5+jLILtyz4nN9OgMW 9J7Itaw9aIQA== X-IronPort-AV: E=McAfee;i="6000,8403,9669"; a="126480596" X-IronPort-AV: E=Sophos;i="5.75,304,1589266800"; d="scan'208";a="126480596" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Jul 2020 04:28:58 -0700 IronPort-SDR: 9pspgZgUgzf7zRU62SMBhQfnaU/uODCsqnCGJmwULdBs3t7b8znyp7HUUCefXA4c2HsAAYqLai Io5U+R/YQi8Q== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,304,1589266800"; d="scan'208";a="481972084" Received: from yhuang-dev.sh.intel.com (HELO yhuang-dev) ([10.239.159.23]) by fmsmga005.fm.intel.com with ESMTP; 02 Jul 2020 04:28:55 -0700 From: "Huang\, Ying" To: Dave Hansen Cc: , , , , , , , , , , Subject: Re: [PATCH 1/3] mm/vmscan: restore zone_reclaim_mode ABI References: <20200701152621.D520E62B@viggo.jf.intel.com> <20200701152623.384AF0A7@viggo.jf.intel.com> Date: Thu, 02 Jul 2020 19:28:55 +0800 In-Reply-To: <20200701152623.384AF0A7@viggo.jf.intel.com> (Dave Hansen's message of "Wed, 1 Jul 2020 08:26:23 -0700") Message-ID: <87d05ejgug.fsf@yhuang-dev.intel.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=ascii X-Rspamd-Queue-Id: EBB9318014EAB X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam04 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Dave Hansen writes: > From: Dave Hansen > > I went to go add a new RECLAIM_* mode for the zone_reclaim_mode > sysctl. Like a good kernel developer, I also went to go update the > documentation. I noticed that the bits in the documentation didn't > match the bits in the #defines. > > The VM never explicitly checks the RECLAIM_ZONE bit. The bit is, > however implicitly checked when checking 'node_reclaim_mode==0'. > The RECLAIM_ZONE #define was removed in a cleanup. That, by itself > is fine. > > But, when the bit was removed (bit 0) the _other_ bit locations also > got changed. That's not OK because the bit values are documented to > mean one specific thing and users surely rely on them meaning that one > thing and not changing from kernel to kernel. The end result is that > if someone had a script that did: > > sysctl vm.zone_reclaim_mode=1 > > That script went from doing nothing Per my understanding, this script would have enabled node reclaim for clean unmapped pages before commit 648b5cf368e0 ("mm/vmscan: remove unused RECLAIM_OFF/RECLAIM_ZONE"). So we should revise the description here? > to writing out pages during > node reclaim after the commit in question. That's not great. > > Put the bits back the way they were and add a comment so something > like this is a bit harder to do again. Update the documentation to > make it clear that the first bit is ignored. > Best Regards, Huang, Ying