[PVFS2-CVS]
commit by slang in pvfs2/test/client/sysint: acache-torture.c
set-info.c
CVS commit program
cvs at parl.clemson.edu
Tue Aug 23 15:44:21 EDT 2005
Update of /projects/cvsroot/pvfs2/test/client/sysint
In directory parlweb:/tmp/cvs-serv20354/test/client/sysint
Modified Files:
acache-torture.c set-info.c
Log Message:
merged acache changes to trunk.
Index: acache-torture.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/test/client/sysint/acache-torture.c,v
diff -p -u -r1.4 -r1.5
--- acache-torture.c 5 Oct 2004 16:03:10 -0000 1.4
+++ acache-torture.c 23 Aug 2005 18:44:21 -0000 1.5
@@ -35,6 +35,13 @@ int main(int argc, char **argv)
gossip_enable_stderr();
gossip_set_debug_mask(1, GOSSIP_ACACHE_DEBUG);
+ ret = PINT_cached_config_initialize();
+ if(ret < 0)
+ {
+ gossip_err("cached_config_initialize() failure.\n");
+ return -1;
+ }
+
/* initialize the cache */
ret = PINT_acache_initialize();
if(ret < 0)
@@ -50,7 +57,7 @@ int main(int argc, char **argv)
tmp.handle = (PVFS_handle)i;
tmp.fs_id = (PVFS_fs_id)(i + 1000);
- pinode1 = PINT_acache_lookup(tmp, NULL);
+ pinode1 = PINT_acache_lookup(tmp, NULL, NULL);
assert(pinode1 == NULL);
pinode1 = PINT_acache_pinode_alloc();
@@ -71,10 +78,10 @@ int main(int argc, char **argv)
tmp.handle = (PVFS_handle)i;
tmp.fs_id = (PVFS_fs_id)(i + 1000);
- pinode2 = PINT_acache_lookup(tmp, NULL);
+ pinode2 = PINT_acache_lookup(tmp, NULL, NULL);
assert(pinode2);
- if (PINT_acache_pinode_status(pinode2) != PINODE_STATUS_VALID)
+ if (PINT_acache_pinode_status(pinode2, NULL) != PINODE_STATUS_VALID)
{
gossip_err("(1) Failure: lookup returned %Lu when it "
"should've returned %Lu.\n",
@@ -91,10 +98,10 @@ int main(int argc, char **argv)
tmp.handle = (PVFS_handle)i;
tmp.fs_id = (PVFS_fs_id)(i + 1000);
- pinode2 = PINT_acache_lookup(tmp, NULL);
+ pinode2 = PINT_acache_lookup(tmp, NULL, NULL);
assert(pinode2);
- if (PINT_acache_pinode_status(pinode2) == PINODE_STATUS_VALID)
+ if (PINT_acache_pinode_status(pinode2, NULL) == PINODE_STATUS_VALID)
{
gossip_err("(2) Failure: lookup returned %Lu when it "
"should've been expired.\n",
@@ -112,10 +119,10 @@ int main(int argc, char **argv)
tmp.handle = (PVFS_handle)i;
tmp.fs_id = (PVFS_fs_id)(i + 1000);
- pinode2 = PINT_acache_lookup(tmp, NULL);
+ pinode2 = PINT_acache_lookup(tmp, NULL, NULL);
assert(pinode2);
- if (PINT_acache_pinode_status(pinode2) != PINODE_STATUS_VALID)
+ if (PINT_acache_pinode_status(pinode2, NULL) != PINODE_STATUS_VALID)
{
gossip_err("(3) Failure: lookup returned %Lu when it "
"should've returned %Lu.\n",
@@ -140,7 +147,7 @@ int main(int argc, char **argv)
tmp.handle = (PVFS_handle)i;
tmp.fs_id = (PVFS_fs_id)(i + 1000);
- PINT_acache_release_refn(tmp);
+ PINT_acache_invalidate(tmp);
}
PINT_acache_finalize();
Index: set-info.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/test/client/sysint/set-info.c,v
diff -p -u -r1.24 -r1.25
--- set-info.c 1 Sep 2004 17:32:03 -0000 1.24
+++ set-info.c 23 Aug 2005 18:44:21 -0000 1.25
@@ -89,12 +89,12 @@ int main(int argc, char **argv)
/* take the retrieved attributes and update the modification time */
resp_getattr.attr.mtime = time(NULL);
- resp_getattr.attr.mask &= ~PVFS_ATTR_COMMON_TYPE;
+ resp_getattr.attr.mask &= ~PVFS_ATTR_SYS_TYPE;
/*
explicitly set the PVFS_ATTR_COMMON_ATIME, since we
want to update the atime field in particular
*/
- resp_getattr.attr.mask |= PVFS_ATTR_COMMON_ATIME;
+ resp_getattr.attr.mask |= PVFS_ATTR_SYS_ATIME;
/* use stored credentials here */
credentials.uid = resp_getattr.attr.owner;
More information about the PVFS2-CVS
mailing list