diff options
author | Mat Martineau <mathewm@codeaurora.org> | 2012-04-11 13:48:42 -0400 |
---|---|---|
committer | Gustavo Padovan <gustavo@padovan.org> | 2012-05-09 00:40:30 -0400 |
commit | 3c588192b5e5328cdfc8e299c55477004d397208 (patch) | |
tree | 1bedbf322a6b1ded901dc00724e5f8c290098997 /include/net/bluetooth/l2cap.h | |
parent | 9033894722ec595053c92bfa4359b37e7bc91b78 (diff) |
Bluetooth: Add the l2cap_seq_list structure for tracking frames
A sequence list is a data structure used to track frames that need to
be retransmitted, and frames that have been requested for
retransmission by the remote device. It can compactly represent a
list of sequence numbers within the ERTM transmit window. Memory for
the list is allocated once at connection time, and common operations
in ERTM are O(1).
Signed-off-by: Mat Martineau <mathewm@codeaurora.org>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'include/net/bluetooth/l2cap.h')
-rw-r--r-- | include/net/bluetooth/l2cap.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/net/bluetooth/l2cap.h b/include/net/bluetooth/l2cap.h index a756c2406306..e33165476e83 100644 --- a/include/net/bluetooth/l2cap.h +++ b/include/net/bluetooth/l2cap.h | |||
@@ -407,6 +407,16 @@ struct l2cap_conn_param_update_rsp { | |||
407 | #define L2CAP_CONN_PARAM_REJECTED 0x0001 | 407 | #define L2CAP_CONN_PARAM_REJECTED 0x0001 |
408 | 408 | ||
409 | /* ----- L2CAP channels and connections ----- */ | 409 | /* ----- L2CAP channels and connections ----- */ |
410 | struct l2cap_seq_list { | ||
411 | __u16 head; | ||
412 | __u16 tail; | ||
413 | __u16 mask; | ||
414 | __u16 *list; | ||
415 | }; | ||
416 | |||
417 | #define L2CAP_SEQ_LIST_CLEAR 0xFFFF | ||
418 | #define L2CAP_SEQ_LIST_TAIL 0x8000 | ||
419 | |||
410 | struct srej_list { | 420 | struct srej_list { |
411 | __u16 tx_seq; | 421 | __u16 tx_seq; |
412 | struct list_head list; | 422 | struct list_head list; |
@@ -501,6 +511,8 @@ struct l2cap_chan { | |||
501 | struct sk_buff *tx_send_head; | 511 | struct sk_buff *tx_send_head; |
502 | struct sk_buff_head tx_q; | 512 | struct sk_buff_head tx_q; |
503 | struct sk_buff_head srej_q; | 513 | struct sk_buff_head srej_q; |
514 | struct l2cap_seq_list srej_list; | ||
515 | struct l2cap_seq_list retrans_list; | ||
504 | struct list_head srej_l; | 516 | struct list_head srej_l; |
505 | 517 | ||
506 | struct list_head list; | 518 | struct list_head list; |