diff options
author | Stanislav Kinsbursky <skinsbursky@parallels.com> | 2012-01-31 06:08:13 -0500 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-02-15 00:19:48 -0500 |
commit | 66697bfd6aec0a9ca9331c1aa544ac20324a7561 (patch) | |
tree | f4e16eba25d9b757e256f96d0a1eca58b65a68cb /include | |
parent | bb2224df5ffe4f864f5b696199b17db1ce77bc0a (diff) |
LockD: make nlm hosts network namespace aware
This object depends on RPC client, and thus on network namespace.
So let's make it's allocation and lookup in network namespace context.
Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/lockd/bind.h | 1 | ||||
-rw-r--r-- | include/linux/lockd/lockd.h | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/lockd/bind.h b/include/linux/lockd/bind.h index fbc48f898521..11a966e5f829 100644 --- a/include/linux/lockd/bind.h +++ b/include/linux/lockd/bind.h | |||
@@ -42,6 +42,7 @@ struct nlmclnt_initdata { | |||
42 | unsigned short protocol; | 42 | unsigned short protocol; |
43 | u32 nfs_version; | 43 | u32 nfs_version; |
44 | int noresvport; | 44 | int noresvport; |
45 | struct net *net; | ||
45 | }; | 46 | }; |
46 | 47 | ||
47 | /* | 48 | /* |
diff --git a/include/linux/lockd/lockd.h b/include/linux/lockd/lockd.h index 8949167a148d..94b3d13be426 100644 --- a/include/linux/lockd/lockd.h +++ b/include/linux/lockd/lockd.h | |||
@@ -67,6 +67,7 @@ struct nlm_host { | |||
67 | struct list_head h_reclaim; /* Locks in RECLAIM state */ | 67 | struct list_head h_reclaim; /* Locks in RECLAIM state */ |
68 | struct nsm_handle *h_nsmhandle; /* NSM status handle */ | 68 | struct nsm_handle *h_nsmhandle; /* NSM status handle */ |
69 | char *h_addrbuf; /* address eyecatcher */ | 69 | char *h_addrbuf; /* address eyecatcher */ |
70 | struct net *net; /* host net */ | ||
70 | }; | 71 | }; |
71 | 72 | ||
72 | /* | 73 | /* |
@@ -222,7 +223,8 @@ struct nlm_host *nlmclnt_lookup_host(const struct sockaddr *sap, | |||
222 | const unsigned short protocol, | 223 | const unsigned short protocol, |
223 | const u32 version, | 224 | const u32 version, |
224 | const char *hostname, | 225 | const char *hostname, |
225 | int noresvport); | 226 | int noresvport, |
227 | struct net *net); | ||
226 | void nlmclnt_release_host(struct nlm_host *); | 228 | void nlmclnt_release_host(struct nlm_host *); |
227 | struct nlm_host *nlmsvc_lookup_host(const struct svc_rqst *rqstp, | 229 | struct nlm_host *nlmsvc_lookup_host(const struct svc_rqst *rqstp, |
228 | const char *hostname, | 230 | const char *hostname, |