* [PATCH] Bluetooth: Increment unacked_frames count only the first transmit
@ 2011-03-09 9:14 Suraj Sumangala
2011-03-11 17:59 ` Gustavo F. Padovan
0 siblings, 1 reply; 2+ messages in thread
From: Suraj Sumangala @ 2011-03-09 9:14 UTC (permalink / raw)
To: linux-bluetooth; +Cc: Jothikumar.Mothilal, Suraj Sumangala
This patch lets 'l2cap_pinfo.unacked_frames' be incremented only
the first time a frame is transmitted.
Previously it was being incremented for retransmitted packets
too resulting the value to cross the transmit window size.
Signed-off-by: Suraj Sumangala <suraj@atheros.com>
---
net/bluetooth/l2cap_core.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index c9f9cec..ca27f3a 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -1116,7 +1116,9 @@ int l2cap_ertm_send(struct sock *sk)
bt_cb(skb)->tx_seq = pi->next_tx_seq;
pi->next_tx_seq = (pi->next_tx_seq + 1) % 64;
- pi->unacked_frames++;
+ if (bt_cb(skb)->retries == 1)
+ pi->unacked_frames++;
+
pi->frames_sent++;
if (skb_queue_is_last(TX_QUEUE(sk), skb))
--
1.7.0.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Bluetooth: Increment unacked_frames count only the first transmit
2011-03-09 9:14 [PATCH] Bluetooth: Increment unacked_frames count only the first transmit Suraj Sumangala
@ 2011-03-11 17:59 ` Gustavo F. Padovan
0 siblings, 0 replies; 2+ messages in thread
From: Gustavo F. Padovan @ 2011-03-11 17:59 UTC (permalink / raw)
To: Suraj Sumangala; +Cc: linux-bluetooth, Jothikumar.Mothilal
Hi Suraj,
* Suraj Sumangala <suraj@atheros.com> [2011-03-09 14:44:05 +0530]:
> This patch lets 'l2cap_pinfo.unacked_frames' be incremented only
> the first time a frame is transmitted.
>
> Previously it was being incremented for retransmitted packets
> too resulting the value to cross the transmit window size.
>
> Signed-off-by: Suraj Sumangala <suraj@atheros.com>
> ---
> net/bluetooth/l2cap_core.c | 4 +++-
> 1 files changed, 3 insertions(+), 1 deletions(-)
Applied, thanks.
--
Gustavo F. Padovan
http://profusion.mobi
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-03-11 17:59 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-09 9:14 [PATCH] Bluetooth: Increment unacked_frames count only the first transmit Suraj Sumangala
2011-03-11 17:59 ` Gustavo F. Padovan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).