On Fri, Mar 23, 2012 at 12:47:43PM +1100, Dave Chinner wrote:
> From: Dave Chinner <dchinner@xxxxxxxxxx>
> When a shutdown is triggered from failing to find an item in the AIL
> during delete, we can be called from either metadata IO completion
> context or from log IO completion context. In the case of log IO
> completion context, we must indicate that this is a log error so
> that the forced shutdown does not attempt to flush the log.
> To flush the log whilst in log IO completion will cause a deadlock
> as the shutdown won't proceed until log IO completes, and log Io
> cannot complete because it has blocked waiting for itself to
> We delete items in the AIL from log IO completion when we are
> unpinning in-memory only items, or items that do not require
> writeback to remove from the AIL (e.g. EFI/EFD items). Hence there
> are several locations that need this treatment.
Looks good. I wonder if it might be simple to simply pass a flags
argument to xfs_ail_delete(_bulk) which tells which kind of shutdown