Re: [PATCH v5 12/34] KVM: SVM: Add initial support for a VMGEXIT VMEXIT

2020-12-15 Thread Paolo Bonzini
On 14/12/20 20:41, Sean Christopherson wrote: I agree VMGEXIT should be added to the hot path, it could very well be the most common exit reason due to all instruction-based emulation getting funneled through VMGEXIT. Yeah, I was thinking that not many guests will be SEV-ES. On the other

Re: [PATCH v5 12/34] KVM: SVM: Add initial support for a VMGEXIT VMEXIT

2020-12-14 Thread Sean Christopherson
On Mon, Dec 14, 2020, Tom Lendacky wrote: > On 12/14/20 9:45 AM, Paolo Bonzini wrote: > > On 10/12/20 18:09, Tom Lendacky wrote: > >> @@ -3184,6 +3186,8 @@ static int svm_invoke_exit_handler(struct vcpu_svm > >> *svm, u64 exit_code) > >>   return halt_interception(svm); > >>   else if

Re: [PATCH v5 12/34] KVM: SVM: Add initial support for a VMGEXIT VMEXIT

2020-12-14 Thread Tom Lendacky
On 12/14/20 9:45 AM, Paolo Bonzini wrote: > On 10/12/20 18:09, Tom Lendacky wrote: >> @@ -3184,6 +3186,8 @@ static int svm_invoke_exit_handler(struct vcpu_svm >> *svm, u64 exit_code) >>   return halt_interception(svm); >>   else if (exit_code == SVM_EXIT_NPF) >>   return

Re: [PATCH v5 12/34] KVM: SVM: Add initial support for a VMGEXIT VMEXIT

2020-12-14 Thread Paolo Bonzini
On 10/12/20 18:09, Tom Lendacky wrote: @@ -3184,6 +3186,8 @@ static int svm_invoke_exit_handler(struct vcpu_svm *svm, u64 exit_code) return halt_interception(svm); else if (exit_code == SVM_EXIT_NPF) return npf_interception(svm); + else if

[PATCH v5 12/34] KVM: SVM: Add initial support for a VMGEXIT VMEXIT

2020-12-10 Thread Tom Lendacky
From: Tom Lendacky SEV-ES adds a new VMEXIT reason code, VMGEXIT. Initial support for a VMGEXIT includes mapping the GHCB based on the guest GPA, which is obtained from a new VMCB field, and then validating the required inputs for the VMGEXIT exit reason. Since many of the VMGEXIT exit reasons