Re: [PATCH v15 18/23] KVM: selftests: Add helpers to init TDX memory and finalize VM
From: Xiaoyao Li
Date: Mon Oct 12 2026 - 01:15:02 EST
On 10/2/2026 3:37 AM, Lisa Wang wrote:
> From: Ackerley Tng <ackerleytng@xxxxxxxxxx>
>
> TDX protected memory needs to be measured and encrypted before it can be
> used by the guest. Traverse the VM's memory regions and initialize all
> the protected ranges by calling KVM_TDX_INIT_MEM_REGION.
>
> Once all the memory is initialized, the VM can be finalized by calling
> KVM_TDX_FINALIZE_VM.
>
> Co-developed-by: Erdem Aktas <erdemaktas@xxxxxxxxxx>
> Signed-off-by: Erdem Aktas <erdemaktas@xxxxxxxxxx>
> Co-developed-by: Sagi Shahar <sagis@xxxxxxxxxx>
> Signed-off-by: Sagi Shahar <sagis@xxxxxxxxxx>
> Co-developed-by: Lisa Wang <wyihan@xxxxxxxxxx>
> Signed-off-by: Lisa Wang <wyihan@xxxxxxxxxx>
> Signed-off-by: Ackerley Tng <ackerleytng@xxxxxxxxxx>
> Reviewed-by: Binbin Wu <binbin.wu@xxxxxxxxxxxxxxx>
> Reviewed-by: Ira Weiny <ira.weiny@xxxxxxxxx>
Reviewed-by: Xiaoyao Li <xiaoyao.li@xxxxxxxxx>