Hi, > - The supported XCR0 and XSS bits needs to be cap'ed by tdx_caps, because > KVM uses them to setup XFAM of TD. > + case 0xd: > + if (index == 0) { > + if (reg == R_EAX) { > + *ret &= (uint32_t)tdx_caps->xfam_fixed0 & XCR0_MASK; > + *ret |= (uint32_t)tdx_caps->xfam_fixed1 & XCR0_MASK; > + } else if (reg == R_EDX) { > + *ret &= (tdx_caps->xfam_fixed0 & XCR0_MASK) >> 32; > + *ret |= (tdx_caps->xfam_fixed1 & XCR0_MASK) >> 32; > + } > + } else if (index == 1) { > + /* TODO: Adjust XSS when it's supported. */ > + } > + break; > + default: > + /* TODO: Use tdx_caps to adjust CPUID leafs. */ > + break; Hmm, that looks all a bit messy and incomplete, also the commit message doesn't match the patch (describes XSS which isn't actually implemented). take care, Gerd