Return-Path: From: Mat Martineau To: linux-bluetooth@vger.kernel.org, gustavo@padovan.org, Andrei.Emeltchenko.news@gmail.com Cc: pkrystad@codeaurora.org Subject: [RFCv0 18/21] Bluetooth: Ignore BR/EDR packet size constraints when fragmenting for AMP Date: Wed, 25 Jul 2012 16:51:10 -0700 Message-Id: <1343260274-11953-19-git-send-email-mathewm@codeaurora.org> In-Reply-To: <1343260274-11953-1-git-send-email-mathewm@codeaurora.org> References: <1343260274-11953-1-git-send-email-mathewm@codeaurora.org> Sender: linux-bluetooth-owner@vger.kernel.org List-ID: Signed-off-by: Mat Martineau --- net/bluetooth/l2cap_core.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c index f430744..e4df53d 100644 --- a/net/bluetooth/l2cap_core.c +++ b/net/bluetooth/l2cap_core.c @@ -2222,7 +2222,9 @@ static int l2cap_segment_sdu(struct l2cap_chan *chan, /* PDU size is derived from the HCI MTU */ pdu_len = chan->conn->mtu; - pdu_len = min_t(size_t, pdu_len, L2CAP_BREDR_MAX_PAYLOAD); + /* Constrain PDU size for BR/EDR connections */ + if (!chan->hs_hcon) + pdu_len = min_t(size_t, pdu_len, L2CAP_BREDR_MAX_PAYLOAD); /* Adjust for largest possible L2CAP overhead. */ if (chan->fcs) -- 1.7.11.2 -- Mat Martineau Employee of Qualcomm Innovation Center, Inc. Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum