From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751401AbeDEOaz (ORCPT ); Thu, 5 Apr 2018 10:30:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:36542 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751318AbeDEOax (ORCPT ); Thu, 5 Apr 2018 10:30:53 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 29CCA21720 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=goodmis.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=rostedt@goodmis.org Date: Thu, 5 Apr 2018 10:30:50 -0400 From: Steven Rostedt To: Matthew Wilcox Cc: Joel Fernandes , Michal Hocko , Zhaoyang Huang , Ingo Molnar , LKML , kernel-patch-test@lists.linaro.org, Andrew Morton , "open list:MEMORY MANAGEMENT" , Vlastimil Babka Subject: Re: [PATCH v1] kernel/trace:check the val against the available mem Message-ID: <20180405103050.22f10319@gandalf.local.home> In-Reply-To: <20180405142258.GA28128@bombadil.infradead.org> References: <20180403123514.GX5501@dhcp22.suse.cz> <20180403093245.43e7e77c@gandalf.local.home> <20180403135607.GC5501@dhcp22.suse.cz> <20180404062340.GD6312@dhcp22.suse.cz> <20180404101149.08f6f881@gandalf.local.home> <20180404142329.GI6312@dhcp22.suse.cz> <20180404114730.65118279@gandalf.local.home> <20180405025841.GA9301@bombadil.infradead.org> <20180405142258.GA28128@bombadil.infradead.org> X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 5 Apr 2018 07:22:58 -0700 Matthew Wilcox wrote: > I understand you don't want GFP_NORETRY. But why is it more important for > this allocation to succeed than other normal GFP_KERNEL allocations? Not sure what you mean by "more important"? Does saying "RETRY_MAYFAIL" make it more important? The difference is, if GFP_KERNEL fails, we don't want to trigger an OOM, and simply clean up and report -ENOMEM to the user. It has nothing to do with being more important than other allocations. If there's 100 Megs of memory available, and the user requests a gig of memory, it's going to fail. Ideally, it doesn't trigger OOM, but instead simply reports -ENOMEM to the user. -- Steve