From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753597AbZELQhk (ORCPT ); Tue, 12 May 2009 12:37:40 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752404AbZELQhb (ORCPT ); Tue, 12 May 2009 12:37:31 -0400 Received: from brick.kernel.dk ([93.163.65.50]:49492 "EHLO kernel.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750832AbZELQha (ORCPT ); Tue, 12 May 2009 12:37:30 -0400 Date: Tue, 12 May 2009 18:37:30 +0200 From: Jens Axboe To: Nick Piggin Cc: Andrew Morton , David Rientjes , mel@csn.ul.ie, a.p.zijlstra@chello.nl, cl@linux-foundation.org, dave@linux.vnet.ibm.com, linux-kernel@vger.kernel.org, Divy Le Ray Subject: Re: [patch -mmotm] mm: invoke oom killer for __GFP_NOFAIL Message-ID: <20090512163730.GQ4140@kernel.dk> References: <20090511134038.5cf1ad3b.akpm@linux-foundation.org> <20090512124201.GO4140@kernel.dk> <20090512130546.GA15793@wotan.suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20090512130546.GA15793@wotan.suse.de> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 12 2009, Nick Piggin wrote: > On Tue, May 12, 2009 at 02:42:02PM +0200, Jens Axboe wrote: > > On Mon, May 11 2009, Andrew Morton wrote: > > > On Sat, 9 May 2009 15:46:39 -0700 (PDT) > > > David Rientjes wrote: > > > > > > > The oom killer must be invoked regardless of the order if the allocation > > > > is __GFP_NOFAIL, otherwise it will loop forever when reclaim fails to > > > > free some memory. > > > > > > Sigh. We're supposed to be deleting __GFP_NOFAIL. I added it as a way > > > of easily finding lame error-handling-challenged callers which need to > > > be fixed up. So of course we went and added lots more callers. > > > > > > y:/usr/src/linux-2.6.30-rc5> grep -rl GFP_NOFAIL . > > > ./fs/bio-integrity.c > > This is no good either, it seems to be in the bio submission path. > > It needs a mempool or something. mempool cannot help here, since the allocation is tied to the process (and IO) life time. > It has a dead code "fallback" that returns an error, but I suspect that's > not really acceptable. It's not that difficult to handle an error there, it just means that we lose any process association with that request. It's mostly making sure that all the bits and pieces deal with that correctly, but it should not be very hard. -- Jens Axboe