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=-7.5 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,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 B0EE6C2B9F4 for ; Thu, 17 Jun 2021 11:22:27 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 745AA60FF0 for ; Thu, 17 Jun 2021 11:22:27 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 745AA60FF0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=xen.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from list by lists.xenproject.org with outflank-mailman.143840.264930 (Exim 4.92) (envelope-from ) id 1ltq6A-0005Pb-PC; Thu, 17 Jun 2021 11:22:14 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 143840.264930; Thu, 17 Jun 2021 11:22:14 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ltq6A-0005PU-LY; Thu, 17 Jun 2021 11:22:14 +0000 Received: by outflank-mailman (input) for mailman id 143840; Thu, 17 Jun 2021 11:22:13 +0000 Received: from mail.xenproject.org ([104.130.215.37]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ltq68-0005PO-W1 for xen-devel@lists.xenproject.org; Thu, 17 Jun 2021 11:22:12 +0000 Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ltq68-0007px-Pv; Thu, 17 Jun 2021 11:22:12 +0000 Received: from [54.239.6.186] (helo=a483e7b01a66.ant.amazon.com) by xenbits.xenproject.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1ltq68-0003z4-5Y; Thu, 17 Jun 2021 11:22:12 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=xen.org; s=20200302mail; h=Content-Transfer-Encoding:Content-Type:In-Reply-To: MIME-Version:Date:Message-ID:From:References:Cc:To:Subject; bh=7eOPxmqioGUTJEF/zP1CGF9hfGxzfNJuFfWnGpbfETw=; b=YSuojr+X5JRPfXMlpH2gfy/1zv VHsSdRaG3JEMWJV9YC6mk6bi2ZkQGkCYRgjBQpRv8zZpzLtb9q6UKffH19TVGS9lnk2+DyCybBNqt NPWGfZWhFv/IO13wAwRK3GdAUus/kwCEt5wuOIoH3mzqRFNP8EvTzUk58SfjGwBiWPdA=; Subject: Re: [PATCH 01/10] xen/arm: introduce domain on Static Allocation To: Penny Zheng , Bertrand Marquis Cc: Stefano Stabellini , Julien Grall , "xen-devel@lists.xenproject.org" , Wei Chen , nd References: <20210518052113.725808-1-penny.zheng@arm.com> <20210518052113.725808-2-penny.zheng@arm.com> <66e32065-ea2d-d000-1a70-e5598a182b6a@xen.org> <14fb6fe4-c293-6994-8cbc-872d3bd8a3ac@xen.org> <4251e0e2-fb53-b8a3-0323-f4ce892cf21e@xen.org> <113937c2-f1a7-c27f-8e2e-79de729ea3ce@xen.org> From: Julien Grall Message-ID: <0e7d32ba-0caa-e23d-ddae-66970b972188@xen.org> Date: Thu, 17 Jun 2021 13:22:08 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit On 15/06/2021 08:08, Penny Zheng wrote: > Hi julien Hi Penny, >> -----Original Message----- >> From: Julien Grall >> Sent: Wednesday, June 9, 2021 6:47 PM >> To: Bertrand Marquis >> Cc: Stefano Stabellini ; Julien Grall >> ; Penny Zheng ; xen- >> devel@lists.xenproject.org; Wei Chen ; nd >> >> Subject: Re: [PATCH 01/10] xen/arm: introduce domain on Static Allocation >> >> >> >> On 09/06/2021 10:56, Bertrand Marquis wrote: >>> Hi All, >> >> Hi, >> >>>> On 7 Jun 2021, at 19:09, Julien Grall >>> > wrote: >>>> Feel free to propose one. I suggested to use /reserved-memory because >>>> this is the approach that makes the most sense to me (see my reply above). >>>> >>>> TBH, even after your explanation, I am still a bit puzzled into why >>>> /reserved-memory cannot be leveraged to exclude domain region from >>>> the hypervisor allocator. >>> >>> I really tend to think that the original solution from Penny is for >>> now the easiest and simplest to document. >> >> I can live with Penny's solution so long we don't duplicate the parsing and we >> don't create new datastructure in Xen for the new type of reserved memory. >> However... >> > > Just to confirm what I understand here, you are not only worrying about the duplication code imported in > dt_unreserved_regions, but also must introducing another path in func early_scan_node to parse my first implementation > "xen,static-mem = <...>", right? That's correct. > > On duplication code part, I could think of a way to extract common codes to fix, but for introducing another new path to parse, > FWIT, it is inevitable if not re-using reserved-memory. ;/ I don't think this is inevitable. If you look at the code, we already share the parsing between reserved-memory and memory. AFAICT, the main difference now is the property to parse. Other than that, the content is exactly the same. So we could pass the name of the property to parse. Cheers, -- Julien Grall