Macbook Pro 2015, Bluetooth USB Host Controller bugfix (Looking for advice)

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

 



Hi,

I submitted a bug on Bugzilla before, about Macbook pro  2015 Bluetooth issue

Device
ID 05ac:8290 Apple, Inc. Bluetooth Host Controller


https://bugzilla.kernel.org/show_bug.cgi?id=197295

I tried to fix it myself first. And it seems that my fix works. Now no
error message reported, and my Bluetooth speaker can produce sound

I am new to both kernel develop and Bluetooth / USB driver develop, so
I spend some time investigating and finally I end up with a patch like
this (necessary debugging code truncated)



@@ -1360,11 +1367,14 @@ static inline int __set_isoc_interface(struct
hci_dev *hdev, int altsetting)
       struct usb_interface *intf = data->isoc;
       struct usb_endpoint_descriptor *ep_desc;
       int i, err;
+    /* Here isoc_tx_ep is not initialized */
+    BT_INFO("[VOID]-__set_isoc_interface(3) called, altsetting = %d
isoc_tx_ep = %p", altsetting, data->isoc_tx_ep);

       if (!data->isoc)
               return -ENODEV;

-       err = usb_set_interface(data->udev, 1, altsetting);
+    /* Here is what I changed */
+       err = usb_set_interface(data->udev, 3, altsetting);

Then it works now. But obviously, it's a workaround not a bugfix. And
I do not have other test cases (I only have one Bluetooth speaker)
Could you please give me some advice on the following questions?

1. Is this bug a Macbook Bluetooth USB Driver (btusb) bug? Or it's a
Bluetooth device bug (Xiaomi Bluetooth speaker) I think it's a btusb
bug, am I right?
2. Does this fix make sense?
3. Where can I get the specification of the certain device(i.e: ID =
05ac:8290) To see it's interface and altsetting definition

Thanks in advance.
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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