diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-04-14 19:58:38 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-04-14 19:58:38 -0400 |
commit | 07c7016de7896493e95bef64fe913ac849509d6e (patch) | |
tree | a4e2827002e649b2555b5575974b6c03d82e371a | |
parent | d295917a47e99fe43f1efb14261612e67120e4bb (diff) | |
parent | f2200ac311302fcdca6556fd0c5127eab6c65a3e (diff) |
Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull perf fixes from Thomas Gleixner:
"Two small fixes for perf:
- the move to support cross arch annotation introduced per arch
initialization requirements, fullfill them for s/390 (Christian
Borntraeger)
- add the missing initialization to the LBR entries to avoid exposing
random or stale data"
* 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
perf/x86: Avoid exposing wrong/stale data in intel_pmu_lbr_read_32()
perf annotate s390: Fix perf annotate error -95 (4.10 regression)
-rw-r--r-- | arch/x86/events/intel/lbr.c | 3 | ||||
-rw-r--r-- | tools/perf/util/annotate.c | 6 |
2 files changed, 9 insertions, 0 deletions
diff --git a/arch/x86/events/intel/lbr.c b/arch/x86/events/intel/lbr.c index 81b321ace8e0..f924629836a8 100644 --- a/arch/x86/events/intel/lbr.c +++ b/arch/x86/events/intel/lbr.c | |||
@@ -507,6 +507,9 @@ static void intel_pmu_lbr_read_32(struct cpu_hw_events *cpuc) | |||
507 | cpuc->lbr_entries[i].to = msr_lastbranch.to; | 507 | cpuc->lbr_entries[i].to = msr_lastbranch.to; |
508 | cpuc->lbr_entries[i].mispred = 0; | 508 | cpuc->lbr_entries[i].mispred = 0; |
509 | cpuc->lbr_entries[i].predicted = 0; | 509 | cpuc->lbr_entries[i].predicted = 0; |
510 | cpuc->lbr_entries[i].in_tx = 0; | ||
511 | cpuc->lbr_entries[i].abort = 0; | ||
512 | cpuc->lbr_entries[i].cycles = 0; | ||
510 | cpuc->lbr_entries[i].reserved = 0; | 513 | cpuc->lbr_entries[i].reserved = 0; |
511 | } | 514 | } |
512 | cpuc->lbr_stack.nr = i; | 515 | cpuc->lbr_stack.nr = i; |
diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c index 273f21fa32b5..7aa57225cbf7 100644 --- a/tools/perf/util/annotate.c +++ b/tools/perf/util/annotate.c | |||
@@ -130,6 +130,12 @@ static struct arch architectures[] = { | |||
130 | .name = "powerpc", | 130 | .name = "powerpc", |
131 | .init = powerpc__annotate_init, | 131 | .init = powerpc__annotate_init, |
132 | }, | 132 | }, |
133 | { | ||
134 | .name = "s390", | ||
135 | .objdump = { | ||
136 | .comment_char = '#', | ||
137 | }, | ||
138 | }, | ||
133 | }; | 139 | }; |
134 | 140 | ||
135 | static void ins__delete(struct ins_operands *ops) | 141 | static void ins__delete(struct ins_operands *ops) |