Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 203826
b: refs/heads/master
c: 6e2b672
h: refs/heads/master
v: v3
  • Loading branch information
Gustavo F. Padovan authored and Marcel Holtmann committed Jul 21, 2010
1 parent 2edbec1 commit 2bf7cd7
Show file tree
Hide file tree
Showing 2 changed files with 7 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: bc1b1f8bee63966649dd5ac7d10d31a6556bf19b
refs/heads/master: 6e2b6722abaa3f6042357e11f465488b7c12f94c
12 changes: 6 additions & 6 deletions trunk/net/bluetooth/l2cap.c
Original file line number Diff line number Diff line change
Expand Up @@ -1415,11 +1415,8 @@ static int l2cap_ertm_send(struct sock *sk)
u16 control, fcs;
int nsent = 0;

if (pi->conn_state & L2CAP_CONN_WAIT_F)
return 0;

while ((skb = sk->sk_send_head) && (!l2cap_tx_window_full(sk)) &&
!(pi->conn_state & L2CAP_CONN_REMOTE_BUSY)) {
while ((skb = sk->sk_send_head) && (!l2cap_tx_window_full(sk))) {

if (pi->remote_max_tx &&
bt_cb(skb)->retries == pi->remote_max_tx) {
Expand Down Expand Up @@ -1792,6 +1789,11 @@ static int l2cap_sock_sendmsg(struct kiocb *iocb, struct socket *sock, struct ms
if (pi->mode == L2CAP_MODE_STREAMING) {
err = l2cap_streaming_send(sk);
} else {
if (pi->conn_state & L2CAP_CONN_REMOTE_BUSY &&
pi->conn_state && L2CAP_CONN_WAIT_F) {
err = len;
break;
}
spin_lock_bh(&pi->send_lock);
err = l2cap_ertm_send(sk);
spin_unlock_bh(&pi->send_lock);
Expand Down Expand Up @@ -3378,8 +3380,6 @@ static inline void l2cap_send_i_or_rr_or_rnr(struct sock *sk)
if (pi->conn_state & L2CAP_CONN_REMOTE_BUSY && pi->unacked_frames > 0)
__mod_retrans_timer();

pi->conn_state &= ~L2CAP_CONN_REMOTE_BUSY;

spin_lock_bh(&pi->send_lock);
l2cap_ertm_send(sk);
spin_unlock_bh(&pi->send_lock);
Expand Down

0 comments on commit 2bf7cd7

Please sign in to comment.