Skip to content

Commit

Permalink
Bluetooth: Fix setting of MTU for ERTM and Streaming Mode
Browse files Browse the repository at this point in the history
The desired MTU should be sent in an Config_Req for all modes.

Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
  • Loading branch information
Gustavo F. Padovan committed Feb 8, 2011
1 parent e702112 commit 7990681
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions net/bluetooth/l2cap.c
Original file line number Diff line number Diff line change
Expand Up @@ -2569,11 +2569,11 @@ static int l2cap_build_conf_req(struct sock *sk, void *data)
}

done:
if (pi->imtu != L2CAP_DEFAULT_MTU)
l2cap_add_conf_opt(&ptr, L2CAP_CONF_MTU, 2, pi->imtu);

switch (pi->mode) {
case L2CAP_MODE_BASIC:
if (pi->imtu != L2CAP_DEFAULT_MTU)
l2cap_add_conf_opt(&ptr, L2CAP_CONF_MTU, 2, pi->imtu);

if (!(pi->conn->feat_mask & L2CAP_FEAT_ERTM) &&
!(pi->conn->feat_mask & L2CAP_FEAT_STREAMING))
break;
Expand Down

0 comments on commit 7990681

Please sign in to comment.