[PATCH 00/10] Various fixes around invalidate_page()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Blame Rik for this.  His "clean up hwpoison page cache page in fault path"
patch on Friday made me look at how invalidate_inode_page() handled tail
pages.  It's not buggy, but __invalidate_mapping_pages() has a minor
accounting bug, and all of this related code could be done a little
more efficiently by using folios instead of pages.

I don't _love_ the name mapping_shrink_folio(), but I'm having a hard
time coming up with a verb that means "remove from cache if unused".
Maybe mapping_evict_folio()?  Or filemap_evict_folio()?

The last two patches are just cleanup that should be done at some point,
and since this patchset already conflicts with everything else, why not?
I've stashed these in my for-next tree immediately after converting
__remove_mapping() to take a folio because it seems to fit best there.
The bots may complain about build problems as a result, but this is
really a patch series for humans to review.

Matthew Wilcox (Oracle) (10):
  splice: Use a folio in page_cache_pipe_buf_try_steal()
  mm/truncate: Inline invalidate_complete_page() into its one caller
  mm/truncate: Convert invalidate_inode_page() to use a folio
  mm/truncate: Replace page_mapped() call in invalidate_inode_page()
  mm: Convert remove_mapping() to take a folio
  mm/truncate: Split invalidate_inode_page() into mapping_shrink_folio()
  mm/truncate: Convert __invalidate_mapping_pages() to use a folio
  mm: Turn deactivate_file_page() into deactivate_file_folio()
  mm/truncate: Combine invalidate_mapping_pagevec() and
    __invalidate_mapping_pages()
  fs: Move many prototypes to pagemap.h

 drivers/block/xen-blkback/xenbus.c           |   1 +
 drivers/usb/gadget/function/f_mass_storage.c |   1 +
 fs/coda/file.c                               |   1 +
 fs/iomap/fiemap.c                            |   1 +
 fs/nfsd/filecache.c                          |   1 +
 fs/nfsd/vfs.c                                |   1 +
 fs/splice.c                                  |  24 ++--
 fs/vboxsf/utils.c                            |   1 +
 include/linux/fs.h                           | 120 -------------------
 include/linux/mm.h                           |   1 -
 include/linux/pagemap.h                      | 114 ++++++++++++++++++
 include/linux/swap.h                         |   3 +-
 mm/internal.h                                |   4 +
 mm/memory-failure.c                          |   4 +-
 mm/swap.c                                    |  33 +++--
 mm/truncate.c                                | 109 ++++++++---------
 mm/vmscan.c                                  |  23 ++--
 17 files changed, 219 insertions(+), 223 deletions(-)

-- 
2.34.1





[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux