Re: [PATCH v2 00/11] Unify TDCALL/SEAMCALL and TDVMCALL assembly

From: Peter Zijlstra
Date: Thu Jul 20 2023 - 09:16:38 EST


On Fri, Jul 21, 2023 at 12:28:03AM +1200, Kai Huang wrote:

> Kai Huang (11):
> x86/tdx: Zero out the missing RSI in TDX_HYPERCALL macro
> x86/tdx: Skip saving output regs when SEAMCALL fails with
> VMFailInvalid
> x86/tdx: Make macros of TDCALLs consistent with the spec
> x86/tdx: Rename __tdx_module_call() to __tdcall()
> x86/tdx: Pass TDCALL/SEAMCALL input/output registers via a structure
> x86/tdx: Extend TDX_MODULE_CALL to support more TDCALL/SEAMCALL leafs
> x86/tdx: Make TDX_HYPERCALL asm similar to TDX_MODULE_CALL
> x86/tdx: Reimplement __tdx_hypercall() using TDX_MODULE_CALL asm
> x86/tdx: Remove 'struct tdx_hypercall_args'
> x86/virt/tdx: Wire up basic SEAMCALL functions
> x86/virt/tdx: Allow SEAMCALL to handle #UD and #GP

These look ok to me, thanks!

This does not yet re-order the args structure to conform to the hardware
index order as per kvm's requirement, right? That will be part of the
KVM series?