[PATCH] knfsd: nfsd4: fslocations data structures

Define FS locations structures, some functions to manipulate them, and add
code to parse FS locations in downcall and add to the exports structure.

[bfields@fieldses.org: bunch of fixes and cleanups]
Signed-off-by: Manoj Naik <manoj@almaden.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
Manoj Naik
2006-10-04 02:16:18 -07:00
committed by Linus Torvalds
parent b009a873de
commit 933469190e
2 changed files with 134 additions and 4 deletions

View File

@@ -45,6 +45,25 @@
#ifdef __KERNEL__
/*
* FS Locations
*/
#define MAX_FS_LOCATIONS 128
struct nfsd4_fs_location {
char *hosts; /* colon separated list of hosts */
char *path; /* slash separated list of path components */
};
struct nfsd4_fs_locations {
uint32_t locations_count;
struct nfsd4_fs_location *locations;
/* If we're not actually serving this data ourselves (only providing a
* list of replicas that do serve it) then we set "migrated": */
int migrated;
};
struct svc_export {
struct cache_head h;
struct auth_domain * ex_client;
@@ -55,6 +74,7 @@ struct svc_export {
uid_t ex_anon_uid;
gid_t ex_anon_gid;
int ex_fsid;
struct nfsd4_fs_locations ex_fslocs;
};
/* an "export key" (expkey) maps a filehandlefragement to an