[PATCH v2 6/6] mm/swap: rename __swap_writepage() to __swap_writeout()
From: Tal Zussman
Date: Sat Aug 29 2026 - 15:12:45 EST
Commit 84798514db50 ("mm: Remove swap_writepage() and
shmem_writepage()") renamed swap_writepage() to swap_writeout(). Rename
__swap_writepage(), which operates on a folio, to match its caller.
Update a stale reference to swap_writepage() in swapfile.c as well.
Reviewed-by: Matthew Wilcox (Oracle) <willy@xxxxxxxxxxxxx>
Reviewed-by: Lorenzo Stoakes (ARM) <ljs@xxxxxxxxxx>
Signed-off-by: Tal Zussman <tz2294@xxxxxxxxxxxx>
---
mm/page_io.c | 4 ++--
mm/swap.h | 2 +-
mm/swapfile.c | 2 +-
mm/zswap.c | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/mm/page_io.c b/mm/page_io.c
index 36466159cf19..1da4ff484f09 100644
--- a/mm/page_io.c
+++ b/mm/page_io.c
@@ -248,7 +248,7 @@ int swap_writeout(struct swap_io_ctx *ctx, struct folio *folio)
}
rcu_read_unlock();
- __swap_writepage(ctx, folio);
+ __swap_writeout(ctx, folio);
return 0;
out_unlock:
folio_unlock(folio);
@@ -369,7 +369,7 @@ static void swap_add_folio(struct swap_io_ctx *ctx, struct folio *folio, int rw)
}
}
-void __swap_writepage(struct swap_io_ctx *ctx, struct folio *folio)
+void __swap_writeout(struct swap_io_ctx *ctx, struct folio *folio)
{
VM_BUG_ON_FOLIO(!folio_test_swapcache(folio), folio);
diff --git a/mm/swap.h b/mm/swap.h
index fddba7a87500..0b5d507739bc 100644
--- a/mm/swap.h
+++ b/mm/swap.h
@@ -258,7 +258,7 @@ void swap_read_folio(struct swap_io_ctx *ctx, struct folio *folio);
void swap_read_submit(struct swap_io_ctx *ctx);
void swap_write_submit(struct swap_io_ctx *ctx);
int swap_writeout(struct swap_io_ctx *ctx, struct folio *folio);
-void __swap_writepage(struct swap_io_ctx *ctx, struct folio *folio);
+void __swap_writeout(struct swap_io_ctx *ctx, struct folio *folio);
/* linux/mm/swap_state.c */
extern struct address_space swap_space __read_mostly;
diff --git a/mm/swapfile.c b/mm/swapfile.c
index 51f5a525bb61..ab9d45dbbef8 100644
--- a/mm/swapfile.c
+++ b/mm/swapfile.c
@@ -2989,7 +2989,7 @@ EXPORT_SYMBOL_GPL(add_swap_extent);
/*
* A `swap extent' is a simple thing which maps a contiguous range of pages
* onto a contiguous range of disk blocks. A rbtree of swap extents is
- * built at swapon time and is then used at swap_writepage/swap_read_folio
+ * built at swapon time and is then used at swap_writeout/swap_read_folio
* time for locating where on disk a page belongs.
*
* If the swapfile is an S_ISBLK block device, a single extent is installed.
diff --git a/mm/zswap.c b/mm/zswap.c
index 37f34e406c8e..88a1a74f9185 100644
--- a/mm/zswap.c
+++ b/mm/zswap.c
@@ -1050,7 +1050,7 @@ static int zswap_writeback_entry(struct zswap_entry *entry,
folio_set_reclaim(folio);
/* start writeback */
- __swap_writepage(&ctx, folio);
+ __swap_writeout(&ctx, folio);
swap_write_submit(&ctx);
out:
--
2.39.5