Re: [PATCH 08/11] KVM: arm64: Inject AArch32 exceptions from HYP
From: Marc Zyngier <maz@kernel.org>
Date: 2020-10-28 20:26:47
Also in:
kvm, kvmarm
On 2020-10-28 19:20, James Morse wrote:
Hi Marc, On 27/10/2020 19:21, Marc Zyngier wrote:quoted
quoted
quoted
+static inline u32 __vcpu_read_cp15(const struct kvm_vcpu *vcpu, int reg) +{ + return __vcpu_read_sys_reg(vcpu, reg / 2); +}quoted
quoted
Doesn't this re-implement the issue 3204be4109ad biased?quoted
I don't think it does. The issue existed when accessing the 32bit shadow, and we had to pick which side of the 64bit register had our 32bit value. Here, we directly access the 64bit file, which is safe.Because its not accessing the copro union, and the two users are both straight forward aliases. ... What do I get if I call: | __vcpu_read_cp15(vcpu, c6_IFAR); Won't this return the value of c6_DFAR instead as they live in the same 64 bit register.
Yes, that would break. Not in this bit of code though.
quoted
But thinking of it, we may as well change the call sites to directly use the 64bit enum, rather than playing gamesGreat!
Yeah, and there is a bunch of ... crap around this aliasing.
Unfortunately, I just noticed that 32bit guests are borked in -rc1.
Debug time.
M.
--
Jazz is not dead. It just smells funny...
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel