diff options
author | Madhavan Srinivasan <maddy@linux.vnet.ibm.com> | 2017-01-18 09:12:56 +0530 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2017-01-18 16:15:58 +1100 |
commit | 27593d72c4ad451ed13af35354b941bcd0abcec6 (patch) | |
tree | 8be5796f02aa106470bb24138672e60bb91a3760 /arch/powerpc/perf/core-book3s.c | |
parent | df21d2fa733035e4d414379960f94b2516b41296 (diff) | |
download | linux-stable-27593d72c4ad451ed13af35354b941bcd0abcec6.tar.gz linux-stable-27593d72c4ad451ed13af35354b941bcd0abcec6.tar.bz2 linux-stable-27593d72c4ad451ed13af35354b941bcd0abcec6.zip |
powerpc/perf: Use MSR to report privilege level on P9 DD1
SIER and SIAR are not updated correctly for some samples, so force the
use of MSR and regs->nip instead for misc_flag updates. This is done by
adding a new ppmu flag and updating the use_siar logic in
perf_read_regs() to use it, and dropping the PPMU_HAS_SIER flag.
Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
[mpe: Rename flag to PPMU_NO_SIAR, and also drop PPMU_HAS_SIER]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/perf/core-book3s.c')
-rw-r--r-- | arch/powerpc/perf/core-book3s.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/perf/core-book3s.c b/arch/powerpc/perf/core-book3s.c index fd3e4034c04d..270eb9b74e2e 100644 --- a/arch/powerpc/perf/core-book3s.c +++ b/arch/powerpc/perf/core-book3s.c @@ -295,6 +295,8 @@ static inline void perf_read_regs(struct pt_regs *regs) */ if (TRAP(regs) != 0xf00) use_siar = 0; + else if ((ppmu->flags & PPMU_NO_SIAR)) + use_siar = 0; else if (marked) use_siar = 1; else if ((ppmu->flags & PPMU_NO_CONT_SAMPLING)) |