Skip to content

Commit 2ce211a

Browse files
Hugh Dickinsopsiff
authored andcommitted
ext4: add __GFP_NOWARN to GFP_NOWAIT in readahead
mainline inclusion from mainline-v6.7-rc1 category: bugfix Since commit e509ad4 ("ext4: use bdev_getblk() to avoid memory reclaim in readahead path") rightly replaced GFP_NOFAIL allocations by GFP_NOWAIT allocations, I've occasionally been seeing "page allocation failure: order:0" warnings under load: all with ext4_sb_breadahead_unmovable() in the stack. I don't think those warnings are of any interest: suppress them with __GFP_NOWARN. Link: https://lkml.kernel.org/r/7bc6ad16-9a4d-dd90-202e-47d6cbb5a136@google.com Fixes: e509ad4 ("ext4: use bdev_getblk() to avoid memory reclaim in readahead path") Signed-off-by: Hugh Dickins <hughd@google.com> Reviewed-by: Jan Kara <jack@suse.cz> Cc: Hui Zhu <teawater@antgroup.com> Cc: Matthew Wilcox (Oracle) <willy@infradead.org> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> (cherry picked from commit 1cbf0a5) Signed-off-by: Wentao Guan <guanwentao@uniontech.com>
1 parent 8e8660d commit 2ce211a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

fs/ext4/super.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ struct buffer_head *ext4_sb_bread_unmovable(struct super_block *sb,
269269
void ext4_sb_breadahead_unmovable(struct super_block *sb, sector_t block)
270270
{
271271
struct buffer_head *bh = bdev_getblk(sb->s_bdev, block,
272-
sb->s_blocksize, GFP_NOWAIT);
272+
sb->s_blocksize, GFP_NOWAIT | __GFP_NOWARN);
273273

274274
if (likely(bh)) {
275275
if (trylock_buffer(bh))

0 commit comments

Comments
 (0)