From: "J. Bruce Fields" <bfields@fieldses.org>
To: "J. Bruce Fields" <bfields@redhat.com>
Cc: stable@vger.kernel.org, linux-nfs@vger.kernel.org,
Stanislav Kinsbursky <skinsbursky@parallels.com>
Subject: [PATCH 4/3] lockd: hard-code init_net in lockd case as well
Date: Wed, 20 Jun 2012 09:27:38 -0400 [thread overview]
Message-ID: <20120620132738.GA30742@fieldses.org> (raw)
In-Reply-To: <1340050049-12880-4-git-send-email-bfields@redhat.com>
From: "J. Bruce Fields" <bfields@redhat.com>
The previous patch missed lockd_down, which has the same problem.
Symptoms were crashes on unmount or reboot.
Note this was fixed in a different way upstream.
Acked-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
---
fs/lockd/svc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/lockd/svc.c b/fs/lockd/svc.c
index f1b3cce..c933df4 100644
--- a/fs/lockd/svc.c
+++ b/fs/lockd/svc.c
@@ -300,7 +300,7 @@ int lockd_up(void)
{
struct svc_serv *serv;
int error = 0;
- struct net *net = current->nsproxy->net_ns;
+ struct net *net = &init_net;
struct lockd_net *ln = net_generic(net, lockd_net_id);
mutex_lock(&nlmsvc_mutex);
@@ -391,7 +391,7 @@ void
lockd_down(void)
{
mutex_lock(&nlmsvc_mutex);
- lockd_down_net(current->nsproxy->net_ns);
+ lockd_down_net(&init_net);
if (nlmsvc_users) {
if (--nlmsvc_users)
goto out;
--
1.7.9.5
next prev parent reply other threads:[~2012-06-20 13:27 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-18 20:07 3.4.z nfsd backports J. Bruce Fields
2012-06-18 20:07 ` [PATCH 1/3] SUNRPC: new svc_bind() routine introduced J. Bruce Fields
2012-06-20 16:34 ` Greg KH
2012-06-20 18:09 ` J. Bruce Fields
2012-06-20 18:18 ` Greg KH
2012-06-25 20:33 ` J. Bruce Fields
2012-06-25 20:44 ` J. Bruce Fields
2012-06-18 20:07 ` [PATCH 2/3] SUNRPC: move per-net operations from svc_destroy() J. Bruce Fields
2012-06-18 20:07 ` [PATCH 3/3] NFS: hard-code init_net for NFS callback transports J. Bruce Fields
2012-06-20 13:27 ` J. Bruce Fields [this message]
2012-06-20 14:54 ` [PATCH 4/3] lockd: hard-code init_net in lockd case as well Greg KH
2012-06-20 16:35 ` 3.4.z nfsd backports Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120620132738.GA30742@fieldses.org \
--to=bfields@fieldses.org \
--cc=bfields@redhat.com \
--cc=linux-nfs@vger.kernel.org \
--cc=skinsbursky@parallels.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).