quota: Drop GFP_NOFS instances under dquot->dq_lock and dqio_sem
authorJan Kara <jack@suse.cz>
Mon, 22 Jan 2024 12:22:42 +0000 (13:22 +0100)
committerJan Kara <jack@suse.cz>
Tue, 23 Jan 2024 18:21:11 +0000 (19:21 +0100)
commita1e1b2becab7c0b23f18b7999a3b48f76210d3a6
treea51afe3d166c7fa0e47fb3043837ce8034bcc398
parent6c5026c1ef5b57a8d1ddeb6f2bf0c1624d6a849f
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>
fs/quota/quota_tree.c
fs/quota/quota_v2.c