diff options
Diffstat (limited to 'net/bluetooth/hidp/core.c')
-rw-r--r-- | net/bluetooth/hidp/core.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c index cc25d0b74b36..07348e142f16 100644 --- a/net/bluetooth/hidp/core.c +++ b/net/bluetooth/hidp/core.c | |||
@@ -1314,13 +1314,14 @@ int hidp_connection_add(struct hidp_connadd_req *req, | |||
1314 | { | 1314 | { |
1315 | struct hidp_session *session; | 1315 | struct hidp_session *session; |
1316 | struct l2cap_conn *conn; | 1316 | struct l2cap_conn *conn; |
1317 | struct l2cap_chan *chan = l2cap_pi(ctrl_sock->sk)->chan; | 1317 | struct l2cap_chan *chan; |
1318 | int ret; | 1318 | int ret; |
1319 | 1319 | ||
1320 | ret = hidp_verify_sockets(ctrl_sock, intr_sock); | 1320 | ret = hidp_verify_sockets(ctrl_sock, intr_sock); |
1321 | if (ret) | 1321 | if (ret) |
1322 | return ret; | 1322 | return ret; |
1323 | 1323 | ||
1324 | chan = l2cap_pi(ctrl_sock->sk)->chan; | ||
1324 | conn = NULL; | 1325 | conn = NULL; |
1325 | l2cap_chan_lock(chan); | 1326 | l2cap_chan_lock(chan); |
1326 | if (chan->conn) | 1327 | if (chan->conn) |