Files
linux/mm
Chris Li 348e474f18 mm/swapfile.c: introduce function alloc_swap_scan_list()
Patch series "mm/swapfile.c and swap.h cleanup", v3.

This patch series, which builds on Kairui's swap improve cluster scan series.
https://lore.kernel.org/linux-mm/20250806161748.76651-1-ryncsn@gmail.com/

It introduces a new function, alloc_swap_scan_list(), for swapfile.c.

It also cleans up swap.h by removing comments that reference fields that
have been deleted.

There are no functional changes in this two-patch series.


This patch (of 2):

alloc_swap_scan_list() will scan the whole list or the first cluster.

This reduces the repeat patterns of isolating a cluster then scanning that
cluster.  As a result, cluster_alloc_swap_entry() is shorter and
shallower.

No functional change.

Link: https://lkml.kernel.org/r/20250812-swap-scan-list-v3-0-6d73504d267b@kernel.org
Link: https://lkml.kernel.org/r/20250812-swap-scan-list-v3-1-6d73504d267b@kernel.org
Signed-off-by: Chris Li <chrisl@kernel.org>
Reviewed-by: Kairui Song <kasong@tencent.com>
Acked-by: Nhat Pham <nphamcs@gmail.com>
Cc: Baoquan He <bhe@redhat.com>
Cc: Barry Song <baohua@kernel.org>
Cc: "Huang, Ying" <ying.huang@linux.alibaba.com>
Cc: Kemeng Shi <shikemeng@huaweicloud.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2025-09-13 16:55:00 -07:00
..
2025-09-13 16:54:58 -07:00
2025-07-23 11:55:22 +02:00
2025-06-05 22:02:25 -07:00
2025-07-24 19:12:36 -07:00
2024-11-03 01:28:06 -05:00
2025-09-13 16:54:58 -07:00
2025-09-13 16:54:54 -07:00
2025-08-02 12:06:09 -07:00
2025-08-02 12:06:10 -07:00
2025-09-13 16:54:50 -07:00
2025-09-13 16:54:58 -07:00
2025-08-02 12:06:09 -07:00
2025-09-13 16:54:46 -07:00
2024-07-10 12:14:54 -07:00
2025-09-13 16:54:58 -07:00
2025-06-18 13:06:26 +02:00
2025-08-27 22:45:43 -07:00
2025-08-02 12:06:09 -07:00
2025-09-13 16:54:58 -07:00