[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [PATCH V4 05/10] xen/arm: static memory initialization
- To: Julien Grall <julien@xxxxxxx>, Penny Zheng <Penny.Zheng@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, "sstabellini@xxxxxxxxxx" <sstabellini@xxxxxxxxxx>
- From: Wei Chen <Wei.Chen@xxxxxxx>
- Date: Mon, 16 Aug 2021 07:00:54 +0000
- Accept-language: en-US
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=omgbgecN/jUL3ruQrEfCmnS27o6FWHsQS+xkrzBDVlc=; b=bwEjjX+/n23RRm2ip/Zsq+V2vbrXvbtNtK0UTclp7H6wo5izjnPBufs02lbSqDr9NlMIQU4LrGFHHYMpyMqcDXWp1WkhbzJsmfEjMvBvDm9JcitQWHyubw0ZT2ou3L0zu1WHBDITzcuhYxMMcqFrlVDIjX4QLKJd9I4ax1siwmle33a81x0b5PSnuLkCVUPF9r/+aOVmU0eVn09ucT1I9KrqD3+x+w+yMQN4PmfOReAPCJmbtBK0r2iB6lnQEkqcRhEElqIymnusqcXPEu4ajbquPg3uECbz4fgxkcUjoeASeX8sCLE36YOBL6z+H8+0FVvryTErYeAbxVsCmQjJjg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=TUaq1wjgDIy8p8R9wWVrqqbZff/eCjyBenpy5Vp+puY/cD0K9DLqvjAOYmoZDrOxtDrE4x7IhYGYWtADHCNxdMGdkywKlpO7NSUuR281flx9njxIxuD4BSay48XwGosq0+SECjn/I/tl8+FeYzIO1YhRzg7vJG/osbTc/aZ6303Bt4MO3RWot1Fx+qTorP7o+AC3B64yALrYh7BRMIBei9R3NmK3D/8YF7l4D6NBrd2RR2QwJ2s9MEsjwVWpQrE2M7qsj+/gFyJtZLeHPosjPpTp0xslC4U4bv4NMfMyqjCoI8HLVYubaRlKhAGV/NLTHdyh+AfK0RHCitWW38jUbw==
- Authentication-results-original: xen.org; dkim=none (message not signed) header.d=none;xen.org; dmarc=none action=none header.from=arm.com;
- Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, nd <nd@xxxxxxx>
- Delivery-date: Mon, 16 Aug 2021 07:01:17 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Nodisclaimer: true
- Original-authentication-results: xen.org; dkim=none (message not signed) header.d=none;xen.org; dmarc=none action=none header.from=arm.com;
- Thread-index: AQHXg5tWhKjEMj8fikey5jo8McJgaKtxeOUAgARWM0A=
- Thread-topic: [PATCH V4 05/10] xen/arm: static memory initialization
Hi Julien,
> -----Original Message-----
> From: Julien Grall <julien@xxxxxxx>
> Sent: 2021年8月13日 20:38
> To: Penny Zheng <Penny.Zheng@xxxxxxx>; xen-devel@xxxxxxxxxxxxxxxxxxxx;
> sstabellini@xxxxxxxxxx
> Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>; Wei Chen
> <Wei.Chen@xxxxxxx>; nd <nd@xxxxxxx>
> Subject: Re: [PATCH V4 05/10] xen/arm: static memory initialization
>
> Hi Penny,
>
> On 28/07/2021 11:27, Penny Zheng wrote:
> > +/* Static memory initialization */
> > +static void __init init_staticmem_pages(void)
> > +{
> > + unsigned int bank;
> > +
> > + /* TODO: Considering NUMA-support scenario. */
>
> I forgot to ask about this. What do you expect to be different with NUMA?
>
From our current NUMA implementation, I think there is no difference
between NUMA and Non-NUMA system for static allocation. Maybe in the
future, we will add some checks to warning user about cross-nodes
configuration. But now, I think it's better for Penny to remove this
comment.
> > + for ( bank = 0 ; bank < bootinfo.static_mem.nr_banks; bank++ )
> > + {
> > + unsigned long bank_start =
> PFN_UP(bootinfo.static_mem.bank[bank].start);
> > + unsigned long bank_size =
> PFN_DOWN(bootinfo.static_mem.bank[bank].size);
> > + unsigned long bank_end = bank_start + bank_size;
> > +
> > + if ( bank_end <= bank_start )
> > + return;
> > +
> > + free_staticmem_pages(mfn_to_page(_mfn(bank_start)),
> > + bank_size, false);
> > + }
> > +}
> > +
>
> Cheers,
>
> --
> Julien Grall
|