[Libsysio-commit] cplant: libsysio/drivers/yod fs_yod.c
Brought to you by:
lward
|
From: Ruth K. <rk...@us...> - 2003-06-12 19:48:44
|
Update of /cvsroot/libsysio/libsysio/drivers/yod
In directory sc8-pr-cvs1:/tmp/cvs-serv1643
Modified Files:
Tag: cplant
fs_yod.c
Log Message:
cplant yod has no utime fn; write/read mods/fixes
Index: fs_yod.c
===================================================================
RCS file: /cvsroot/libsysio/libsysio/drivers/yod/Attic/fs_yod.c,v
retrieving revision 1.1.2.4
retrieving revision 1.1.2.5
diff -u -w -b -B -p -r1.1.2.4 -r1.1.2.5
--- fs_yod.c 1 May 2003 22:52:46 -0000 1.1.2.4
+++ fs_yod.c 12 Jun 2003 19:48:37 -0000 1.1.2.5
@@ -650,24 +650,7 @@ yod_inop_setattr(struct pnode *pno,
}
if (err)
mask &= ~SETATTR_MODE;
-#if 0
- else if (mask & (SETATTR_MTIME|SETATTR_ATIME)) {
- struct utimbuf ut;
- /*
- * Alter access and/or modify time attributes.
- */
- ut.actime = st.st_atime;
- ut.modtime = st.st_mtime;
- if (mask & SETATTR_MTIME)
- ut.modtime = stbuf->st_mtime;
- if (mask & SETATTR_ATIME)
- ut.actime = stbuf->st_atime;
- err = utime_yod(path, &ut);
- }
- if (err)
- mask &= ~(SETATTR_MTIME|SETATTR_ATIME);
- else
-#endif
+
if (mask & (SETATTR_UID|SETATTR_GID)) {
/*
@@ -1000,16 +983,11 @@ doio(ssize_t (*f)(int, const struct iove
* Helper function passed to doio(), above, to accomplish a real readv.
*/
static ssize_t
-_readv(int fd, const struct iovec *vector, int count)
+_readv(int fd, const struct iovec *vector, int count __IS_UNUSED)
{
- int i;
- ssize_t total;
-
- for (i = 0; i < count; i++)
- total += read_yod(fd,
- vector[i].iov_base,
- vector[i].iov_len);
- return total;
+ return read_yod(fd,
+ vector[0].iov_base,
+ vector[0].iov_len);
}
static int
@@ -1028,7 +1006,7 @@ static ssize_t
_writev(int fd, const struct iovec *vector, int count)
{
int i;
- ssize_t total;
+ ssize_t total = 0;
for (i = 0; i < count; i++)
total += write_yod(fd,
|