aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/bluetooth/l2cap.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/net/bluetooth/l2cap.c b/net/bluetooth/l2cap.c
index c5904082392c..2fb45c481762 100644
--- a/net/bluetooth/l2cap.c
+++ b/net/bluetooth/l2cap.c
@@ -2473,15 +2473,10 @@ static int l2cap_build_conf_req(struct sock *sk, void *data)
2473 switch (pi->mode) { 2473 switch (pi->mode) {
2474 case L2CAP_MODE_STREAMING: 2474 case L2CAP_MODE_STREAMING:
2475 case L2CAP_MODE_ERTM: 2475 case L2CAP_MODE_ERTM:
2476 if (!(pi->conf_state & L2CAP_CONF_STATE2_DEVICE)) { 2476 if (pi->conf_state & L2CAP_CONF_STATE2_DEVICE)
2477 pi->mode = l2cap_select_mode(rfc.mode,
2478 pi->conn->feat_mask);
2479 break; 2477 break;
2480 }
2481 2478
2482 if (!l2cap_mode_supported(pi->mode, pi->conn->feat_mask)) 2479 /* fall through */
2483 l2cap_send_disconn_req(pi->conn, sk, ECONNRESET);
2484 break;
2485 default: 2480 default:
2486 pi->mode = l2cap_select_mode(rfc.mode, pi->conn->feat_mask); 2481 pi->mode = l2cap_select_mode(rfc.mode, pi->conn->feat_mask);
2487 break; 2482 break;