diff options
author | Jan Kara <jack@suse.cz> | 2024-01-22 15:22:42 +0300 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2024-01-23 21:21:11 +0300 |
commit | a1e1b2becab7c0b23f18b7999a3b48f76210d3a6 (patch) | |
tree | a51afe3d166c7fa0e47fb3043837ce8034bcc398 /fs/quota/quota_v2.c | |
parent | 6c5026c1ef5b57a8d1ddeb6f2bf0c1624d6a849f (diff) | |
download | linux-a1e1b2becab7c0b23f18b7999a3b48f76210d3a6.tar.xz |
quota: Drop GFP_NOFS instances under dquot->dq_lock and dqio_sem
Quota code acquires dquot->dq_lock whenever reading / writing dquot.
When reading / writing quota info we hold dqio_sem. Since these locks
can be acquired during inode reclaim (through dquot_drop() -> dqput() ->
dquot_release()) we are setting nofs allocation context whenever
acquiring these locks. Hence there's no need to use GFP_NOFS allocations
in quota code doing IO. Just switch it to GFP_KERNEL.
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/quota/quota_v2.c')
-rw-r--r-- | fs/quota/quota_v2.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/quota/quota_v2.c b/fs/quota/quota_v2.c index 48e0d610ceef..5eb0de8e7e40 100644 --- a/fs/quota/quota_v2.c +++ b/fs/quota/quota_v2.c @@ -121,7 +121,7 @@ static int v2_read_file_info(struct super_block *sb, int type) ret = -EIO; goto out; } - info->dqi_priv = kmalloc(sizeof(struct qtree_mem_dqinfo), GFP_NOFS); + info->dqi_priv = kmalloc(sizeof(struct qtree_mem_dqinfo), GFP_KERNEL); if (!info->dqi_priv) { ret = -ENOMEM; goto out; |