]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: add a shrinker to background inode reclaim
authorDave Chinner <dchinner@redhat.com>
Wed, 28 Apr 2010 23:55:50 +0000 (09:55 +1000)
committerAlex Elder <aelder@sgi.com>
Thu, 29 Apr 2010 21:22:13 +0000 (16:22 -0500)
commit637e399aef29cee96efccbcaaf86c0d34c5b1690
tree9e6350fd9da5aef0b53ddeddd82f618ae16bf931
parent2f1fc216de2fe0fe6f8e1990c51363d858c19f42
xfs: add a shrinker to background inode reclaim

On low memory boxes or those with highmem, kernel can OOM before the
background reclaims inodes via xfssyncd. Add a shrinker to run inode
reclaim so that it inode reclaim is expedited when memory is low.

This is more complex than it needs to be because the VM folk don't
want a context added to the shrinker infrastructure. Hence we need
to add a global list of XFS mount structures so the shrinker can
traverse them.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/linux-2.6/xfs_super.c
fs/xfs/linux-2.6/xfs_sync.c
fs/xfs/linux-2.6/xfs_sync.h
fs/xfs/quota/xfs_qm_syscalls.c
fs/xfs/xfs_ag.h
fs/xfs/xfs_mount.h