Skip to content

Commit dd309bf

Browse files
ryncsnakpm00
authored andcommitted
mm, swap: remove no longer used swap mapping helper
This helper existed to fix the circular header dependency issue but it is no longer used since commit 0d40cfe ("fs: remove folio_file_mapping()"), remove it. Link: https://lkml.kernel.org/r/20250430181052.55698-7-ryncsn@gmail.com Signed-off-by: Kairui Song <kasong@tencent.com> Reviewed-by: Matthew Wilcox (Oracle) <willy@infradead.org> Acked-by: David Hildenbrand <david@redhat.com> Cc: Chao Yu <chao@kernel.org> Cc: Chris Li <chrisl@kernel.org> Cc: Chris Mason <clm@fb.com> Cc: Christian Brauner <brauner@kernel.org> Cc: David Sterba <dsterba@suse.com> Cc: "Huang, Ying" <ying.huang@linux.alibaba.com> Cc: Hugh Dickins <hughd@google.com> Cc: Jaegeuk Kim <jaegeuk@kernel.org> Cc: Joanne Koong <joannelkoong@gmail.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Josef Bacik <josef@toxicpanda.com> Cc: Miklos Szeredi <miklos@szeredi.hu> Cc: Nhat Pham <nphamcs@gmail.com> Cc: Qu Wenruo <wqu@suse.com> Cc: Yosry Ahmed <yosryahmed@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
1 parent 7d0f0f0 commit dd309bf

File tree

2 files changed

+0
-10
lines changed

2 files changed

+0
-10
lines changed

include/linux/pagemap.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,6 @@ static inline void filemap_nr_thps_dec(struct address_space *mapping)
533533
}
534534

535535
struct address_space *folio_mapping(struct folio *);
536-
struct address_space *swapcache_mapping(struct folio *);
537536

538537
/**
539538
* folio_flush_mapping - Find the file mapping this folio belongs to.

mm/swapfile.c

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3662,15 +3662,6 @@ struct swap_info_struct *swp_swap_info(swp_entry_t entry)
36623662
return swap_type_to_swap_info(swp_type(entry));
36633663
}
36643664

3665-
/*
3666-
* out-of-line methods to avoid include hell.
3667-
*/
3668-
struct address_space *swapcache_mapping(struct folio *folio)
3669-
{
3670-
return swp_swap_info(folio->swap)->swap_file->f_mapping;
3671-
}
3672-
EXPORT_SYMBOL_GPL(swapcache_mapping);
3673-
36743665
/*
36753666
* add_swap_count_continuation - called when a swap count is duplicated
36763667
* beyond SWAP_MAP_MAX, it allocates a new page and links that to the entry's

0 commit comments

Comments
 (0)