Re: [PATCH v1] Bluetooth: btintel: Check if controller is ISO capable on btintel_classify_pkt_type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sean,

On Wed, Jul 9, 2025 at 3:13 PM Luiz Augusto von Dentz
<luiz.dentz@xxxxxxxxx> wrote:
>
> From: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
>
> Due to what seem to be a bug with variant version returned by some
> firmwares the code may set hdev->classify_pkt_type with
> btintel_classify_pkt_type when in fact the controller doesn't even
> support ISO channels feature but may use the handle range expected from
> a controllers that does causing the packets to be reclassified as ISO
> causing several bugs.
>
> Link: https://bugzilla.kernel.org/show_bug.cgi?id=219553
> Link: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2100565
> Link: https://github.com/StarLabsLtd/firmware/issues/180
> Fixes: f25b7fd36cc3 ("Bluetooth: Add vendor-specific packet classification for ISO data")
> Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
> ---
>  drivers/bluetooth/btintel.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/bluetooth/btintel.c b/drivers/bluetooth/btintel.c
> index 55cc1652bfe4..06575a0b9aee 100644
> --- a/drivers/bluetooth/btintel.c
> +++ b/drivers/bluetooth/btintel.c
> @@ -2670,7 +2670,7 @@ static u8 btintel_classify_pkt_type(struct hci_dev *hdev, struct sk_buff *skb)
>          * Distinguish ISO data packets form ACL data packets
>          * based on their connection handle value range.
>          */
> -       if (hci_skb_pkt_type(skb) == HCI_ACLDATA_PKT) {
> +       if (iso_capable(hdev) && hci_skb_pkt_type(skb) == HCI_ACLDATA_PKT) {
>                 __u16 handle = __le16_to_cpu(hci_acl_hdr(skb)->handle);
>
>                 if (hci_handle(handle) >= BTINTEL_ISODATA_HANDLE_BASE)
> --
> 2.50.0

Can you try with the changes above?

-- 
Luiz Augusto von Dentz





[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux