diff options
| author | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2026-03-16 14:34:13 -0400 |
|---|---|---|
| committer | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2026-04-13 09:17:52 -0400 |
| commit | 15bf35a660eb82a49f8397fc3d3acada8dae13db (patch) | |
| tree | 6534d56ae2c90e620979a0fa31ffe97953948706 | |
| parent | 9f168e4de5fd43766f6d49b393f445be805c1e05 (diff) | |
| download | linux-15bf35a660eb82a49f8397fc3d3acada8dae13db.tar.gz linux-15bf35a660eb82a49f8397fc3d3acada8dae13db.zip | |
Bluetooth: L2CAP: Fix printing wrong information if SDU length exceeds MTU
The code was printing skb->len and sdu_len in the places where it should
be sdu_len and chan->imtu respectively to match the if conditions.
Link: https://lore.kernel.org/linux-bluetooth/20260315132013.75ab40c5@kernel.org/T/#m1418f9c82eeff8510c1beaa21cf53af20db96c06
Fixes: e1d9a6688986 ("Bluetooth: LE L2CAP: Disconnect if received packet's SDU exceeds IMTU")
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Reviewed-by: Paul Menzel <pmenzel@molgen.mpg.de>
| -rw-r--r-- | net/bluetooth/l2cap_core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c index 9916ae6abef0..5a4cd530ef33 100644 --- a/net/bluetooth/l2cap_core.c +++ b/net/bluetooth/l2cap_core.c @@ -6740,7 +6740,7 @@ static int l2cap_ecred_data_rcv(struct l2cap_chan *chan, struct sk_buff *skb) if (sdu_len > chan->imtu) { BT_ERR("Too big LE L2CAP SDU length: len %u > %u", - skb->len, sdu_len); + sdu_len, chan->imtu); l2cap_send_disconn_req(chan, ECONNRESET); err = -EMSGSIZE; goto failed; |
