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

Re: [PATCH v4 0/8] xen/arm: Emulate ID registers


  • To: Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • From: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>
  • Date: Fri, 18 Dec 2020 10:12:33 +0000
  • Accept-language: en-GB, 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=EJ52zsdBOHezTfSwHXPXJYFkoB/2E22UlIIDGO1K0T8=; b=CNkXFUAmJmEcP6+AI8kwXBgEdjUAngfKUc7l3KDCWV9bP+gs7i6XIDxUCtpleTljPmgegm8KKuF2qH43JXWN3th5HHq9jfrakOqnT5VFE7XkWCHZm7TQxojAolUoVzc7Dk8N8GNQZNQSWnN6l8NPYgeAwhL54Ke9i65ad8QUvjIhORHlq+R5sOO+XEUoNxslE5A5Laa7zD2pgvK4AkhcmCPbbl4IvRjY7QDer4PPaC2QTRWTqWVsQ0fsC5wD1jnTSpE/5XUfjMssvJgMae4tp9wB0WJSzUyx/LaBh4LwxwQcUaq1VHmll7YMIV/oLymQ0TWsdKHcR5xP1RPPFQrJsw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cKSTUXNz5yLsF4bYu30pBqCtOslX+F+Eld+J+g0Zzjz3tYcIhZQNFcDMuJWAbQ4R74X/mIhrV+DNOu1SbtE/O9cfixeH5n7V2nC0Ne97Lfyyd75YoYiIJWfEWDetrlKIUipaG+tyOXzuOPIXW2oPm8D8rxGIfxB2CClo2rQJ5x+TeV/3KXIMGJ3Xi9hKpsNbobt2r1SBHZtxdrn2PbJnA2wA8lAT6qrKPYYSnAMaHtRHDdxinOz4UM/12VAgEtWGQQgvENTg57e6YvwnrgKeOADKKRxRN0Smf90ZWphweyaazI0BF3X86E9mDT/mp9HzwGyGl+1YVaaraVCqOSDTAQ==
  • Authentication-results-original: kernel.org; dkim=none (message not signed) header.d=none;kernel.org; dmarc=none action=none header.from=arm.com;
  • Cc: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, "andrew.cooper3@xxxxxxxxxx" <andrew.cooper3@xxxxxxxxxx>, "george.dunlap@xxxxxxxxxx" <george.dunlap@xxxxxxxxxx>, "iwj@xxxxxxxxxxxxxx" <iwj@xxxxxxxxxxxxxx>, "wl@xxxxxxx" <wl@xxxxxxx>
  • Delivery-date: Fri, 18 Dec 2020 10:13:29 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: kernel.org; dkim=none (message not signed) header.d=none;kernel.org; dmarc=none action=none header.from=arm.com;
  • Thread-index: AQHW1IrfRffCgVO4HkGjd1qFhI+/sqn79O8AgACulYA=
  • Thread-topic: [PATCH v4 0/8] xen/arm: Emulate ID registers

Hi Stefano,

> On 17 Dec 2020, at 23:47, Stefano Stabellini <sstabellini@xxxxxxxxxx> wrote:
> 
> On Thu, 17 Dec 2020, Bertrand Marquis wrote:
>> The goal of this serie is to emulate coprocessor ID registers so that
>> Xen only publish to guest features that are supported by Xen and can
>> actually be used by guests.
>> One practical example where this is required are SVE support which is
>> forbidden by Xen as it is not supported, but if Linux is compiled with
>> it, it will crash on boot. An other one is AMU which is also forbidden
>> by Xen but one Linux compiled with it would crash if the platform
>> supports it.
>> 
>> To be able to emulate the coprocessor registers defining what features
>> are supported by the hardware, the TID3 bit of HCR must be disabled and
>> Xen must emulated the values of those registers when an exception is
>> catched when a guest is accessing it.
>> 
>> This serie is first creating a guest cpuinfo structure which will
>> contain the values that we want to publish to the guests and then
>> provides the proper emulationg for those registers when Xen is getting
>> an exception due to an access to any of those registers.
>> 
>> This is a first simple implementation to solve the problem and the way
>> to define the values that we provide to guests and which features are
>> disabled will be in a future patchset enhance so that we could decide
>> per guest what can be used or not and depending on this deduce the bits
>> to activate in HCR and the values that we must publish on ID registers.
> 
> As per our discussion I think we want to add this to the series.

Fully agree.

> 
> ---
> 
> xen/arm: clarify support status for various ARMv8.x CPUs
> 
> ARMv8.1+ is not security supported for now, as it would require more
> investigation on hardware features that Xen has to hide from the guest.
> 
> Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxx>
Reviewed-by: Bertrand Marquis <bertrand.marquis@xxxxxxx>

Cheers
Bertrand

> 
> diff --git a/SUPPORT.md b/SUPPORT.md
> index ab02aca5f4..d95ce3a411 100644
> --- a/SUPPORT.md
> +++ b/SUPPORT.md
> @@ -37,7 +37,8 @@ supported in this document.
> 
> ### ARM v8
> 
> -    Status: Supported
> +    Status, ARMv8.0: Supported
> +    Status, ARMv8.1+: Supported, not security supported
>     Status, Cortex A57 r0p0-r1p1: Supported, not security supported
> 
> For the Cortex A57 r0p0 - r1p1, see Errata 832075.




 


Rackspace

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