]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: use a normal shrinker for the dquot freelist
authorChristoph Hellwig <hch@infradead.org>
Wed, 1 Feb 2012 13:57:20 +0000 (13:57 +0000)
committerBen Myers <bpm@sgi.com>
Fri, 10 Feb 2012 18:38:09 +0000 (12:38 -0600)
commit8014f1691da4aeec2986408bb7f166b213af8971
tree312cdaf3479d943234d2a887a4395aa9626f6442
parent036d9a915c956cec6ce287e4d6a29cc4f8d757e3
xfs: use a normal shrinker for the dquot freelist

Stop reusing dquots from the freelist when allocating new ones directly, and
implement a shrinker that actually follows the specifications for the
interface.  The shrinker implementation is still highly suboptimal at this
point, but we can gradually work on it.

This also fixes an bug in the previous lock ordering, where we would take
the hash and dqlist locks inside of the freelist lock against the normal
lock ordering.  This is only solvable by introducing the dispose list,
and thus not when using direct reclaim of unused dquots for new allocations.

As a side-effect the quota upper bound and used to free ratio values in
/proc/fs/xfs/xqm are set to 0 as these values don't make any sense in the
new world order.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Ben Myers <bpm@sgi.com>
(cherry picked from commit a081298745e976e61afb3d71e68ee4e674625264)
fs/xfs/kmem.h
fs/xfs/xfs_dquot.c
fs/xfs/xfs_qm.c
fs/xfs/xfs_qm.h
fs/xfs/xfs_qm_stats.c
fs/xfs/xfs_trace.h