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 X-Spam-Level: X-Spam-Status: No, score=-5.6 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D1E31C433E0 for ; Fri, 26 Feb 2021 11:08:13 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 30E3464EF0 for ; Fri, 26 Feb 2021 11:08:13 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 30E3464EF0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id A9BE96B0006; Fri, 26 Feb 2021 06:08:12 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id A4D056B006C; Fri, 26 Feb 2021 06:08:12 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 965626B006E; Fri, 26 Feb 2021 06:08:12 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0070.hostedemail.com [216.40.44.70]) by kanga.kvack.org (Postfix) with ESMTP id 812416B0006 for ; Fri, 26 Feb 2021 06:08:12 -0500 (EST) Received: from smtpin30.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 3C7A6DDE7 for ; Fri, 26 Feb 2021 11:08:12 +0000 (UTC) X-FDA: 77860144824.30.451A59C Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by imf26.hostedemail.com (Postfix) with ESMTP id CB87F407F8FF for ; Fri, 26 Feb 2021 11:08:06 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 56765AF33; Fri, 26 Feb 2021 11:08:10 +0000 (UTC) Subject: Re: [PATCH v7 1/1] mm/page_alloc.c: refactor initialization of struct page for holes in memory layout To: Mike Rapoport Cc: Mike Rapoport , Andrew Morton , Andrea Arcangeli , Baoquan He , Borislav Petkov , Chris Wilson , David Hildenbrand , "H. Peter Anvin" , Ingo Molnar , Linus Torvalds , =?UTF-8?Q?=c5=81ukasz_Majczak?= , Mel Gorman , Michal Hocko , Qian Cai , "Sarvela, Tomi P" , Thomas Gleixner , linux-kernel@vger.kernel.org, linux-mm@kvack.org, stable@vger.kernel.org, x86@kernel.org References: <20210224153950.20789-1-rppt@kernel.org> <20210224153950.20789-2-rppt@kernel.org> <20210225180521.GH1854360@linux.ibm.com> <20210226105900.GK1854360@linux.ibm.com> From: Vlastimil Babka Message-ID: Date: Fri, 26 Feb 2021 12:08:09 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: <20210226105900.GK1854360@linux.ibm.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Stat-Signature: qkfwfqu6qn19i4hondye8josxg5z7arw X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: CB87F407F8FF Received-SPF: none (suse.cz>: No applicable sender policy available) receiver=imf26; identity=mailfrom; envelope-from=""; helo=mx2.suse.de; client-ip=195.135.220.15 X-HE-DKIM-Result: none/none X-HE-Tag: 1614337686-109545 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 2/26/21 11:59 AM, Mike Rapoport wrote: > On Thu, Feb 25, 2021 at 07:38:44PM +0100, Vlastimil Babka wrote: >> On 2/25/21 7:05 PM, Mike Rapoport wrote: >> >> >> >> What if two zones are adjacent? I.e. if the hole was at a boundary between two >> >> zones. >> > >> > What do you mean by "adjacent zones"? If there is a hole near the zone >> > boundary, zone span would be clamped to exclude the hole. >> >> Yeah, zone span should exclude those pages, but you still somehow handle them? >> That's how I read "pages that are not spanned by any node will get links to the >> adjacent zone/node." >> So is it always a unique zone/node can be determined? >> >> Let's say we have: >> >> >> ---- pageblock boundary ---- >> >> >> >> ---- pageblock boundary ---- >> >> Now I hope such configurations don't really exist :) But if we simulated them in >> QEMU, what would be the linkage in struct pages in that hole? > > I don't think such configuration is possible in practice but it can be > forced with e.g memmap="2M hole at 4G - 1M". Right. > The hole in your example the hole will get node1 for node and zone that > spans the beginning of node1 for zone. Yeah the comments in v8 make that clear now, thanks!