Lines Matching refs:ptrace

17 #include <sys/ptrace.h>
63 /* Basic ptrace operations */
68 ret = ptrace(PTRACE_ATTACH, child, NULL, NULL);
70 perror("ptrace(PTRACE_ATTACH) failed");
85 ret = ptrace(PTRACE_DETACH, child, NULL, NULL);
87 perror("ptrace(PTRACE_DETACH) failed");
97 ret = ptrace(PTRACE_CONT, child, NULL, NULL);
99 perror("ptrace(PTRACE_CONT) failed");
116 ret = ptrace(PTRACE_GETREGSET, child, type, &iov);
136 ret = ptrace(PTRACE_SETREGSET, child, type, &iov);
158 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TAR, &iov);
160 perror("ptrace(PTRACE_GETREGSET) failed");
166 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_PPR, &iov);
168 perror("ptrace(PTRACE_GETREGSET) failed");
174 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_DSCR, &iov);
176 perror("ptrace(PTRACE_GETREGSET) failed");
206 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TAR, &iov);
208 perror("ptrace(PTRACE_SETREGSET) failed");
213 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_PPR, &iov);
215 perror("ptrace(PTRACE_SETREGSET) failed");
220 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_DSCR, &iov);
222 perror("ptrace(PTRACE_SETREGSET) failed");
248 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CTAR, &iov);
250 perror("ptrace(PTRACE_GETREGSET) failed");
256 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CPPR, &iov);
258 perror("ptrace(PTRACE_GETREGSET) failed");
264 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CDSCR, &iov);
266 perror("ptrace(PTRACE_GETREGSET) failed");
297 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CTAR, &iov);
299 perror("ptrace(PTRACE_GETREGSET) failed");
304 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CPPR, &iov);
306 perror("ptrace(PTRACE_GETREGSET) failed");
311 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CDSCR, &iov);
313 perror("ptrace(PTRACE_GETREGSET) failed");
331 ret = ptrace(PTRACE_GETFPREGS, child, NULL, regs);
333 perror("ptrace(PTRACE_GETREGSET) failed");
350 ret = ptrace(PTRACE_GETFPREGS, child, NULL, regs);
352 perror("ptrace(PTRACE_GETREGSET) failed");
359 ret = ptrace(PTRACE_SETFPREGS, child, NULL, regs);
361 perror("ptrace(PTRACE_GETREGSET) failed");
377 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CFPR, &iov);
379 perror("ptrace(PTRACE_GETREGSET) failed");
401 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CFPR, &iov);
403 perror("ptrace(PTRACE_GETREGSET) failed");
410 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CFPR, &iov);
412 perror("ptrace(PTRACE_GETREGSET) failed");
430 ret = ptrace(PTRACE_GETREGS, child, NULL, regs);
432 perror("ptrace(PTRACE_GETREGSET) failed");
468 perror("ptrace(PTRACE_PEEKUSR) failed");
476 printf("ptrace(PTRACE_PEEKUSR) succeeded unexpectedly!\n");
493 perror("ptrace(PTRACE_POKEUSR) failed");
501 printf("ptrace(PTRACE_POKEUSR) succeeded unexpectedly!\n");
519 ret = ptrace(PTRACE_GETREGS, child, NULL, regs);
521 perror("ptrace(PTRACE_GETREGSET) failed");
528 ret = ptrace(PTRACE_SETREGS, child, NULL, regs);
530 perror("ptrace(PTRACE_GETREGSET) failed");
551 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CGPR, &iov);
553 perror("ptrace(PTRACE_GETREGSET) failed");
579 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CGPR, &iov);
581 perror("ptrace(PTRACE_GETREGSET) failed");
588 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CGPR, &iov);
590 perror("ptrace(PTRACE_GETREGSET) failed");
601 ret = ptrace(PTRACE_GETVRREGS, child, 0, vmx);
603 perror("ptrace(PTRACE_GETVRREGS) failed");
617 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CVMX, &iov);
619 perror("ptrace(PTRACE_GETREGSET, NT_PPC_TM_CVMX) failed");
631 ret = ptrace(PTRACE_SETVRREGS, child, 0, vmx);
633 perror("ptrace(PTRACE_SETVRREGS) failed");
648 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CVMX, &iov);
650 perror("ptrace(PTRACE_SETREGSET, NT_PPC_TM_CVMX) failed");
661 ret = ptrace(PTRACE_GETVSRREGS, child, 0, vsx);
663 perror("ptrace(PTRACE_GETVSRREGS) failed");
677 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_CVSX, &iov);
679 perror("ptrace(PTRACE_GETREGSET, NT_PPC_TM_CVSX) failed");
690 ret = ptrace(PTRACE_SETVSRREGS, child, 0, vsx);
692 perror("ptrace(PTRACE_SETVSRREGS) failed");
707 ret = ptrace(PTRACE_SETREGSET, child, NT_PPC_TM_CVSX, &iov);
709 perror("ptrace(PTRACE_SETREGSET, NT_PPC_TM_CVSX) failed");
731 ret = ptrace(PTRACE_GETREGSET, child, NT_PPC_TM_SPR, &iov);
733 perror("ptrace(PTRACE_GETREGSET) failed");