xfs: flatten the dquot lock ordering
authorChristoph Hellwig <hch@infradead.org>
Tue, 6 Dec 2011 21:58:18 +0000 (21:58 +0000)
committerBen Myers <bpm@sgi.com>
Wed, 14 Dec 2011 22:32:21 +0000 (16:32 -0600)
commit92678554abfc2a2f2727ad168da87d8d434ac904
tree082b395f587dca7903c083e8e10529be1890dc4e
parentbe7ffc38a80a78e6b68d0f51fae8e8d57b55324c
xfs: flatten the dquot lock ordering

Introduce a new XFS_DQ_FREEING flag that tells lookup and mplist walks
to skip a dquot that is beeing freed, and use this avoid the trylock
on the hash and mplist locks in xfs_qm_dqreclaim_one.  Also simplify
xfs_dqpurge by moving the inodes to a dispose list after marking them
XFS_DQ_FREEING and avoid the locker ordering constraints.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Ben Myers <bpm@sgi.com>
fs/xfs/xfs_dquot.c
fs/xfs/xfs_dquot.h
fs/xfs/xfs_qm.c
fs/xfs/xfs_quota.h