diff options
author | Bryan Schumaker <bjschuma@netapp.com> | 2012-07-30 16:05:23 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-07-30 19:06:41 -0400 |
commit | ddda8e0aa8b955e20cb80908189bfa154ab54837 (patch) | |
tree | ff5b1041ce86c76519c1b824161ce5d7ad2e49db /fs/nfs/client.c | |
parent | fac1e8e4ef417e958060a6c3a061cc1a180bd8ae (diff) |
NFS: Convert v2 into a module
The module (nfs2.ko) will be created in the same directory as nfs.ko and
will be automatically loaded the first time you try to mount over NFS v2.
Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/client.c')
-rw-r--r-- | fs/nfs/client.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/nfs/client.c b/fs/nfs/client.c index 1f2908287cba..fa8acf510333 100644 --- a/fs/nfs/client.c +++ b/fs/nfs/client.c | |||
@@ -149,11 +149,7 @@ EXPORT_SYMBOL_GPL(unregister_nfs_version); | |||
149 | */ | 149 | */ |
150 | int __init nfs_register_versions(void) | 150 | int __init nfs_register_versions(void) |
151 | { | 151 | { |
152 | int err = init_nfs_v2(); | 152 | int err = init_nfs_v3(); |
153 | if (err) | ||
154 | return err; | ||
155 | |||
156 | err = init_nfs_v3(); | ||
157 | if (err) | 153 | if (err) |
158 | return err; | 154 | return err; |
159 | 155 | ||
@@ -165,7 +161,6 @@ int __init nfs_register_versions(void) | |||
165 | */ | 161 | */ |
166 | void nfs_unregister_versions(void) | 162 | void nfs_unregister_versions(void) |
167 | { | 163 | { |
168 | exit_nfs_v2(); | ||
169 | exit_nfs_v3(); | 164 | exit_nfs_v3(); |
170 | exit_nfs_v4(); | 165 | exit_nfs_v4(); |
171 | } | 166 | } |
@@ -222,6 +217,7 @@ error_cleanup: | |||
222 | error_0: | 217 | error_0: |
223 | return ERR_PTR(err); | 218 | return ERR_PTR(err); |
224 | } | 219 | } |
220 | EXPORT_SYMBOL_GPL(nfs_alloc_client); | ||
225 | 221 | ||
226 | #ifdef CONFIG_NFS_V4 | 222 | #ifdef CONFIG_NFS_V4 |
227 | /* idr_remove_all is not needed as all id's are removed by nfs_put_client */ | 223 | /* idr_remove_all is not needed as all id's are removed by nfs_put_client */ |
@@ -284,6 +280,7 @@ void nfs_free_client(struct nfs_client *clp) | |||
284 | 280 | ||
285 | dprintk("<-- nfs_free_client()\n"); | 281 | dprintk("<-- nfs_free_client()\n"); |
286 | } | 282 | } |
283 | EXPORT_SYMBOL_GPL(nfs_free_client); | ||
287 | 284 | ||
288 | /* | 285 | /* |
289 | * Release a reference to a shared client record | 286 | * Release a reference to a shared client record |
@@ -753,6 +750,7 @@ error: | |||
753 | dprintk("<-- nfs_init_client() = xerror %d\n", error); | 750 | dprintk("<-- nfs_init_client() = xerror %d\n", error); |
754 | return ERR_PTR(error); | 751 | return ERR_PTR(error); |
755 | } | 752 | } |
753 | EXPORT_SYMBOL_GPL(nfs_init_client); | ||
756 | 754 | ||
757 | /* | 755 | /* |
758 | * Create a version 2 or 3 client | 756 | * Create a version 2 or 3 client |
@@ -1122,6 +1120,7 @@ error: | |||
1122 | nfs_free_server(server); | 1120 | nfs_free_server(server); |
1123 | return ERR_PTR(error); | 1121 | return ERR_PTR(error); |
1124 | } | 1122 | } |
1123 | EXPORT_SYMBOL_GPL(nfs_create_server); | ||
1125 | 1124 | ||
1126 | /* | 1125 | /* |
1127 | * Clone an NFS2, NFS3 or NFS4 server record | 1126 | * Clone an NFS2, NFS3 or NFS4 server record |
@@ -1191,6 +1190,7 @@ out_free_server: | |||
1191 | dprintk("<-- nfs_clone_server() = error %d\n", error); | 1190 | dprintk("<-- nfs_clone_server() = error %d\n", error); |
1192 | return ERR_PTR(error); | 1191 | return ERR_PTR(error); |
1193 | } | 1192 | } |
1193 | EXPORT_SYMBOL_GPL(nfs_clone_server); | ||
1194 | 1194 | ||
1195 | void nfs_clients_init(struct net *net) | 1195 | void nfs_clients_init(struct net *net) |
1196 | { | 1196 | { |