From: Kairui Song <ryncsn@gmail.com>
To: linux-mm@kvack.org
Cc: Andrew Morton <akpm@linux-foundation.org>,
Kemeng Shi <shikemeng@huaweicloud.com>,
Kairui Song <kasong@tencent.com>, Nhat Pham <nphamcs@gmail.com>,
Baoquan He <bhe@redhat.com>, Barry Song <baohua@kernel.org>,
Chris Li <chrisl@kernel.org>,
Baolin Wang <baolin.wang@linux.alibaba.com>,
David Hildenbrand <david@redhat.com>,
"Matthew Wilcox (Oracle)" <willy@infradead.org>,
Ying Huang <ying.huang@linux.alibaba.com>,
YoungJun Park <youngjun.park@lge.com>,
Kairui Song <ryncsn@gmail.com>,
linux-kernel@vger.kernel.org
Subject: [PATCH v2 5/5] mm, swap: remove redundant argument for isolating a cluster
Date: Fri, 24 Oct 2025 02:00:43 +0800 [thread overview]
Message-ID: <20251024-swap-clean-after-swap-table-p1-v2-5-a709469052e7@tencent.com> (raw)
In-Reply-To: <20251024-swap-clean-after-swap-table-p1-v2-0-a709469052e7@tencent.com>
From: Kairui Song <kasong@tencent.com>
The order argument was introduced by an intermediate commit and was then
never used, just remove it.
Signed-off-by: Kairui Song <kasong@tencent.com>
---
mm/swapfile.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/mm/swapfile.c b/mm/swapfile.c
index 42e2b2759240..214ccd1f69cd 100644
--- a/mm/swapfile.c
+++ b/mm/swapfile.c
@@ -594,7 +594,7 @@ static void __free_cluster(struct swap_info_struct *si, struct swap_cluster_info
* this returns NULL for an non-empty list.
*/
static struct swap_cluster_info *isolate_lock_cluster(
- struct swap_info_struct *si, struct list_head *list, int order)
+ struct swap_info_struct *si, struct list_head *list)
{
struct swap_cluster_info *ci, *found = NULL;
@@ -957,7 +957,7 @@ static unsigned int alloc_swap_scan_list(struct swap_info_struct *si,
unsigned int found = SWAP_ENTRY_INVALID;
do {
- struct swap_cluster_info *ci = isolate_lock_cluster(si, list, order);
+ struct swap_cluster_info *ci = isolate_lock_cluster(si, list);
unsigned long offset;
if (!ci)
@@ -982,7 +982,7 @@ static void swap_reclaim_full_clusters(struct swap_info_struct *si, bool force)
if (force)
to_scan = swap_usage_in_pages(si) / SWAPFILE_CLUSTER;
- while ((ci = isolate_lock_cluster(si, &si->full_clusters, 0))) {
+ while ((ci = isolate_lock_cluster(si, &si->full_clusters))) {
offset = cluster_offset(si, ci);
end = min(si->max, offset + SWAPFILE_CLUSTER);
to_scan--;
--
2.51.0
next prev parent reply other threads:[~2025-10-23 18:02 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-23 18:00 [PATCH v2 0/5] mm, swap: misc cleanup and bugfix Kairui Song
2025-10-23 18:00 ` [PATCH v2 2/5] mm, swap: rename helper for setup bad slots Kairui Song
2025-10-23 18:00 ` [PATCH v2 3/5] mm, swap: cleanup swap entry allocation parameter Kairui Song
2025-10-23 18:00 ` [PATCH v2 4/5] mm/migrate, swap: drop usage of folio_index Kairui Song
2025-10-23 18:00 ` Kairui Song [this message]
2025-10-23 18:49 ` [PATCH v2 5/5] mm, swap: remove redundant argument for isolating a cluster Nhat Pham
2025-10-24 13:18 ` [PATCH v2 0/5] mm, swap: misc cleanup and bugfix Lorenzo Stoakes
2025-10-24 13:26 ` Kairui Song
2025-10-25 3:31 ` Baoquan He
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=20251024-swap-clean-after-swap-table-p1-v2-5-a709469052e7@tencent.com \
--to=ryncsn@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=baohua@kernel.org \
--cc=baolin.wang@linux.alibaba.com \
--cc=bhe@redhat.com \
--cc=chrisl@kernel.org \
--cc=david@redhat.com \
--cc=kasong@tencent.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=nphamcs@gmail.com \
--cc=shikemeng@huaweicloud.com \
--cc=willy@infradead.org \
--cc=ying.huang@linux.alibaba.com \
--cc=youngjun.park@lge.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