Skip to content

Commit ed30285

Browse files
calmisibonzini
authored andcommitted
KVM: TDX: Don't report base TDVMCALLs
Remove TDVMCALLINFO_GET_QUOTE from user_tdvmcallinfo_1_r11 reported to userspace to align with the direction of the GHCI spec. Recently, concern was raised about a gap in the GHCI spec that left ambiguity in how to expose to the guest that only a subset of GHCI TDVMCalls were supported. During the back and forth on the spec details[0], <GetQuote> was moved from an individually enumerable TDVMCall, to one that is part of the 'base spec', meaning it doesn't have a specific bit in the <GetTDVMCallInfo> return values. Although the spec[1] is still in draft form, the GetQoute part has been agreed by the major TDX VMMs. Unfortunately the commits that were upstreamed still treat <GetQuote> as individually enumerable. They set bit 0 in the user_tdvmcallinfo_1_r11 which is reported to userspace to tell supported optional TDVMCalls, intending to say that <GetQuote> is supported. So stop reporting <GetQute> in user_tdvmcallinfo_1_r11 to align with the direction of the spec, and allow some future TDVMCall to use that bit. [0] https://lore.kernel.org/all/[email protected]/ [1] https://cdrdv2.intel.com/v1/dl/getContent/858626 Fixes: 28224ef ("KVM: TDX: Report supported optional TDVMCALLs in TDX capabilities") Signed-off-by: Xiaoyao Li <[email protected]> Message-ID: <[email protected]> Signed-off-by: Paolo Bonzini <[email protected]>
1 parent 709ea4a commit ed30285

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

arch/x86/kvm/vmx/tdx.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,6 @@ static void td_init_cpuid_entry2(struct kvm_cpuid_entry2 *entry, unsigned char i
173173
tdx_clear_unsupported_cpuid(entry);
174174
}
175175

176-
#define TDVMCALLINFO_GET_QUOTE BIT(0)
177176
#define TDVMCALLINFO_SETUP_EVENT_NOTIFY_INTERRUPT BIT(1)
178177

179178
static int init_kvm_tdx_caps(const struct tdx_sys_info_td_conf *td_conf,
@@ -192,7 +191,6 @@ static int init_kvm_tdx_caps(const struct tdx_sys_info_td_conf *td_conf,
192191
caps->cpuid.nent = td_conf->num_cpuid_config;
193192

194193
caps->user_tdvmcallinfo_1_r11 =
195-
TDVMCALLINFO_GET_QUOTE |
196194
TDVMCALLINFO_SETUP_EVENT_NOTIFY_INTERRUPT;
197195

198196
for (i = 0; i < td_conf->num_cpuid_config; i++)

0 commit comments

Comments
 (0)