From: David Hildenbrand <david@redhat.com>
To: Kairui Song <kasong@tencent.com>, linux-mm@kvack.org
Cc: Andrew Morton <akpm@linux-foundation.org>,
Matthew Wilcox <willy@infradead.org>,
Hugh Dickins <hughd@google.com>, Chris Li <chrisl@kernel.org>,
Yosry Ahmed <yosryahmed@google.com>,
"Huang, Ying" <ying.huang@linux.alibaba.com>,
Nhat Pham <nphamcs@gmail.com>,
Johannes Weiner <hannes@cmpxchg.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 5/6] mm: move folio_index to mm/swap.h and remove no longer needed helper
Date: Wed, 30 Apr 2025 23:11:03 +0200 [thread overview]
Message-ID: <19908a46-feaf-4bbb-b41c-ef5b7d72343a@redhat.com> (raw)
In-Reply-To: <20250430181052.55698-6-ryncsn@gmail.com>
On 30.04.25 20:10, Kairui Song wrote:
> From: Kairui Song <kasong@tencent.com>
>
> There are no remaining users of folio_index() outside the mm subsystem.
> Move it to mm/swap.h to co-locate it with swap_cache_index(), eliminating
> a forward declaration, and a function call overhead.
>
> Also remove the helper that was used to fix circular header dependency
> issue.
>
> Signed-off-by: Kairui Song <kasong@tencent.com>
> ---
> include/linux/pagemap.h | 20 --------------------
> mm/gup.c | 1 +
> mm/memfd.c | 1 +
> mm/migrate.c | 1 +
> mm/page-writeback.c | 1 +
> mm/swap.h | 18 ++++++++++++++++++
> mm/swapfile.c | 6 ------
> 7 files changed, 22 insertions(+), 26 deletions(-)
[...]
> bool isolate_movable_page(struct page *page, isolate_mode_t mode)
> {
> diff --git a/mm/page-writeback.c b/mm/page-writeback.c
> index 20e1d76f1eba..9ff44b64d3d6 100644
> --- a/mm/page-writeback.c
> +++ b/mm/page-writeback.c
> @@ -41,6 +41,7 @@
> #include <trace/events/writeback.h>
>
> #include "internal.h"
> +#include "swap.h"
I wonder if we should just have it in mm/internal.h instead?
In any case
Acked-by: David Hildenbrand <david@redhat.com>
--
Cheers,
David / dhildenb
next prev parent reply other threads:[~2025-04-30 21:11 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-30 18:10 [PATCH v3 0/6] mm, swap: clean up swap cache mapping helper Kairui Song
2025-04-30 18:10 ` [PATCH v3 1/6] fuse: drop usage of folio_index Kairui Song
2025-04-30 21:08 ` David Hildenbrand
2025-04-30 18:10 ` [PATCH v3 2/6] btrfs: " Kairui Song
2025-04-30 21:06 ` Andrew Morton
2025-04-30 21:07 ` David Hildenbrand
2025-05-01 10:13 ` Kairui Song
2025-04-30 21:08 ` David Hildenbrand
2025-05-01 8:50 ` David Sterba
2025-05-02 11:10 ` David Sterba
2025-04-30 18:10 ` [PATCH v3 3/6] f2fs: " Kairui Song
2025-04-30 21:08 ` David Hildenbrand
2025-05-06 8:49 ` Chao Yu
2025-06-09 20:56 ` [f2fs-dev] " patchwork-bot+f2fs
2025-04-30 18:10 ` [PATCH v3 4/6] filemap: do not use folio_contains for swap cache folios Kairui Song
2025-04-30 18:15 ` Kairui Song
2025-04-30 18:10 ` [PATCH v3 5/6] mm: move folio_index to mm/swap.h and remove no longer needed helper Kairui Song
2025-04-30 21:11 ` David Hildenbrand [this message]
2025-05-01 10:08 ` Kairui Song
2025-04-30 18:10 ` [PATCH v3 6/6] mm, swap: remove no longer used swap mapping helper Kairui Song
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=19908a46-feaf-4bbb-b41c-ef5b7d72343a@redhat.com \
--to=david@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=chrisl@kernel.org \
--cc=hannes@cmpxchg.org \
--cc=hughd@google.com \
--cc=kasong@tencent.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=nphamcs@gmail.com \
--cc=willy@infradead.org \
--cc=ying.huang@linux.alibaba.com \
--cc=yosryahmed@google.com \
/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