| 1 | #ifndef _LINUX_PTRACE_H |
|---|
| 2 | #define _LINUX_PTRACE_H |
|---|
| 3 | /* ptrace.h */ |
|---|
| 4 | /* structs and defines to help the user use the ptrace system call. */ |
|---|
| 5 | |
|---|
| 6 | /* has the defines to get at the registers. */ |
|---|
| 7 | |
|---|
| 8 | #define PTRACE_TRACEME 0 |
|---|
| 9 | #define PTRACE_PEEKTEXT 1 |
|---|
| 10 | #define PTRACE_PEEKDATA 2 |
|---|
| 11 | #define PTRACE_PEEKUSR 3 |
|---|
| 12 | #define PTRACE_POKETEXT 4 |
|---|
| 13 | #define PTRACE_POKEDATA 5 |
|---|
| 14 | #define PTRACE_POKEUSR 6 |
|---|
| 15 | #define PTRACE_CONT 7 |
|---|
| 16 | #define PTRACE_KILL 8 |
|---|
| 17 | #define PTRACE_SINGLESTEP 9 |
|---|
| 18 | |
|---|
| 19 | #define PTRACE_ATTACH 0x10 |
|---|
| 20 | #define PTRACE_DETACH 0x11 |
|---|
| 21 | |
|---|
| 22 | #define PTRACE_SYSCALL 24 |
|---|
| 23 | |
|---|
| 24 | /* 0x4200-0x4300 are reserved for architecture-independent additions. */ |
|---|
| 25 | #define PTRACE_SETOPTIONS 0x4200 |
|---|
| 26 | #define PTRACE_GETEVENTMSG 0x4201 |
|---|
| 27 | #define PTRACE_GETSIGINFO 0x4202 |
|---|
| 28 | #define PTRACE_SETSIGINFO 0x4203 |
|---|
| 29 | |
|---|
| 30 | /* options set using PTRACE_SETOPTIONS */ |
|---|
| 31 | #define PTRACE_O_TRACESYSGOOD 0x00000001 |
|---|
| 32 | #define PTRACE_O_TRACEFORK 0x00000002 |
|---|
| 33 | #define PTRACE_O_TRACEVFORK 0x00000004 |
|---|
| 34 | #define PTRACE_O_TRACECLONE 0x00000008 |
|---|
| 35 | #define PTRACE_O_TRACEEXEC 0x00000010 |
|---|
| 36 | #define PTRACE_O_TRACEVFORKDONE 0x00000020 |
|---|
| 37 | #define PTRACE_O_TRACEEXIT 0x00000040 |
|---|
| 38 | #define PT_ATTACHED 0x00000400 /* parent != real_parent */ |
|---|
| 39 | |
|---|
| 40 | #define PTRACE_O_MASK 0x0000007f |
|---|
| 41 | |
|---|
| 42 | /* Wait extended result codes for the above trace options. */ |
|---|
| 43 | #define PTRACE_EVENT_FORK 1 |
|---|
| 44 | #define PTRACE_EVENT_VFORK 2 |
|---|
| 45 | #define PTRACE_EVENT_CLONE 3 |
|---|
| 46 | #define PTRACE_EVENT_EXEC 4 |
|---|
| 47 | #define PTRACE_EVENT_VFORK_DONE 5 |
|---|
| 48 | #define PTRACE_EVENT_EXIT 6 |
|---|
| 49 | |
|---|
| 50 | #include <asm/ptrace.h> |
|---|
| 51 | |
|---|
| 52 | #endif |
|---|