aboutsummaryrefslogtreecommitdiff
path: root/fs/nfs/inode.c
diff options
context:
space:
mode:
authorBryan Schumaker <bjschuma@netapp.com>2012-07-30 16:05:16 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2012-07-30 19:04:17 -0400
commitab7017a3a0a64b953e091619c30413b3721d925d (patch)
tree1ec947c2794b217d7ead01ee29d8cc5aae4c51f8 /fs/nfs/inode.c
parenta427b9ec4eda8cd6e641ea24541d30b641fc3140 (diff)
NFS: Add version registering framework
This patch adds in the code to track multiple versions of the NFS protocol. I created default structures for v2, v3 and v4 so that each version can continue to work while I convert them into kernel modules. I also removed the const parameter from the rpc_version array so that I can change it at runtime. Signed-off-by: Bryan Schumaker <bjschuma@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/inode.c')
-rw-r--r--fs/nfs/inode.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
index 35f7e4bc680..e8877c82582 100644
--- a/fs/nfs/inode.c
+++ b/fs/nfs/inode.c
@@ -50,6 +50,7 @@
#include "fscache.h"
#include "dns_resolve.h"
#include "pnfs.h"
+#include "nfs.h"
#include "netns.h"
#define NFSDBG_FACILITY NFSDBG_VFS
@@ -1671,21 +1672,17 @@ static int __init init_nfs_fs(void)
rpc_proc_register(&init_net, &nfs_rpcstat);
#endif
-#ifdef CONFIG_NFS_V4
- err = init_nfs_v4();
+ err = nfs_register_versions();
if (err)
goto out1;
-#endif
if ((err = register_nfs_fs()) != 0)
goto out0;
return 0;
out0:
-#ifdef CONFIG_NFS_V4
- exit_nfs_v4();
+ nfs_unregister_versions();
out1:
-#endif
#ifdef CONFIG_PROC_FS
rpc_proc_unregister(&init_net, "nfs");
#endif