From: Chris Lu <chris.lu@mediatek.com>
To: Marcel Holtmann <marcel@holtmann.org>,
Johan Hedberg <johan.hedberg@gmail.com>,
Luiz Von Dentz <luiz.dentz@gmail.com>
Cc: Hao Qin <hao.qin@mediatek.com>,
Wenlong Tian <ot_wenlong.tian@mediatek.com>,
Sean Wang <sean.wang@mediatek.com>,
Will Lee <will-cy.Lee@mediatek.com>, SS Wu <ss.wu@mediatek.com>,
linux-bluetooth <linux-bluetooth@vger.kernel.org>,
linux-kernel <linux-kernel@vger.kernel.org>,
linux-mediatek <linux-mediatek@lists.infradead.org>,
Chris Lu <chris.lu@mediatek.com>
Subject: [PATCH 0/2] Bluetooth: btmtk: fix ISO data reception
Date: Tue, 13 Oct 2026 16:18:21 +0800 [thread overview]
Message-ID: <20261013081823.817996-1-chris.lu@mediatek.com> (raw)
Two problems in btmtk_recv_isopkt(), both found while debugging LE Audio
on MT7925. The function is shared by every MediaTek USB controller that
supports ISO data, so neither is specific to that part.
Patch 1 stops the zero padding emitted by the ISO interrupt IN endpoint
from being parsed as ISO packets. The endpoint delivers one packet per
264-byte transfer and zero-fills the rest; the driver turns every four
zero bytes into a handle 0 packet with Data_Total_Length 0 and reports it
to the stack. A single transfer can inject up to 64 of them, which is
what fills the HCI log with malformed ISO frames, and a valid SDU is lost
whenever handle 0 belongs to a live CIS/BIS.
Patch 2 corrects the receive skb being allocated 4 bytes too small, so
that a 248..251 byte payload would be rejected with -EILSEQ.
HCI_MAX_ISO_SIZE is a payload limit rather than a frame limit, and the
allocation should reflect that.
The two hunks are independent, so patch 1 applies on its own if you would
rather not take patch 2.
Based on bluetooth-next.
Chris Lu (2):
Bluetooth: btmtk: drop zero-length ISO packets from endpoint padding
Bluetooth: btmtk: size the ISO receive skb to hold header plus payload
drivers/bluetooth/btmtk.c | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)
--
2.45.2
next reply other threads:[~2026-10-13 8:18 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-13 8:18 Chris Lu [this message]
2026-10-13 8:18 ` [PATCH 1/2] Bluetooth: btmtk: drop zero-length ISO packets from endpoint padding Chris Lu
2026-10-13 11:53 ` Bluetooth: btmtk: fix ISO data reception bluez.test.bot
2026-10-13 8:18 ` [PATCH 2/2] Bluetooth: btmtk: size the ISO receive skb to hold header plus payload Chris Lu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261013081823.817996-1-chris.lu@mediatek.com \
--to=chris.lu@mediatek.com \
--cc=hao.qin@mediatek.com \
--cc=johan.hedberg@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=luiz.dentz@gmail.com \
--cc=marcel@holtmann.org \
--cc=ot_wenlong.tian@mediatek.com \
--cc=sean.wang@mediatek.com \
--cc=ss.wu@mediatek.com \
--cc=will-cy.Lee@mediatek.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox