aboutsummaryrefslogtreecommitdiff
path: root/fs/ext2
diff options
context:
space:
mode:
authorGravatar Jan Kara <jack@suse.cz> 2024-01-09 12:15:43 +0100
committerGravatar Jan Kara <jack@suse.cz> 2024-01-23 19:21:10 +0100
commit36975616ea5837955ce9bbe84095680c940fe025 (patch)
treec994eb8bc8fd6a1c4128241fbd8255c22c6e9bd6 /fs/ext2
parentext2: Drop GFP_NOFS allocation from ext2_init_block_alloc_info() (diff)
downloadlinux-36975616ea5837955ce9bbe84095680c940fe025.tar.gz
linux-36975616ea5837955ce9bbe84095680c940fe025.tar.bz2
linux-36975616ea5837955ce9bbe84095680c940fe025.zip
ext2: Drop GFP_NOFS use in ext2_get_blocks()
ext2_get_blocks() calls sb_issue_zeroout() with GFP_NOFS flag. However the call is performed under inode->i_rwsem and EXT2_I(inode)->i_truncate_mutex neither of which is acquired during direct fs reclaim. So it is safe to change the gfp mask to GFP_KERNEL. Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/ext2')
-rw-r--r--fs/ext2/inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext2/inode.c b/fs/ext2/inode.c
index 5a4272b2c6b0..f3d570a9302b 100644
--- a/fs/ext2/inode.c
+++ b/fs/ext2/inode.c
@@ -754,7 +754,7 @@ static int ext2_get_blocks(struct inode *inode,
*/
err = sb_issue_zeroout(inode->i_sb,
le32_to_cpu(chain[depth-1].key), count,
- GFP_NOFS);
+ GFP_KERNEL);
if (err) {
mutex_unlock(&ei->truncate_mutex);
goto cleanup;