Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp3598169pxv; Mon, 28 Jun 2021 08:15:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy0sWBc4RUxRy7uGiw5EaGek51jHCk2EY1XPhRgXNUqX6lkr/DRzTGqVCvzqKAj2tluD38/ X-Received: by 2002:a05:6e02:e0a:: with SMTP id a10mr18393499ilk.23.1624893336908; Mon, 28 Jun 2021 08:15:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624893336; cv=none; d=google.com; s=arc-20160816; b=eU8RlwOFQQxCnXQjqZ18kXa/g/CchbuBdcw8gyi9fbw5/juEnneurgf9fSU55xoZJy Amq3bGw0HsSDhSkiCUIy2forGrP2OmqlGcUA1QtOZpvrpJ1dVPHhGVupYCdRCQoguAmd kOLMl3k2x0eay3xAjYJU5suubly4k/i1MXSXatZLGVZJx5ZjSZj3ET/DSn6dpddNXXj/ KIsi70oOS1LoOE/ORMJnbDAvC0xTyjQyby09Qu6Y3ADQvg7aP3kO4CXE+QJypQOOhPnO I+mfg6tMZzsk7Sleq4JVF3LEIyEyFp4KRVcMM0Op4zlgH4yxrjt/dm8LZLmbUX1qdoCL FHLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=UzhTvmTcJuUnKpusSrGpgVAUYBcdqhBSXMa89U+Tolc=; b=URrUezdSL0TGFKiOKPYX5RjL9m7vrZFJpP5UyVvcFFt74+zYfy+KaKN6Q/u3kqQiQy MNraGFH2MkW8Q3hPTA2DfbrKEkYNp2KuiHdjDdq/WKiE5S4G4Nrv/o1enho1VD9SdJuA qRQSojP2Fl+FsTyHbQJfRj9TEhoPXahPaJrw8uYD5BzR53bVaVLZFclc3cxZSbS4eEL0 deMN8mI1U083Dw4JpJClCI8g7KH9WQ+PxjioinHGTvg+eH4ahnXpeuDV6BrL9Hfu0/Wk xym5qDvN3RgvwKP69Tw/e3kXbqrFwaPh7Od9inauPFTlGN68x/iNSMONT8jthy576wyn BgKQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g15si17353455iln.71.2021.06.28.08.15.17; Mon, 28 Jun 2021 08:15:36 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237986AbhF1PPK (ORCPT + 99 others); Mon, 28 Jun 2021 11:15:10 -0400 Received: from outbound-smtp44.blacknight.com ([46.22.136.52]:38945 "EHLO outbound-smtp44.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234595AbhF1Oxs (ORCPT ); Mon, 28 Jun 2021 10:53:48 -0400 Received: from mail.blacknight.com (pemlinmail06.blacknight.ie [81.17.255.152]) by outbound-smtp44.blacknight.com (Postfix) with ESMTPS id 68512F8016 for ; Mon, 28 Jun 2021 15:51:18 +0100 (IST) Received: (qmail 15563 invoked from network); 28 Jun 2021 14:51:18 -0000 Received: from unknown (HELO techsingularity.net) (mgorman@techsingularity.net@[84.203.17.255]) by 81.17.254.9 with ESMTPSA (AES256-SHA encrypted, authenticated); 28 Jun 2021 14:51:18 -0000 Date: Mon, 28 Jun 2021 15:51:16 +0100 From: Mel Gorman To: Mike Galbraith Cc: lkml Subject: Re: v5.13 regression - suspend went belly up Message-ID: <20210628145116.GB3840@techsingularity.net> References: <760cf981588a31b9a51fa1f6d485d5dbdc61400a.camel@gmx.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <760cf981588a31b9a51fa1f6d485d5dbdc61400a.camel@gmx.de> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 28, 2021 at 03:33:42PM +0200, Mike Galbraith wrote: > Greetings, > > A regression popping up post rc7 is a bit unusual, but hohum, I suppose > they can bite whenever they damn well feel like it. This one was > bisected rc7..release, the (surprising to me) result then confirmed in > four disgruntled local trees. > Hi Mike, this may be NFS-related fallout given that it appears in the stack. Can you try this please? --8<--- mm/page_alloc: Correct return value of populated elements if bulk array is populated Dave Jones reported the following This made it into 5.13 final, and completely breaks NFSD for me (Serving tcp v3 mounts). Existing mounts on clients hang, as do new mounts from new clients. Rebooting the server back to rc7 everything recovers. The commit b3b64ebd3822 ("mm/page_alloc: do bulk array bounds check after checking populated elements") returns the wrong value if the array is already populated which is interpreted as an allocation failure. Fixes: b3b64ebd3822 ("mm/page_alloc: do bulk array bounds check after checking populated elements") Reported-by: Dave Jones Signed-off-by: Mel Gorman Cc: [5.13+] --- mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index ef2265f86b91..04220581579c 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -5058,7 +5058,7 @@ unsigned long __alloc_pages_bulk(gfp_t gfp, int preferred_nid, /* Already populated array? */ if (unlikely(page_array && nr_pages - nr_populated == 0)) - return 0; + return nr_populated; /* Use the single page allocator for one page. */ if (nr_pages - nr_populated == 1)