On Thu, Oct 25, 2018 at 11:06:59AM +0800, Robert Hoo wrote: > On Wed, 2018-10-24 at 07:16 -0300, Eduardo Habkost wrote: [...] > > > + struct { /*CPUID that enumerate this MSR*/ > > > + FeatureWord cpuid_class; > > > + uint32_t cpuid_flag; > > > + } cpuid_dep; > > > > Aren't you going to use this field anywhere? Probably we want to > > prevent the VM from starting if a bit is set in the feature world > > but the cpuid_dep bit is not set. > > > > e.g.: > > qemu-system-x86_64 -cpu Skylake-Client,-arch-capabilities,+rsba > > probably should fail to start. > > How about in x86_cpu_filter_features() filters the MSR feature word, if > its dependent CPUID feature bit is not set? > The filter results will be record in cpu->filtered_features, and print > out, like other filtered features.
Sounds good to me. -- Eduardo