xfs: use KM_NOFS for allocations during attribute list operations
authorDave Chinner <dchinner@redhat.com>
Thu, 23 Dec 2010 00:57:37 +0000 (11:57 +1100)
committerDave Chinner <david@fromorbit.com>
Thu, 23 Dec 2010 00:57:37 +0000 (11:57 +1100)
When listing attributes, we are doiing memory allocations under the
inode ilock using only KM_SLEEP. This allows memory allocation to
recurse back into the filesystem and do writeback, which may the
ilock we already hold on the current inode. THis will deadlock.
Hence use KM_NOFS for such allocations outside of transaction
context to ensure that reclaim recursion does not occur.

Reported-by: Nick Piggin <npiggin@gmail.com>
Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>

No differences found