Re: 3.10-rc: bluetooth disappeared on thinkpad x60 (regression)

From: Pavel Machek
Date: Wed Jun 12 2013 - 07:23:36 EST


On Tue 2013-06-11 13:20:25, Johan Hedberg wrote:
> Hi Pavel,
>
> On Tue, Jun 11, 2013, Johan Hedberg wrote:
> > On Mon, Jun 10, 2013, Pavel Machek wrote:
> > > < HCI Command: Delete Stored Link Key (0x03|0x0012) plen 7
> > > bdaddr 00:00:00:00:00:00 all 1
> > > > HCI Event: Command Complete (0x0e) plen 4
> > > Delete Stored Link Key (0x03|0x0012) ncmd 1
> > > status 0x11 deleted 0
> > > Error: Unsupported Feature or Parameter Value
> >
> > Here's the cause of your issue. It's not one of the recently added HCI
> > commands but one that's been around for quite some time. I just checked
> > and it's even there in kernel 3.9, so I'm surprised that you're saying
> > this is a regression since that version. Are you completely sure about
> > it?
>
> Could you try if the attached patch helps? It modifies the HCI request
> state tracking to allow flagging certain HCI commands as non-critical
> and just ignores their failures.

Yes, it helps.

> If the patch helps, could you still provide a HCI trace (both plain text
> and btsnoop format) of a successful "hciconfig hci0 up"? It might help
> create a simpler patch for this issue.

Thanks,
Pavel

Here you go (binary dump attached):

root@amd:~# hcidump hci0 -X -V
HCI sniffer - Bluetooth packet analyzer ver 1.42
device: hci0 snap_len: 1028 filter: 0xffffffff
< HCI Command: Reset (0x03|0x0003) plen 0
> HCI Event: Command Complete (0x0e) plen 4
Reset (0x03|0x0003) ncmd 1
status 0x00
< HCI Command: Read Local Supported Features (0x04|0x0003) plen 0
> HCI Event: Command Complete (0x0e) plen 12
Read Local Supported Features (0x04|0x0003) ncmd 1
status 0x00
Features: 0xff 0xff 0x8d 0xfe 0x9b 0xf9 0x00 0x80
< HCI Command: Read Local Version Information (0x04|0x0001) plen 0
> HCI Event: Command Complete (0x0e) plen 12
Read Local Version Information (0x04|0x0001) ncmd 1
status 0x00
HCI Version: 2.0 (0x3) HCI Revision: 0x206c
LMP Version: 2.0 (0x3) LMP Subversion: 0x4132
Manufacturer: Broadcom Corporation (15)
< HCI Command: Read BD ADDR (0x04|0x0009) plen 0
> HCI Event: Command Complete (0x0e) plen 10
Read BD ADDR (0x04|0x0009) ncmd 1
status 0x00 bdaddr 00:16:CE:EC:4D:C2
< HCI Command: Read Buffer Size (0x04|0x0005) plen 0
> HCI Event: Command Complete (0x0e) plen 11
Read Buffer Size (0x04|0x0005) ncmd 1
status 0x00
ACL MTU 1017:8 SCO MTU 64:0
< HCI Command: Read Class of Device (0x03|0x0023) plen 0
> HCI Event: Command Complete (0x0e) plen 7
Read Class of Device (0x03|0x0023) ncmd 1
status 0x00 class 0x000000
< HCI Command: Read Local Name (0x03|0x0014) plen 0
> HCI Event: Command Complete (0x0e) plen 252
Read Local Name (0x03|0x0014) ncmd 1
status 0x00 name 'amd-0'
< HCI Command: Read Voice Setting (0x03|0x0025) plen 0
> HCI Event: Command Complete (0x0e) plen 6
Read Voice Setting (0x03|0x0025) ncmd 1
status 0x00 voice setting 0x0060
< HCI Command: Set Event Filter (0x03|0x0005) plen 1
type 0 condition 0
Clear all filters
> HCI Event: Command Complete (0x0e) plen 4
Set Event Filter (0x03|0x0005) ncmd 1
status 0x00
< HCI Command: Write Connection Accept Timeout (0x03|0x0016) plen 2
timeout 32000
> HCI Event: Command Complete (0x0e) plen 4
Write Connection Accept Timeout (0x03|0x0016) ncmd 1
status 0x00
< HCI Command: Delete Stored Link Key (0x03|0x0012) plen 7
bdaddr 00:00:00:00:00:00 all 1
> HCI Event: Command Complete (0x0e) plen 4
Delete Stored Link Key (0x03|0x0012) ncmd 1
status 0x11 deleted 0
Error: Unsupported Feature or Parameter Value
< HCI Command: Read Page Scan Activity (0x03|0x001b) plen 0
> HCI Event: Command Complete (0x0e) plen 8
Read Page Scan Activity (0x03|0x001b) ncmd 1
status 0x00 interval 2048 window 18
< HCI Command: Read Page Scan Type (0x03|0x0046) plen 0
> HCI Event: Command Complete (0x0e) plen 5
Read Page Scan Type (0x03|0x0046) ncmd 1
0000: 00 01 ..
< HCI Command: Set Event Mask (0x03|0x0001) plen 8
Mask: 0xfffffbff07180000
> HCI Event: Command Complete (0x0e) plen 4
Set Event Mask (0x03|0x0001) ncmd 1
status 0x00
< HCI Command: Read Local Supported Commands (0x04|0x0002) plen 0
> HCI Event: Command Complete (0x0e) plen 68
Read Local Supported Commands (0x04|0x0002) ncmd 1
status 0x00
Commands: ffffffffffff1ffffffffffff30fffff3f
< HCI Command: Write Inquiry Mode (0x03|0x0045) plen 1
mode 1
> HCI Event: Command Complete (0x0e) plen 4
Write Inquiry Mode (0x03|0x0045) ncmd 1
status 0x00
< HCI Command: Read Local Extended Features (0x04|0x0004) plen 1
page 1
> HCI Event: Command Complete (0x0e) plen 14
Read Local Extended Features (0x04|0x0004) ncmd 1
status 0x00 page 1 max 0
Features: 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
< HCI Command: Write Default Link Policy Settings (0x02|0x000f) plen 2
policy 0x0f
Link policy: RSWITCH HOLD SNIFF PARK
> HCI Event: Command Complete (0x0e) plen 4
Write Default Link Policy Settings (0x02|0x000f) ncmd 1
status 0x00
< HCI Command: Write Page Timeout (0x03|0x0018) plen 2
timeout 8192
> HCI Event: Command Complete (0x0e) plen 4
Write Page Timeout (0x03|0x0018) ncmd 1
status 0x00
< HCI Command: Write Default Link Policy Settings (0x02|l Name
(0x03|0x0014) plen 0
> HCI Event: Command Complete (0x0e) plen 2
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

Attachment: delme
Description: Binary data