Received: by 2002:ab2:6309:0:b0:1fb:d597:ff75 with SMTP id s9csp514231lqt; Thu, 6 Jun 2024 09:53:53 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVLqK+esDR2pSzEqwmT+mszSSvaH/J3aQ3MuPjCe0TAAMzw7O8rJQfOQXkRDTn75/nxMw0tgy8D3DEM8Y7sGSGxfIkR+vnFITSerGY3Qw== X-Google-Smtp-Source: AGHT+IFk5zw04yBCSKxD/iI7+Kbg3P9KJJmO9p6j9JnRTt5O2dCx2Iub3tL8HUyUsQk/gRFoFP/m X-Received: by 2002:a25:2e08:0:b0:dfa:72e6:47a0 with SMTP id 3f1490d57ef6-dfacab1a773mr6065417276.10.1717692833198; Thu, 06 Jun 2024 09:53:53 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717692833; cv=pass; d=google.com; s=arc-20160816; b=cWetSz2uGq7Ctb4oafwk90+hvr1/Y9ZxqT3IFzqQk47cpU/UnlXDuX1vrOYGfjVRcu owVq0KFD1Eheez/+fOAGzmLnn6Sr8QPEjvd4zL9Mc9AG6KFZsLi/NaKkvuTw2eLkmzKh Z+v8Kf5MRsaBrHa3/A00leT+i7RilOIijfZY8bMTGbxBD9KWUklJWIFN2+UUCXDlAcqP xe4kwxdevLep4Smy2xylx1tWovxvQA6ULx3DIlZWpkGDcTriR7eZYQne/GRzb7kp+v6Y 6deiGufDxxVeVl8jcEe0zlyqMinGWzD97o0iUq6rWB0vze8RYNQIK7P3O7JiEZOg5T0L P3CQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=CXkQIcH8/l+6fWsuP2KqStMF4NvMD2uUROMEiEGLHQw=; fh=HCDR8UO2STZ6/3VQkcm/cFvjz3sv+6seMJZYoUvvXdc=; b=qez5Fi5F+6PlENxS4zMz4CsBW5rm3di/roz3ZYqf1Oog574GkF9pffiNAXaKZn7cmN S+NGn0p5BfMbcpGISM8FjktRlhWGdZ709A/tN5RIfN/rrWPe5U+767eqqGUXjgrTE7p0 kR3UfvhAAs3iPKTZpFLyRJJSqtXFSZx7zGoiShSwx+bYhFx0dV6JwJOYISLAhl/e4Lxa 21LaDGH679hULlUQxzPX/9763izm1ub9GAbfSlGj4TO0Ce+DjbGehUQLzORu0hi+a3El hjq7quZAAm9SShr3hrhw524CovrrXkKrgDjIYCUY8H3TShp3hXvB42DRwTl3//BaTe28 ueEg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=DSQS1HFl; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-204742-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-204742-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id d75a77b69052e-44038b16214si19737711cf.352.2024.06.06.09.53.53 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Jun 2024 09:53:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-204742-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=DSQS1HFl; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-204742-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-204742-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id E670C1C20FC7 for ; Thu, 6 Jun 2024 16:53:52 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BDB2E198E60; Thu, 6 Jun 2024 16:53:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="DSQS1HFl" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E8669224D1 for ; Thu, 6 Jun 2024 16:53:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717692823; cv=none; b=WWs7tdaykU/ObKSfo4XMJZvHarHpHw44hlKdwseTi7VZsyDhSSRQZBzDZHEv+5L8NJEex9+nQDrU0Gs1CtYP7Q1qV7aSbAD6V8xkGOAPl7aETUwJK5+ei4zzJDQEYIdA90jRT8rZK201uEEwwSQxI3y94mwiKZCG7N22893odS8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717692823; c=relaxed/simple; bh=UfPRa8N1NpQXy0hUsyfCoV9/IzKPawQ3WxpkEv4gwoQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=fXUouGT4gJDWE2ZwXkVBNZQ+jYNEU/1DNBZlo3FMsS4zw4IMwsj/lrKiF5fj0h6AJQJvwGnF6+cli/yi0AanUIO6I2izqN4iu+m2K84hXiK/9Qo/HopLcjZ/vIcBHLlZCVafNguIuxos/1dUXV5emEjti9WweVIEMpsrg1yGVUQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=DSQS1HFl; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0919AC2BD10; Thu, 6 Jun 2024 16:53:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1717692822; bh=UfPRa8N1NpQXy0hUsyfCoV9/IzKPawQ3WxpkEv4gwoQ=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=DSQS1HFlpBRZ83O1xKUSI5diJtuOlVYBr2LgczQEvleXWNd6HpjbexSOBzjkR5WbY BSqiVya+7Z5Bxpd4p20MoH6QOAgx/Yz2qeT8KVm2+c702w87lV+lvfZKQtx/IHYQBm 9SXDanaV5WWdi9qzuEQcE+lIZWxbw3xOX44VoXmhi7nWvpqr+DTOSjMf7gkEHSIHGR KTWPQ+OvIoPA48E78fLk923VjkKy2Oi09ajoH1Hs9dRIYbCMCpdyOhVxh7Bbkx9rWV dcJHbFamIVno+gXC6hCG/CPK3BIgvvhxAsmR4o9jYW5ToB/sh5wGsfDcMSSReJG8FP +54Rq6Ik/+LXg== Message-ID: Date: Thu, 6 Jun 2024 18:53:36 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: kswapd0: page allocation failure: order:0, mode:0x820(GFP_ATOMIC), nodemask=(null),cpuset=/,mems_allowed=0 (Kernel v6.5.9, 32bit ppc) Content-Language: en-US To: Erhard Furtner Cc: Yosry Ahmed , Yu Zhao , linux-mm@kvack.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, Johannes Weiner , Nhat Pham , Chengming Zhou , Sergey Senozhatsky , Minchan Kim , Michal Hocko References: <20240508202111.768b7a4d@yea> <20240515224524.1c8befbe@yea> <20240602200332.3e531ff1@yea> <20240604001304.5420284f@yea> <20240604134458.3ae4396a@yea> <20240604231019.18e2f373@yea> <20240606010431.2b33318c@yea> <20240606153210.18ef5299@yea> From: "Vlastimil Babka (SUSE)" In-Reply-To: <20240606153210.18ef5299@yea> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 6/6/24 3:32 PM, Erhard Furtner wrote: > On Thu, 6 Jun 2024 09:24:56 +0200 > "Vlastimil Babka (SUSE)" wrote: > >> Besides the zpool commit which might have just pushed the machine over the >> edge, but it was probably close to it already. I've noticed a more general >> problem that there are GFP_KERNEL allocations failing from kswapd. Those >> could probably use be __GFP_NOMEMALLOC (or scoped variant, is there one?) >> since it's the case of "allocating memory to free memory". Or use mempools >> if the progress (success will lead to freeing memory) is really guaranteed. >> >> Another interesting data point could be to see if traditional reclaim >> behaves any better on this machine than MGLRU. I saw in the config: >> >> CONFIG_LRU_GEN=y >> CONFIG_LRU_GEN_ENABLED=y >> >> So disabling at least the second one would revert to the traditional reclaim >> and we could see if it handles such a constrained system better or not. > > I set RANDOM_KMALLOC_CACHES=n and LRU_GEN_ENABLED=n but still hit the issue. > > dmesg looks a bit different (unpatched v6.10-rc2). What caught my eye, but it's also in some of the previous dmesg with MGRLU, is that in one case there's: DMA free:0kB That means many allocations went through that are allowed to just ignore all reserves, and depleted everything. That would mean __GFP_MEMALLOC or PF_MEMALLOC, which I suggested earlier for the GFP_KERNEL failure, is being used somewhere, but not leading to the expected memory freeing. > Regards, > Erhard