[PATCH v3 04/41] KVM: arm64: Rework hyp_panic for VHE and non-VHE
Julien Grall
julien.grall at linaro.org
Mon Feb 5 10:10:00 PST 2018
On 05/02/18 18:04, Julien Grall wrote:
> On 12/01/18 12:07, Christoffer Dall wrote:
>> @@ -436,37 +446,31 @@ static void __hyp_text __hyp_call_panic_nvhe(u64
>> spsr, u64 elr, u64 par,
>> read_sysreg(hpfar_el2), par, vcpu);
>> }
>> -static void __hyp_text __hyp_call_panic_vhe(u64 spsr, u64 elr, u64 par,
>> - struct kvm_vcpu *vcpu)
>> +static void __hyp_call_panic_vhe(u64 spsr, u64 elr, u64 par,
>> + struct kvm_cpu_context *host_ctxt)
>> {
>> + struct kvm_vcpu *vcpu;
>> + vcpu = host_ctxt->__hyp_running_vcpu;
>> +
>> + __deactivate_traps(vcpu);
>> + __sysreg_restore_host_state(host_ctxt);
>
> I was about to ask why you keep this function around as it does nothing
> in VHE case. But I see that this will actually restore some values in a
> later patch.
Actually, I just misread the code. Sorry for the noise.
Cheers,
--
Julien Grall
More information about the linux-arm-kernel
mailing list