[pnfs] CVS: nfsv4
Marc Eshel IBM
eshel at citi.umich.edu
Fri Dec 1 19:35:04 EST 2006
CVSROOT: /cvs
Module name: nfsv4
Changes by: eshel at citi. 2006/12/01 19:35:04
Modified files:
cvs/pnfs/fs/nfsd: nfs4pnfsds.c nfs4state.c
Log message:
Use also MDS si_boot to find the right stateid.
Index: nfs4pnfsds.c
===================================================================
RCS file: /cvs/nfsv4/cvs/pnfs/fs/nfsd/nfs4pnfsds.c,v
retrieving revision 1.5
diff -u -r1.5 nfs4pnfsds.c
--- nfs4pnfsds.c 12 Apr 2006 18:03:42 -0000 1.5
+++ nfs4pnfsds.c 2 Dec 2006 00:33:02 -0000
@@ -143,7 +143,8 @@
hashval = stateid_hashval(st_id, f_id);
list_for_each_entry(local, &ds_stid_hashtbl[hashval], ds_hash) {
if ((local->ds_stid.si_stateownerid == st_id) &&
- (local->ds_stid.si_fileid == f_id))
+ (local->ds_stid.si_fileid == f_id) &&
+ (local->ds_stid.si_boot == stid->si_boot))
return local;
}
return NULL;
@@ -312,15 +313,6 @@
return nfserr_bad_stateid;
if (stateid->si_generation > dsp->ds_stid.si_generation)
return nfserr_bad_stateid;
-#if 0
- /* STALE STATEID
- * XXX are we going to require the mds to send it's boot time
- * to enable the stale stateid check?
- struct pnfs_mds_id *mdp = ?? back pointer in dsp, or mdsdevid..in dsp.
- */
- if (stateid->si_boot == mdp->di_mdsboot)
- return nfserr_stale_stateid;
-#endif
/* OLD STATEID */
if (stateid->si_generation < dsp->ds_stid.si_generation)
Index: nfs4state.c
===================================================================
RCS file: /cvs/nfsv4/cvs/pnfs/fs/nfsd/nfs4state.c,v
retrieving revision 1.16
diff -u -r1.16 nfs4state.c
--- nfs4state.c 30 Nov 2006 16:43:18 -0000 1.16
+++ nfs4state.c 2 Dec 2006 00:33:03 -0000
@@ -3527,7 +3527,7 @@
int nfs4_pnfs_get_layout(struct super_block *sb, struct svc_fh *current_fh,
struct nfsd4_pnfs_layoutget *lgp)
{
- int i, status = -ENOENT;
+ int status = -ENOENT;
struct inode *ino = current_fh->fh_dentry->d_inode;
struct nfs4_file *fp;
struct nfs4_client *clp = NULL;
More information about the pNFS
mailing list