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

Re: Xen Armv8-R booting protocol


  • To: Ayan Kumar Halder <ayankuma@xxxxxxx>
  • From: Luca Fancellu <Luca.Fancellu@xxxxxxx>
  • Date: Tue, 15 Apr 2025 13:10:25 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 4.158.2.129) smtp.rcpttodomain=amd.com smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com])
  • 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=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=lHGK4CiB/aVaVHQboabuIt3SWAUuYctdwyk/zvUe9T8=; b=ADMFRoCIcgKG4Dwv82/Kgu5b2LMzBd6rFt9zUU2w/RbSKR8mMMqEOaFIUaIFgDo3IZXFXRft9x255PlU3dZRuUG7WPyHID86znWoKiHF6RkwUKmm1eyndcmwx+QkSQ9Z4pjiOmje9tRKE9TfElZV6PtRhIYaCKFwSidRIbhfadQ6h27U1VGg/XcX0QS6Y4mimuf9lS1dmeL5dhYS5w/zvVrd2WWA8s22B524BdxbdDbmf4SsrRwIrQ6lndgflyxB8aQNIeI2pAtXbaQ0ZC5zMK1GtmiEJz9cV9fiq6/3c7JfmVTpejw8qmodTCFaCEKLQYnKADpnaPj5NfU8vMHjZA==
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=lHGK4CiB/aVaVHQboabuIt3SWAUuYctdwyk/zvUe9T8=; b=AFliD+wcdhQwBvU6oE/GGhI+eXx4yqrynTGU4Z1IinI/bx1ujZ/FM6NCO9ko6Jo7PRhHyKSrUgjKembkJU08HZh/vecxznAh0s6/xM8H3We64I3OWeWPf5xVdlYsbCMdBOuXySQwRVUvARAIaayQyS3F6yI0C5zToCej0msKwyQI1SqJ01MP3Edi/tRol1UvBeD7rQBwGKZ/MO9WzMsxBMfyid0qPFM0FuM08/zQ6AlswSw2w4DLKX7IY2Vzz68Yet+ty2dIqoRL+5qF2xqIoKNXYgbItr1nI0FGsFzlMEq47pT0IuxKesKN/1w+iqeCVIuIpLp++iC7rrUdWqF0Xg==
  • Arc-seal: i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass; b=y3SgDthTN8yHp4UGMmp7KDUX38w2CFuW4/n7uAiqeHwzmj91XuYI7a/HTmQXH2FEgPBl5LAqtc3S3PlBJacZdof30UVz0G3OqMVm/A6V1narFmNZfudXLZgH/69IsbjkgJooGZ0gT4OsQ0dWVrutB7K0+oy15wRvmIq4h0pdQFlIypUnqnf1mxUvTTSHakeGfDlcyymYsqVx4dRhsAICk/kkH3TAIoOJuSxcvKPYbdULLRaI/+/ZaT8K/hx1za9/BO2hQvFdOIa8oz2kQNfUJaph7U7AvvzxuviqoJmIH7wA+MN8tSrdRdXcLKnRhJRyo/hsZA5uWwplZPA3GgEMvA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=tsSOeCGVk1LDfSoffxwlE7v/Qty+5hcQLmguyilrNFKmwHIFaelMe7Hx6czwgiisLX7lzqhlf0p5ZMGd3kE7r3hXiuikRVMSN5yiYdym0g9+It5euKyIPU82G36bCU7ZLEzeXKJ87Vm5dKii1UG2kErVfCaQxAC3/ZHnrjoQAMK9uZWxmvfNQQL0p4511QA14Mn4M3oftdXWclVCwXQXpYwbqJUib9zGLIX/DGl1erhLygD5Lgjt33N5UlBk+zlUQ/88yRjwuHCigWIZ24Dg7DWBOFHSfE88NBHSDkZxoXySLRy6wBnq5ptt9Copj72FEJYrMV9gNL15VhgjEfJGyg==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Julien Grall <julien@xxxxxxx>, "Orzel, Michal" <michal.orzel@xxxxxxx>, Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>
  • Delivery-date: Tue, 15 Apr 2025 13:11:15 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Thread-index: AQHbrf9eNLQ3I8ChLUu7y92fKMnf87OksnaAgAAA54A=
  • Thread-topic: Xen Armv8-R booting protocol

Hi Ayan,

> On 15 Apr 2025, at 14:06, Ayan Kumar Halder <ayankuma@xxxxxxx> wrote:
> 
> 
> On 15/04/2025 13:10, Luca Fancellu wrote:
>> Hi all,
> Hi Luca,
>> 
>> I’ve started this thread to talk about a possible Xen booting protocol when 
>> running on Armv8-R,
>> currently Xen uses the Linux boot protocol and some other requirements 
>> stated in docs/misc/arm/booting.txt.
>> 
>> Unfortunately we don’t have anything already available for Armv8-R, the only 
>> implementation of a bootloader
>> is the boot-wrapper-aarch64 which keeps the MPU off, I/D cache off.
>> 
>> So my proposal is to add additional requirements in our 
>> docs/misc/arm/booting.txt for the case where Xen is
>> started on Armv8-R, under "Firmware/bootloader requirements”.
> This makes sense.
>> 
>> diff --git a/docs/misc/arm/booting.txt b/docs/misc/arm/booting.txt
>> index 21ae74837dcc..39f029153e38 100644
>> --- a/docs/misc/arm/booting.txt
>> +++ b/docs/misc/arm/booting.txt
>> @@ -62,6 +62,14 @@ Xen relies on some settings the firmware has to configure 
>> in EL3 before starting
>>    * The bit SCR_EL3.HCE (resp. SCR.HCE for 32-bit ARM) must be set to 1.
>>  +When Xen runs on Armv8-R, the highest exception level is EL2 and the only
>> +available mode is secure, hence the above requirements needs to be adjusted 
>> to
>> +this case:
>> +
>> +* Xen must be entered in S EL2 mode.
> 
> Refer ARM DDI 0568A.c ID110520 A1.3.1
> 
> Armv8-R (AArch32) only supports a single Security state, Non-secure.
> 
> I see that it differs from Armv8-R (AArch64) ARM DDI 0600A.d ID120821, A1.3
> 
> The PE is always in Secure state.
> 
> Probably you can mention both.

ok, then it should be S/NS EL2.

> 
>> +
>> +* Xen must be entered with MPU off and data cache disabled (SCTLR_EL2.M bit 
>> and
>> +  SCTLR_EL2.C set to 0).
>>    [1] linux/Documentation/arm/booting.rst
>>  Latest version: 
>> http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/Documentation/arch/arm/booting.rst
>> 
>> Please let me know your thoughts.
> 
> A question, Do you know if u-boot (or any other bootloader) is supported on 
> Armv8-R ? Because someone needs to pass the DTB address in r2/x0.

As far as I know, no other boot loader is supported, we had patches for u-boot 
enabling MPU at EL2 but they were not merged.

I’m currently building Xen with the device tree embedded.

Cheers,
Luca


 


Rackspace

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