Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Detect TDX Guest when it's virtualised using Hyper-V (#138)
Microsoft has decided to purposefully hide the information of the guest TEE when VMs are being created using Hyper-V. This leads us to check for the Hyper-V cpuid features (0x4000000C), and then for the `ebx` value set. For Intel TDX, `ebx` is set as `0xbe3`, being 3 the part we're mostly interested about,according to: https://github.com/torvalds/linux/blob/d2f51b3516dade79269ff45eae2a7668ae711b25/arch/x86/include/asm/hyperv-tlfs.h#L169-L174 NOTE: On the tests side, we had to manually override the cpuid in order to avoid the tests failing, and this was suggested by Klaus himself. Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
- Loading branch information