summaryrefslogtreecommitdiffstats
path: root/include/linux/nfsd/export.h
diff options
context:
space:
mode:
authorNeilBrown2007-02-14 09:33:12 +0100
committerLinus Torvalds2007-02-14 17:09:53 +0100
commitaf6a4e280e3ff453653f39190b57b345ff0bec16 (patch)
tree4895c90613737db7354f43431ed10a55dc0c98f0 /include/linux/nfsd/export.h
parent[PATCH] knfsd: tidy up choice of filesystem-identifier when creating a fileha... (diff)
downloadkernel-qcow2-linux-af6a4e280e3ff453653f39190b57b345ff0bec16.tar.gz
kernel-qcow2-linux-af6a4e280e3ff453653f39190b57b345ff0bec16.tar.xz
kernel-qcow2-linux-af6a4e280e3ff453653f39190b57b345ff0bec16.zip
[PATCH] knfsd: add some new fsid types
Add support for using a filesystem UUID to identify and export point in the filehandle. For NFSv2, this UUID is xor-ed down to 4 or 8 bytes so that it doesn't take up too much room. For NFSv3+, we use the full 16 bytes, and possibly also a 64bit inode number for exports beneath the root of a filesystem. When generating an fsid to return in 'stat' information, use the UUID (hashed down to size) if it is available and a small 'fsid' was not specifically provided. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/nfsd/export.h')
-rw-r--r--include/linux/nfsd/export.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/nfsd/export.h b/include/linux/nfsd/export.h
index 045e38cdbe64..9f62d6182d32 100644
--- a/include/linux/nfsd/export.h
+++ b/include/linux/nfsd/export.h
@@ -74,19 +74,20 @@ struct svc_export {
uid_t ex_anon_uid;
gid_t ex_anon_gid;
int ex_fsid;
+ unsigned char * ex_uuid; /* 16 byte fsid */
struct nfsd4_fs_locations ex_fslocs;
};
/* an "export key" (expkey) maps a filehandlefragement to an
- * svc_export for a given client. There can be two per export, one
- * for type 0 (dev/ino), one for type 1 (fsid)
+ * svc_export for a given client. There can be several per export,
+ * for the different fsid types.
*/
struct svc_expkey {
struct cache_head h;
struct auth_domain * ek_client;
int ek_fsidtype;
- u32 ek_fsid[3];
+ u32 ek_fsid[6];
struct vfsmount * ek_mnt;
struct dentry * ek_dentry;