2005-04-17 02:20:36 +04:00
|
|
|
/*
|
2007-10-16 12:27:00 +04:00
|
|
|
* Copyright (C) 2000 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
|
2005-04-17 02:20:36 +04:00
|
|
|
* Licensed under the GPL
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __UM_PTRACE_GENERIC_H
|
|
|
|
#define __UM_PTRACE_GENERIC_H
|
|
|
|
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
|
2008-08-18 08:19:01 +04:00
|
|
|
#include <asm/ptrace-abi.h>
|
2012-10-08 06:27:32 +04:00
|
|
|
#include <sysdep/ptrace.h>
|
2005-04-17 02:20:36 +04:00
|
|
|
|
|
|
|
struct pt_regs {
|
2007-10-16 12:26:58 +04:00
|
|
|
struct uml_pt_regs regs;
|
2005-04-17 02:20:36 +04:00
|
|
|
};
|
|
|
|
|
2010-03-11 02:22:56 +03:00
|
|
|
#define arch_has_single_step() (1)
|
|
|
|
|
2006-03-31 14:30:15 +04:00
|
|
|
#define EMPTY_REGS { .regs = EMPTY_UML_PT_REGS }
|
2005-04-17 02:20:36 +04:00
|
|
|
|
|
|
|
#define PT_REGS_IP(r) UPT_IP(&(r)->regs)
|
|
|
|
#define PT_REGS_SP(r) UPT_SP(&(r)->regs)
|
|
|
|
|
|
|
|
#define PT_REGS_RESTART_SYSCALL(r) UPT_RESTART_SYSCALL(&(r)->regs)
|
|
|
|
|
|
|
|
#define PT_REGS_SYSCALL_NR(r) UPT_SYSCALL_NR(&(r)->regs)
|
|
|
|
|
|
|
|
#define instruction_pointer(regs) PT_REGS_IP(regs)
|
|
|
|
|
|
|
|
struct task_struct;
|
|
|
|
|
2010-11-12 01:05:04 +03:00
|
|
|
extern long subarch_ptrace(struct task_struct *child, long request,
|
|
|
|
unsigned long addr, unsigned long data);
|
2005-04-17 02:20:36 +04:00
|
|
|
extern unsigned long getreg(struct task_struct *child, int regno);
|
|
|
|
extern int putreg(struct task_struct *child, int regno, unsigned long value);
|
|
|
|
|
2006-03-31 14:30:22 +04:00
|
|
|
extern int arch_copy_tls(struct task_struct *new);
|
|
|
|
extern void clear_flushed_tls(struct task_struct *task);
|
2012-05-23 08:18:33 +04:00
|
|
|
extern void syscall_trace_enter(struct pt_regs *regs);
|
|
|
|
extern void syscall_trace_leave(struct pt_regs *regs);
|
2005-04-17 02:20:36 +04:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|
2006-03-31 14:30:22 +04:00
|
|
|
#endif
|