summaryrefslogtreecommitdiffstats
path: root/net/bluetooth/l2cap.c
diff options
context:
space:
mode:
authorGustavo F. Padovan <padovan@profusion.mobi>2010-06-09 16:39:05 -0300
committerMarcel Holtmann <marcel@holtmann.org>2010-07-21 10:39:08 -0700
commit2ba13ed678775195e8255b4e503c59d48b615bd8 (patch)
treebcd27d8898526e2f04ed323bdac494566e2cd7ab /net/bluetooth/l2cap.c
parent6c2ea7a8f5fea67fa20e5825401b8fce5a78dbf6 (diff)
downloadop-kernel-dev-2ba13ed678775195e8255b4e503c59d48b615bd8.zip
op-kernel-dev-2ba13ed678775195e8255b4e503c59d48b615bd8.tar.gz
Bluetooth: Remove check for supported mode
Since now we have checks for the supported mode before on l2cap_info_rsp we can remove the check for it here. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth/l2cap.c')
-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 c590408..2fb45c4 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)
switch (pi->mode) {
case L2CAP_MODE_STREAMING:
case L2CAP_MODE_ERTM:
- if (!(pi->conf_state & L2CAP_CONF_STATE2_DEVICE)) {
- pi->mode = l2cap_select_mode(rfc.mode,
- pi->conn->feat_mask);
+ if (pi->conf_state & L2CAP_CONF_STATE2_DEVICE)
break;
- }
- if (!l2cap_mode_supported(pi->mode, pi->conn->feat_mask))
- l2cap_send_disconn_req(pi->conn, sk, ECONNRESET);
- break;
+ /* fall through */
default:
pi->mode = l2cap_select_mode(rfc.mode, pi->conn->feat_mask);
break;
OpenPOWER on IntegriCloud