Re: [PATCH v4 26/30] KVM: x86: Don't treat interrupts as allowed just because a nested run is pending
From: Yosry Ahmed
Date: Mon Jun 15 2026 - 15:50:01 EST
> > The code makes sense to me but I am trying to make sense of the changelog.
>
> What part (parts?) is confusing? Honest question. I'm trying to reword the
> changelog to make it "better", but I'm failing miserable because I don't know
> what's wrong :-)
1. For kvm_vcpu_has_events() being unaffected, the explanation in
paragraph #3 is focused on the code path from nested_vmx_run() ->
kvm_emulate_halt_noskip(). I don't immediately see how
kvm_arch_vcpu_runnable() is unaffected.
2. More importantly, paragraphs #3 and #4 read like this patch would
regress kvm_vcpu_ready_for_interrupt_injection() and
kvm_vcpu_has_events() if it affected them. Maybe clearly state that
this patch is the right thing to do for these 2 functions as well, but
they are more-or-less unaffected by the bug anyway? For
kvm_vcpu_ready_for_interrupt_injection(), maybe just make it more
clear in paragraph #4 that it currently incorrectly treats interrupts
as allowed in the problematic scenario, but it is not a problem
because ..., and it only results in a spurious exit to userspace (or
not even that?).