diff options
author | Trond Myklebust <trond.myklebust@primarydata.com> | 2015-12-28 11:48:14 -0500 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@primarydata.com> | 2015-12-28 14:33:04 -0500 |
commit | 0654cc726fc6eed6dca915fb65ba7975716ea080 (patch) | |
tree | 367e0058259d17d89ffec6d02ea333aa4bb5485f /fs/nfs/pnfs.c | |
parent | ab7d763e477c5be33ac9cffc68e808bbd69371f7 (diff) | |
download | linux-stable-0654cc726fc6eed6dca915fb65ba7975716ea080.tar.gz linux-stable-0654cc726fc6eed6dca915fb65ba7975716ea080.tar.bz2 linux-stable-0654cc726fc6eed6dca915fb65ba7975716ea080.zip |
NFSv4.1/pNFS: Add a helper to mark the layout as returned
This ensures that we don't reuse the stateid if a layout return or
implied layout return means that we've returned all layout segments
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/pnfs.c')
-rw-r--r-- | fs/nfs/pnfs.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c index 6095a8d42766..b3fb6bb02275 100644 --- a/fs/nfs/pnfs.c +++ b/fs/nfs/pnfs.c @@ -1149,6 +1149,7 @@ void pnfs_roc_set_barrier(struct inode *ino, u32 barrier) spin_lock(&ino->i_lock); lo = NFS_I(ino)->layout; + pnfs_mark_layout_returned_if_empty(lo); if (pnfs_seqid_is_newer(barrier, lo->plh_barrier)) lo->plh_barrier = barrier; spin_unlock(&ino->i_lock); |