l2cap_sock.c (39d5a3ee355fa903ef4609402c79f570eb9fc4d2) | l2cap_sock.c (58d35f87effa0235181a24d55576aaa756ef7312) |
---|---|
1/* 2 BlueZ - Bluetooth protocol stack for Linux 3 Copyright (C) 2000-2001 Qualcomm Incorporated 4 Copyright (C) 2009-2010 Gustavo F. Padovan <gustavo@padovan.org> 5 Copyright (C) 2010 Google Inc. 6 7 Written 2000,2001 by Maxim Krasnyansky <maxk@qualcomm.com> 8 --- 750 unchanged lines hidden (view full) --- 759 /* Entire SDU fits into one PDU */ 760 if (len <= pi->chan->remote_mps) { 761 control = L2CAP_SDU_UNSEGMENTED; 762 skb = l2cap_create_iframe_pdu(sk, msg, len, control, 0); 763 if (IS_ERR(skb)) { 764 err = PTR_ERR(skb); 765 goto done; 766 } | 1/* 2 BlueZ - Bluetooth protocol stack for Linux 3 Copyright (C) 2000-2001 Qualcomm Incorporated 4 Copyright (C) 2009-2010 Gustavo F. Padovan <gustavo@padovan.org> 5 Copyright (C) 2010 Google Inc. 6 7 Written 2000,2001 by Maxim Krasnyansky <maxk@qualcomm.com> 8 --- 750 unchanged lines hidden (view full) --- 759 /* Entire SDU fits into one PDU */ 760 if (len <= pi->chan->remote_mps) { 761 control = L2CAP_SDU_UNSEGMENTED; 762 skb = l2cap_create_iframe_pdu(sk, msg, len, control, 0); 763 if (IS_ERR(skb)) { 764 err = PTR_ERR(skb); 765 goto done; 766 } |
767 __skb_queue_tail(TX_QUEUE(sk), skb); | 767 __skb_queue_tail(&pi->chan->tx_q, skb); |
768 | 768 |
769 if (sk->sk_send_head == NULL) 770 sk->sk_send_head = skb; | 769 if (pi->chan->tx_send_head == NULL) 770 pi->chan->tx_send_head = skb; |
771 772 } else { 773 /* Segment SDU into multiples PDUs */ 774 err = l2cap_sar_segment_sdu(pi->chan, msg, len); 775 if (err < 0) 776 goto done; 777 } 778 --- 233 unchanged lines hidden (view full) --- 1012 pi->sec_level = BT_SECURITY_LOW; 1013 pi->role_switch = 0; 1014 pi->force_reliable = 0; 1015 pi->flushable = BT_FLUSHABLE_OFF; 1016 } 1017 1018 /* Default config options */ 1019 pi->flush_to = L2CAP_DEFAULT_FLUSH_TO; | 771 772 } else { 773 /* Segment SDU into multiples PDUs */ 774 err = l2cap_sar_segment_sdu(pi->chan, msg, len); 775 if (err < 0) 776 goto done; 777 } 778 --- 233 unchanged lines hidden (view full) --- 1012 pi->sec_level = BT_SECURITY_LOW; 1013 pi->role_switch = 0; 1014 pi->force_reliable = 0; 1015 pi->flushable = BT_FLUSHABLE_OFF; 1016 } 1017 1018 /* Default config options */ 1019 pi->flush_to = L2CAP_DEFAULT_FLUSH_TO; |
1020 skb_queue_head_init(TX_QUEUE(sk)); | |
1021} 1022 1023static struct proto l2cap_proto = { 1024 .name = "L2CAP", 1025 .owner = THIS_MODULE, 1026 .obj_size = sizeof(struct l2cap_pinfo) 1027}; 1028 --- 106 unchanged lines hidden --- | 1020} 1021 1022static struct proto l2cap_proto = { 1023 .name = "L2CAP", 1024 .owner = THIS_MODULE, 1025 .obj_size = sizeof(struct l2cap_pinfo) 1026}; 1027 --- 106 unchanged lines hidden --- |