diff options
author | Bodo Stroesser <bstroesser@fujitsu-siemens.com> | 2005-09-03 18:57:19 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@evo.osdl.org> | 2005-09-05 03:06:20 -0400 |
commit | c8c86cecd1d1a2722acb28a01d1babf7b6993697 (patch) | |
tree | e51097940d245b298278ffaac27d2992b0ac257b /arch/i386/kernel/entry.S | |
parent | ed75e8d58010fdc06e2c3a81bfbebae92314c7e3 (diff) |
[PATCH] Uml support: reorganize PTRACE_SYSEMU support
With this patch, we change the way we handle switching from PTRACE_SYSEMU to
PTRACE_{SINGLESTEP,SYSCALL}, to free TIF_SYSCALL_EMU from double use as a
preparation for PTRACE_SYSEMU_SINGLESTEP extension, without changing the
behavior of the host kernel.
Signed-off-by: Bodo Stroesser <bstroesser@fujitsu-siemens.com>
Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/i386/kernel/entry.S')
-rw-r--r-- | arch/i386/kernel/entry.S | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/i386/kernel/entry.S b/arch/i386/kernel/entry.S index b389e5f3bdee..9a47723469c6 100644 --- a/arch/i386/kernel/entry.S +++ b/arch/i386/kernel/entry.S | |||
@@ -339,12 +339,18 @@ syscall_trace_entry: | |||
339 | xorl %edx,%edx | 339 | xorl %edx,%edx |
340 | call do_syscall_trace | 340 | call do_syscall_trace |
341 | cmpl $0, %eax | 341 | cmpl $0, %eax |
342 | jne syscall_exit # ret != 0 -> running under PTRACE_SYSEMU, | 342 | jne syscall_skip # ret != 0 -> running under PTRACE_SYSEMU, |
343 | # so must skip actual syscall | 343 | # so must skip actual syscall |
344 | movl ORIG_EAX(%esp), %eax | 344 | movl ORIG_EAX(%esp), %eax |
345 | cmpl $(nr_syscalls), %eax | 345 | cmpl $(nr_syscalls), %eax |
346 | jnae syscall_call | 346 | jnae syscall_call |
347 | jmp syscall_exit | 347 | jmp syscall_exit |
348 | syscall_skip: | ||
349 | cli # make sure we don't miss an interrupt | ||
350 | # setting need_resched or sigpending | ||
351 | # between sampling and the iret | ||
352 | movl TI_flags(%ebp), %ecx | ||
353 | jmp work_pending | ||
348 | 354 | ||
349 | # perform syscall exit tracing | 355 | # perform syscall exit tracing |
350 | ALIGN | 356 | ALIGN |