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

From
Matthew Wilcox (Oracle) <willy@infradead.org>
Date
2026-08-30 04:19:11
Also in
linux-fsdevel, linux-mm, linux-nfs, lkml
Reply to
Matthew Wilcox (Oracle), 2026-08-30
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@infradead.org>
---
 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
Thread (33 messages) 33 messages, 8 authors, last reply 2026-09-03
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help