Re: [PATCH 1/2] x86/tdx: Add helper to query maximum TD Quote size
From: Xiaoyao Li
Date: Thu Jul 02 2026 - 06:24:38 EST
On 6/23/2026 12:44 PM, Peter Fang wrote:
On Fri, Jun 12, 2026 at 10:25:03PM +0800, Xiaoyao Li wrote:
Assisted-by: Claude:claude-opus-4-7
Assisted-by: GitHub Copilot:gpt-5.4
Signed-off-by: Peter Fang <peter.fang@xxxxxxxxx>
Reviewed-by: Xiaoyao Li <xiaoyao.li@xxxxxxxxx>
Thanks for the review Xiaoyao!
I have another nit other than Kiryl's
+u32 tdx_get_max_quote_size(void)
+{
+ u64 val, ret;
+
+ ret = tdg_vm_rd(TDCS_QUOTE_MAX_SIZE, &val);
+
+ return ret ? 0 : (u32)val;
+}
+EXPORT_SYMBOL_GPL(tdx_get_max_quote_size);
Do we need to start to use
EXPORT_SYMBOL_FOR_MODULES(tdx_get_max_quote_size, "tdx-guest") ?
This makes sense. But can we use a follow-up patch to improve this file
later? Right now there are only EXPORT_SYMBOL_GPL() usages, so using
EXPORT_SYMBOL_FOR_MODULES() here might look inconsistent.
If maintainers is going to merge the series as-is, then fine.
If we will have a v2, I don't see why cannot update to use EXPORT_SYMBOL_FOR_MODULES().
The existing ones can be updated in a separate patch before or after.