Re: [RFC]xfs: using GFP_NOFS for blkdev_issue_flush

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

On Mon, Apr 16, 2012 at 01:32:01PM +0800, Shaohua Li wrote:

The list linux-xfs@xxxxxxxxxxxxxxx does not exist.  As per
MAINTAINERS, xfs@xxxxxxxxxxx is the place to send XFS patches.

> flush request is issued in transaction commit code path usually, so
> looks using
> GFP_KERNEL to allocate memory for flush request bio falls into the classic
> deadlock issue. Per Dave Chinner, there is only blkdev_issue_flush might
> be buggy here. But using GFP_NOFS by default for all calls should
> not matter.

I know what bug you are trying to fix, but I had to read that 5 times to
translate it into something I understood :/ Perhaps something like:

"Issuing a block device flush request in transaction context using
GFP_KERNEL directly can cause deadlocks due to memory reclaim
recursion. Use GFP_NOFS to avoid recursion from reclaim context."

The code is fine, though ;)


Dave Chinner
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at