[PATCH] xfs: I/O completion handlers must use NOFS allocations
Christoph Hellwig
hch at infradead.org
Tue Nov 3 08:45:46 CST 2009
On Mon, Nov 02, 2009 at 02:34:01PM -0600, Alex Elder wrote:
> This looks good. It's kind of too bad the GFP_ flag
> argument had to be added, but I can't think of a cleaner
> way than the way you did it.
The slightly better way would be to set the PF_FSTRANS flag for the
workqueue threads, but the workqueue interfaces that allows setting
these flags were removed a while ago.
> I have one minor suggestion on wording used in a comment,
> but the code looks correct to me. I verified that--as you
> say--the only place we're doing an allocation in an I/O
> completion handler (i.e., a function called via
> io_end->io_work->func) is in xfs_iomap_write_unwritten(),
> so this fix should cover the only case.
> > + * Note that we opencoding the transaction allocation here
> > + * to pass KM_NOFS - we can't risk to recurse back into
>
>
> How about, "we can't risk recursing back into"
Fine with me. Do you want me to resend or are you going to fix it up on
fly before applying the patch?
More information about the xfs
mailing list