diff options
author | Kajol Jain <kjain@linux.ibm.com> | 2021-08-18 20:15:55 +0300 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2021-08-25 15:38:19 +0300 |
commit | cc90c6742ef5b438f4cb86029d7a794bd0a44a06 (patch) | |
tree | 5c27230a6bace8bf164d323536e0ecddec7953da /arch/powerpc/perf | |
parent | b1643084d164cea0c107a39bcdf0119fc52619af (diff) | |
download | linux-cc90c6742ef5b438f4cb86029d7a794bd0a44a06.tar.xz |
powerpc/perf: Drop the case of returning 0 as instruction pointer
Drop the case of returning 0 as instruction pointer since kernel
never executes at 0 and userspace almost never does either.
Fixes: e6878835ac47 ("powerpc/perf: Sample only if SIAR-Valid bit is set in P7+")
Signed-off-by: Kajol Jain <kjain@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20210818171556.36912-2-kjain@linux.ibm.com
Diffstat (limited to 'arch/powerpc/perf')
-rw-r--r-- | arch/powerpc/perf/core-book3s.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/powerpc/perf/core-book3s.c b/arch/powerpc/perf/core-book3s.c index 3a782a35100d..9bb466d2d99e 100644 --- a/arch/powerpc/perf/core-book3s.c +++ b/arch/powerpc/perf/core-book3s.c @@ -2270,8 +2270,6 @@ unsigned long perf_instruction_pointer(struct pt_regs *regs) return regs->nip; } else if (use_siar && siar_valid(regs)) return siar + perf_ip_adjust(regs); - else if (use_siar) - return 0; // no valid instruction pointer else return regs->nip; } |