Re: [PATCH v3 02/10] x86/virt/tdx: Convert the version metadata reader

From: Edgecombe, Rick P

Date: Wed Sep 30 2026 - 20:36:56 EST


On Tue, 2026-09-29 at 22:38 -0700, Chao Gao wrote:
> With the helper to read a table of metadata fields in place, the
> existing metadata readers can be standardized on it.
>
> Convert the version metadata reader: add a table that pairs each field ID
> with the 'struct tdx_sys_info_version' member that holds its value, and
> read all version fields by walking that table.
>
> Name the field IDs for readability, so the table entries don't carry raw
> hex literals.
>
> AI was used under supervision to review code and workshop logs.
>
> Signed-off-by: Chao Gao <chao.gao@xxxxxxxxx>
> ---
Reviewed-by: Rick Edgecombe <rick.p.edgecombe@xxxxxxxxx>