[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Proposal for Porting Xen to Armv8-R64 - DraftA


  • To: Wei Chen <Wei.Chen@xxxxxxx>, Julien Grall <julien@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • From: Wei Chen <Wei.Chen@xxxxxxx>
  • Date: Mon, 7 Mar 2022 02:12:09 +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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=0g8yivnvx85CDEKooahcFOCx+7K/iJEV17lk+KBSg5s=; b=PZrw7sQcq7psiZOw1gekvpgIxlGzZkq8eWmvVsrayQYbw54y7P3c602sP0+UfB5z0UHZyYkohLCjQAtQfaxqGyrxS4aKV7MjPGnoGOhpQs11cKnGBTdYORS42WIpEht0r1wkHv6rSUVXBupX0rp0D/7Az2/Fh9PNiGikX5muSyoIO6O7FVtW9WqLT1FOwxRW6CXW4HbZjndBgL1qrWS/KgRx4gNaHaT1PD6UBPJNVaZk/799mtctdMqu7mR29/5/txhohdjd7ylf9fLodXX0/dN9pbDBA4qd3kf31nTICGVWDp4kWvMODuGM76tI0DHI76KSzSOOg7juTwPCgyhb9g==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LUz6UEMnDCO8ILbjxNthzOJ/nGh71OnpO/Mdlz/Gq3kMXQvWh63+oJs8XGnmxx0PPHtQNYETDdxwbJJKyuIyxqyWbUXcb7azPMjC2hyQQV9JiBQS54Kh6BVd4TX9tKfRUsM5TQxixGMtYGfER3X1IKikj7Izbn8wvsq4bGnAwPVhoED+C+THih4ZdyErxfEX0SrQC2UxXO3cY2D/+N10MeoOoYBA79UzWefbopuu4KeN2R3mTYO6DrGsUFvgJ+ruDgyxvSGhSXx8JHJacEZWWWkPqK3A6DYCC6KYlpkW1XmGjJmXXl0PAVff5yLOOQ+pziXtCEr5tB0rLNAVHmh5rA==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Penny Zheng <Penny.Zheng@xxxxxxx>, Henry Wang <Henry.Wang@xxxxxxx>, nd <nd@xxxxxxx>
  • Delivery-date: Mon, 07 Mar 2022 02:12:56 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AdgpQxtXwh7LkfydTgiYk9bhMgU+ogBRt1sAAKse4VAAPag1gAAckyvAAMo7i2A=
  • Thread-topic: Proposal for Porting Xen to Armv8-R64 - DraftA

Hi Stefano,

> -----Original Message-----
> From: Xen-devel <xen-devel-bounces@xxxxxxxxxxxxxxxxxxxx> On Behalf Of Wei
> Chen
> Sent: 2022年3月3日 10:07
> To: Julien Grall <julien@xxxxxxx>; xen-devel@xxxxxxxxxxxxxxxxxxxx; Stefano
> Stabellini <sstabellini@xxxxxxxxxx>
> Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>; Penny Zheng
> <Penny.Zheng@xxxxxxx>; Henry Wang <Henry.Wang@xxxxxxx>; nd <nd@xxxxxxx>
> Subject: RE: Proposal for Porting Xen to Armv8-R64 - DraftA
> 
> Hi Julien,
> 
> > -----Original Message-----
> > From: Julien Grall <julien@xxxxxxx>
> > Sent: 2022年3月2日 20:00
> > To: Wei Chen <Wei.Chen@xxxxxxx>; xen-devel@xxxxxxxxxxxxxxxxxxxx; Stefano
> > Stabellini <sstabellini@xxxxxxxxxx>
> > Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>; Penny Zheng
> > <Penny.Zheng@xxxxxxx>; Henry Wang <Henry.Wang@xxxxxxx>; nd <nd@xxxxxxx>
> > Subject: Re: Proposal for Porting Xen to Armv8-R64 - DraftA
> >
> >
> >
> > On 01/03/2022 07:51, Wei Chen wrote:
> > > Hi Julien,
> >
> > Hi Wei,
> >
> > >> -----Original Message-----
> > >> From: Julien Grall <julien@xxxxxxx>
> > >> Sent: 2022年2月26日 4:55
> > >> To: Wei Chen <Wei.Chen@xxxxxxx>; xen-devel@xxxxxxxxxxxxxxxxxxxx;
> > Stefano
> > >> Stabellini <sstabellini@xxxxxxxxxx>
> > >> Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>; Penny Zheng
> > >> <Penny.Zheng@xxxxxxx>; Henry Wang <Henry.Wang@xxxxxxx>; nd
> <nd@xxxxxxx>
> > >> Subject: Re: Proposal for Porting Xen to Armv8-R64 - DraftA
> > >>> ### 1.2. Xen Challenges with PMSA Virtualization
> > >>> Xen is PMSA unaware Type-1 Hypervisor, it will need modifications to
> > run
> > >>> with an MPU and host multiple guest OSes.
> > >>>
> > >>> - No MMU at EL2:
> > >>>       - No EL2 Stage 1 address translation
> > >>>           - Xen provides fixed ARM64 virtual memory layout as basis
> of
> > >> EL2
> > >>>             stage 1 address translation, which is not applicable on
> > MPU
> > >> system,
> > >>>             where there is no virtual addressing. As a result, any
> > >> operation
> > >>>             involving transition from PA to VA, like ioremap, needs
> > >> modification
> > >>>             on MPU system.
> > >>>       - Xen's run-time addresses are the same as the link time
> > addresses.
> > >>>           - Enable PIC (position-independent code) on a real-time
> > target
> > >>>             processor probably very rare.
> > >>
> > >> Aside the assembly boot code and UEFI stub, Xen already runs at the
> > same
> > >> address as it was linked.
> > >>
> > >
> > > But the difference is that, base on MMU, we can use the same link
> > address
> > > for all platforms. But on MPU system, we can't do it in the same way.
> >
> > I agree that we currently use the same link address for all the
> > platforms. But this is also a problem when using MMU because EL2 has a
> > single TTBR.
> >
> > At the moment we are switching page-tables with the MMU which is not
> > safe. Instead we need to turn out the MMU off, switch page-tables and
> > then turn on the MMU. This means we need to have an identity mapping of
> > Xen in the page-tables. Assuming Xen is not relocated, the identity
> > mapping may clash with Xen (or the rest of the virtual address map).
> >
> 
> Is this the same reason we create a dummy reloc section for EFI loader?
> 
> > My initial idea was to enable PIC and update the relocation at boot
> > time. But this is a bit cumbersome to do. So now I am looking to have a
> > semi-dynamic virtual layout and find some place to relocate part of Xen
> > to use for CPU bring-up.
> >
> > Anyway, my point is we possibly could look at PIC if that could allow
> > generic Xen image.
> >
> 
> I understand your concern. IMO, PIC is possible to do this, but obviously,
> it's not a small amount of work. And I want to hear some suggestions from
> Stefano, because he also has some solutions in previous thread.
>

Can you have a look at the PIC discussion between Julien and me?
I think we may need some inputs from your view.

Thanks,
Wei Chen

[...]

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.