Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp10746769rwl; Thu, 12 Jan 2023 01:54:55 -0800 (PST) X-Google-Smtp-Source: AMrXdXtEtZgCquWVTmN3uwNX/0+UyjjfxhhxtsOyX3XSN8JQ5efZNDz0+110YoJzXUVvWIVenXpH X-Received: by 2002:a17:90b:70a:b0:227:62:8169 with SMTP id s10-20020a17090b070a00b0022700628169mr16644477pjz.35.1673517295590; Thu, 12 Jan 2023 01:54:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673517295; cv=none; d=google.com; s=arc-20160816; b=wZzn5tTHg0JyUsbZPH8KQ/zhmKYuC2PBJvQLIjOjlgJQwHb8tWj2mPuqGsv4fBx/9Q +aril7caiieRhl3CZwRNoQUunkxKFasVLIn++FkOlRATasB2KIOQkan6waICmCgxdG6s 4tXIZX7lAX1os7Y7dCqJl7sSWeSid2gOTd4tVWwU3EuwFiyh5XKK7q2CnIs8yHS6Uvyq Gvd8LeUl9NDRK5e0YW1i3jvW9jn9niNGH3YTPf6p2UI8pXw7WQbtyj0jBHJYZCIv+Hik hKOjyo85/iTONIs736+LYQNPugaVQDgvWrbn/pmAZ23UIGb/ML3unvvqpbauHM54M4+A 22bA== 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; bh=o8ucxtl5LnJ0qaUAAbYln6hKCZJ50zMENIMsdpTR0Sg=; b=icxLoPH4c74OedPkU7Jr99lZroN5C1afW3F1sh9XbmySgoF875ib3JE7pcDscenh/9 nfQlVYNNyhesTD7LFJFcFVhctOSBa9bOMxg+Sh0UEWFV5uBl7bqrYixLLAkfMNS6MYbA BfCEsu87NsCrogidUZiNBiDWTpxIBluH25u8vXKiNrryeIPWNOxuXWDo7aLQPlfDHN6J YVLAxfHklMcsDMMeLS7Gx42IOUYQTZnHLzmpOZi7bljoF99u6WoAZdklib87Yer9uwjz Cm46MG+ZKdSW+v7nuFB96dKIlIdYfk7rUi+8h8yYEg/9KOl1xtPW36vbFa+1XML8j5un 8uig== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id mm24-20020a17090b359800b0022659d6e821si20254317pjb.96.2023.01.12.01.54.49; Thu, 12 Jan 2023 01:54:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239591AbjALJsF (ORCPT + 52 others); Thu, 12 Jan 2023 04:48:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60484 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239781AbjALJrS (ORCPT ); Thu, 12 Jan 2023 04:47:18 -0500 Received: from outbound-smtp21.blacknight.com (outbound-smtp21.blacknight.com [81.17.249.41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8722913F21 for ; Thu, 12 Jan 2023 01:43:45 -0800 (PST) Received: from mail.blacknight.com (pemlinmail06.blacknight.ie [81.17.255.152]) by outbound-smtp21.blacknight.com (Postfix) with ESMTPS id 2874ECCCFB for ; Thu, 12 Jan 2023 09:43:44 +0000 (GMT) Received: (qmail 4654 invoked from network); 12 Jan 2023 09:43:43 -0000 Received: from unknown (HELO techsingularity.net) (mgorman@techsingularity.net@[84.203.198.246]) by 81.17.254.9 with ESMTPSA (AES256-SHA encrypted, authenticated); 12 Jan 2023 09:43:43 -0000 Date: Thu, 12 Jan 2023 09:43:41 +0000 From: Mel Gorman To: Michal Hocko Cc: Linux-MM , Andrew Morton , NeilBrown , Thierry Reding , Matthew Wilcox , Vlastimil Babka , LKML Subject: Re: [PATCH 5/7] mm/page_alloc.c: Allow __GFP_NOFAIL requests deeper access to reserves Message-ID: <20230112094341.hom3ccscbko6v626@techsingularity.net> References: <20230109151631.24923-1-mgorman@techsingularity.net> <20230109151631.24923-6-mgorman@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 11, 2023 at 04:46:13PM +0100, Michal Hocko wrote: > On Mon 09-01-23 15:16:29, Mel Gorman wrote: > > Currently __GFP_NOFAIL allocations without any other flags can access 25% > > of the reserves but these requests imply that the system cannot make forward > > progress until the allocation succeeds. Allow __GFP_NOFAIL access to 75% > > of the min reserve. > > I am not sure this is really needed. IIRC the original motivation for > allowing NOFAIL request to access access to memory reserves was > GFP_NOFS|__GFP_NOFAIL requests which do not invoke the OOM killer. > The amount of memory reserves granted was not really important. The > point was to allow to move forward. Giving more of the reserves is a > double edge sword. It can help in some cases but it can also prevent > other high priority users from fwd progress. > > I would much rahter see such a change with an example where it really > made a difference. > Fair point but based on your review for "mm/page_alloc: Give GFP_ATOMIC and non-blocking allocations access to reserves" and only allowing non-blocking allocations to access reserves if __GFP_HIGH is also specified, this patch becomes a no-op and can be dropped. If GFP_NOFAIL requests really require deeper access to reserves, it'll have to be explicitly handled in __zone_watermark_ok and __GFP_NOFAIL would be added to the ALLOC_RESERVES collection of flags. -- Mel Gorman SUSE Labs