]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
quota: Improve locking
authorJan Kara <jack@suse.cz>
Mon, 12 Jan 2009 16:23:05 +0000 (17:23 +0100)
committerJan Kara <jack@suse.cz>
Fri, 16 Jan 2009 17:02:10 +0000 (18:02 +0100)
commitcc33412fb1f11613e20f9dfc2919a77ecd63fbc4
tree657ccb0860127852179efe8c13fc24b5ba624017
parent7cb36b6ccdca03bd87e8faca7fd920643dd1aec7
quota: Improve locking

We implement dqget() and dqput() that need neither dqonoff_mutex nor dqptr_sem.
Then move dqget() and dqput() calls so that they are not called from under
dqptr_sem. This is important because filesystem callbacks aren't called from
under dqptr_sem which used to cause *lots* of problems with lock ranking
(and with OCFS2 they became close to unsolvable).

The patch also removes two functions which were introduced solely because OCFS2
needed them to cope with the old locking scheme. As time showed, they were not
enough for OCFS2 anyway and it would be unnecessary work to adapt them to the
new locking scheme in which they aren't needed.  As a result OCFS2 needs the
following patch to compile properly with quotas.  Sorry to any bisecters which
hit this in advance.

Signed-off-by: Jan Kara <jack@suse.cz>
fs/dquot.c
include/linux/quotaops.h