summaryrefslogtreecommitdiffstats
path: root/fs/nfs/nfs4session.h
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2015-02-18 11:30:18 -0800
committerTrond Myklebust <trond.myklebust@primarydata.com>2015-02-18 12:28:50 -0800
commit79969dd12e8756f64a999992c0536ccd91bf6e54 (patch)
treeb66d51039b086df40fdc3420a977f10c248f3454 /fs/nfs/nfs4session.h
parent65d2918e716afb89359cfa59734d76c1ff8700cb (diff)
downloadlinux-79969dd12e8756f64a999992c0536ccd91bf6e54.tar.bz2
NFSv4.1: Clean up create_session
Don't decode directly into the shared struct session Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/nfs4session.h')
-rw-r--r--fs/nfs/nfs4session.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/nfs/nfs4session.h b/fs/nfs/nfs4session.h
index b34ada9bc6a2..fc46c7455898 100644
--- a/fs/nfs/nfs4session.h
+++ b/fs/nfs/nfs4session.h
@@ -118,6 +118,12 @@ static inline int nfs4_has_persistent_session(const struct nfs_client *clp)
return 0;
}
+static inline void nfs4_copy_sessionid(struct nfs4_sessionid *dst,
+ const struct nfs4_sessionid *src)
+{
+ memcpy(dst->data, src->data, NFS4_MAX_SESSIONID_LEN);
+}
+
#ifdef CONFIG_CRC32
/*
* nfs_session_id_hash - calculate the crc32 hash for the session id