Bluetooth: Ignore BR/EDR packet size constraints when fragmenting for AMP
When operating over BR/EDR, ERTM accounts for the maximum over-the-air packet size when setting the PDU size. AMP controllers do not use the same over-the-air packets, so the PDU size should only be based on the HCI MTU of the AMP controller. Signed-off-by: Mat Martineau <mathewm@codeaurora.org> Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com> Acked-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
This commit is contained in:
parent
36c86c8566
commit
a549574da3
1 changed files with 3 additions and 1 deletions
|
@ -2272,6 +2272,8 @@ static int l2cap_segment_sdu(struct l2cap_chan *chan,
|
|||
/* PDU size is derived from the HCI MTU */
|
||||
pdu_len = chan->conn->mtu;
|
||||
|
||||
/* 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. */
|
||||
|
|
Loading…
Reference in a new issue