[PATCH 6/9] ntfs: Remove redundant FGP_NOFS from ntfs_wof_collect_dest()

From: Matthew Wilcox (Oracle)

Date: Sun Aug 30 2026 - 00:19:22 EST


The flags already include FGP_NOWAIT which prohibits all reclaim, not
just reclaiming from the filesystem. Use mapping_gfp_mask() instead of
GFP_NOFS as this will preserve flags like GFP_MOVABLE.

Signed-off-by: Matthew Wilcox (Oracle) <willy@xxxxxxxxxxxxx>
---
fs/ntfs/wof.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/fs/ntfs/wof.c b/fs/ntfs/wof.c
index 8f84c2212eee..c981b4a3b695 100644
--- a/fs/ntfs/wof.c
+++ b/fs/ntfs/wof.c
@@ -464,10 +464,9 @@ static int ntfs_wof_collect_dest(struct address_space *mapping,
folio = target;
is_target = true;
} else {
- folio = __filemap_get_folio(
- mapping, index,
- FGP_LOCK | FGP_CREAT | FGP_NOFS | FGP_NOWAIT,
- GFP_NOFS);
+ folio = __filemap_get_folio(mapping, index,
+ FGP_LOCK | FGP_CREAT | FGP_NOWAIT,
+ mapping_gfp_mask(mapping));
if (IS_ERR(folio))
return PTR_ERR(folio);
is_target = false;
--
2.47.3