]> git.baikalelectronics.ru Git - kernel.git/commit
quota: Fix possible dq_flags corruption
authorAndrew Perepechko <andrew.perepechko@sun.com>
Mon, 12 Apr 2010 18:16:50 +0000 (22:16 +0400)
committerJan Kara <jack@suse.cz>
Mon, 12 Apr 2010 19:12:36 +0000 (21:12 +0200)
commitba8dc6af6cc97b04c687abdea0ca387eddc6ab20
tree752b396f409897a4357ca29bc2f9c3384d29e07d
parent4373e17503c37e4bf723ba57155b44076ca274f6
quota: Fix possible dq_flags corruption

dq_flags are modified non-atomically in do_set_dqblk via __set_bit calls and
atomically for example in mark_dquot_dirty or clear_dquot_dirty.  Hence a
change done by an atomic operation can be overwritten by a change done by a
non-atomic one. Fix the problem by using atomic bitops even in do_set_dqblk.

Signed-off-by: Andrew Perepechko <andrew.perepechko@sun.com>
Signed-off-by: Jan Kara <jack@suse.cz>
fs/quota/dquot.c