? diff Index: coregrind/vg_syscalls.c =================================================================== RCS file: /home/kde/valgrind/coregrind/vg_syscalls.c,v retrieving revision 1.81 diff -u -3 -p -r1.81 vg_syscalls.c --- coregrind/vg_syscalls.c 24 Jan 2004 18:18:53 -0000 1.81 +++ coregrind/vg_syscalls.c 25 Jan 2004 18:31:25 -0000 @@ -3945,6 +3945,43 @@ POST(poll) } } +#ifdef KERNEL_2_6 +PRE(epoll_create) +{ + /* int epoll_create(int size) */ + MAYBE_PRINTF("epoll_create ( %d )\n", arg1); +} + +PRE(epoll_ctl) +{ + /* int epoll_ctl(int epfd, int op, int fd, struct epoll_event *event) */ + static const char* epoll_ctl_s[3] = { + "EPOLL_CTL_ADD", + "EPOLL_CTL_DEL", + "EPOLL_CTL_MOD" + }; + MAYBE_PRINTF("epoll_ctl ( %d, %s, %d, %p )\n", + arg1, ( arg2<3 ? epoll_ctl_s[arg2] : "?" ), arg3, arg4); + SYSCALL_TRACK( pre_mem_read, tid, "epoll_ctl(event)", + arg4, sizeof(struct epoll_event) ); +} + +PRE(epoll_wait) +{ + /* int epoll_wait(int epfd, struct epoll_event * events, + int maxevents, int timeout) */ + MAYBE_PRINTF("epoll_wait ( %d, %p, %d, %d )\n", arg1, arg2, arg3, arg4); + if (res > 0) + SYSCALL_TRACK( pre_mem_write, tid, "epoll_wait(events)", + arg2, sizeof(struct epoll_event)*arg3); +} + +POST(epoll_wait) +{ + VG_TRACK( post_mem_write, arg2, sizeof(struct epoll_event)*res ) ; +} +#endif /* KERNEL_2_6 */ + PRE(readlink) { /* int readlink(const char *path, char *buf, size_t bufsiz); */ @@ -5201,6 +5238,11 @@ static const struct sys_info sys_info[] SYSBA(creat, True), SYSBA(pipe, False), SYSBA(poll, True), +# ifdef KERNEL_2_6 + SYSB_(epoll_create, False), + SYSB_(epoll_ctl, False), + SYSBA(epoll_wait, True), +# endif SYSBA(readlink, False), SYSBA(readv, True), SYSB_(rename, False), Index: coregrind/vg_unsafe.h =================================================================== RCS file: /home/kde/valgrind/coregrind/vg_unsafe.h,v retrieving revision 1.23 diff -u -3 -p -r1.23 vg_unsafe.h --- coregrind/vg_unsafe.h 4 Jan 2004 16:43:20 -0000 1.23 +++ coregrind/vg_unsafe.h 25 Jan 2004 18:31:25 -0000 @@ -93,6 +93,10 @@ #include +/* 2.6 stuff */ +#ifdef KERNEL_2_6 +#include +#endif /*--------------------------------------------------------------------*/ /*--- end vg_unsafe.h ---*/