Lines Matching refs:tcp
235 printflock(struct tcb *tcp, long addr, int getlk) in printflock() argument
250 if (umove(tcp, addr, &fl32) < 0) { in printflock()
268 if (umove(tcp, addr, &fl) < 0) { in printflock()
288 printflock64(struct tcb *tcp, long addr, int getlk) in printflock64() argument
292 if (umove(tcp, addr, &fl) < 0) { in printflock64()
309 sys_fcntl(struct tcb *tcp) in sys_fcntl() argument
311 if (entering(tcp)) { in sys_fcntl()
312 printfd(tcp, tcp->u_arg[0]); in sys_fcntl()
314 printxval(fcntlcmds, tcp->u_arg[1], "F_???"); in sys_fcntl()
315 switch (tcp->u_arg[1]) { in sys_fcntl()
318 printflags(fdflags, tcp->u_arg[2], "FD_???"); in sys_fcntl()
324 tprintf(", %ld", tcp->u_arg[2]); in sys_fcntl()
328 tprint_open_modes(tcp->u_arg[2]); in sys_fcntl()
335 printflock(tcp, tcp->u_arg[2], 0); in sys_fcntl()
350 printflock64(tcp, tcp->u_arg[2], 0); in sys_fcntl()
356 printflags(notifyflags, tcp->u_arg[2], "DN_???"); in sys_fcntl()
362 printxval(lockfcmds, tcp->u_arg[2], "F_???"); in sys_fcntl()
368 switch (tcp->u_arg[1]) { in sys_fcntl()
384 if (syserror(tcp) || tcp->u_rval == 0) in sys_fcntl()
386 tcp->auxstr = sprintflags("flags ", fdflags, tcp->u_rval); in sys_fcntl()
389 if (syserror(tcp)) in sys_fcntl()
391 tcp->auxstr = sprint_open_modes(tcp->u_rval); in sys_fcntl()
395 printflock(tcp, tcp->u_arg[2], 1); in sys_fcntl()
402 printflock64(tcp, tcp->u_arg[2], 1); in sys_fcntl()
407 if (syserror(tcp)) in sys_fcntl()
409 tcp->auxstr = xlookup(lockfcmds, tcp->u_rval); in sys_fcntl()
413 tprintf(", %#lx", tcp->u_arg[2]); in sys_fcntl()
423 sys_flock(struct tcb *tcp) in sys_flock() argument
425 if (entering(tcp)) { in sys_flock()
426 printfd(tcp, tcp->u_arg[0]); in sys_flock()
428 printflags(flockcmds, tcp->u_arg[1], "LOCK_???"); in sys_flock()
435 sys_close(struct tcb *tcp) in sys_close() argument
437 if (entering(tcp)) { in sys_close()
438 printfd(tcp, tcp->u_arg[0]); in sys_close()
444 sys_dup(struct tcb *tcp) in sys_dup() argument
446 if (entering(tcp)) { in sys_dup()
447 printfd(tcp, tcp->u_arg[0]); in sys_dup()
453 do_dup2(struct tcb *tcp, int flags_arg) in do_dup2() argument
455 if (entering(tcp)) { in do_dup2()
456 printfd(tcp, tcp->u_arg[0]); in do_dup2()
458 printfd(tcp, tcp->u_arg[1]); in do_dup2()
461 printflags(open_mode_flags, tcp->u_arg[flags_arg], "O_???"); in do_dup2()
468 sys_dup2(struct tcb *tcp) in sys_dup2() argument
470 return do_dup2(tcp, -1); in sys_dup2()
475 sys_dup3(struct tcb *tcp) in sys_dup3() argument
477 return do_dup2(tcp, 2); in sys_dup3()
483 sys_getdtablesize(struct tcb *tcp) in sys_getdtablesize() argument
490 decode_select(struct tcb *tcp, long *args, enum bitness_t bitness) in decode_select() argument
500 if (entering(tcp)) { in decode_select()
512 if (fds == NULL || !verbose(tcp)) { in decode_select()
516 if (umoven(tcp, arg, fdsize, (char *) fds) < 0) { in decode_select()
524 printfd(tcp, j); in decode_select()
532 printtv_bitness(tcp, args[4], bitness, 0); in decode_select()
539 if (syserror(tcp)) in decode_select()
542 if ((nfds = tcp->u_rval) == 0) { in decode_select()
543 tcp->auxstr = "Timeout"; in decode_select()
555 tcp->auxstr = outstr; in decode_select()
558 umoven(tcp, arg, fdsize, (char *) fds) < 0) in decode_select()
592 sprinttv(tcp, args[4], bitness, str + strlen(str)); in decode_select()
605 sys_oldselect(struct tcb *tcp) in sys_oldselect() argument
609 if (umoven(tcp, tcp->u_arg[0], sizeof args, (char *) args) < 0) { in sys_oldselect()
613 return decode_select(tcp, args, BITNESS_CURRENT); in sys_oldselect()
618 sys_osf_select(struct tcb *tcp) in sys_osf_select() argument
620 long *args = tcp->u_arg; in sys_osf_select()
621 return decode_select(tcp, args, BITNESS_32); in sys_osf_select()
679 sys_epoll_create(struct tcb *tcp) in sys_epoll_create() argument
681 if (entering(tcp)) in sys_epoll_create()
682 tprintf("%ld", tcp->u_arg[0]); in sys_epoll_create()
687 sys_epoll_create1(struct tcb *tcp) in sys_epoll_create1() argument
689 if (entering(tcp)) in sys_epoll_create1()
690 printflags(open_mode_flags, tcp->u_arg[0], "O_???"); in sys_epoll_create1()
708 sys_epoll_ctl(struct tcb *tcp) in sys_epoll_ctl() argument
710 if (entering(tcp)) { in sys_epoll_ctl()
711 printfd(tcp, tcp->u_arg[0]); in sys_epoll_ctl()
713 printxval(epollctls, tcp->u_arg[1], "EPOLL_CTL_???"); in sys_epoll_ctl()
715 printfd(tcp, tcp->u_arg[2]); in sys_epoll_ctl()
717 if (tcp->u_arg[3] == 0) in sys_epoll_ctl()
722 if (umove(tcp, tcp->u_arg[3], &ev) == 0) in sys_epoll_ctl()
733 epoll_wait_common(struct tcb *tcp) in epoll_wait_common() argument
735 if (entering(tcp)) { in epoll_wait_common()
736 printfd(tcp, tcp->u_arg[0]); in epoll_wait_common()
739 if (syserror(tcp)) in epoll_wait_common()
740 tprintf("%lx", tcp->u_arg[1]); in epoll_wait_common()
741 else if (tcp->u_rval == 0) in epoll_wait_common()
749 start = (struct epoll_event *) tcp->u_arg[1]; in epoll_wait_common()
750 end = start + tcp->u_rval; in epoll_wait_common()
754 if (umove(tcp, (long) cur, &ev) == 0) in epoll_wait_common()
769 tprintf(", %ld, %ld", tcp->u_arg[2], tcp->u_arg[3]); in epoll_wait_common()
774 sys_epoll_wait(struct tcb *tcp) in sys_epoll_wait() argument
776 epoll_wait_common(tcp); in sys_epoll_wait()
781 sys_epoll_pwait(struct tcb *tcp) in sys_epoll_pwait() argument
783 epoll_wait_common(tcp); in sys_epoll_pwait()
784 if (exiting(tcp)) { in sys_epoll_pwait()
786 print_sigset(tcp, tcp->u_arg[4], 0); in sys_epoll_pwait()
792 sys_io_setup(struct tcb *tcp) in sys_io_setup() argument
794 if (entering(tcp)) in sys_io_setup()
795 tprintf("%ld, ", tcp->u_arg[0]); in sys_io_setup()
797 if (syserror(tcp)) in sys_io_setup()
798 tprintf("0x%0lx", tcp->u_arg[1]); in sys_io_setup()
801 if (umove(tcp, tcp->u_arg[1], &user_id) == 0) in sys_io_setup()
811 sys_io_destroy(struct tcb *tcp) in sys_io_destroy() argument
813 if (entering(tcp)) in sys_io_destroy()
814 tprintf("%lu", tcp->u_arg[0]); in sys_io_destroy()
819 sys_io_submit(struct tcb *tcp) in sys_io_submit() argument
822 if (entering(tcp)) { in sys_io_submit()
823 tprintf("%lu, %ld, ", tcp->u_arg[0], tcp->u_arg[1]); in sys_io_submit()
824 nr = tcp->u_arg[1]; in sys_io_submit()
831 struct iocb *iocbp, **iocbs = (void *)tcp->u_arg[2]; in sys_io_submit()
840 if (umove(tcp, (unsigned long)iocbs, &iocbp) || in sys_io_submit()
841 umove(tcp, (unsigned long)iocbp, &iocb)) { in sys_io_submit()
861 sys_io_cancel(struct tcb *tcp) in sys_io_cancel() argument
863 if (entering(tcp)) { in sys_io_cancel()
867 tprintf("%lu, ", tcp->u_arg[0]); in sys_io_cancel()
869 if (umove(tcp, tcp->u_arg[1], &iocb) == 0) { in sys_io_cancel()
878 if (tcp->u_rval < 0) in sys_io_cancel()
883 if (umove(tcp, tcp->u_arg[2], &event) == 0) in sys_io_cancel()
896 sys_io_getevents(struct tcb *tcp) in sys_io_getevents() argument
898 if (entering(tcp)) { in sys_io_getevents()
899 tprintf("%ld, %ld, %ld, ", tcp->u_arg[0], tcp->u_arg[1], in sys_io_getevents()
900 tcp->u_arg[2]); in sys_io_getevents()
902 if (tcp->u_rval == 0) { in sys_io_getevents()
906 struct io_event *events = (void *)tcp->u_arg[3]; in sys_io_getevents()
907 long i, nr = tcp->u_rval; in sys_io_getevents()
917 if (umove(tcp, (unsigned long)events, &event) != 0) { in sys_io_getevents()
930 print_timespec(tcp, tcp->u_arg[4]); in sys_io_getevents()
937 sys_select(struct tcb *tcp) in sys_select() argument
939 return decode_select(tcp, tcp->u_arg, BITNESS_CURRENT); in sys_select()
944 sys_pselect6(struct tcb *tcp) in sys_pselect6() argument
946 int rc = decode_select(tcp, tcp->u_arg, BITNESS_CURRENT); in sys_pselect6()
947 if (entering(tcp)) { in sys_pselect6()
952 if (umove(tcp, tcp->u_arg[5], &data) < 0) in sys_pselect6()
953 tprintf(", %#lx", tcp->u_arg[5]); in sys_pselect6()
959 print_sigset(tcp, (long)data.ss, 0); in sys_pselect6()
967 do_eventfd(struct tcb *tcp, int flags_arg) in do_eventfd() argument
969 if (entering(tcp)) { in do_eventfd()
970 tprintf("%lu", tcp->u_arg[0]); in do_eventfd()
973 printflags(open_mode_flags, tcp->u_arg[flags_arg], "O_???"); in do_eventfd()
980 sys_eventfd(struct tcb *tcp) in sys_eventfd() argument
982 return do_eventfd(tcp, -1); in sys_eventfd()
986 sys_eventfd2(struct tcb *tcp) in sys_eventfd2() argument
988 return do_eventfd(tcp, 1); in sys_eventfd2()