Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp7037568rwd; Tue, 6 Jun 2023 05:41:50 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7lEEY37w2uJNzoJd0cEpspqV0zsQpdxQnzaU+9guSXAqCuYRRwy0pe3Zuey2+v2bk9eSFQ X-Received: by 2002:aca:120e:0:b0:398:1186:88ba with SMTP id 14-20020aca120e000000b00398118688bamr1986081ois.31.1686055309922; Tue, 06 Jun 2023 05:41:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686055309; cv=none; d=google.com; s=arc-20160816; b=FhCGRFi0PPI6O3Ebm0B+awo1iuiUgkWEFzOC91JBHU5KbsYP15H4etb5IssM+g9sO5 fGIWZHQrrWrFKqkB7oDN4uqY2EmwQ5Ngf5/PPSdo/jClj5HA+FYy3H64huEyR9TyeExs ++3lKW1c+flDiqr0rpwmie99Maf7b4I8ygn/WStvXLGU8XMWHED4FZ9NVk9ceXsG5lrn 3VYD7JwTXOQniMKajwwYBpBpeR4VIYDGTbvUq3cKKsXjPZcm/242x3JxfvS44pupym2N t9cEPb4tdMdJaq6iKvGydua9yGGxBFgGLWcUKku2GILqcpkBVV5Bi+z84gaMfXlgk4HR HlWA== 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:feedback-id :dkim-signature:dkim-signature; bh=eMgbmfO4n2kZdbVnfADr60x6eK0Ld2t432qe3NAZMQ4=; b=EJWjfR3m7XIQEKx7wBmVb988JvceIg+EQtPd4ICFx5tHBBLcHQgytdMU8GZrne/bJX uFCCC3SgOS79iD7CQ/eZOM37KyANabgEqINdN/Tk1lUe2EgwwIxbJ1gz5UsfNL3aDq7J 9JEEP8hodJ+gJ+3Ip8iuO2q9zfWKiFeDqZp3Illpfid5Dul1sbfV8XuKFofZ2aQ+3KWG VnH0TfieRBYV3xYnBlDxbok2y6af324n3/Y3WIUFi5vKaHngry+OJev3fAM06Q8OKd3k TzYyPmz7EJyepO4zLI4HsubqpFKJjurENlFIAxIBioZtbKNCd+mJTDvq7ImhPjiO/JEm 1bzA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@shutemov.name header.s=fm3 header.b=jHQpYMBW; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=DFK3TMmu; 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 x10-20020a170902ec8a00b001a99ace3e76si7525926plg.554.2023.06.06.05.41.38; Tue, 06 Jun 2023 05:41:49 -0700 (PDT) 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; dkim=pass header.i=@shutemov.name header.s=fm3 header.b=jHQpYMBW; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=DFK3TMmu; 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 S233403AbjFFMTc (ORCPT + 99 others); Tue, 6 Jun 2023 08:19:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230297AbjFFMTb (ORCPT ); Tue, 6 Jun 2023 08:19:31 -0400 Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2D4F9E54; Tue, 6 Jun 2023 05:19:30 -0700 (PDT) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 8FBC55C00F9; Tue, 6 Jun 2023 08:19:29 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute5.internal (MEProxy); Tue, 06 Jun 2023 08:19:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shutemov.name; h=cc:cc:content-type:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm3; t=1686053969; x= 1686140369; bh=eMgbmfO4n2kZdbVnfADr60x6eK0Ld2t432qe3NAZMQ4=; b=j HQpYMBWdPEngh7GTogG1JcK44zHd1xFfQKCr7pw8AlFmkjPrLOyN/GbO7Kwu2pnJ 7VFvwO8mAe5G1Ofx0T5jqZycNb5fn3XU+MG9jqgmfSppXoi+6ed4AgCc9HafMN6F mrfmcnf0aLSOpBf8NZEsr12Fhj7Paz3N53O0fGsMz12xpBJhwU5hVN7oAusfb5YK PrUmtDm+AsFwfy1+RnPi8HTzkQbEjTXJiVS3NGxSrrmVc/OLncvqDWIlYxq2Jfwk VDHrQm8J86dvg6VAzxanW11lxLMuilF9P8tLUv8bZkCuZd59fUXk2540YhRkAgTY DcyWhpv7OnuIsbShnJ5iQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; t=1686053969; x=1686140369; bh=eMgbmfO4n2kZd bVnfADr60x6eK0Ld2t432qe3NAZMQ4=; b=DFK3TMmuHfpcBYoyzfHZXn4gdyTZe jGBw/bQOF0V+z/hcbx5eFli8UCiXay4dhrNYzheOVeESayrqgmYJo5GADrPPreW/ a0equVNAGjnXBqkwWGvI/e9+puX6yYZdMZmZMNMsVeHQwBRbfyLNkKLgrCeEMjzC b/cGlVzJTDxagJsW4P4f3VCCvQIz8WZyPqjTG5UNAzu3kvVL3FeqyFE8rcIJj0/x Lp4A4cMbKjY+j/EPEM3gUGV+DrX0UfEWR1pA7xZ7R0r89s3zHxDLcDqaMrywYjn2 UimK6pVZVsSHXd8uisqpwt912ZbQNtr5xAcvKfydpXo0rdqB9z1tYCCDA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrgedtuddghedvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkfhggtggujgesthdttddttddtvdenucfhrhhomhepfdfmihhr ihhllhcutedrucfuhhhuthgvmhhovhdfuceokhhirhhilhhlsehshhhuthgvmhhovhdrnh grmhgvqeenucggtffrrghtthgvrhhnpefhieeghfdtfeehtdeftdehgfehuddtvdeuheet tddtheejueekjeegueeivdektdenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmh epmhgrihhlfhhrohhmpehkihhrihhllhesshhhuhhtvghmohhvrdhnrghmvg X-ME-Proxy: Feedback-ID: ie3994620:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 6 Jun 2023 08:19:27 -0400 (EDT) Received: by box.shutemov.name (Postfix, from userid 1000) id 21F0810A6A4; Tue, 6 Jun 2023 15:19:24 +0300 (+03) Date: Tue, 6 Jun 2023 15:19:24 +0300 From: "Kirill A. Shutemov" To: Borislav Petkov Cc: "Kirill A. Shutemov" , Andy Lutomirski , Dave Hansen , Sean Christopherson , Andrew Morton , Joerg Roedel , Ard Biesheuvel , Andi Kleen , Kuppuswamy Sathyanarayanan , David Rientjes , Vlastimil Babka , Tom Lendacky , Thomas Gleixner , Peter Zijlstra , Paolo Bonzini , Ingo Molnar , Dario Faggioli , Mike Rapoport , David Hildenbrand , Mel Gorman , marcelo.cerri@canonical.com, tim.gardner@canonical.com, khalid.elmously@canonical.com, philip.cox@canonical.com, aarcange@redhat.com, peterx@redhat.com, x86@kernel.org, linux-mm@kvack.org, linux-coco@lists.linux.dev, linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCHv13 5/9] efi: Add unaccepted memory support Message-ID: <20230606121924.wcjezcppuiofvnk6@box.shutemov.name> References: <20230601182543.19036-1-kirill.shutemov@linux.intel.com> <20230601182543.19036-6-kirill.shutemov@linux.intel.com> <20230605154333.GLZH4CpV3eXCCWCGxi@fat_crate.local> <20230605173303.k5yt535snxyk4ez3@box.shutemov.name> <20230605191225.GCZH4zmbtkWWRG4lzf@fat_crate.local> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230605191225.GCZH4zmbtkWWRG4lzf@fat_crate.local> X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 Mon, Jun 05, 2023 at 09:12:25PM +0200, Borislav Petkov wrote: > So how about you explain that explicitly somewhere, perhaps in a comment > above accept_memory(), that the unaccepted range is not the whole memory > but only, well, what is unaccepted and the rest is implicitly accepted? Does it look okay to you? /* * accept_memory() -- Consult bitmap and accept the memory if needed. * * Only memory that explicitly marked as unaccepted in the bitmap requires * an action. * * No need to accept: * - anything if the system has no unaccepted table; * - memory that is below phys_base; * - memory that is above the memory that addressable by the bitmap; */ -- Kiryl Shutsemau / Kirill A. Shutemov