Re: [PATCH v9 13/22] KVM: VMX: Virtualize FRED nested exception tracking
From: Xin Li
Date: Fri Mar 06 2026 - 22:22:10 EST
> On Mar 6, 2026, at 6:07 PM, Sean Christopherson <seanjc@xxxxxxxxxx> wrote:
>
>> @@ -2231,7 +2232,8 @@ void kvm_queue_exception(struct kvm_vcpu *vcpu, unsigned nr);
>> void kvm_queue_exception_e(struct kvm_vcpu *vcpu, unsigned nr, u32 error_code);
>> void kvm_queue_exception_p(struct kvm_vcpu *vcpu, unsigned nr, unsigned long payload);
>> void kvm_requeue_exception(struct kvm_vcpu *vcpu, unsigned int nr,
>> - bool has_error_code, u32 error_code, u64 event_data);
>> + bool has_error_code, u32 error_code, bool nested,
>
> I think we should pick a different name, as both VMX and SVM declare "nested" as
> a global boolean. I.e. this creates some nasty variable shadowing.
>
> Maybe is_nested?
is_nested looks good to me.
I thought about is_nested_exp, however the function names already contain
“exception”, no point to duplicate it.