diff options
author | Ingo Molnar <mingo@kernel.org> | 2013-09-28 17:48:48 +0400 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2013-09-28 17:48:48 +0400 |
commit | 8a3da6c7d0031fcb6a0d17f9c7a68b0e01f52855 (patch) | |
tree | b312e40b52ceebb7d61a6a54f22dc231d4c15c55 | |
parent | c1bf21455d7053ad996426a4783745cf3592a5f3 (diff) | |
download | linux-8a3da6c7d0031fcb6a0d17f9c7a68b0e01f52855.tar.xz |
perf/x86: Fix PMU detection printout when no PMU is detected
Ran into this cryptic PMU bootup log recently:
[ 0.124047] Performance Events:
[ 0.125000] smpboot: ...
Turns out we print this if no PMU is detected. Fall back to
the right condition so that the following is printed:
[ 0.122381] Performance Events: no PMU driver, software events only.
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Link: http://lkml.kernel.org/n/tip-u2fwaUffakjp0qkpRfqljgsn@git.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r-- | arch/x86/kernel/cpu/perf_event.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/cpu/perf_event.c b/arch/x86/kernel/cpu/perf_event.c index a9c606bb4945..897783b3302a 100644 --- a/arch/x86/kernel/cpu/perf_event.c +++ b/arch/x86/kernel/cpu/perf_event.c @@ -1506,7 +1506,7 @@ static int __init init_hw_perf_events(void) err = amd_pmu_init(); break; default: - return 0; + err = -ENOTSUPP; } if (err != 0) { pr_cont("no PMU driver, software events only.\n"); |