aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kernel/ptrace_32.c57
1 files changed, 0 insertions, 57 deletions
diff --git a/arch/x86/kernel/ptrace_32.c b/arch/x86/kernel/ptrace_32.c
index bc7fd802dcc7..bd3668c2421a 100644
--- a/arch/x86/kernel/ptrace_32.c
+++ b/arch/x86/kernel/ptrace_32.c
@@ -277,63 +277,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data)
277 } 277 }
278 break; 278 break;
279 279
280 case PTRACE_SYSEMU: /* continue and stop at next syscall, which will not be executed */
281 case PTRACE_SYSCALL: /* continue and stop at next (return from) syscall */
282 case PTRACE_CONT: /* restart after signal. */
283 ret = -EIO;
284 if (!valid_signal(data))
285 break;
286 if (request == PTRACE_SYSEMU) {
287 set_tsk_thread_flag(child, TIF_SYSCALL_EMU);
288 clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
289 } else if (request == PTRACE_SYSCALL) {
290 set_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
291 clear_tsk_thread_flag(child, TIF_SYSCALL_EMU);
292 } else {
293 clear_tsk_thread_flag(child, TIF_SYSCALL_EMU);
294 clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
295 }
296 child->exit_code = data;
297 /* make sure the single step bit is not set. */
298 user_disable_single_step(child);
299 wake_up_process(child);
300 ret = 0;
301 break;
302
303/*
304 * make the child exit. Best I can do is send it a sigkill.
305 * perhaps it should be put in the status that it wants to
306 * exit.
307 */
308 case PTRACE_KILL:
309 ret = 0;
310 if (child->exit_state == EXIT_ZOMBIE) /* already dead */
311 break;
312 child->exit_code = SIGKILL;
313 /* make sure the single step bit is not set. */
314 user_disable_single_step(child);
315 wake_up_process(child);
316 break;
317
318 case PTRACE_SYSEMU_SINGLESTEP: /* Same as SYSEMU, but singlestep if not syscall */
319 case PTRACE_SINGLESTEP: /* set the trap flag. */
320 ret = -EIO;
321 if (!valid_signal(data))
322 break;
323
324 if (request == PTRACE_SYSEMU_SINGLESTEP)
325 set_tsk_thread_flag(child, TIF_SYSCALL_EMU);
326 else
327 clear_tsk_thread_flag(child, TIF_SYSCALL_EMU);
328
329 clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
330 user_enable_single_step(child);
331 child->exit_code = data;
332 /* give it a chance to run. */
333 wake_up_process(child);
334 ret = 0;
335 break;
336
337 case PTRACE_GETREGS: { /* Get all gp regs from the child. */ 280 case PTRACE_GETREGS: { /* Get all gp regs from the child. */
338 if (!access_ok(VERIFY_WRITE, datap, FRAME_SIZE*sizeof(long))) { 281 if (!access_ok(VERIFY_WRITE, datap, FRAME_SIZE*sizeof(long))) {
339 ret = -EIO; 282 ret = -EIO;