aboutsummaryrefslogtreecommitdiffstats
path: root/net/rds/tcp.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/rds/tcp.c')
-rw-r--r--net/rds/tcp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/rds/tcp.c b/net/rds/tcp.c
index 61ed2a8764ba..86187dad1440 100644
--- a/net/rds/tcp.c
+++ b/net/rds/tcp.c
@@ -127,7 +127,7 @@ void rds_tcp_restore_callbacks(struct socket *sock,
127 127
128/* 128/*
129 * This is the only path that sets tc->t_sock. Send and receive trust that 129 * This is the only path that sets tc->t_sock. Send and receive trust that
130 * it is set. The RDS_CONN_CONNECTED bit protects those paths from being 130 * it is set. The RDS_CONN_UP bit protects those paths from being
131 * called while it isn't set. 131 * called while it isn't set.
132 */ 132 */
133void rds_tcp_set_callbacks(struct socket *sock, struct rds_connection *conn) 133void rds_tcp_set_callbacks(struct socket *sock, struct rds_connection *conn)
@@ -216,6 +216,7 @@ static int rds_tcp_conn_alloc(struct rds_connection *conn, gfp_t gfp)
216 if (!tc) 216 if (!tc)
217 return -ENOMEM; 217 return -ENOMEM;
218 218
219 mutex_init(&tc->t_conn_lock);
219 tc->t_sock = NULL; 220 tc->t_sock = NULL;
220 tc->t_tinc = NULL; 221 tc->t_tinc = NULL;
221 tc->t_tinc_hdr_rem = sizeof(struct rds_header); 222 tc->t_tinc_hdr_rem = sizeof(struct rds_header);