[lkml]   [2019]   [Dec]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH v4 11/19] x86/cpu: Print VMX flags in /proc/cpuinfo using VMX_FEATURES_*

> On 12 Dec 2019, at 19:47, Paolo Bonzini <> wrote:
> On 12/12/19 18:43, Sean Christopherson wrote:
>> Key word being "usually". My intent in printing out partially redundant
>> flags was to help users debug/understand why the combined feature isn't
>> supported. E.g. userspace can already easily (relatively speaking) query
>> flexpriority support via /sys/module/kvm_intel/parameters/flexpriority.
>> But if that comes back "N", the user has no way to determine exactly why
>> flexpriority is disabled.
> There are tools such as vmxcap. It is part of QEMU, but I wouldn't mind
> moving it into the kernel tree.
> Paolo

True. But it relies on /dev/msr0 (exposed from msr kernel module) to be able to read any host arbitrary MSR.
It’s much more elegant to just report CPU VMX features in a /proc/cpuinfo pseudo-file and don’t require strong privileges.
Why should CPU VMX features be treated differently than standard CPUID deduced features?
CPU SVM features are also present in /proc/cpuinfo today (Because they are deduced from CPUID leafs). So it should be similar.

 \ /
  Last update: 2019-12-12 18:56    [W:0.079 / U:2.684 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site