diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/elf.h | 6 | ||||
-rw-r--r-- | include/linux/ptrace.h | 15 |
2 files changed, 20 insertions, 1 deletions
diff --git a/include/linux/elf.h b/include/linux/elf.h index a8c4af073ce9..d8e6e61ad9ff 100644 --- a/include/linux/elf.h +++ b/include/linux/elf.h | |||
@@ -349,7 +349,11 @@ typedef struct elf64_shdr { | |||
349 | #define ELF_OSABI ELFOSABI_NONE | 349 | #define ELF_OSABI ELFOSABI_NONE |
350 | #endif | 350 | #endif |
351 | 351 | ||
352 | /* Notes used in ET_CORE */ | 352 | /* |
353 | * Notes used in ET_CORE. Architectures export some of the arch register sets | ||
354 | * using the corresponding note types via the PTRACE_GETREGSET and | ||
355 | * PTRACE_SETREGSET requests. | ||
356 | */ | ||
353 | #define NT_PRSTATUS 1 | 357 | #define NT_PRSTATUS 1 |
354 | #define NT_PRFPREG 2 | 358 | #define NT_PRFPREG 2 |
355 | #define NT_PRPSINFO 3 | 359 | #define NT_PRPSINFO 3 |
diff --git a/include/linux/ptrace.h b/include/linux/ptrace.h index 56f2d63a5cbb..dbfa821d5a6e 100644 --- a/include/linux/ptrace.h +++ b/include/linux/ptrace.h | |||
@@ -27,6 +27,21 @@ | |||
27 | #define PTRACE_GETSIGINFO 0x4202 | 27 | #define PTRACE_GETSIGINFO 0x4202 |
28 | #define PTRACE_SETSIGINFO 0x4203 | 28 | #define PTRACE_SETSIGINFO 0x4203 |
29 | 29 | ||
30 | /* | ||
31 | * Generic ptrace interface that exports the architecture specific regsets | ||
32 | * using the corresponding NT_* types (which are also used in the core dump). | ||
33 | * | ||
34 | * This interface usage is as follows: | ||
35 | * struct iovec iov = { buf, len}; | ||
36 | * | ||
37 | * ret = ptrace(PTRACE_GETREGSET/PTRACE_SETREGSET, pid, NT_XXX_TYPE, &iov); | ||
38 | * | ||
39 | * On the successful completion, iov.len will be updated by the kernel, | ||
40 | * specifying how much the kernel has written/read to/from the user's iov.buf. | ||
41 | */ | ||
42 | #define PTRACE_GETREGSET 0x4204 | ||
43 | #define PTRACE_SETREGSET 0x4205 | ||
44 | |||
30 | /* options set using PTRACE_SETOPTIONS */ | 45 | /* options set using PTRACE_SETOPTIONS */ |
31 | #define PTRACE_O_TRACESYSGOOD 0x00000001 | 46 | #define PTRACE_O_TRACESYSGOOD 0x00000001 |
32 | #define PTRACE_O_TRACEFORK 0x00000002 | 47 | #define PTRACE_O_TRACEFORK 0x00000002 |