https://github.com/torvalds/linux
Revision c9b08884c9c98929ec2d8abafd78e89062d01ee7 authored by Peter Zijlstra on 03 February 2014, 13:29:03 UTC, committed by Thomas Gleixner on 21 February 2014, 21:09:01 UTC
The current code simply assumes Intel Arch PerfMon v2+ to have
the IA32_PERF_CAPABILITIES MSR; the SDM specifies that we should check
CPUID[1].ECX[15] (aka, FEATURE_PDCM) instead.

This was found by KVM which implements v2+ but didn't provide the
capabilities MSR. Change the code to DTRT; KVM will also implement the
MSR and return 0.

Cc: pbonzini@redhat.com
Reported-by: "Michael S. Tsirkin" <mst@redhat.com>
Suggested-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20140203132903.GI8874@twins.programming.kicks-ass.net
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
1 parent a3ef222
History
Tip revision: c9b08884c9c98929ec2d8abafd78e89062d01ee7 authored by Peter Zijlstra on 03 February 2014, 13:29:03 UTC
perf/x86: Correctly use FEATURE_PDCM
Tip revision: c9b0888
File Mode Size
Kconfig -rw-r--r-- 59.6 KB
Makefile -rw-r--r-- 1.1 KB
calibrate.c -rw-r--r-- 8.3 KB
do_mounts.c -rw-r--r-- 14.3 KB
do_mounts.h -rw-r--r-- 1.4 KB
do_mounts_initrd.c -rw-r--r-- 3.4 KB
do_mounts_md.c -rw-r--r-- 8.2 KB
do_mounts_rd.c -rw-r--r-- 8.6 KB
init_task.c -rw-r--r-- 728 bytes
initramfs.c -rw-r--r-- 13.0 KB
main.c -rw-r--r-- 22.7 KB
noinitramfs.c -rw-r--r-- 1.5 KB
version.c -rw-r--r-- 1.2 KB

back to top