Re: [PATCH v3 0/4] KVM: TDX: Validate directly configurable CPUID bits

From: Edgecombe, Rick P

Date: Wed Sep 02 2026 - 12:26:01 EST


On Tue, 2026-09-01 at 17:42 +0800, Xiaoyao Li wrote:
> On 8/31/2026 1:01 PM, Binbin Wu wrote:
> > > > So if the approach in this series is taken, I think we still need such
> > > > an opt- in interface to tell the TDX module that the VMM is now
> > > > filtering the CPUID bits so that the TDX module knows that it's safe to
> > > > report new host state clobbering features.
> > > Yep. Can we think about what it would look like? Easiest would be a bit
> > > passed in TDH_SYS_CONFIG. But then arch/x86 is saying how KVM will behave.
> > > Ok to me, for the simplicity. Could come with a nice comment.
>
> Can you just treat current KVM behavior of allowing userspace to enable
> any configurable bits as the bug of KVM and backport this series as
> Binbin suggested below? Instead of introducing more opt-in knobs.

Ok, so if we are agreed on the other branch of the thread, the only big question
is: Do we want an opt-in for future clobbering CPUID bits.

I think either is ok. I don't love the precedent that we asserted that no new
clobber bits could be added without opt-in, and then we would backport changes
to allow this anyway. But on pure code, the backport would be simpler in the
long term. If you guys are strongly in favor, I can agree.

Are we sure no other VMM needs an opt-in, before finalizing it though? Binbin,
can flag this to the TDX module team?