perf/x86/intel: Fix rdlbr_to() MSR reading typo
authorPeter Zijlstra <peterz@infradead.org>
Thu, 30 Jun 2016 09:49:08 +0000 (11:49 +0200)
committerIngo Molnar <mingo@kernel.org>
Thu, 7 Jul 2016 07:03:28 +0000 (09:03 +0200)
It helps to actually read the right MSR..

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vince Weaver <vincent.weaver@maine.edu>
Cc: linux-kernel@vger.kernel.org
Fixes: d4cf1949f968 ("perf/x86/intel: Add {rd,wr}lbr_{to,from} wrappers")
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/events/intel/lbr.c

index cc4555a9e8760ea898ba737677a0099dabcd09c2..707d358e0dff59ed5871bc49ceda0462c4f818be 100644 (file)
@@ -323,7 +323,7 @@ static inline u64 rdlbr_to(unsigned int idx)
 {
        u64 val;
 
-       rdmsrl(x86_pmu.lbr_from + idx, val);
+       rdmsrl(x86_pmu.lbr_to + idx, val);
 
        return val;
 }