[Libsysio-commit] b_lustre: libsysio/src chdir.c chmod.c chown.c dup.c fcntl.c fsync.c getdirentries
Brought to you by:
lward
Update of /cvsroot/libsysio/libsysio/src In directory sc8-pr-cvs1:/tmp/cvs-serv29118/src Modified Files: Tag: b_lustre chdir.c chmod.c chown.c dup.c fcntl.c fsync.c getdirentries.c ioctl.c iowait.c lseek.c mkdir.c mknod.c open.c read.c rmdir.c stat.c stat64.c statvfs.c statvfs64.c symlink.c truncate.c unlink.c write.c Log Message: add back the syscall enter/leave tracking which Lee want to keep. Index: chdir.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/chdir.c,v retrieving revision 1.3.8.6 retrieving revision 1.3.8.7 diff -u -w -b -B -p -r1.3.8.6 -r1.3.8.7 --- chdir.c 15 Dec 2003 08:22:16 -0000 1.3.8.6 +++ chdir.c 16 Dec 2003 07:07:42 -0000 1.3.8.7 @@ -119,15 +119,18 @@ chdir(const char *path) { int err; struct pnode *pno; + SYSIO_ENTER; err = _sysio_namei(_sysio_cwd, path, 0, NULL, &pno); if (err) { errno = -err; + SYSIO_LEAVE; return -1; } err = _sysio_p_chdir(pno); + SYSIO_LEAVE; return err; } @@ -221,12 +224,15 @@ char * getcwd(char *buf, size_t size) { int err; + SYSIO_ENTER; err = _sysio_p_path(_sysio_cwd, &buf, buf ? size : 0); if (err) { errno = -err; + SYSIO_LEAVE; return NULL; } + SYSIO_LEAVE; return buf; } Index: chmod.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/chmod.c,v retrieving revision 1.3.4.4 retrieving revision 1.3.4.5 diff -u -w -b -B -p -r1.3.4.4 -r1.3.4.5 --- chmod.c 15 Dec 2003 08:22:16 -0000 1.3.4.4 +++ chmod.c 16 Dec 2003 07:07:42 -0000 1.3.4.5 @@ -72,6 +72,7 @@ chmod(const char *path, mode_t mode) { int err; struct pnode *pno; + SYSIO_ENTER; err = _sysio_namei(_sysio_cwd, path, 0, NULL, &pno); if (err) @@ -83,6 +84,7 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: chown.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/chown.c,v retrieving revision 1.3.4.3 retrieving revision 1.3.4.4 diff -u -w -b -B -p -r1.3.4.3 -r1.3.4.4 --- chown.c 15 Dec 2003 08:22:16 -0000 1.3.4.3 +++ chown.c 16 Dec 2003 07:07:42 -0000 1.3.4.4 @@ -59,6 +59,7 @@ _do_chown(struct pnode *pno, struct inod int err; struct intnl_stat stbuf; unsigned mask; + SYSIO_ENTER; (void )memset(&stbuf, 0, sizeof(struct intnl_stat)); mask = 0; @@ -91,6 +92,7 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: dup.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/dup.c,v retrieving revision 1.1.1.1.12.4 retrieving revision 1.1.1.1.12.5 diff -u -w -b -B -p -r1.1.1.1.12.4 -r1.1.1.1.12.5 --- dup.c 15 Dec 2003 08:22:16 -0000 1.1.1.1.12.4 +++ dup.c 16 Dec 2003 07:07:42 -0000 1.1.1.1.12.5 @@ -54,22 +54,35 @@ int dup2(int oldfd, int newfd) { + int rc; + SYSIO_ENTER; if (newfd < 0) { errno = EBADF; + SYSIO_LEAVE; return -1; } - if (oldfd == newfd) + if (oldfd == newfd) { + SYSIO_LEAVE; return newfd; + } + + rc = _sysio_fd_dup2(oldfd, newfd); - return _sysio_fd_dup2(oldfd, newfd); + SYSIO_LEAVE; + return rc; } int dup(int oldfd) { + int rc; + SYSIO_ENTER; + + rc = _sysio_fd_dup2(oldfd, -1); - return _sysio_fd_dup2(oldfd, -1); + SYSIO_LEAVE; + return rc; } Index: fcntl.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/fcntl.c,v retrieving revision 1.3.2.11 retrieving revision 1.3.2.12 diff -u -w -b -B -p -r1.3.2.11 -r1.3.2.12 --- fcntl.c 15 Dec 2003 08:22:16 -0000 1.3.2.11 +++ fcntl.c 16 Dec 2003 07:07:42 -0000 1.3.2.12 @@ -88,6 +88,7 @@ fcntl(int fd, int cmd, ...) int err; struct file *fil; va_list ap; + SYSIO_ENTER; err = 0; fil = _sysio_fd_find(fd); @@ -95,6 +96,7 @@ fcntl(int fd, int cmd, ...) va_start(ap, cmd); err = _sysio_fcntl_common(fd, cmd, ap); va_end(ap); + SYSIO_LEAVE; return err; } @@ -103,6 +105,7 @@ fcntl(int fd, int cmd, ...) case F_DUPFD: { long newfd; + int rc; va_start(ap, cmd); newfd = va_arg(ap, long); @@ -111,7 +114,10 @@ fcntl(int fd, int cmd, ...) err = -EBADF; goto out; } - return _sysio_fd_dup2(fd, (int )newfd); + rc = _sysio_fd_dup2(fd, (int )newfd); + + SYSIO_LEAVE; + return rc; } break; default: @@ -126,6 +132,7 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: fsync.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/fsync.c,v retrieving revision 1.2.8.2 retrieving revision 1.2.8.3 diff -u -w -b -B -p -r1.2.8.2 -r1.2.8.3 --- fsync.c 15 Dec 2003 08:22:16 -0000 1.2.8.2 +++ fsync.c 16 Dec 2003 07:07:42 -0000 1.2.8.3 @@ -55,17 +55,22 @@ fsync(int fd) { struct file *fil; int err; + SYSIO_ENTER; fil = _sysio_fd_find(fd); if (!(fil && fil->f_ino)) { errno = -EBADF; + SYSIO_LEAVE; return -1; } err = (*fil->f_ino->i_ops.inop_sync)(fil->f_ino); if (err) { errno = -err; + SYSIO_LEAVE; return -1; } + + SYSIO_LEAVE; return 0; } @@ -74,16 +79,21 @@ fdatasync(int fd) { struct file *fil; int err; + SYSIO_ENTER; fil = _sysio_fd_find(fd); if (!(fil && fil->f_ino)) { errno = -EBADF; + SYSIO_LEAVE; return -1; } err = (*fil->f_ino->i_ops.inop_datasync)(fil->f_ino); if (err) { errno = -err; + SYSIO_LEAVE; return -1; } + + SYSIO_LEAVE; return 0; } Index: getdirentries.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/getdirentries.c,v retrieving revision 1.1.8.4 retrieving revision 1.1.8.5 diff -u -w -b -B -p -r1.1.8.4 -r1.1.8.5 --- getdirentries.c 15 Dec 2003 08:22:16 -0000 1.1.8.4 +++ getdirentries.c 16 Dec 2003 07:07:42 -0000 1.1.8.5 @@ -96,6 +96,7 @@ getdirentries(int fd, size_t n; size_t reclen; char *cp; + SYSIO_ENTER; #define _dbaselen ((size_t )&((struct dirent *)0)->d_name[0]) #ifdef __GLIBC__ @@ -128,6 +129,7 @@ getdirentries(int fd, ibuf = _fast_alloc(inbytes); if (!ibuf) { errno = ENOMEM; + SYSIO_LEAVE; return -1; } @@ -199,6 +201,7 @@ out: if (dp == (struct dirent *)buf && cc < 0) { errno = (int )-cc; + SYSIO_LEAVE; return -1; } cc = (char *)dp - buf; @@ -209,6 +212,7 @@ out: #else off; #endif + SYSIO_LEAVE; return cc; #ifdef __GLIBC__ Index: ioctl.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/ioctl.c,v retrieving revision 1.1.1.1.12.6 retrieving revision 1.1.1.1.12.7 diff -u -w -b -B -p -r1.1.1.1.12.6 -r1.1.1.1.12.7 --- ioctl.c 15 Dec 2003 08:22:16 -0000 1.1.1.1.12.6 +++ ioctl.c 16 Dec 2003 07:07:42 -0000 1.1.1.1.12.7 @@ -63,6 +63,7 @@ ioctl(int fd, unsigned long request, ... int err; struct file *fil; va_list ap; + SYSIO_ENTER; err = 0; fil = _sysio_fd_find(fd); @@ -80,6 +81,7 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: iowait.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/iowait.c,v retrieving revision 1.3.8.4 retrieving revision 1.3.8.5 diff -u -w -b -B -p -r1.3.8.4 -r1.3.8.5 --- iowait.c 15 Dec 2003 08:22:16 -0000 1.3.8.4 +++ iowait.c 16 Dec 2003 07:07:42 -0000 1.3.8.5 @@ -70,13 +70,19 @@ int iodone(ioid_t ioid) { struct ioctx *ioctx; + int rc; + SYSIO_ENTER; ioctx = lookup_ioid(ioid); - if (!ioctx) + if (!ioctx) { + SYSIO_LEAVE; return -1; + } - return (ioctx->ioctx_done || + rc = (ioctx->ioctx_done || (*ioctx->ioctx_ino->i_ops.inop_iodone)(ioctx)); + SYSIO_LEAVE; + return rc; } /* @@ -90,15 +96,19 @@ iowait(ioid_t ioid) { struct ioctx *ioctx; ssize_t cc; + SYSIO_ENTER; ioctx = lookup_ioid(ioid); - if (!ioctx) + if (!ioctx) { + SYSIO_LEAVE; return -1; + } cc = _sysio_ioctx_wait(ioctx); if (cc < 0) { errno = -(int )cc; cc = -1; } + SYSIO_LEAVE; return cc; } Index: lseek.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/lseek.c,v retrieving revision 1.4.2.6 retrieving revision 1.4.2.7 diff -u -w -b -B -p -r1.4.2.6 -r1.4.2.7 --- lseek.c 15 Dec 2003 08:22:16 -0000 1.4.2.6 +++ lseek.c 16 Dec 2003 07:07:42 -0000 1.4.2.7 @@ -115,15 +115,20 @@ lseek(int fd, off_t offset, int whence) { _SYSIO_OFF_T off; off_t rtn; + SYSIO_ENTER; off = _sysio_lseek(fd, offset, whence); - if (off < 0) + if (off < 0) { + SYSIO_LEAVE; return -1; + } rtn = (off_t )off; if ((_SYSIO_OFF_T )rtn != off) { errno = EINVAL; + SYSIO_LEAVE; return -1; } + SYSIO_LEAVE; return rtn; } Index: mkdir.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/mkdir.c,v retrieving revision 1.3.4.2 retrieving revision 1.3.4.3 diff -u -w -b -B -p -r1.3.4.2 -r1.3.4.3 --- mkdir.c 15 Dec 2003 08:22:16 -0000 1.3.4.2 +++ mkdir.c 16 Dec 2003 07:07:42 -0000 1.3.4.3 @@ -58,6 +58,7 @@ mkdir(const char *path, mode_t mode) int err; struct intent intent; struct pnode *pno; + SYSIO_ENTER; INTENT_INIT(&intent, INT_CREAT, &mode, NULL); err = _sysio_namei(_sysio_cwd, path, ND_NEGOK, &intent, &pno); @@ -80,5 +81,7 @@ out: errno = -err; err = -1; } + + SYSIO_LEAVE; return err; } Index: mknod.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/mknod.c,v retrieving revision 1.3.4.3 retrieving revision 1.3.4.4 diff -u -w -b -B -p -r1.3.4.3 -r1.3.4.4 --- mknod.c 15 Dec 2003 08:22:16 -0000 1.3.4.3 +++ mknod.c 16 Dec 2003 07:07:42 -0000 1.3.4.4 @@ -114,8 +114,13 @@ out: static int __mknod(const char *path, mode_t mode, dev_t dev) { + int rc; + SYSIO_ENTER; - return __xmknod(_MKNOD_VER, path, mode, &dev); + rc = __xmknod(_MKNOD_VER, path, mode, &dev); + + SYSIO_LEAVE; + return rc; } sysio_sym_weak_alias(__mknod, mknod) Index: open.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/open.c,v retrieving revision 1.7.2.7 retrieving revision 1.7.2.8 diff -u -w -b -B -p -r1.7.2.7 -r1.7.2.8 --- open.c 15 Dec 2003 08:22:16 -0000 1.7.2.7 +++ open.c 16 Dec 2003 07:07:42 -0000 1.7.2.8 @@ -130,6 +130,7 @@ open(const char *path, int flags, ...) int err; struct pnode *pno; struct file *fil; + SYSIO_ENTER; /* * Get mode argument and determine parameters for namei @@ -197,6 +198,7 @@ open(const char *path, int flags, ...) P_RELE(pno); + SYSIO_LEAVE; return err; error: @@ -205,6 +207,7 @@ error: if (pno) P_RELE(pno); errno = -err; + SYSIO_LEAVE; return -1; } @@ -222,10 +225,12 @@ int close(int fd) { int err; + SYSIO_ENTER; err = _sysio_fd_close(fd); if (err) errno = -err; + SYSIO_LEAVE; return err ? -1 : 0; } Index: read.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/read.c,v retrieving revision 1.2.8.10 retrieving revision 1.2.8.11 diff -u -w -b -B -p -r1.2.8.10 -r1.2.8.11 --- read.c 15 Dec 2003 08:22:16 -0000 1.2.8.10 +++ read.c 16 Dec 2003 07:07:42 -0000 1.2.8.11 @@ -116,14 +116,18 @@ ipreadv(int fd, const struct iovec *iov, { struct file *fil; struct ioctx *ioctxp; + ioid_t rc; + SYSIO_ENTER; fil = _sysio_fd_find(fd); if (!fil) { errno = -EBADF; + SYSIO_LEAVE; return IOID_FAIL; } ioctxp = do_ixreadv(fil, iov, count, offset, NULL); + SYSIO_LEAVE; return ioctxp ? ioctxp->ioctx_id : IOID_FAIL; } @@ -193,16 +197,22 @@ ireadv(int fd, const struct iovec *iov, { struct file *fil; struct ioctx *ioctxp; + ioid_t rc; + SYSIO_ENTER; fil = _sysio_fd_find(fd); if (!fil) { errno = -EBADF; + SYSIO_LEAVE; return IOID_FAIL; } ioctxp = do_ixreadv(fil, iov, count, fil->f_pos, _sysio_fcompletio); - if (!ioctxp) + if (!ioctxp) { + SYSIO_LEAVE; return IOID_FAIL; + } + SYSIO_LEAVE; return ioctxp->ioctx_id; } Index: rmdir.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/rmdir.c,v retrieving revision 1.3.4.3 retrieving revision 1.3.4.4 diff -u -w -b -B -p -r1.3.4.3 -r1.3.4.4 --- rmdir.c 15 Dec 2003 08:22:16 -0000 1.3.4.3 +++ rmdir.c 16 Dec 2003 07:07:42 -0000 1.3.4.4 @@ -58,6 +58,7 @@ rmdir(const char *path) struct intent intent; int err; struct pnode *pno; + SYSIO_ENTER; INTENT_INIT(&intent, INT_UPDPARENT, NULL, NULL); err = _sysio_namei(_sysio_cwd, path, 0, &intent, &pno); @@ -82,5 +83,6 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: stat.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/stat.c,v retrieving revision 1.3.4.4 retrieving revision 1.3.4.5 diff -u -w -b -B -p -r1.3.4.4 -r1.3.4.5 --- stat.c 15 Dec 2003 08:22:16 -0000 1.3.4.4 +++ stat.c 16 Dec 2003 07:07:42 -0000 1.3.4.5 @@ -129,7 +129,13 @@ out: static int __fstat(int fd, struct stat *buf) { - return __fxstat_internal(_STAT_VER, fd, buf); + int rc; + SYSIO_ENTER; + + rc = __fxstat_internal(_STAT_VER, fd, buf); + + SYSIO_LEAVE; + return rc; } sysio_sym_weak_alias(__fstat, fstat) @@ -185,8 +191,13 @@ out: static int __stat(const char *filename, struct stat *buf) { + int rc; + SYSIO_ENTER; - return __xstat(_STAT_VER, filename, buf); + rc = __xstat(_STAT_VER, filename, buf); + + SYSIO_LEAVE; + return rc; } sysio_sym_weak_alias(__stat, stat) @@ -242,8 +253,13 @@ out: static int __lstat(const char *filename, struct stat *buf) { + int rc; + SYSIO_ENTER; + + rc = __lxstat(_STAT_VER, filename, buf); - return __lxstat(_STAT_VER, filename, buf); + SYSIO_LEAVE; + return rc; } sysio_sym_weak_alias(__lstat, lstat) Index: stat64.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/stat64.c,v retrieving revision 1.3.4.4 retrieving revision 1.3.4.5 diff -u -w -b -B -p -r1.3.4.4 -r1.3.4.5 --- stat64.c 15 Dec 2003 08:22:16 -0000 1.3.4.4 +++ stat64.c 16 Dec 2003 07:07:42 -0000 1.3.4.5 @@ -91,7 +91,13 @@ out: int fstat64(int fd, struct stat64 *buf) { - return __fxstat64_internal(_STAT_VER, fd, buf); + int rc; + SYSIO_ENTER; + + rc = __fxstat64_internal(_STAT_VER, fd, buf); + + SYSIO_LEAVE; + return rc; } int @@ -126,8 +132,13 @@ out: int stat64(const char *filename, struct stat64 *buf) { + int rc; + SYSIO_ENTER; - return __xstat64(_STAT_VER, filename, buf); + rc = __xstat64(_STAT_VER, filename, buf); + + SYSIO_LEAVE; + return rc; } int @@ -162,7 +173,12 @@ out: int lstat64(const char *filename, struct stat64 *buf) { + int rc; + SYSIO_ENTER; + + rc = __lxstat64(_STAT_VER, filename, buf); - return __lxstat64(_STAT_VER, filename, buf); + SYSIO_LEAVE; + return rc; } #endif /* !_LARGEFILE64_SOURCE */ Index: statvfs.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/statvfs.c,v retrieving revision 1.3.4.4 retrieving revision 1.3.4.5 diff -u -w -b -B -p -r1.3.4.4 -r1.3.4.5 --- statvfs.c 15 Dec 2003 08:22:16 -0000 1.3.4.4 +++ statvfs.c 16 Dec 2003 07:07:42 -0000 1.3.4.5 @@ -92,6 +92,7 @@ statvfs(const char *path, struct statvfs struct intnl_statvfs _call_buffer; struct intnl_statvfs *_call_buf = &_call_buffer; #endif + SYSIO_ENTER; err = _sysio_namei(_sysio_cwd, path, 0, NULL, &pno); if (err) @@ -109,6 +110,7 @@ err: errno = -err; err = -1; out: + SYSIO_LEAVE; return err; } @@ -123,6 +125,7 @@ fstatvfs(int fd, struct statvfs *buf) struct intnl_statvfs _call_buffer; struct intnl_statvfs *_call_buf = &_call_buffer; #endif + SYSIO_ENTER; err = 0; filp = _sysio_fd_find(fd); @@ -142,6 +145,7 @@ err: errno = -err; err = -1; out: + SYSIO_LEAVE; return err; } #endif /* if !(defined(BSD) || defined(REDSTORM)) */ Index: statvfs64.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/statvfs64.c,v retrieving revision 1.3.4.3 retrieving revision 1.3.4.4 diff -u -w -b -B -p -r1.3.4.3 -r1.3.4.4 --- statvfs64.c 15 Dec 2003 08:22:16 -0000 1.3.4.3 +++ statvfs64.c 16 Dec 2003 07:07:42 -0000 1.3.4.4 @@ -60,6 +60,7 @@ statvfs64(const char *path, struct statv { int err; struct pnode *pno; + SYSIO_ENTER; err = _sysio_namei(_sysio_cwd, path, 0, NULL, &pno); if (err) @@ -72,6 +73,8 @@ out: errno = -err; err = -1; } + + SYSIO_LEAVE; return err; } @@ -80,6 +83,7 @@ fstatvfs64(int fd, struct statvfs64 *buf { int err; struct file *filp; + SYSIO_ENTER; err = 0; filp = _sysio_fd_find(fd); @@ -94,6 +98,8 @@ out: errno = -err; err = -1; } + + SYSIO_LEAVE; return err; } #endif /* if !(defined(BSD) || defined(REDSTORM)) */ Index: symlink.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/symlink.c,v retrieving revision 1.3.4.2 retrieving revision 1.3.4.3 diff -u -w -b -B -p -r1.3.4.2 -r1.3.4.3 --- symlink.c 15 Dec 2003 08:22:16 -0000 1.3.4.2 +++ symlink.c 16 Dec 2003 07:07:42 -0000 1.3.4.3 @@ -58,6 +58,7 @@ symlink(const char *oldpath, const char int err; struct intent intent; struct pnode *pno; + SYSIO_ENTER; INTENT_INIT(&intent, INT_CREAT, NULL, NULL); err = _sysio_namei(_sysio_cwd, newpath, ND_NEGOK, &intent, &pno); @@ -81,5 +82,6 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: truncate.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/truncate.c,v retrieving revision 1.3.4.4 retrieving revision 1.3.4.5 diff -u -w -b -B -p -r1.3.4.4 -r1.3.4.5 --- truncate.c 15 Dec 2003 08:22:16 -0000 1.3.4.4 +++ truncate.c 16 Dec 2003 07:07:42 -0000 1.3.4.5 @@ -84,6 +84,7 @@ _truncate(const char *path, _SYSIO_OFF_T { int err; struct pnode *pno; + SYSIO_ENTER; err = _sysio_namei(_sysio_cwd, path, 0, NULL, &pno); if (err) @@ -96,6 +97,7 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } @@ -120,6 +122,7 @@ _ftruncate(int fd, _SYSIO_OFF_T length) { int err; struct file *fil; + SYSIO_ENTER; err = 0; fil = _sysio_fd_find(fd); @@ -133,6 +136,7 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: unlink.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/unlink.c,v retrieving revision 1.3.4.4 retrieving revision 1.3.4.5 diff -u -w -b -B -p -r1.3.4.4 -r1.3.4.5 --- unlink.c 15 Dec 2003 08:22:16 -0000 1.3.4.4 +++ unlink.c 16 Dec 2003 07:07:42 -0000 1.3.4.5 @@ -58,6 +58,7 @@ unlink(const char *path) struct intent intent; int err; struct pnode *pno; + SYSIO_ENTER; INTENT_INIT(&intent, INT_UPDPARENT, NULL, NULL); err = _sysio_namei(_sysio_cwd, path, ND_NOFOLLOW, &intent, &pno); @@ -82,5 +83,6 @@ out: errno = -err; err = -1; } + SYSIO_LEAVE; return err; } Index: write.c =================================================================== RCS file: /cvsroot/libsysio/libsysio/src/write.c,v retrieving revision 1.2.10.10 retrieving revision 1.2.10.11 diff -u -w -b -B -p -r1.2.10.10 -r1.2.10.11 --- write.c 15 Dec 2003 08:22:16 -0000 1.2.10.10 +++ write.c 16 Dec 2003 07:07:42 -0000 1.2.10.11 @@ -115,14 +115,18 @@ ipwritev(int fd, const struct iovec *iov { struct file *fil; struct ioctx *ioctxp; + ioid_t rc; + SYSIO_ENTER; fil = _sysio_fd_find(fd); if (!fil) { errno = -EBADF; + SYSIO_LEAVE; return IOID_FAIL; } ioctxp = do_ixwritev(fil, iov, count, offset, NULL); + SYSIO_LEAVE; return ioctxp ? ioctxp->ioctx_id : IOID_FAIL; } @@ -192,16 +196,22 @@ iwritev(int fd, const struct iovec *iov, { struct file *fil; struct ioctx *ioctxp; + ioid_t rc; + SYSIO_ENTER; fil = _sysio_fd_find(fd); if (!fil) { errno = -EBADF; + SYSIO_LEAVE; return IOID_FAIL; } ioctxp = do_ixwritev(fil, iov, count, fil->f_pos, _sysio_fcompletio); - if (!ioctxp) + if (!ioctxp) { + SYSIO_LEAVE; return IOID_FAIL; + } + SYSIO_LEAVE; return ioctxp->ioctx_id; } |