]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
perf tests: Test breakpoint overflow signal handler
authorJiri Olsa <jolsa@redhat.com>
Sun, 10 Mar 2013 18:41:10 +0000 (19:41 +0100)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 15 Mar 2013 16:06:10 +0000 (13:06 -0300)
commit5a6bef47b418676546ab86d25631c3cfb9ffaf2a
treefe4a133db664100f4a0e463e192e4a09a845d3df
parent45fa534cffb246872de0cb8af207bea4a09aeb2f
perf tests: Test breakpoint overflow signal handler

Adding automated test for breakpoint event signal handler checking if
it's executed properly.

The test is related to the proper handling of the RF EFLAGS bit on
x86_64, but it's generic for all archs.

First we check the signal handler is properly called and that the
following debug exception return to user space wouldn't trigger
recursive breakpoint.

This is related to x86_64 RF EFLAGS bit being managed in a wrong way.

Second we check that we can set breakpoint in signal handler, which is
not possible on x86_64 if the signal handler is executed with RF EFLAG
set.

This test is inpired by overflow tests done by Vince Weaver.

Signed-off-by: Jiri Olsa <jolsa@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vince Weaver <vincent.weaver@maine.edu>
Link: http://lkml.kernel.org/r/1362940871-24486-6-git-send-email-jolsa@redhat.com
[ committer note: s/pr_err/pr_debug/g i.e. print just OK or FAILED in non verbose mode ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/Makefile
tools/perf/tests/bp_signal.c [new file with mode: 0644]
tools/perf/tests/builtin-test.c
tools/perf/tests/tests.h