Browse Source

pNFS: Clear the layout metadata if the server changed the layout stateid

If the server changed the layout stateid's "other" field, then
we should treat the old layout as being completely gone. In that
case, we want to clear the metadata such as scheduled layoutreturns.

Do this by calling pnfs_mark_layout_stateid_invalid().

Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Trond Myklebust 9 years ago
parent
commit
d9b61708fe
1 changed files with 1 additions and 1 deletions
  1. 1 1
      fs/nfs/pnfs.c

+ 1 - 1
fs/nfs/pnfs.c

@@ -1785,7 +1785,7 @@ pnfs_layout_process(struct nfs4_layoutget *lgp)
 		 * inode invalid, and don't bother validating the stateid
 		 * inode invalid, and don't bother validating the stateid
 		 * sequence number.
 		 * sequence number.
 		 */
 		 */
-		pnfs_mark_matching_lsegs_invalid(lo, &free_me, NULL, 0);
+		pnfs_mark_layout_stateid_invalid(lo, &free_me);
 
 
 		nfs4_stateid_copy(&lo->plh_stateid, &res->stateid);
 		nfs4_stateid_copy(&lo->plh_stateid, &res->stateid);
 		lo->plh_barrier = be32_to_cpu(res->stateid.seqid);
 		lo->plh_barrier = be32_to_cpu(res->stateid.seqid);