Re: [RFC PATCH 06/15] x86/virt/tdx: Initialize Quoting extension during bringup
From: Peter Fang
Date: Sun Jun 14 2026 - 03:21:06 EST
On Thu, Jun 11, 2026 at 07:22:18PM +0300, Adrian Hunter wrote:
> On 22/05/2026 06:41, Xu Yilun wrote:
> > From: Peter Fang <peter.fang@xxxxxxxxx>
> >
> > Initialize the Quoting extension and fetch its metadata during TDX
> > bringup.
> >
> > Because Quoting is an optional TDX feature, do not let its
> > initialization failures cause TDX bringup to fail.
>
> Is there a reason Linux needs to support TDX with failed Quote
> extension initialization?
The Quoting extension is not the only way to get TD Quotes. If this
extension fails, the host can still fall back to the legacy SGX-based
Quoting in userspace. I think the decision to actually fall back can be
left to userspace at that point.
>
> > +static void tdx_quote_init(void)
> > +{
> > + struct tdx_module_args args = {};
> > + u64 r;
> > +
> > + do {
> > + r = seamcall(TDH_QUOTE_INIT, &args);
> > + } while (r == TDX_INTERRUPTED_RESUMABLE);
> > +
> > + if (r)
>
> Elsewhere it tends to be:
>
> if (r != TDX_SUCCESS)
Good catch. I'll fix this. Thanks!
>