Lines Matching refs:tracee

1496 			   pid_t tracee, int status, void *args);
1498 void start_tracer(struct __test_metadata *_metadata, int fd, pid_t tracee,
1512 ret = ptrace(PTRACE_ATTACH, tracee, NULL, 0);
1514 kill(tracee, SIGKILL);
1519 ret = ptrace(PTRACE_SETOPTIONS, tracee, NULL, ptrace_syscall ?
1524 kill(tracee, SIGKILL);
1527 tracee, NULL, 0);
1530 /* Unblock the tracee */
1538 if (wait(&status) != tracee)
1547 tracer_func(_metadata, tracee, status, args);
1550 tracee, NULL, 0);
1566 pid_t tracee = getpid();
1577 start_tracer(_metadata, pipefd[1], tracee, func, args,
1610 void tracer_poke(struct __test_metadata *_metadata, pid_t tracee, int status,
1617 ret = ptrace(PTRACE_GETEVENTMSG, tracee, NULL, &msg);
1621 kill(tracee, SIGKILL);
1628 ret = ptrace(PTRACE_POKEDATA, tracee, info->poke_addr, 0x1001);
1717 EXPECT_EQ(0, ptrace(PTRACE_SET_SYSCALL, tracee, NULL, _nr))
1731 EXPECT_EQ(0, ptrace(PTRACE_SETREGSET, tracee, \
1889 # define ARCH_GETREGS(_regs) ptrace(PTRACE_GETREGS, tracee, 0, &(_regs))
1890 # define ARCH_SETREGS(_regs) ptrace(PTRACE_SETREGS, tracee, 0, &(_regs))
1896 ptrace(PTRACE_GETREGSET, tracee, NT_PRSTATUS, &__v); \
1902 ptrace(PTRACE_SETREGSET, tracee, NT_PRSTATUS, &__v); \
1907 int get_syscall(struct __test_metadata *_metadata, pid_t tracee)
1920 pid_t tracee, long *syscall, long *ret)
1946 pid_t tracee, long syscall)
1948 __change_syscall(_metadata, tracee, &syscall, NULL);
1953 pid_t tracee, long ret)
1957 __change_syscall(_metadata, tracee, &syscall, &ret);
1960 void tracer_seccomp(struct __test_metadata *_metadata, pid_t tracee,
1967 ret = ptrace(PTRACE_GETEVENTMSG, tracee, NULL, &msg);
1974 EXPECT_EQ(__NR_getpid, get_syscall(_metadata, tracee));
1975 change_syscall_nr(_metadata, tracee, __NR_getppid);
1979 EXPECT_EQ(__NR_gettid, get_syscall(_metadata, tracee));
1980 change_syscall_ret(_metadata, tracee, 45000);
1984 EXPECT_EQ(__NR_openat, get_syscall(_metadata, tracee));
1985 change_syscall_ret(_metadata, tracee, -ESRCH);
1989 EXPECT_EQ(__NR_getppid, get_syscall(_metadata, tracee));
1994 kill(tracee, SIGKILL);
2006 void tracer_ptrace(struct __test_metadata *_metadata, pid_t tracee,
2023 ret = ptrace(PTRACE_GETEVENTMSG, tracee, NULL, &msg);
2036 self->syscall_nr = get_syscall(_metadata, tracee);
2067 __change_syscall(_metadata, tracee, syscall_nr, syscall_ret);