]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mm: add FGP_DONTCACHE folio creation flag
authorJens Axboe <axboe@kernel.dk>
Fri, 20 Dec 2024 15:47:50 +0000 (08:47 -0700)
committerAndrew Morton <akpm@linux-foundation.org>
Sun, 26 Jan 2025 04:22:44 +0000 (20:22 -0800)
commitd94d23fdd7529f1f3218235d1e0a69e9856907b7
tree4d141ebef762478f35f56094ba9ce7b2da852598
parent1d4457576570627e1702614bc060b55d95b85e39
mm: add FGP_DONTCACHE folio creation flag

Callers can pass this in for uncached folio creation, in which case if a
folio is newly created it gets marked as uncached.  If a folio exists for
this index and lookup succeeds, then it will not get marked as uncached.
If an !uncached lookup finds a cached folio, clear the flag.  For that
case, there are competeting uncached and cached users of the folio, and it
should not get pruned.

Link: https://lkml.kernel.org/r/20241220154831.1086649-13-axboe@kernel.dk
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Cc: Brian Foster <bfoster@redhat.com>
Cc: Chris Mason <clm@meta.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/pagemap.h
mm/filemap.c