From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6217EC4332F for ; Fri, 16 Dec 2022 10:24:20 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D5E0F8E0003; Fri, 16 Dec 2022 05:24:19 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id D0DB78E0002; Fri, 16 Dec 2022 05:24:19 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id BFC908E0003; Fri, 16 Dec 2022 05:24:19 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id AFAEB8E0002 for ; Fri, 16 Dec 2022 05:24:19 -0500 (EST) Received: from smtpin15.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 7D89380FC6 for ; Fri, 16 Dec 2022 10:24:19 +0000 (UTC) X-FDA: 80247784638.15.B143776 Received: from outbound-smtp20.blacknight.com (outbound-smtp20.blacknight.com [46.22.139.247]) by imf10.hostedemail.com (Postfix) with ESMTP id B56E5C0002 for ; Fri, 16 Dec 2022 10:24:17 +0000 (UTC) Authentication-Results: imf10.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf10.hostedemail.com: domain of mgorman@techsingularity.net designates 46.22.139.247 as permitted sender) smtp.mailfrom=mgorman@techsingularity.net ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1671186258; a=rsa-sha256; cv=none; b=uxU01Lt6mnEgSF1JyMFY4c2u9f9k6wXXAAzmCSS56CNU0oxgxnitgafeDMQ8lm7R+DO9YV 1/cwKzThFUdjuVi1CRg2NwWsJqIjwWPtiQbwBl5vacDi6S1oa+fRvtXbGDEjT/IRg8zPZ9 FIQ5v9wupQP9wS7lAczyw3AVxbfrx8c= ARC-Authentication-Results: i=1; imf10.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf10.hostedemail.com: domain of mgorman@techsingularity.net designates 46.22.139.247 as permitted sender) smtp.mailfrom=mgorman@techsingularity.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1671186258; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=IQC6LbVniJ3AT6mf9woZsSANCuZHe6OjXHQHBy7XtR8=; b=W2i+RbAsTd3fRaBsL77yfIHhpRZARgZQG5Y/0tYCwJwqKiyisBEwxB9DFNQKa/zcplKSqM wBFPK4SQQsVbb8W/q16yjCWRGO2Ziie0EOHzMkiQs2cxMe8thNr3xBUXxmEpf/gUOSD5ta hZO0zaIPj6LNLpXhcbbuUe7JASYFCBM= Received: from mail.blacknight.com (pemlinmail04.blacknight.ie [81.17.254.17]) by outbound-smtp20.blacknight.com (Postfix) with ESMTPS id 085381C3AFA for ; Fri, 16 Dec 2022 10:24:16 +0000 (GMT) Received: (qmail 5411 invoked from network); 16 Dec 2022 10:24:15 -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); 16 Dec 2022 10:24:15 -0000 Date: Fri, 16 Dec 2022 10:24:10 +0000 From: Mel Gorman To: "Akira Naribayashi (Fujitsu)" Cc: "akpm@linux-foundation.org" , "vbabka@suse.cz" , "rientjes@google.com" , "linux-mm@kvack.org" , "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" Subject: Re: [PATCH] mm, compaction: fix fast_isolate_around() to stay within boundaries Message-ID: <20221216102410.hem6wxqyqf43vnnp@techsingularity.net> References: <20221027132557.5f724149bd5753036f41512a@linux-foundation.org> <20221031073559.36021-1-a.naribayashi@fujitsu.com> <20221107154350.34brdl3ms2ve5wud@techsingularity.net> <20221123102550.kbsd3xclsr6o27up@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: X-Rspam-User: X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: B56E5C0002 X-Stat-Signature: mrq4a6h1fo4g4sbczmunty7mxbrgy8fu X-HE-Tag: 1671186257-745738 X-HE-Meta: U2FsdGVkX1/Y65z4kqqB3pOeDbedJywGDdLjRJmq37ehVJCrdLJYu0TUhHpVP1qipBXtBg+NZEV2aicqCDxlw1JeLS4ysUNX+64HyUbwg27r7KWHdGIqKfVE2JTHx+jfTAQaSi4BUDoKgZ6SCwZ1znwTwXU5MvBVew/Bd0YUm4fIyAuoqxLs7gQD784jRHm/vSfKiFlDtkONlFtYz69BSmyWwZG8i1LTqNZh8oSNgoZhVuSNCGfwdPUCoEtTHbXb33dvj3EeUdeWh/bRa5cPpzio9Ku9jNiIyPSXVhYDEcWauASLt3ehpPL8E72+BTP0aVRC3Uw+bJa/1EhvLZMJ5SeGvNap1xxD8XjCg8FMuygksbxyWn5usHiEoXN78WoWTscvIZVVVKMgVn6kzL1dffTCWdjB8BBwFBfPHnz6plZPad99Laq1zkVz2pXKVQvzrPaZlN/QS68PfnCinwKqTaP8hrrKqsEa+Etav1ZiORVnftm+sy2d/ivR9bfDKn3ZSFlTgFr5eUvURLm0NGjps2d26SfEpSUrDZMC6wuacTnWyOvgtBgr3GjWyR45JS+mml9Z6ecwOPJ+RhP4WlK6E+fYEEHhY/tX9yYDhq0lYxuK+8LEyzCU2E4NLygtcHppyFFv8Byk/4mqbCHt/xfok8y0Zg3myOblvQ3M87vAvhjdvmBOxJUiDdhKHtmXwzodIZakTl8CaKXiaUL7XtQEQrbGEhHf5RENLORGWkQrQgOU7lvoGhdL/dFtax4C4HikLXnk1HXsWcXuDRFWZomVoOsYM4iSsNT3B/IuAPniTccJHRrVdJRLV3WpbqeVtFyP6B3EuVTvxFpHONLJxP+KnjtP3jzChOazAdgz9x4MLnVNG7FuHAB7MX5rNaSEHcUdrrhn/jJ589OnaSEuzoQnJzPLK4Pk1ktMzT5Zv+41ODdZ1wf3hNUr1FJCErSRZRCYDKGvMbY3RbrojkhPfYu OHOedR1m tXMyM X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, Dec 09, 2022 at 09:19:37AM +0000, Akira Naribayashi (Fujitsu) wrote: > On Wed, 23 Nov 2022 10:26:05 +0000, Mei Gorman wrote: > > On Wed, Nov 09, 2022 at 05:41:12AM +0000, Akira Naribayashi (Fujitsu) wrote: > > > On Mon, 7 Nov 2022 15:43:56 +0000, Mei Gorman wrote: > > > > On Mon, Nov 07, 2022 at 12:32:34PM +0000, Akira Naribayashi (Fujitsu) wrote: > > > > > > Under what circumstances will this panic occur? I assume those > > > > > > circumstnces are pretty rare, give that 6e2b7044c1992 was nearly two > > > > > > years ago. > > > > > > > > > > > > Did you consider the desirability of backporting this fix into earlier > > > > > > kernels? > > > > > > > > > > > > > > > Panic can occur on systems with multiple zones in a single pageblock. > > > > > > > > > > > > > Please provide an example of the panic and the zoneinfo. > > > > > > This issue is occurring in our customer's environment and cannot > > > be shared publicly as it contains customer information. > > > Also, the panic is occurring with the kernel in RHEL and may not > > > panic with Upstream's community kernel. > > > In other words, it is possible to panic on older kernels. > > > I think this fix should be backported to stable kernel series. > > > > > > > > The reason it is rare is that it only happens in special configurations. > > > > > > > > How is this special configuration created? > > > > > > This is the case when the node boundary is not aligned to pageblock boundary. > > > > In that case, does this work to avoid rescanning an area that was already > > isolated? > > In the case of your patch, I think I need to clamp the isolated_end as well. > Because sometimes isolated_end < start_pfn(value before entering Scan after) < end_pfn. > > After re-reading the source, I think the problem is that min_pfn and low_pfn > can be out of range in fast_isolate_freepages. > How about the following patch? > Ok, makes sense and it is a condition that could happen because of pageblock alignment. -- Mel Gorman SUSE Labs