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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id B37FFC04FFE for ; Fri, 17 May 2024 09:14:03 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 24DB66B0085; Fri, 17 May 2024 05:14:03 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 1FE326B0088; Fri, 17 May 2024 05:14:03 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0ED126B0089; Fri, 17 May 2024 05:14:03 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id E6D166B0085 for ; Fri, 17 May 2024 05:14:02 -0400 (EDT) Received: from smtpin12.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 5FDD61A006F for ; Fri, 17 May 2024 09:14:02 +0000 (UTC) X-FDA: 82127325924.12.16FCE55 Received: from phoenix.uberspace.de (phoenix.uberspace.de [95.143.172.135]) by imf14.hostedemail.com (Postfix) with ESMTP id 5F7B810000A for ; Fri, 17 May 2024 09:14:00 +0000 (UTC) Authentication-Results: imf14.hostedemail.com; dkim=pass header.d=yshyn.com header.s=uberspace header.b=s8qF9X+x; spf=pass (imf14.hostedemail.com: domain of illia@yshyn.com designates 95.143.172.135 as permitted sender) smtp.mailfrom=illia@yshyn.com; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1715937240; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:references:dkim-signature; bh=oPFQIg0ko21AngBowgpROR5t84Fq6KmBGriZzjFVcw4=; b=kP6CfuZAPZGG6zXawLNKrF/j5/UArYCAqXvTmnzUKnUhkCvPjal+4N1sl35iYSBbaS7aQ2 MkDlnyWY/JPcG1nf50A8xQ9HD+h9IxcJpzoi2rj90za2tthWS1lt2LY35V01q4vRKxqJ/I /DpasHWxCtSgYHqGpSKgFFIFrdsmLEA= ARC-Authentication-Results: i=1; imf14.hostedemail.com; dkim=pass header.d=yshyn.com header.s=uberspace header.b=s8qF9X+x; spf=pass (imf14.hostedemail.com: domain of illia@yshyn.com designates 95.143.172.135 as permitted sender) smtp.mailfrom=illia@yshyn.com; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1715937240; a=rsa-sha256; cv=none; b=HZ5e/MX8YdRyfM7g/JW9UJT41Vr/o4tjiicijpOOruYV9i1FP0XhHECcR4+AlH6w8sb1a4 uVb3+wmEL4bZ44uDzV0XKkThba0kpKt8FZS5Kjxdq2Fl8UADT4VPsNrXlyLSSe3ZgqS4RY VS26vOjCgA1kMlfHuqCVQnSr9CIJM3M= Received: (qmail 13005 invoked by uid 988); 17 May 2024 09:13:58 -0000 Received: from unknown (HELO unkown) (::1) by phoenix.uberspace.de (Haraka/3.0.1) with ESMTPSA; Fri, 17 May 2024 11:13:57 +0200 From: Illia Ostapyshyn To: Jonathan Corbet , Andrew Morton , Matthew Wilcox Cc: linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Illia Ostapyshyn Subject: [PATCH] mm/vmscan: Update stale references to shrink_page_list Date: Fri, 17 May 2024 11:13:48 +0200 Message-Id: <20240517091348.1185566-1-illia@yshyn.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Bar: + X-Rspamd-Report: MID_CONTAINS_FROM(1) MIME_GOOD(-0.1) R_MISSING_CHARSET(0.5) X-Rspamd-Score: 1.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yshyn.com; s=uberspace; h=from:to:cc:subject:date; bh=zUX5qNIfW548vNLMV3YfOWr2RVuk/rIW/JNspwwgaDA=; b=s8qF9X+xASJEWN/cMfdXpv37+eChv24TVme12xnLdvA65YeLPvsTXzosKqg8OeC49J5W76JCJG jXt8b3WBCoWyHOW6ZAXTIEhwcx3HgSKo7GNhhPzlmOFAiMkpfbb/Qr2+tBLxzjpAAPK2KqHIAS3X dun0Pvmwj1DQ5Ikf7ijj4Y6RxzPpcYrN9nNzeGMn0R0Thnq6Z3unRuYKkAK98CKUGmfeVqggYD8j 7pWiuwES3hWX1bm0vSyKHopIQGsB0IWLRKFbBd0pEPGW4zAG8AmBYKOyWdHAm1T2zG3TdRB4+fRv qKhYjDH39qcYIOrnRP/Z7LvFijc0MOp8VK/n/Kiw== X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 5F7B810000A X-Stat-Signature: 4i41ux9m4zbgn81paur6roa5o6hs8q76 X-Rspam-User: X-HE-Tag: 1715937240-249868 X-HE-Meta: U2FsdGVkX18y3liYuGQ7PSSt6CNU7bgjC59KzlIeU8nEiviXOVA+3Xfx89IEZthDDvsfzgINsTO6tS5/wuRzHvYVnPjQUWUaYLPpLF9s/uxVXL+rEVTUwov3YWogT8iMYYD90itp/H+kfFtnTEulhnE/JI9XPFebVZHMvA/3oGAZ8ztvzatOzRhaA/neCkedeiAQBqVYaaUsOmZOAuuj0TM12LTd5lmJUEoPVfYBCmGzlhDTTytaR72dElszOj7zDyt7r43p01gBOlsOZPvtp0VdjOGuSOCI/FSxnozF89IHrK+rkuNjNsVeIKTro2ySLurV+O3d5rPOr8N5RK/uduS3sihhGlLHz3KPdKMwPVPpFNtexsRWeoyb/3DByB/obCZ4/m+uKfibbrH+cX2JVcMazdSQWPqQYp577OMayTuD4O8vrFqUkfAcTBfVbHbBeZqxbMOeG2zen8wLluerV6mCOceQ7ivKm5VnHBfXn4bLrRLVhwH9sZ+uKHKmxoORZm4p0gZmo5+lVgsJxvgP3BMVc6ynA9osU+civhE60ldLTFAj4ECq9j+AbdxJN0AATdQaYUwZOu1ELQP3QhG+PcUWT9BRYjm8ovPNTqgIHgKAEL4JqK+cVRTx6NFAsFaqyJ7bAiUwFEPDXlxHKhGCDNcwBW2DK2XohbL7sL3/5zrHm8SmNtjT9RfbsUqGLn6MJJX/VBQjk9IX7yDi5eIeUF4LWHBXd03SvM68Be/HZdT64bcDviwnXBPCcxkd1Yb3GGXxKqszhwwBOFpE1C0OUY2WQQhynI8dLyX9Vk41walz+uEpQTZqcki0ODv5/flZybtAz0xvas7JqLYs2P5M+YpnZF2PPjP++rxiz5Z+6t6rnIy/SgeAjGvmTcC6bI8UA/XOOEa4De9FLYP7x2hux/on8kiIIsD6Ofg7toQravPmdLVg+YYND5S82uGirDxaP3mrWGO0MssbA+P7j2C UwN627jb Pjv9ea5Ec+UjCqxYuYATDcV2kwVUMOylPuHoEUGj+DuG6LbzHdkU6lZ0OYKNSpJDG+EsHPds8mtge5+w0mHvO8Hjmkidx+sSdFxOda749RGEqF2Iq3aPkGotpmGT//v64faT2JEi+AacgtGxyLUSuwuGZ9p98QuAh2o9SEi3te0W+WlCMSLBqWNAB1Qftq1Ekn4GcvP79hepHF7iUB0nKFjqf1mY1PGeOhJAUatRakhWZWhvotkIvjMs/dPOAYmideiFj 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: List-Subscribe: List-Unsubscribe: Commit 49fd9b6df54e ("mm/vmscan: fix a lot of comments") renamed shrink_page_list() to shrink_folio_list(). Fix up the remaining references to the old name in comments and documentation. Signed-off-by: Illia Ostapyshyn --- Documentation/mm/unevictable-lru.rst | 10 +++++----- mm/memory.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Documentation/mm/unevictable-lru.rst b/Documentation/mm/unevictable-lru.rst index b6a07a26b10d..2feb2ed51ae2 100644 --- a/Documentation/mm/unevictable-lru.rst +++ b/Documentation/mm/unevictable-lru.rst @@ -191,13 +191,13 @@ have become evictable again (via munlock() for example) and have been "rescued" from the unevictable list. However, there may be situations where we decide, for the sake of expediency, to leave an unevictable folio on one of the regular active/inactive LRU lists for vmscan to deal with. vmscan checks for such -folios in all of the shrink_{active|inactive|page}_list() functions and will +folios in all of the shrink_{active|inactive|folio}_list() functions and will "cull" such folios that it encounters: that is, it diverts those folios to the unevictable list for the memory cgroup and node being scanned. There may be situations where a folio is mapped into a VM_LOCKED VMA, but the folio does not have the mlocked flag set. Such folios will make -it all the way to shrink_active_list() or shrink_page_list() where they +it all the way to shrink_active_list() or shrink_folio_list() where they will be detected when vmscan walks the reverse map in folio_referenced() or try_to_unmap(). The folio is culled to the unevictable list when it is released by the shrinker. @@ -269,7 +269,7 @@ the LRU. Such pages can be "noticed" by memory management in several places: (4) in the fault path and when a VM_LOCKED stack segment is expanded; or - (5) as mentioned above, in vmscan:shrink_page_list() when attempting to + (5) as mentioned above, in vmscan:shrink_folio_list() when attempting to reclaim a page in a VM_LOCKED VMA by folio_referenced() or try_to_unmap(). mlocked pages become unlocked and rescued from the unevictable list when: @@ -548,12 +548,12 @@ Some examples of these unevictable pages on the LRU lists are: (3) pages still mapped into VM_LOCKED VMAs, which should be marked mlocked, but events left mlock_count too low, so they were munlocked too early. -vmscan's shrink_inactive_list() and shrink_page_list() also divert obviously +vmscan's shrink_inactive_list() and shrink_folio_list() also divert obviously unevictable pages found on the inactive lists to the appropriate memory cgroup and node unevictable list. rmap's folio_referenced_one(), called via vmscan's shrink_active_list() or -shrink_page_list(), and rmap's try_to_unmap_one() called via shrink_page_list(), +shrink_folio_list(), and rmap's try_to_unmap_one() called via shrink_folio_list(), check for (3) pages still mapped into VM_LOCKED VMAs, and call mlock_vma_folio() to correct them. Such pages are culled to the unevictable list when released by the shrinker. diff --git a/mm/memory.c b/mm/memory.c index 0201f50d8307..c58b3d92e6a8 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -4511,7 +4511,7 @@ static vm_fault_t __do_fault(struct vm_fault *vmf) * lock_page(B) * lock_page(B) * pte_alloc_one - * shrink_page_list + * shrink_folio_list * wait_on_page_writeback(A) * SetPageWriteback(B) * unlock_page(B) diff --git a/mm/swap_state.c b/mm/swap_state.c index bfc7e8c58a6d..3d163ec1364a 100644 --- a/mm/swap_state.c +++ b/mm/swap_state.c @@ -28,7 +28,7 @@ /* * swapper_space is a fiction, retained to simplify the path through - * vmscan's shrink_page_list. + * vmscan's shrink_folio_list. */ static const struct address_space_operations swap_aops = { .writepage = swap_writepage, diff --git a/mm/truncate.c b/mm/truncate.c index 725b150e47ac..e1c352bb026b 100644 --- a/mm/truncate.c +++ b/mm/truncate.c @@ -554,7 +554,7 @@ EXPORT_SYMBOL(invalidate_mapping_pages); * This is like mapping_evict_folio(), except it ignores the folio's * refcount. We do this because invalidate_inode_pages2() needs stronger * invalidation guarantees, and cannot afford to leave folios behind because - * shrink_page_list() has a temp ref on them, or because they're transiently + * shrink_folio_list() has a temp ref on them, or because they're transiently * sitting in the folio_add_lru() caches. */ static int invalidate_complete_folio2(struct address_space *mapping, -- 2.39.2