Home
last modified time | relevance | path

Searched refs:ptrace (Results 1 – 25 of 239) sorted by relevance

12345678910

/external/linux-kselftest/tools/testing/selftests/powerpc/ptrace/
DMakefile2 TEST_GEN_PROGS := ptrace-gpr ptrace-tm-gpr ptrace-tm-spd-gpr \
3 ptrace-tar ptrace-tm-tar ptrace-tm-spd-tar ptrace-vsx ptrace-tm-vsx \
4 ptrace-tm-spd-vsx ptrace-tm-spr ptrace-hwbreak ptrace-pkey core-pkey \
5 perf-hwbreak ptrace-syscall
12 $(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: child.h
13 $(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: LDLIBS += -pthread
15 $(TEST_GEN_PROGS): ../harness.c ../utils.c ../lib/reg.S ptrace.h
D.gitignore1 ptrace-gpr
2 ptrace-tm-gpr
3 ptrace-tm-spd-gpr
4 ptrace-tar
5 ptrace-tm-tar
6 ptrace-tm-spd-tar
7 ptrace-vsx
8 ptrace-tm-vsx
9 ptrace-tm-spd-vsx
10 ptrace-tm-spr
[all …]
Dptrace.h64 ret = ptrace(PTRACE_ATTACH, child, NULL, NULL); in start_trace()
81 ret = ptrace(PTRACE_DETACH, child, NULL, NULL); in stop_trace()
93 ret = ptrace(PTRACE_CONT, child, NULL, NULL); in cont_trace()
112 ret = ptrace(PTRACE_GETREGSET, child, type, &iov); in ptrace_read_regs()
132 ret = ptrace(PTRACE_SETREGSET, child, type, &iov); in ptrace_write_regs()
154 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TAR, &iov); in show_tar_registers()
162 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_PPR, &iov); in show_tar_registers()
170 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_DSCR, &iov); in show_tar_registers()
202 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TAR, &iov); in write_tar_registers()
209 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_PPR, &iov); in write_tar_registers()
[all …]
Dptrace-hwbreak.c50 if (ptrace(PPC_PTRACE_GETHWDBGINFO, child_pid, NULL, dbginfo)) { in get_dbginfo()
117 if (ptrace(PTRACE_TRACEME, 0, NULL, 0)) { in test_workload()
202 ptrace(PTRACE_GETSIGINFO, child_pid, NULL, &siginfo); in check_success()
219 ptrace(PTRACE_SINGLESTEP, child_pid, NULL, 0); in check_success()
226 if (ptrace(PTRACE_SET_DEBUGREG, child_pid, 0, wp_addr)) { in ptrace_set_debugreg()
234 int wh = ptrace(PPC_PTRACE_SETHWDEBUG, child_pid, 0, info); in ptrace_sethwdebug()
245 if (ptrace(PPC_PTRACE_DELHWDEBUG, child_pid, 0, wh) < 0) { in ptrace_delhwdebug()
267 ptrace(PTRACE_CONT, child_pid, NULL, 0); in test_set_debugreg()
277 ptrace(PTRACE_CONT, child_pid, NULL, 0); in test_set_debugreg()
288 ptrace(PTRACE_CONT, child_pid, NULL, 0); in test_set_debugreg()
[all …]
Dptrace-syscall.c74 if (ptrace(PTRACE_TRACEME, 0, 0, 0) != 0) in test_ptrace_syscall_restart()
92 if (ptrace(PTRACE_SYSEMU, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
96 if (ptrace(PTRACE_GETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
127 if (ptrace(PTRACE_SETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
130 if (ptrace(PTRACE_SYSEMU, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
134 if (ptrace(PTRACE_GETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
170 if (ptrace(PTRACE_SETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
173 if (ptrace(PTRACE_SYSEMU, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
177 if (ptrace(PTRACE_GETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
203 if (ptrace(PTRACE_CONT, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
/external/ltp/m4/
Dltp-ptrace.m48 dnl Check for ptrace support
13 sys/ptrace.h \
15 asm/ptrace.h \
16 linux/ptrace.h \
19 CPPFLAGS="$CPPFLAGS -I$srcdir/testcases/kernel/syscalls/ptrace"
20 AC_CHECK_TYPES([struct user_regs_struct, struct pt_regs],,,[#include "ptrace.h"])
21 AC_CHECK_DECLS([PTRACE_GETSIGINFO, PTRACE_O_TRACEVFORKDONE, PTRACE_SETOPTIONS],,,[#include "ptrace.…
22 dnl glibc-2.18 defines ptrace_peeksiginfo_args in sys/ptrace.h which
23 dnl conflicts with the one from linux kernel in linux/ptrace.h
24 AC_CHECK_TYPES([struct ptrace_peeksiginfo_args],,,[#include <sys/ptrace.h>])
/external/libunwind/src/ptrace/
D_UPT_access_reg.c65 nat_bits = ptrace (PTRACE_PEEKUSER, pid, PT_NAT_BITS, 0); in _UPT_access_reg()
80 ptrace (PTRACE_POKEUSER, pid, PT_NAT_BITS, nat_bits); in _UPT_access_reg()
105 psr = ptrace (PTRACE_PEEKUSER, pid, PT_CR_IPSR, 0); in _UPT_access_reg()
117 ptrace (PTRACE_POKEUSER, pid, PT_CR_IIP, ip); in _UPT_access_reg()
118 ptrace (PTRACE_POKEUSER, pid, PT_CR_IPSR, psr); in _UPT_access_reg()
129 ip = ptrace (PTRACE_PEEKUSER, pid, PT_CR_IIP, 0); in _UPT_access_reg()
153 cfm = ptrace (PTRACE_PEEKUSER, pid, PT_CFM, 0); in _UPT_access_reg()
166 ptrace (PTRACE_POKEUSER, pid, PT_AR_BSP, bsp); in _UPT_access_reg()
177 bsp = ptrace (PTRACE_PEEKUSER, pid, PT_AR_BSP, 0); in _UPT_access_reg()
197 bsp = ptrace (PTRACE_PEEKUSER, pid, PT_AR_BSP, 0); in _UPT_access_reg()
[all …]
D_UPT_access_mem.c48 ptrace (PTRACE_POKEDATA, pid, (void*) (uintptr_t) addr, (void*) (uintptr_t) *val); in _UPT_access_mem()
64 reg1 = ptrace (PTRACE_PEEKDATA, pid, (void*) (uintptr_t) addr, 0); in _UPT_access_mem()
67 reg2 = ptrace (PTRACE_PEEKDATA, pid, (void*) (uintptr_t) (addr + sizeof(long)), 0); in _UPT_access_mem()
73 *val = ptrace (PTRACE_PEEKDATA, pid, (void*) addr, 0); in _UPT_access_mem()
100 if (ptrace(PT_IO, pid, (caddr_t)&iod, 0) == -1) in _UPT_access_mem()
Dlibunwind-ptrace.pc.in6 Name: libunwind-ptrace
7 Description: libunwind ptrace library
10 Libs: -L${libdir} -lunwind-ptrace
D_UPT_access_fpreg.c50 ptrace (PTRACE_POKEUSER, pid, (void*) (_UPT_reg_offset[reg] + i * sizeof(wp[i])), in _UPT_access_fpreg()
64 wp[i] = ptrace (PTRACE_PEEKUSER, pid, in _UPT_access_fpreg()
85 if (ptrace(PT_GETFPREGS, pid, (caddr_t)&fpreg, 0) == -1) in _UPT_access_fpreg()
95 if (ptrace(PT_SETFPREGS, pid, (caddr_t)&fpreg, 0) == -1) in _UPT_access_fpreg()
/external/compiler-rt/test/sanitizer_common/TestCases/Linux/
Dptrace.cc26 ptrace(PTRACE_TRACEME, 0, NULL, NULL); in main()
34 res = ptrace(PTRACE_GETREGS, pid, NULL, &regs); in main()
40 res = ptrace(PTRACE_GETFPREGS, pid, NULL, &fpregs); in main()
48 res = ptrace((enum __ptrace_request)PTRACE_GETREGS, pid, NULL, &regs); in main()
62 res = ptrace((enum __ptrace_request)PTRACE_GETFPREGS, pid, NULL, &fpregs); in main()
68 res = ptrace((enum __ptrace_request)PTRACE_GETVFPREGS, pid, 0, regbuf); in main()
81 res = ptrace(PTRACE_GETREGSET, pid, (void*)NT_PRSTATUS, (void*)&regset_io); in main()
89 res = ptrace(PTRACE_GETREGSET, pid, (void*)NT_FPREGSET, (void*)&regset_io); in main()
101 res = ptrace(PTRACE_GETREGSET, pid, (void*)NT_PRSTATUS, (void*)&regset_io); in main()
109 res = ptrace(PTRACE_GETREGSET, pid, (void*)NT_FPREGSET, (void*)&regset_io); in main()
[all …]
/external/linux-kselftest/tools/testing/selftests/x86/
Dptrace_syscall.c183 if (ptrace(PTRACE_TRACEME, 0, 0, 0) != 0) in test_ptrace_syscall_restart()
204 if (ptrace(PTRACE_SYSEMU, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
208 if (ptrace(PTRACE_GETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
232 if (ptrace(PTRACE_SETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
235 if (ptrace(PTRACE_SYSEMU, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
239 if (ptrace(PTRACE_GETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
264 if (ptrace(PTRACE_SETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
267 if (ptrace(PTRACE_SYSEMU, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
271 if (ptrace(PTRACE_GETREGS, chld, 0, &regs) != 0) in test_ptrace_syscall_restart()
283 if (ptrace(PTRACE_CONT, chld, 0, 0) != 0) in test_ptrace_syscall_restart()
[all …]
/external/linux-kselftest/tools/testing/selftests/breakpoints/
Dbreakpoint_test.c46 ret = ptrace(PTRACE_POKEUSER, child_pid, in set_breakpoint_addr()
88 dr7 = ptrace(PTRACE_PEEKUSER, child_pid, in toggle_breakpoint()
108 ret = ptrace(PTRACE_POKEUSER, child_pid, in toggle_breakpoint()
209 ret = ptrace(PTRACE_TRACEME, 0, NULL, 0); in trigger_tests()
276 child_nr_tests = ptrace(PTRACE_PEEKDATA, child_pid, in check_success()
280 if (ptrace(PTRACE_POKEDATA, child_pid, &trapped, 1)) in check_success()
299 ptrace(PTRACE_CONT, child_pid, NULL, 0); in launch_instruction_breakpoints()
321 ptrace(PTRACE_CONT, child_pid, NULL, 0); in launch_watchpoints()
377 ptrace(PTRACE_CONT, child_pid, NULL, 0); in launch_tests()
381 ptrace(PTRACE_CONT, child_pid, NULL, 0); in launch_tests()
[all …]
/external/strace/
DREADME-linux-ptrace1 This document describes Linux ptrace implementation in Linux kernels
18 a specific tracee using ptrace(PTRACE_foo, pid, ...), where pid is a
23 There are many kinds of states when tracee is stopped, and in ptrace
28 ptrace commands from the tracer is called ptrace-stop. Ptrace-stops can
33 1.x Death under ptrace.
38 not a ptrace-stop (because tracer can't query tracee status such as
41 ptrace-stop.
55 Tracer can kill a tracee with ptrace(PTRACE_KILL, pid, 0, 0). This
72 Tracer cannot assume that ptrace-stopped tracee exists. There are many
75 ptrace operation. Unfortunately, the same error is returned if tracee
[all …]
/external/libunwind/tests/
Dtest-ptrace.c220 ptrace (PTRACE_TRACEME, 0, 0, 0); in main()
222 ptrace (PT_TRACE_ME, 0, 0, 0); in main()
296 ptrace (PTRACE_CONT, target_pid, 0, 0); in main()
298 ptrace (PT_CONTINUE, target_pid, (caddr_t)1, 0); in main()
306 ptrace (PTRACE_SINGLESTEP, target_pid, 0, pending_sig); in main()
308 ptrace (PT_STEP, target_pid, (caddr_t)1, pending_sig); in main()
320 ptrace (PTRACE_SYSCALL, target_pid, 0, pending_sig); in main()
322 ptrace (PT_SYSCALL, target_pid, (caddr_t)1, pending_sig); in main()
331 ptrace (PTRACE_SINGLESTEP, target_pid, 0, pending_sig); in main()
333 ptrace (PT_STEP, target_pid, (caddr_t)1, pending_sig); in main()
DMakefile.am3 EXTRA_DIST = run-ia64-test-dyn1 run-ptrace-mapper run-ptrace-misc \
54 check_SCRIPTS_cdep += run-ptrace-mapper run-ptrace-misc
55 check_PROGRAMS_cdep += test-ptrace
56 noinst_PROGRAMS_cdep += mapper test-ptrace-misc
129 test_ptrace_misc_SOURCES = test-ptrace-misc.c ident.c
136 LIBUNWIND_ptrace = $(top_builddir)/src/libunwind-ptrace.la
/external/libunwind/src/coredump/
DREADME1 This code is based on "unwinding via ptrace" code from ptrace/
5 from their ptrace/_UPT_... progenitors.
8 from ptrace/, or unimplemented stubs.
/external/compiler-rt/test/asan/TestCases/Linux/
Dptrace.cc76 ptrace(PTRACE_TRACEME, 0, NULL, NULL); in main()
100 res = ptrace((enum __ptrace_request)__PTRACE_REQUEST, pid, __PTRACE_ARGS); in main()
112 res = ptrace((enum __ptrace_request)PTRACE_GETREGSET, pid, (void*)NT_FPREGSET, in main()
117 res = ptrace((enum __ptrace_request)__PTRACE_FPREQUEST, pid, __PTRACE_FPARGS); in main()
123 res = ptrace(PTRACE_GETFPXREGS, pid, NULL, &fpxregs); in main()
128 ptrace(PTRACE_CONT, pid, NULL, NULL); in main()
/external/boringssl/src/crypto/fipsmodule/rand/
Durandom_test.cc159 if (ptrace(PTRACE_TRACEME, 0, 0, 0) != 0) { in GetTrace()
178 ASSERT_EQ(0, ptrace(PTRACE_SETOPTIONS, child_pid, nullptr, in GetTrace()
188 ASSERT_EQ(0, ptrace(PTRACE_SYSCALL, child_pid, 0, 0)); in GetTrace()
201 ASSERT_EQ(0, ptrace(PTRACE_GETREGS, child_pid, nullptr, &regs)); in GetTrace()
269 ASSERT_EQ(0, ptrace(PTRACE_SETREGS, child_pid, nullptr, &regs)); in GetTrace()
272 ASSERT_EQ(0, ptrace(PTRACE_SYSCALL, child_pid, 0, 0)); in GetTrace()
288 ASSERT_EQ(0, ptrace(PTRACE_GETREGS, child_pid, nullptr, &regs)); in GetTrace()
290 ASSERT_EQ(0, ptrace(PTRACE_SETREGS, child_pid, nullptr, &regs)); in GetTrace()
293 ASSERT_EQ(0, ptrace(PTRACE_GETREGS, child_pid, nullptr, &regs)); in GetTrace()
316 u.word = ptrace(PTRACE_PEEKDATA, child_pid, in GetTrace()
[all …]
/external/libunwind/doc/
Dlibunwind-ptrace.tex8 …gin{Name}{3}{libunwind-ptrace}{David Mosberger-Tang}{Programming Library}{ptrace() support in libu…
13 \File{\#include $<$libunwind-ptrace.h$>$}\\
41 The \Func{ptrace}(2) system-call makes it possible for a process to
45 \Func{ptrace}(2). While it's not very difficult to do so directly,
49 stands for ``unwind-via-ptrace''.
68 Next, the application can turn on ptrace-mode on the target process,
80 the target process. It simply invokes \Func{ptrace}(2) with a command
91 Since \Func{ptrace}(2) works within a single machine only, the
113 \item[\File{libunwind-ptrace.h}] Headerfile to include when using the
115 \item[\Opt{-l}\File{unwind-ptrace} \Opt{-l}\File{unwind-generic}]
[all …]
/external/selinux/python/sepolicy/sepolicy/help/
Dlockdown_ptrace.txt1 Disable ptrace capability on your system.
8ptrace and sys_ptrace. These accesses allow one process to read the memory of another process.
14 Note: Disabling ptrace can break some bug trappers that attempt to collect crash data.
/external/ltp/testcases/kernel/controllers/freezer/
Dvfork.c82 if (ptrace(PTRACE_KILL, child, NULL, NULL) < 0) { in kill_child()
207 if (ptrace(PTRACE_GETSIGINFO, gchild, NULL, &info) == -1) { in trace_grandchild()
222 if (ptrace(PTRACE_DETACH, gchild, NULL, NULL) == -1) in trace_grandchild()
254 if (ptrace(PTRACE_CONT, process, NULL, NULL) == -1) in do_trace()
341 if (ptrace(PTRACE_ATTACH, child, NULL, NULL) == -1) { in main()
351 if (ptrace(PTRACE_SETOPTIONS, child, NULL, in main()
357 if (ptrace(PTRACE_CONT, child, NULL, NULL) == in main()
/external/strace/m4/
Dst_libunwind.m454 AC_CHECK_HEADERS([libunwind-ptrace.h],
72 AC_CHECK_LIB([unwind-ptrace], [_UPT_create],
77 AC_MSG_FAILURE([failed to find _UPT_create in libunwind-ptrace])
102 AC_MSG_FAILURE([failed to find libunwind-ptrace.h])
/external/honggfuzz/docs/
DAndroid.md4 both ptrace() API and POSIX signals interface. When ptrace() API is enabled,
30 | **armeabi** | ptrace() API & POSIX signal interface |
31 | **armeabi-v7a** | ptrace() API & POSIX signal interface |
32 | **arm64-v8a** | ptrace() API & POSIX signal interface `*`|
33 | **x86** | ptrace() API & POSIX signal interface |
34 | **x86_64** | ptrace() API & POSIX signal interface |
/external/ltp/testcases/kernel/syscalls/ptrace/
Dptrace07.c103 TEST(ptrace(PTRACE_ATTACH, pid, 0, 0)); in do_test()
108 TEST(ptrace(PTRACE_GETREGSET, pid, NT_X86_XSTATE, &iov)); in do_test()
133 TEST(ptrace(PTRACE_SETREGSET, pid, NT_X86_XSTATE, &iov)); in do_test()
153 TEST(ptrace(PTRACE_DETACH, pid, 0, 0)); in do_test()

12345678910