Skip to contentSkip to conversation

MacbookPro12,1 Bluetooth not found by Bluez

DISCUSSION Michael Gratton 2 participants 5 messages Sep 9, 2015 – Sep 10, 2015 Bluetooth drivers

lore
Share & tools
lore
#0 lore raw

Hi list,

No Bluetooth adapter is being found by Bluez on my MacbookPro12,1 when running Ubuntu 15.10, Linux 4.2rc8 and Bluez 5.33. After normal boot, the output of hcitool dev contains no devices.

Relevant kernel logs are below, but since it finds the BT adaptor but also reports it as both hid-generic and input devices, I imagine I need to switch it out of HID mode and into HCI mode. However, when I try manually running hid2hci as root, the command silently fails and no change in the visibility of the adaptor is observed:

Quoted 3 lines
mjg@payens:~$ sudo /lib/udev/hid2hci --evpath=/devices/pci0000:00/0000:00:14.0/usb1/1-3 --method=csr2 || echo fail
fail
mjg@payens:~$

Using methods other than csr2 results in hid2hci reporting an error.

Is there anything I can do to help debug this?

Thanks,
//Mike

Kernel logs:

Quoted 15 lines
[ 1.869553] usb 1-3: new full-speed USB device number 2 using xhci_hcd
...
[ 2.004387] usb 1-3: New USB device found, idVendor=05ac, idProduct=8290
[ 2.004388] usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 2.004389] usb 1-3: Product: Bluetooth USB Host Controller
[ 2.004390] usb 1-3: Manufacturer: Broadcom Corp.
[ 2.004478] usb 1-3: ep 0x85 - rounding interval to 64 microframes, ep desc says 80 microframes
[ 2.004480] usb 1-3: ep 0x86 - rounding interval to 64 microframes, ep desc says 80 microframes
...
[ 2.425178] hid-generic 0003:05AC:8290.0001: input,hidraw4: USB HID v1.11 Keyboard [Broadcom Corp. Bluetooth USB Host Controller] on usb-0000:00:14.0-3/input0
[ 2.425259] input: Broadcom Corp. Bluetooth USB Host Controller as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3:1.1/0003:05AC:8290.0002/input/input7
...
[ 10.254634] usbcore: registered new interface driver btusb
...
[ 16.642700] usb 1-3: device descriptor read/64, error -110
Signature · 2 lines
⊨ Michael Gratton, Percept Wrangler.
⚙ <http://mjog.vee.net/>
maintainer
#1 lore raw

Hi Michael,

Quoted 11 lines

No Bluetooth adapter is being found by Bluez on my MacbookPro12,1 when running Ubuntu 15.10, Linux 4.2rc8 and Bluez 5.33. After normal boot, the output of hcitool dev contains no devices.

Relevant kernel logs are below, but since it finds the BT adaptor but also reports it as both hid-generic and input devices, I imagine I need to switch it out of HID mode and into HCI mode. However, when I try manually running hid2hci as root, the command silently fails and no change in the visibility of the adaptor is observed:

Quoted 3 lines
mjg@payens:~$ sudo /lib/udev/hid2hci --evpath=/devices/pci0000:00/0000:00:14.0/usb1/1-3 --method=csr2 || echo fail
fail
mjg@payens:~$

Using methods other than csr2 results in hid2hci reporting an error.

Is there anything I can do to help debug this?

check /sys/kernel/debug/usb/devices for the Bluetooth controller entry.

Quoted 17 lines

Kernel logs:

Quoted 15 lines
[ 1.869553] usb 1-3: new full-speed USB device number 2 using xhci_hcd
...
[ 2.004387] usb 1-3: New USB device found, idVendor=05ac, idProduct=8290
[ 2.004388] usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 2.004389] usb 1-3: Product: Bluetooth USB Host Controller
[ 2.004390] usb 1-3: Manufacturer: Broadcom Corp.
[ 2.004478] usb 1-3: ep 0x85 - rounding interval to 64 microframes, ep desc says 80 microframes
[ 2.004480] usb 1-3: ep 0x86 - rounding interval to 64 microframes, ep desc says 80 microframes
...
[ 2.425178] hid-generic 0003:05AC:8290.0001: input,hidraw4: USB HID v1.11 Keyboard [Broadcom Corp. Bluetooth USB Host Controller] on usb-0000:00:14.0-3/input0
[ 2.425259] input: Broadcom Corp. Bluetooth USB Host Controller as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3:1.1/0003:05AC:8290.0002/input/input7
...
[ 10.254634] usbcore: registered new interface driver btusb
...
[ 16.642700] usb 1-3: device descriptor read/64, error -110

This might actually be the problem. It seems the Bluetooth controller gets detected correctly and the btusb driver loaded, but then we get some issues with the descriptor reading.

Does the original Ubuntu 15.10 kernel work or any other kernel than 4.2-rc8. If you find a working kernel, you might need to bisect this. However my feeling is that this might be an issue in the USB host controller or somewhere else.

In general all MacBook Bluetooth controllers are suppose to work. If you happen to still have OS X installed, then start it and see if it might runs a firmware upgrade for the controller.

Regards

Marcel

#2 lore raw

Hi Marcel,

Quoted 5 lines · On Wed, 9 Sep, 2015 at 3:57 PM, Marcel Holtmann <[email protected]>=20 wrote:
Quoted 2 lines

=20
Is there anything I can do to help debug this?

=20
check /sys/kernel/debug/usb/devices for the Bluetooth controller=20 entry.

The following is reported there:

T: Bus=3D01 Lev=3D01 Prnt=3D01 Port=3D02 Cnt=3D01 Dev#=3D 2 Spd=3D12 MxCh= =3D 0
D: Ver=3D 2.01 Cls=3Def(misc ) Sub=3D02 Prot=3D01 MxPS=3D64 #Cfgs=3D 1
P: Vendor=3D05ac ProdID=3D8290 Rev=3D 0.90
S: Manufacturer=3DBroadcom Corp.
S: Product=3DBluetooth USB Host Controller
C:* #Ifs=3D 6 Cfg#=3D 1 Atr=3De0 MxPwr=3D 0mA
A: FirstIf#=3D 2 IfCount=3D 4 Cls=3Dff(vend.) Sub=3D01 Prot=3D01 I:* If#=3D 0 Alt=3D 0 #EPs=3D 1 Cls=3D03(HID ) Sub=3D01 Prot=3D01 Driver=3D= usbhid
E: Ad=3D85(I) Atr=3D03(Int.) MxPS=3D 8 Ivl=3D10ms
I:* If#=3D 1 Alt=3D 0 #EPs=3D 1 Cls=3D03(HID ) Sub=3D01 Prot=3D02 Driver=3D= usbhid
E: Ad=3D86(I) Atr=3D03(Int.) MxPS=3D 8 Ivl=3D10ms
I:* If#=3D 2 Alt=3D 0 #EPs=3D 3 Cls=3Dff(vend.) Sub=3D01 Prot=3D01 Driver= =3D(none)
E: Ad=3D81(I) Atr=3D03(Int.) MxPS=3D 16 Ivl=3D1ms
E: Ad=3D82(I) Atr=3D02(Bulk) MxPS=3D 64 Ivl=3D0ms
E: Ad=3D02(O) Atr=3D02(Bulk) MxPS=3D 64 Ivl=3D0ms
I:* If#=3D 3 Alt=3D 0 #EPs=3D 2 Cls=3De0(wlcon) Sub=3D01 Prot=3D01 Driver= =3D(none)
E: Ad=3D83(I) Atr=3D01(Isoc) MxPS=3D 0 Ivl=3D1ms
E: Ad=3D03(O) Atr=3D01(Isoc) MxPS=3D 0 Ivl=3D1ms
I: If#=3D 3 Alt=3D 1 #EPs=3D 2 Cls=3De0(wlcon) Sub=3D01 Prot=3D01 Driver=3D= (none)
E: Ad=3D83(I) Atr=3D01(Isoc) MxPS=3D 9 Ivl=3D1ms
E: Ad=3D03(O) Atr=3D01(Isoc) MxPS=3D 9 Ivl=3D1ms
I: If#=3D 3 Alt=3D 2 #EPs=3D 2 Cls=3De0(wlcon) Sub=3D01 Prot=3D01 Driver=3D= (none)
E: Ad=3D83(I) Atr=3D01(Isoc) MxPS=3D 17 Ivl=3D1ms
E: Ad=3D03(O) Atr=3D01(Isoc) MxPS=3D 17 Ivl=3D1ms
I: If#=3D 3 Alt=3D 3 #EPs=3D 2 Cls=3De0(wlcon) Sub=3D01 Prot=3D01 Driver=3D= (none)
E: Ad=3D83(I) Atr=3D01(Isoc) MxPS=3D 25 Ivl=3D1ms
E: Ad=3D03(O) Atr=3D01(Isoc) MxPS=3D 25 Ivl=3D1ms
I: If#=3D 3 Alt=3D 4 #EPs=3D 2 Cls=3De0(wlcon) Sub=3D01 Prot=3D01 Driver=3D= (none)
E: Ad=3D83(I) Atr=3D01(Isoc) MxPS=3D 33 Ivl=3D1ms
E: Ad=3D03(O) Atr=3D01(Isoc) MxPS=3D 33 Ivl=3D1ms
I: If#=3D 3 Alt=3D 5 #EPs=3D 2 Cls=3De0(wlcon) Sub=3D01 Prot=3D01 Driver=3D= (none)
E: Ad=3D83(I) Atr=3D01(Isoc) MxPS=3D 49 Ivl=3D1ms
E: Ad=3D03(O) Atr=3D01(Isoc) MxPS=3D 49 Ivl=3D1ms
I:* If#=3D 4 Alt=3D 0 #EPs=3D 2 Cls=3Dff(vend.) Sub=3Dff Prot=3Dff Driver= =3D(none)
E: Ad=3D84(I) Atr=3D02(Bulk) MxPS=3D 32 Ivl=3D0ms
E: Ad=3D04(O) Atr=3D02(Bulk) MxPS=3D 32 Ivl=3D0ms
I:* If#=3D 5 Alt=3D 0 #EPs=3D 0 Cls=3Dfe(app. ) Sub=3D01 Prot=3D01 Driver= =3D(none)

Quoted 1 line
Quoted 1 line

Kernel logs:

[snip]

Quoted 12 lines
Quoted 3 lines
Quoted 3 lines
 [ 10.254634] usbcore: registered new interface driver btusb
 ...
 [ 16.642700] usb 1-3: device descriptor read/64, error -110

=20
This might actually be the problem. It seems the Bluetooth controller=20 gets detected correctly and the btusb driver loaded, but then we get=20 some issues with the descriptor reading.
=20
Does the original Ubuntu 15.10 kernel work or any other kernel than=20 4.2-rc8. If you find a working kernel, you might need to bisect this.=20 However my feeling is that this might be an issue in the USB host=20 controller or somewhere else.

Just rebooted into the stock Ubuntu 4.2.0 kernel - same result. I=20 upgraded this system from 15.04, which was running 3.19, and this=20 problem existed with that version as well.

Quoted 3 lines

In general all MacBook Bluetooth controllers are suppose to work. If=20 you happen to still have OS X installed, then start it and see if it=20 might runs a firmware upgrade for the controller.

I don't - I might be able to try it form an external hard drive over=20 the next few days however. Will report back if I do manage to.

Thanks,
//Mike

--=20
=E2=8A=A8 Michael Gratton, Percept Wrangler.
=E2=9A=99 <http://mjog.vee.net/>

=

maintainer
#3 lore raw

Hi Michael,

Quoted 34 lines
Quoted 2 lines
Quoted 1 line

Is there anything I can do to help debug this?

check /sys/kernel/debug/usb/devices for the Bluetooth controller entry.

The following is reported there:

T: Bus=01 Lev=01 Prnt=01 Port=02 Cnt=01 Dev#= 2 Spd=12 MxCh= 0
D: Ver= 2.01 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=05ac ProdID=8290 Rev= 0.90
S: Manufacturer=Broadcom Corp.
S: Product=Bluetooth USB Host Controller
C:* #Ifs= 6 Cfg#= 1 Atr=e0 MxPwr= 0mA
A: FirstIf#= 2 IfCount= 4 Cls=ff(vend.) Sub=01 Prot=01 I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=01 Prot=01 Driver=usbhid
E: Ad=85(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
I:* If#= 1 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=01 Prot=02 Driver=usbhid
E: Ad=86(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
I:* If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 3 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 3 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 3 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 3 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms

Quoted 8 lines

E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 3 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
I:* If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E: Ad=84(I) Atr=02(Bulk) MxPS= 32 Ivl=0ms
E: Ad=04(O) Atr=02(Bulk) MxPS= 32 Ivl=0ms
I:* If#= 5 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)

okay, this is new. Is this by any chance the new Broadwell based MacBook Pro from beginning of the year?

Quoted 5 lines
Quoted 1 line
Quoted 1 line

Kernel logs:

[snip]

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
[ 10.254634] usbcore: registered new interface driver btusb
...
[ 16.642700] usb 1-3: device descriptor read/64, error -110
Quoted 8 lines
Quoted 2 lines

This might actually be the problem. It seems the Bluetooth controller gets detected correctly and the btusb driver loaded, but then we get some issues with the descriptor reading.
Does the original Ubuntu 15.10 kernel work or any other kernel than 4.2-rc8. If you find a working kernel, you might need to bisect this. However my feeling is that this might be an issue in the USB host controller or somewhere else.

Just rebooted into the stock Ubuntu 4.2.0 kernel - same result. I upgraded this system from 15.04, which was running 3.19, and this problem existed with that version as well.

Quoted 1 line

In general all MacBook Bluetooth controllers are suppose to work. If you happen to still have OS X installed, then start it and see if it might runs a firmware upgrade for the controller.

I don't - I might be able to try it form an external hard drive over the next few days however. Will report back if I do manage to.

If you can, then that would be great, however I assume that with the new Broadwell designs they have picked new Broadcom controllers and instead of hiding behind an internal USB hub, the devices are multi-function devices with HID and Bluetooth combined into a single USB device.

I do think there is an update of the Bluetooth controller firmware from 0.90 that you have to 1.04 at least. While it might not make the controller work, but it might fix actual Bluetooth bug in the firmware that you would stumble over later. So try to boot up an OS X if you can. If this is the BCM20703A1 chip from Broadcom, then they are rather new and having an updated firmware helps there.

We have the following statement in probe function:

        /* interface numbers are hardcoded in the spec */                        
        if (intf->cur_altsetting->desc.bInterfaceNumber != 0)                    
                return -ENODEV;

This will avoid activating the device correctly in your case.

As a background, we chose to do it this simple since Bluetooth is a multi-interface device by itself. It uses interface 0 (for ACL/cmd/evt) and also interface 1 (for SCO). So the interface numbers are pretty much hard coded and in the last 15 years nobody did it different. However it seems you find the first device that does this differently now.

So you change the above 0 to a 2 and the later on then 1 to a 3.

                /* Interface numbers are hardcoded in the specification */       
                data->isoc = usb_ifnum_to_if(data->udev, 1);

This should get you your controller working, but obviously that is just for testing. The real fix is a lot more complicated and such a simple change will break every other Bluetooth dongle you might want to play with.

Regards

Marcel

#4 lore raw
Quoted 2 lines · On Thu, 10 Sep, 2015 at 1:21 AM, Marcel Holtmann <[email protected]>=20 wrote:
Quoted 2 lines

=20
T: Bus=3D01 Lev=3D01 Prnt=3D01 Port=3D02 Cnt=3D01 Dev#=3D 2 Spd=3D12 Mx=

Ch=3D 0

Quoted 4 lines
Quoted 4 lines

D: Ver=3D 2.01 Cls=3Def(misc ) Sub=3D02 Prot=3D01 MxPS=3D64 #Cfgs=3D 1
P: Vendor=3D05ac ProdID=3D8290 Rev=3D 0.90
S: Manufacturer=3DBroadcom Corp.
S: Product=3DBluetooth USB Host Controller

[snip]

Quoted 3 lines

=20
okay, this is new. Is this by any chance the new Broadwell based=20 MacBook Pro from beginning of the year?

Yep, it sure is - has an i7-5557U Broadwell-U SoC.

Quoted 37 lines
Quoted 6 lines
Quoted 3 lines

In general all MacBook Bluetooth controllers are suppose to work.=20
If you happen to still have OS X installed, then start it and see=20 if it might runs a firmware upgrade for the controller.

=20
I don't - I might be able to try it form an external hard drive=20
over the next few days however. Will report back if I do manage to.

=20
If you can, then that would be great, however I assume that with the=20 new Broadwell designs they have picked new Broadcom controllers and=20 instead of hiding behind an internal USB hub, the devices are=20 multi-function devices with HID and Bluetooth combined into a single=20 USB device.
=20
I do think there is an update of the Bluetooth controller firmware=20 from 0.90 that you have to 1.04 at least. While it might not make the=20 controller work, but it might fix actual Bluetooth bug in the=20 firmware that you would stumble over later. So try to boot up an OS X=20 if you can. If this is the BCM20703A1 chip from Broadcom, then they=20 are rather new and having an updated firmware helps there. =20
We have the following statement in probe function:
=20

        /* interface numbers are hardcoded in the spec */
        if (intf->cur_altsetting->desc.bInterfaceNumber !=3D 0)
                return -ENODEV;

=20
This will avoid activating the device correctly in your case. =20
As a background, we chose to do it this simple since Bluetooth is a=20 multi-interface device by itself. It uses interface 0 (for=20 ACL/cmd/evt) and also interface 1 (for SCO). So the interface numbers=20 are pretty much hard coded and in the last 15 years nobody did it=20 different. However it seems you find the first device that does this=20 differently now.
=20
So you change the above 0 to a 2 and the later on then 1 to a 3. =20

Quoted 8 lines
                /* Interface numbers are hardcoded in the=20
specification */
                data->isoc =3D usb_ifnum_to_if(data->udev, 1);

=20
This should get you your controller working, but obviously that is=20 just for testing. The real fix is a lot more complicated and such a=20 simple change will break every other Bluetooth dongle you might want=20 to play with.

It did indeed - I changed those values, recompiled and installed the=20 new kernel, rebooted and the adapter is now being found. I was able to=20 pair it with my Nexus 5 and transfer a file across, but getting=20 Internet access through doesn't seem to be working.

I'll look into doing the firmware upgrade that you suggest above and=20 see if that helps anything.

Thanks for looking into this. I could try working on a real fix but=20 don't have any experience working on the kernel, so would need some=20 guidance. In any case I am more than happy to test patches and what-not.

//Mike

--=20
=E2=8A=A8 Michael Gratton, Percept Wrangler.
=E2=9A=99 <http://mjog.vee.net/>

=