[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z6xX6PCjW0PZe59D@intel.com>
Date: Wed, 12 Feb 2025 16:12:24 +0800
From: Chao Gao <chao.gao@...el.com>
To: Binbin Wu <binbin.wu@...ux.intel.com>
CC: <pbonzini@...hat.com>, <seanjc@...gle.com>, <kvm@...r.kernel.org>,
<rick.p.edgecombe@...el.com>, <kai.huang@...el.com>,
<adrian.hunter@...el.com>, <reinette.chatre@...el.com>,
<xiaoyao.li@...el.com>, <tony.lindgren@...el.com>,
<isaku.yamahata@...el.com>, <yan.y.zhao@...el.com>,
<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 01/17] KVM: TDX: Add support for find pending IRQ in a
protected local APIC
>diff --git a/arch/x86/kvm/vmx/main.c b/arch/x86/kvm/vmx/main.c
>index 7f1318c44040..2b1ea57a3a4e 100644
>--- a/arch/x86/kvm/vmx/main.c
>+++ b/arch/x86/kvm/vmx/main.c
>@@ -62,6 +62,8 @@ static __init int vt_hardware_setup(void)
> vt_x86_ops.set_external_spte = tdx_sept_set_private_spte;
> vt_x86_ops.free_external_spt = tdx_sept_free_private_spt;
> vt_x86_ops.remove_external_spte = tdx_sept_remove_private_spte;
Nit: I think it would be more consistent to set up .protected_apic_has_interrupt
if TDX is enabled (rather than clearing it if TDX is disabled).
>+ } else {
>+ vt_x86_ops.protected_apic_has_interrupt = NULL;
> }
>
> return 0;
>@@ -371,6 +373,7 @@ struct kvm_x86_ops vt_x86_ops __initdata = {
> .sync_pir_to_irr = vmx_sync_pir_to_irr,
> .deliver_interrupt = vmx_deliver_interrupt,
> .dy_apicv_has_pending_interrupt = pi_has_pending_interrupt,
>+ .protected_apic_has_interrupt = tdx_protected_apic_has_interrupt,
>
> .set_tss_addr = vmx_set_tss_addr,
> .set_identity_map_addr = vmx_set_identity_map_addr,
Powered by blists - more mailing lists