On Fri, Feb 17, 2012 at 03:00:09PM -0800, kdasu wrote:
>
>
> On the 2.6.37 kernel, xfs_fs_evict_inode() leads to a deadlock when
> freeing multiple realtime extents. On further debugging the root
> cause it was determined to be recursive locking of the RT bitmap
> inode during evict operation within the same task context.
> The same vfs evict sequence is replayed by the xfs log recovery on
> mounts on a reboot after the problem happens first time.
> This problem exists on kernel v2.6.39 as well.
I think you're better off fixing this problem like I did for the
allocation side, that is:
- remove the xfs_ilock and xfs_trans_ijoin (or probably still
xfs_trans_iget in your version) from xfs_rtfree_extent, and
instead add asserts that the inode is locked and has an inode_item
attach to it.
- in xfs_bunmapi if we are dealing with an inode with the rt flag
bump the reference count on the inode there and attach it to the
transaction before calling into xfs_bmap_del_extent, similar to
what we do in xfs_bmap_rtalloc.
|