On 18/08/2020 10:34, Olaf Hering wrote:
> Since commit 6b85e427098cce1a6d386b3bae2f0c7ce86e47f7 'xen-cpuid -p' shows 
> the cpuid policies. I think these policies define what a domU will get to see 
> when cpuid() is invoked, or when MSRs are accessed.

Only a subset of the read-only MSRs - those which effectively behave
like further feature information.

0xce is Intel-only MSR which we actually advertise consistently, to
offer CPUID faulting capabilities to VMs.

Future MSRs are going to be MSR_ARCH_CAPS (when we've got the toostack
side of the work done), then MSR_FEATURE_CONTROL and all the VMX MSRs
for Intel nested virt.

> Unfortunately this commit shows only the raw hex values, which makes it 
> difficult to compare output from different physical hosts. I think the actual 
> policy values could be shown in expanded form, similar to what 'xen-cpuid -d' 
> would show.
>
> Did you ever consider to show the expanded form for policies?

Using a bit of sed, you can transform the CPUID part into something
which `cpuid` can interpret and decode.  I'm not aware of anything for
the MSR side yet.

As always, xen-cpuid is a debug tool, and tends to only gain new
functionality on an as-time-permits basis.  I do have a few vague plans
to extend it, but they are definitely not higher priority than getting
MSR_ARCH_CAPS working.

~Andrew

Reply via email to