On Mon, Feb 03, 2014 at 03:07:33PM +0100, Paolo Bonzini wrote:
> Il 03/02/2014 15:06, Michael S. Tsirkin ha scritto:
> >>Linux seems to be trying to read IA32_PERF_CAPABILITIES without checking the
> >>PDCM flag (CPUID[1].ECX[15]).
> >>
> >>I can't see why this wasn't crashing before, though. That code seems to be
> >>old.
> >>
> >> * v2 and above have a perf capabilities MSR
> >> */
> >> if (version > 1) {
> >> u64 capabilities;
> >>
> >> rdmsrl(MSR_IA32_PERF_CAPABILITIES, capabilities);
> >> x86_pmu.intel_cap.capabilities = capabilities;
> >> }
> >>
> >>Where does the "v2 and above have a perf capabilities MSR" claim in the code
> >>come from?
> >
> >
> >But why doesn't it crash on baremetal?
> >Probably baremetal simply returns 0 or something.
> >Let me try ..
>
> Because KVM doesn't implement the MSR, but your baremetal likely does.
>
> Paolo
Yep. I get 31c3 on bare-metal.
So I suppose the claim is actually true, and ideally kvm should
emulate this instead of crashing guest.
--
MST
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html