Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

perf/x86/64: Do report user_regs->cx while we are in syscall, in get_regs_user()

Yes, it is true that cx contains return address.
It's not clear why we trash it.
Stop doing that.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1428671219-29341-2-git-send-email-dvlasenk@redhat.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>

authored by

Denys Vlasenko and committed by
Ingo Molnar
5df71b39 aa21df04

-2
-2
arch/x86/kernel/perf_regs.c
··· 177 177 * than just blindly copying user_regs. 178 178 */ 179 179 regs_user->abi = PERF_SAMPLE_REGS_ABI_64; 180 - /* usually contains return address (same as ->ip) */ 181 - regs_user_copy->cx = -1; 182 180 } else { 183 181 /* We're probably in an interrupt or exception. */ 184 182 regs_user->abi = user_64bit_mode(user_regs) ?