[PATCH] xfs: unregister inode shrinker before freeing filesystem structures V2

Christoph Hellwig hch at infradead.org
Mon Jul 12 10:05:31 CDT 2010


On Mon, Jul 12, 2010 at 04:40:58PM +1000, Dave Chinner wrote:
> From: Dave Chinner <dchinner at redhat.com>
> 
> Currently we don't remove the XFS mount from the shrinker list until late in
> the unmount path. By this time, we have already torn down the internals of the
> filesystem (e.g. the per-ag structures), and hence if the shrinker is executed
> between the teardown and the unregistering, the shrinker will get NULL per-ag
> structure pointers and panic trying to dereference them.
> 
> Fix this by removing the xfs mount from the shrinker list before tearing down
> it's internal structures.
> 
> Signed-off-by: Dave Chinner <dchinner at redhat.com>
> ---

Looks good


Reviewed-by: Christoph Hellwig <hch at lst.de>




More information about the xfs mailing list