Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp564350pxu; Fri, 4 Dec 2020 09:48:31 -0800 (PST) X-Google-Smtp-Source: ABdhPJyQ3I8QUyVLwwVK3RVCj7ED0V4PUAmr3UtJScdWc1wmgaqY7xEflpfhr1jWU9TDEOotoVIr X-Received: by 2002:a17:906:52d9:: with SMTP id w25mr7886788ejn.504.1607104111480; Fri, 04 Dec 2020 09:48:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607104111; cv=none; d=google.com; s=arc-20160816; b=ojwIr6L8M6xIE8vejwksR64O2gmYXzGDuVwUXcX8BmRR9vdoXqCzI7/HN2FUX1e/2y aP6+vjUXhuZMalHD8RagNn8clQAmM/uToFR1A96Q1hIeLHaLHm0/vRQc6fiXy3xuZjKy 6IEOehJfpplXDbEI72UBtlbwctLnPNbvZ8lw5S8dvU0hEJGyegaOOxxv0zmVpjirs5GA vlNh1MTOWCXMFWJWtwPC9fsBK5V8ZUZqhRAtbUBPeFcfsVS7puzg7rtWImbQ4Y4I/VV8 zNqvwZ92XCChgjVo+w56xJhsw80ooacT34qwybWBuHQMwWsl5dd6NVm/0xsAytkHAzF2 Ixww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:dkim-signature:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=IgGdlLuQS16IZLAWFCNIGBVZxQ+IIVFfpXGYwQb1klc=; b=ngyo++l0Mxq+Gux47oMFFswPehlhvFHeSa/2108Do3atbtFhZbW+VvQsS+C+yPh4uh jBbyRJuDTzVNYMuThMQB867RrraYL+ZgvRoVk9qN7RYW3M9yKEihFtoJnho/bb5ti2Ov oHLsmpaJFh0tE95+zs2bmc38TfCt01menMHUzrr5wNtYm4kSDkIgstgWS/TYMaTDqsSo xEqvddYk8BqE2OZ+9LZo77z+v6TSsunduVyDD45Z+erqprwtTvn0mu4DZg78jimoa1bt 3eaXcAixwJW0WE3AlTZjekz6yyXi10rthaJqW4/mvZumNUQj68VeGjPGJQek6sHHy+JW Yi7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=FVg+MJmj; 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=NONE sp=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hq4si1857508ejc.14.2020.12.04.09.48.07; Fri, 04 Dec 2020 09:48:31 -0800 (PST) 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=@nvidia.com header.s=n1 header.b=FVg+MJmj; 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=NONE sp=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731295AbgLDRoL (ORCPT + 99 others); Fri, 4 Dec 2020 12:44:11 -0500 Received: from hqnvemgate24.nvidia.com ([216.228.121.143]:3153 "EHLO hqnvemgate24.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730782AbgLDRoL (ORCPT ); Fri, 4 Dec 2020 12:44:11 -0500 Received: from hqmail.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate24.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Fri, 04 Dec 2020 09:43:31 -0800 Received: from [10.26.72.142] (172.20.13.39) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Fri, 4 Dec 2020 17:43:23 +0000 Subject: Re: [PATCH] mm/memblock:use a more appropriate order calculation when free memblock pages To: Marek Szyprowski , Qian Cai , , CC: , , , Hailong Liu , Stephen Rothwell , Linux Next Mailing List , Bartlomiej Zolnierkiewicz , linux-tegra References: <20201203152311.5272-1-carver4lio@163.com> From: Jon Hunter Message-ID: <3d709122-0364-5bca-9247-3f212096b389@nvidia.com> Date: Fri, 4 Dec 2020 17:43:21 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [172.20.13.39] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To HQMAIL107.nvidia.com (172.20.187.13) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1607103811; bh=IgGdlLuQS16IZLAWFCNIGBVZxQ+IIVFfpXGYwQb1klc=; h=Subject:To:CC:References:From:Message-ID:Date:User-Agent: MIME-Version:In-Reply-To:Content-Type:Content-Language: Content-Transfer-Encoding:X-Originating-IP:X-ClientProxiedBy; b=FVg+MJmjt2AMhdRUox9urOJdfPsfGxCByjMrp+4uu3Dimtf4Y4VONLwIJtOgWp7Ny bK4V2Q8gpRAfwbBi9TcvjLoUSankrGmH4PpXQxlIBJ7ACszcbLpwJxhsRdbdOXqfZE 5C9WKJLEvQVyxvG8uPVfGT6CGVDwXYxCOAv+vguJr5f6Wi73F09U4RX+/0zXPtoi4x TVFHPY/TlJrJGPGLvq+hjKh2Uc8omWEWOCKmXjKOjsva1zwvtWT5FpJ8WB+E/o2Ucn cy++evZ3n6CYkMEkKcRAWztAv8u0fj5CWG9OHobpgsQq9ZS5wi30K0bmvtkWrGLoSM KXwn4ItI/GdaA== Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/12/2020 16:07, Marek Szyprowski wrote: > Hi All, > > On 04.12.2020 14:42, Qian Cai wrote: >> On Thu, 2020-12-03 at 23:23 +0800, carver4lio@163.com wrote: >>> From: Hailong Liu >>> >>> When system in the booting stage, pages span from [start, end] of a memblock >>> are freed to buddy in a order as large as possible (less than MAX_ORDER) at >>> first, then decrease gradually to a proper order(less than end) in a loop. >>> >>> However, *min(MAX_ORDER - 1UL, __ffs(start))* can not get the largest order >>> in some cases. >>> Instead, *__ffs(end - start)* may be more appropriate and meaningful. >>> >>> Signed-off-by: Hailong Liu >> Reverting this commit on the top of today's linux-next fixed boot crashes on >> multiple NUMA systems. > > I confirm. Reverting commit 4df001639c84 ("mm/memblock: use a more > appropriate order calculation when free memblock pages") on top of linux > next-20201204 fixed booting of my ARM32bit test systems. FWIW, I also confirm that this is causing several 32-bit Tegra platforms to crash on boot and reverting this fixes the problem. Jon -- nvpublic