Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 203852
b: refs/heads/master
c: 6254775
h: refs/heads/master
v: v3
  • Loading branch information
Gustavo F. Padovan authored and Marcel Holtmann committed Jul 21, 2010
1 parent 9554671 commit 52d2d10
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ae12d52efd492ee6634c34322302ac754ff8cde8
refs/heads/master: 625477523b4e656fbcc5ec2a8ca7a1beb39b1caf
17 changes: 11 additions & 6 deletions trunk/net/bluetooth/l2cap.c
Original file line number Diff line number Diff line change
Expand Up @@ -2492,6 +2492,14 @@ static int l2cap_build_conf_req(struct sock *sk, void *data)
case L2CAP_MODE_BASIC:
if (pi->imtu != L2CAP_DEFAULT_MTU)
l2cap_add_conf_opt(&ptr, L2CAP_CONF_MTU, 2, pi->imtu);

rfc.mode = L2CAP_MODE_BASIC;
rfc.txwin_size = 0;
rfc.max_transmit = 0;
rfc.retrans_timeout = 0;
rfc.monitor_timeout = 0;
rfc.max_pdu_size = 0;

break;

case L2CAP_MODE_ERTM:
Expand All @@ -2504,9 +2512,6 @@ static int l2cap_build_conf_req(struct sock *sk, void *data)
if (L2CAP_DEFAULT_MAX_PDU_SIZE > pi->conn->mtu - 10)
rfc.max_pdu_size = cpu_to_le16(pi->conn->mtu - 10);

l2cap_add_conf_opt(&ptr, L2CAP_CONF_RFC,
sizeof(rfc), (unsigned long) &rfc);

if (!(pi->conn->feat_mask & L2CAP_FEAT_FCS))
break;

Expand All @@ -2527,9 +2532,6 @@ static int l2cap_build_conf_req(struct sock *sk, void *data)
if (L2CAP_DEFAULT_MAX_PDU_SIZE > pi->conn->mtu - 10)
rfc.max_pdu_size = cpu_to_le16(pi->conn->mtu - 10);

l2cap_add_conf_opt(&ptr, L2CAP_CONF_RFC,
sizeof(rfc), (unsigned long) &rfc);

if (!(pi->conn->feat_mask & L2CAP_FEAT_FCS))
break;

Expand All @@ -2541,6 +2543,9 @@ static int l2cap_build_conf_req(struct sock *sk, void *data)
break;
}

l2cap_add_conf_opt(&ptr, L2CAP_CONF_RFC, sizeof(rfc),
(unsigned long) &rfc);

/* FIXME: Need actual value of the flush timeout */
//if (flush_to != L2CAP_DEFAULT_FLUSH_TO)
// l2cap_add_conf_opt(&ptr, L2CAP_CONF_FLUSH_TO, 2, pi->flush_to);
Expand Down

0 comments on commit 52d2d10

Please sign in to comment.