From: "J. Bruce Fields" <bfields@redhat.com>
To: linux-nfs@vger.kernel.org
Cc: "J. Bruce Fields" <bfields@redhat.com>
Subject: [PATCH 8/8] nfsd4: remove redundant callback probe
Date: Mon, 1 Oct 2012 13:46:52 -0400 [thread overview]
Message-ID: <1349113612-30374-9-git-send-email-bfields@redhat.com> (raw)
In-Reply-To: <1349113612-30374-1-git-send-email-bfields@redhat.com>
From: "J. Bruce Fields" <bfields@redhat.com>
Both nfsd4_init_conn and alloc_init_session are probing the callback
channel, harmless but pointless.
Also, nfsd4_init_conn should probably be probing in the "unknown" case
as well. In fact I don't see any harm to just doing it unconditionally
when we get a new backchannel connection.
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
---
fs/nfsd/nfs4state.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 592cd7f..773b903 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -861,8 +861,7 @@ static void nfsd4_init_conn(struct svc_rqst *rqstp, struct nfsd4_conn *conn, str
if (ret)
/* oops; xprt is already down: */
nfsd4_conn_lost(&conn->cn_xpt_user);
- if (ses->se_client->cl_cb_state == NFSD4_CB_DOWN &&
- conn->cn_flags & NFS4_CDFC4_BACK) {
+ if (conn->cn_flags & NFS4_CDFC4_BACK) {
/* callback channel may be back up */
nfsd4_probe_callback(ses->se_client);
}
@@ -979,7 +978,6 @@ static struct nfsd4_session *init_session(struct svc_rqst *rqstp, struct nfsd4_s
rpc_copy_addr((struct sockaddr *)&clp->cl_cb_conn.cb_addr, sa);
clp->cl_cb_conn.cb_addrlen = svc_addr_len(sa);
}
- nfsd4_probe_callback(clp);
return new;
}
--
1.7.9.5
prev parent reply other threads:[~2012-10-01 17:46 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-01 17:46 4.1 session allocation cleanup J. Bruce Fields
2012-10-01 17:46 ` [PATCH 1/8] nfsd4: reject bad forechannel attrs earlier J. Bruce Fields
2012-10-01 17:46 ` [PATCH 2/8] nfsd4: separate connection allocation and initialization J. Bruce Fields
2012-10-01 17:46 ` [PATCH 3/8] nfsd4: new_conn_from_crses should only allocate J. Bruce Fields
2012-10-01 17:46 ` [PATCH 4/8] nfsd4: minor free_session cleanup J. Bruce Fields
2012-10-01 17:46 ` [PATCH 5/8] nfsd4: clean up session allocation J. Bruce Fields
2012-10-01 17:46 ` [PATCH 6/8] nfsd4: separate session allocation and initialization J. Bruce Fields
2012-10-01 17:46 ` [PATCH 7/8] nfsd4: expire old client earlier J. Bruce Fields
2012-10-01 17:46 ` J. Bruce Fields [this message]
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=1349113612-30374-9-git-send-email-bfields@redhat.com \
--to=bfields@redhat.com \
--cc=linux-nfs@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).