Blob Blame History Raw
From: Ilya Dryomov <idryomov@gmail.com>
Date: Mon, 14 Oct 2019 16:25:32 +0200
Subject: libceph: drop unnecessary check from dispatch() in mon_client.c
Git-commit: d8f544c30ba0ec7b3e5d0dd2c4258181b2adb8a0
Patch-mainline: v5.5-rc1
References: jsc#SES-1134

con->private is set in ceph_con_init() and is never cleared.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Acked-by: Luis Henriques <lhenriques@suse.com>
---
 net/ceph/mon_client.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/net/ceph/mon_client.c b/net/ceph/mon_client.c
index 7256c402ebaa..9d9e4e4ea600 100644
--- a/net/ceph/mon_client.c
+++ b/net/ceph/mon_client.c
@@ -1233,9 +1233,6 @@ static void dispatch(struct ceph_connection *con, struct ceph_msg *msg)
 	struct ceph_mon_client *monc = con->private;
 	int type = le16_to_cpu(msg->hdr.type);
 
-	if (!monc)
-		return;
-
 	switch (type) {
 	case CEPH_MSG_AUTH_REPLY:
 		handle_auth_reply(monc, msg);