RE: [PATCH v3A 1/6] target/i386: add support for FRED in CPUID enumeration

Li, Xin3
2023-12-22T08:24:59Z

> > > NULL, NULL, NULL, NULL, @@ -1552,6 +1552,14 @@ static
> > > FeatureDep feature_dependencies[] = {
> > > .from = { FEAT_VMX_SECONDARY_CTLS,
> VMX_SECONDARY_EXEC_ENABLE_USER_WAIT_PAUSE },
> > > .to = { FEAT_7_0_ECX, CPUID_7_0_ECX_WAITPKG },
> > > },
> > > + {
> > > + .from = { FEAT_7_1_EAX, CPUID_7_1_EAX_LKGS },
> > > + .to = { FEAT_7_1_EAX, CPUID_7_1_EAX_FRED },
> > > + },
> > > + {
> > > + .from = { FEAT_7_1_EAX, CPUID_7_1_EAX_WRMSRNS },
> > > + .to = { FEAT_7_1_EAX, CPUID_7_1_EAX_FRED },
> > > + },
>
> Oh, sorry, one thing that comes to mind, is this dependency required?
> Since the FRED spec (v3.0) is all about WRMSR as the example, without
> mentioning WRMSRNS, could there be other implementations that depend on
> WRMSR instead of WRMSRNS?

This is a community ask from tglx:
https://lkml.kernel.org/kvm/87y1h81ht4.ffs@tglx/

Boris had the same question:
https://lore.kernel.org/lkml/20231114050201.GAZVL%2FSd%2FyLIdON9la@fat_crate.local/

But it needs to go through a formal approach, which takes time, to reach
the FRED public spec.

Thanks!
Xin