Re: [PATCH v19 089/130] KVM: TDX: Add support for find pending IRQ in a protected local APIC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2024-02-26 at 00:26 -0800, isaku.yamahata@xxxxxxxxx wrote:
>  
> +static bool vt_protected_apic_has_interrupt(struct kvm_vcpu *vcpu)
> +{
> +       KVM_BUG_ON(!is_td_vcpu(vcpu), vcpu->kvm);
> +
> +       return tdx_protected_apic_has_interrupt(vcpu);
> +}
> +

There was some internal discussion on whether to drop the KVM_BUG_ON() here, and
then since vt_protected_apic_has_interrupt() would be just a simple call to
tdx_protected_apic_has_interrupt(), just wire in
tdx_protected_apic_has_interrupt() directly.

The reasoning for dropping the KVM_BUG_ON() is that the function has "protected"
in its name so is unlikely to be called in another context. It was apparently
added when the TDX series was still new. But with the more mature series it
doesn't seem likely to find any bugs. The caller checks
vcpu->arch.apic->guest_apic_protected.




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux