Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp992945pxb; Tue, 26 Oct 2021 00:23:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx3QPjYWM3mPnzYqERksc0hMaOfz84eyCs2R53PpfkwfLsRR9ltI/M61Mns5JYgg79Oos1Y X-Received: by 2002:a63:4d20:: with SMTP id a32mr17320681pgb.247.1635232998445; Tue, 26 Oct 2021 00:23:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635232998; cv=none; d=google.com; s=arc-20160816; b=Y0iaH8spzfodRvDmG+qdKbjotWxdPJVMrjKqnBIH7DhgVStSXnaVkSJotrpyGTry1F 4eUxathF/vKkiraNqPPg9FAJSsyRjm02/Ypgthb3OZXFzB7XmurXCcO8CuEPinRLrzST TYyyQ9mfV17gL7ihwRDd5n4Gd70RVw7F93FINm+etQQUIcZJ+Fkg6GlvCHEg7Cq5kcfM p8xXeyl1A6GdNClr8fpZikZ31r6LBYgEJ1DjuO7hDHL53qMLPkXKyEb3HHa/XNQ/b2U8 9hmyXbTVcWFF9ASU8aUtYh7jtX95je8JsdQtKaJFA5igj8WghB62A8QnTfT64PXaQQGC 3nmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Mq9APL2CfqMqjGpYMi+6mlPHzzLvKocGw0zALcVBOW0=; b=tyQzSkwzHpf2yGFORywZ6B/n9gzl6+TNPMrEx9sVNRb25vg2NNubFO2BBpIqXBaUN1 MaViLseRsSNO/RzX/Stsjw8vZ7p2Nr2BPoVYU9zuw9dRXSmTHMuKbDYdsnw7c/O1kc4C /XmGbwHrtynpiXbfOkACM4IOIkBBFjyyua40CUSCwCkpx2VDtu85CYr3pHOWmJ8vzqup OXhWU/0XxHFiaMrrYZO69QluIsfWKr++AlIAQum4mVuhEVXwQffdXk4d474upFCgOKGz u4gViaMfevUyNaomO+wXMGboBg15GNwkXw7sj1iPN8TkqQl4q9VcQY/yG5VMUAIQby82 H4cA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=QsMNOfPP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k13si19089389pgb.635.2021.10.26.00.23.05; Tue, 26 Oct 2021 00:23:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=QsMNOfPP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234541AbhJZHF1 (ORCPT + 99 others); Tue, 26 Oct 2021 03:05:27 -0400 Received: from smtp-out1.suse.de ([195.135.220.28]:43394 "EHLO smtp-out1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229525AbhJZHF0 (ORCPT ); Tue, 26 Oct 2021 03:05:26 -0400 Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id 3CAA121957; Tue, 26 Oct 2021 07:03:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1635231782; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Mq9APL2CfqMqjGpYMi+6mlPHzzLvKocGw0zALcVBOW0=; b=QsMNOfPPbHPZ6065oUYV7TFulmvKfp2P+adQeHhtlfwDxkqwJ7UZe5vLBzffqj4jjEYHoN IowE3CSDu+DCuODpoF1WfnuK66SAfBuao8H8OLTK94KcXEIJDxLoupoNMc+8vaevHmeHOt 4sSMvc3b1l8i6shOwqSusLLYuR7nZrw= Received: from suse.cz (unknown [10.100.201.86]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id EAB4BA3B8C; Tue, 26 Oct 2021 07:03:01 +0000 (UTC) Date: Tue, 26 Oct 2021 09:03:01 +0200 From: Michal Hocko To: NeilBrown Cc: linux-mm@kvack.org, Dave Chinner , Andrew Morton , Christoph Hellwig , Uladzislau Rezki , linux-fsdevel@vger.kernel.org, LKML , Ilya Dryomov , Jeff Layton Subject: Re: [PATCH 2/4] mm/vmalloc: add support for __GFP_NOFAIL Message-ID: References: <20211025150223.13621-1-mhocko@kernel.org> <20211025150223.13621-3-mhocko@kernel.org> <163520277623.16092.15759069160856953654@noble.neil.brown.name> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <163520277623.16092.15759069160856953654@noble.neil.brown.name> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 26-10-21 09:59:36, Neil Brown wrote: > On Tue, 26 Oct 2021, Michal Hocko wrote: [...] > > @@ -3032,6 +3036,10 @@ void *__vmalloc_node_range(unsigned long size, unsigned long align, > > warn_alloc(gfp_mask, NULL, > > "vmalloc error: size %lu, vm_struct allocation failed", > > real_size); > > + if (gfp_mask & __GFP_NOFAIL) { > > + schedule_timeout_uninterruptible(1); > > + goto again; > > + } > > Shouldn't the retry happen *before* the warning? I've done it after to catch the "depleted or fragmented" vmalloc space. This is not related to the memory available and therefore it won't be handled by the oom killer. The error message shouldn't imply the vmalloc allocation failure IMHO but I am open to suggestions. -- Michal Hocko SUSE Labs