Re: [PATCH 02/27] arm64: KVM: Hide unsupported AArch64 CPU features from guests

2017-08-16 Thread Dave Martin
On Wed, Aug 16, 2017 at 12:10:38PM +0100, Marc Zyngier wrote: > On 09/08/17 13:05, Dave Martin wrote: > > Currently, a guest kernel sees the true CPU feature registers > > (ID_*_EL1) when it reads them using MRS instructions. This means > > that the guest will observe features that are present in

Re: [PATCH 24/27] arm64/sve: Detect SVE and activate runtime support

2017-08-16 Thread Suzuki K Poulose
On 09/08/17 13:05, Dave Martin wrote: [This sender failed our fraud detection checks and may not be who they appear to be. Learn about spoofing at http://aka.ms/LearnAboutSpoofing] This patch enables detection of hardware SVE support via the cpufeatures framework, and reports its presence to

Re: [PATCH 15/27] arm64/sve: Probe SVE capabilities and usable vector lengths

2017-08-16 Thread Suzuki K Poulose
On 09/08/17 13:05, Dave Martin wrote: [This sender failed our fraud detection checks and may not be who they appear to be. Learn about spoofing at http://aka.ms/LearnAboutSpoofing] This patch uses the cpufeatures framework to determine common SVE capabilities and vector lengths, and configures

Re: [PATCH 21/27] arm64/sve: KVM: Prevent guests from using SVE

2017-08-16 Thread Dave Martin
On Wed, Aug 16, 2017 at 12:20:41PM +0100, Marc Zyngier wrote: > On 16/08/17 11:50, Dave Martin wrote: > > On Tue, Aug 15, 2017 at 05:33:15PM +0100, Marc Zyngier wrote: > >> On 09/08/17 13:05, Dave Martin wrote: > >>> Until KVM has full SVE support, guests must not be allowed to > >>> execute SVE

Re: [PATCH 23/27] arm64/sve: KVM: Hide SVE from CPU features exposed to guests

2017-08-16 Thread Dave Martin
On Wed, Aug 16, 2017 at 12:10:53PM +0100, Marc Zyngier wrote: > On 16/08/17 11:54, Dave Martin wrote: > > On Tue, Aug 15, 2017 at 05:37:55PM +0100, Marc Zyngier wrote: > >> On 09/08/17 13:05, Dave Martin wrote: [...] > >>> + if (id == SYS_ID_AA64PFR0_EL1) { > >>> + static bool printed; >

Re: [PATCH 21/27] arm64/sve: KVM: Prevent guests from using SVE

2017-08-16 Thread Marc Zyngier
On 16/08/17 12:20, Marc Zyngier wrote: > On 16/08/17 11:50, Dave Martin wrote: >> On Tue, Aug 15, 2017 at 05:33:15PM +0100, Marc Zyngier wrote: >>> On 09/08/17 13:05, Dave Martin wrote: Until KVM has full SVE support, guests must not be allowed to execute SVE instructions. This

Re: [PATCH 21/27] arm64/sve: KVM: Prevent guests from using SVE

2017-08-16 Thread Marc Zyngier
On 16/08/17 11:50, Dave Martin wrote: > On Tue, Aug 15, 2017 at 05:33:15PM +0100, Marc Zyngier wrote: >> On 09/08/17 13:05, Dave Martin wrote: >>> Until KVM has full SVE support, guests must not be allowed to >>> execute SVE instructions. >>> >>> This patch enables the necessary traps, and also

Re: [PATCH 02/27] arm64: KVM: Hide unsupported AArch64 CPU features from guests

2017-08-16 Thread Marc Zyngier
On 09/08/17 13:05, Dave Martin wrote: > Currently, a guest kernel sees the true CPU feature registers > (ID_*_EL1) when it reads them using MRS instructions. This means > that the guest will observe features that are present in the > hardware but the host doesn't understand or doesn't provide

Re: [PATCH 23/27] arm64/sve: KVM: Hide SVE from CPU features exposed to guests

2017-08-16 Thread Marc Zyngier
On 16/08/17 11:54, Dave Martin wrote: > On Tue, Aug 15, 2017 at 05:37:55PM +0100, Marc Zyngier wrote: >> On 09/08/17 13:05, Dave Martin wrote: >>> KVM guests cannot currently use SVE, because SVE is always >>> configured to trap to EL2. >>> >>> However, a guest that sees SVE reported as present in

Re: [PATCH 23/27] arm64/sve: KVM: Hide SVE from CPU features exposed to guests

2017-08-16 Thread Dave Martin
On Tue, Aug 15, 2017 at 05:37:55PM +0100, Marc Zyngier wrote: > On 09/08/17 13:05, Dave Martin wrote: > > KVM guests cannot currently use SVE, because SVE is always > > configured to trap to EL2. > > > > However, a guest that sees SVE reported as present in > > ID_AA64PFR0_EL1 may legitimately

Re: [PATCH 21/27] arm64/sve: KVM: Prevent guests from using SVE

2017-08-16 Thread Dave Martin
On Tue, Aug 15, 2017 at 05:33:15PM +0100, Marc Zyngier wrote: > On 09/08/17 13:05, Dave Martin wrote: > > Until KVM has full SVE support, guests must not be allowed to > > execute SVE instructions. > > > > This patch enables the necessary traps, and also ensures that the > > traps are disabled

Re: [PATCH 11/27] arm64/sve: Core task context handling

2017-08-16 Thread Dave Martin
On Tue, Aug 15, 2017 at 06:31:05PM +0100, Ard Biesheuvel wrote: > Hi Dave, > > On 9 August 2017 at 13:05, Dave Martin wrote: > > This patch adds the core support for switching and managing the SVE > > architectural state of user tasks. > > > > Calls to the existing FPSIMD

Re: [PATCH 17/27] arm64/sve: Preserve SVE registers around EFI runtime service calls

2017-08-16 Thread Dave Martin
On Tue, Aug 15, 2017 at 06:44:45PM +0100, Ard Biesheuvel wrote: > On 9 August 2017 at 13:05, Dave Martin wrote: > > The EFI runtime services ABI allows EFI to make free use of the > > FPSIMD registers during EFI runtime service calls, subject to the > > callee-save