summary refs log tree commit diff stats
path: root/python/scripts
diff options
context:
space:
mode:
authorXiaoyao Li <xiaoyao.li@intel.com>2025-05-08 10:59:27 -0400
committerPaolo Bonzini <pbonzini@redhat.com>2025-05-28 19:35:49 +0200
commitf18672e4cf91feed4b91ef85a264a500935a2865 (patch)
tree09efbf27bb4befa2723b3226bbcc83621d94f078 /python/scripts
parent4420ba0ebbf014acc68f78669e0767e288313ed6 (diff)
downloadfocaccia-qemu-f18672e4cf91feed4b91ef85a264a500935a2865.tar.gz
focaccia-qemu-f18672e4cf91feed4b91ef85a264a500935a2865.zip
i386/tdx: Track RAM entries for TDX VM
The RAM of TDX VM can be classified into two types:

 - TDX_RAM_UNACCEPTED: default type of TDX memory, which needs to be
   accepted by TDX guest before it can be used and will be all-zeros
   after being accepted.

 - TDX_RAM_ADDED: the RAM that is ADD'ed to TD guest before running, and
   can be used directly. E.g., TD HOB and TEMP MEM that needed by TDVF.

Maintain TdxRamEntries[] which grabs the initial RAM info from e820 table
and mark each RAM range as default type TDX_RAM_UNACCEPTED.

Then turn the range of TD HOB and TEMP MEM to TDX_RAM_ADDED since these
ranges will be ADD'ed before TD runs and no need to be accepted runtime.

The TdxRamEntries[] are later used to setup the memory TD resource HOB
that passes memory info from QEMU to TDVF.

Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
Acked-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Zhao Liu <zhao1.liu@intel.com>
Link: https://lore.kernel.org/r/20250508150002.689633-22-xiaoyao.li@intel.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'python/scripts')
0 files changed, 0 insertions, 0 deletions