xfs
[Top] [All Lists]

Re: [PATCH 7/7] xfs: Don't use PF_MEMALLOC

To: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx>
Subject: Re: [PATCH 7/7] xfs: Don't use PF_MEMALLOC
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Wed, 18 Nov 2009 09:11:08 +1100
Cc: LKML <linux-kernel@xxxxxxxxxxxxxxx>, linux-mm <linux-mm@xxxxxxxxx>, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>, Christoph Hellwig <hch@xxxxxxxxxxxxx>, linux-fsdevel@xxxxxxxxxxxxxxx, xfs-masters@xxxxxxxxxxx, xfs@xxxxxxxxxxx
In-reply-to: <20091117162235.3DEB.A69D9226@xxxxxxxxxxxxxx>
References: <20091117161551.3DD4.A69D9226@xxxxxxxxxxxxxx> <20091117162235.3DEB.A69D9226@xxxxxxxxxxxxxx>
User-agent: Mutt/1.5.18 (2008-05-17)
On Tue, Nov 17, 2009 at 04:23:43PM +0900, KOSAKI Motohiro wrote:
> 
> Non MM subsystem must not use PF_MEMALLOC. Memory reclaim need few
> memory, anyone must not prevent it. Otherwise the system cause
> mysterious hang-up and/or OOM Killer invokation.

The xfsbufd is a woken run by a registered memory shaker. i.e. it
runs when the system needs to reclaim memory. It forceѕ the
delayed write metadata buffers (of which there can be a lot) to disk
so that they can be reclaimed on IO completion. This IO submission
may require ѕome memory to be allocated to be able to free that
memory.

Hence, AFAICT the use of PF_MEMALLOC is valid here.

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>