]> git.neil.brown.name Git - history.git/commit
[PATCH] ppc64: fix single-stepping into/out of signal handlers
authorPaul Mackerras <paulus@samba.org>
Fri, 17 Dec 2004 01:19:57 +0000 (17:19 -0800)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Fri, 17 Dec 2004 01:19:57 +0000 (17:19 -0800)
commit44e0a901c266f940ab4bd4c37b10f0af5de4e03b
tree549fc38fd23539bcf001b20f8c7665bafb81e36c
parentb832c33597ae7acc7448614e305733aa98713b82
[PATCH] ppc64: fix single-stepping into/out of signal handlers

This is the second of 3 patches from David Woodhouse which fix various
problems with signal handling on ppc64.

The problem that this patch fixes is that a process being single-stepped
will execute one instruction too many in certain cases: when a signal is
delivered, when a signal handler returns, and when a system call
instruction is single-stepped.  This patch fixes it by checking if the
process is being single-stepped in the syscall exit path and on signal
delivery, and stopping it if so.  To avoid slowing down the syscall exit
path in the normal case, we use a bit in the thread_info flags, which can
be tested along with the other bits we already test in the syscall exit
path.

Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/ppc64/kernel/entry.S
arch/ppc64/kernel/ptrace.c
arch/ppc64/kernel/signal.c
arch/ppc64/kernel/signal32.c
include/asm-ppc64/ptrace-common.h
include/asm-ppc64/thread_info.h