Re: 057c:3800 BlueFRITZ! Bluetooth Stick broken since 2.6.something
From: Andrei Emeltchenko <hidden>
Date: 2011-11-21 09:12:55
On Mon, Nov 21, 2011 at 10:57:06AM +0200, Andrei Emeltchenko wrote:
Hi Johan, On Fri, Nov 18, 2011 at 06:21:11PM +0200, Johan Hedberg wrote:quoted
Hi Michael, On Fri, Nov 18, 2011, Michael Schmitt wrote:quoted
< HCI Command: Read Local Version Information (0x04|0x0001) plen 0quoted
HCI Event: Command Complete (0x0e) plen 12Read Local Version Information (0x04|0x0001) ncmd 1 status 0x00 HCI Version: 1.2 (0x2) HCI Revision: 0x2006 LMP Version: 1.2 (0x2) LMP Subversion: 0x1806 Manufacturer: AVM Berlin (31)Ok, so this is a 1.2 adapter.quoted
< HCI Command: Read Local Supported Commands (0x04|0x0002) plen 0quoted
HCI Event: Command Status (0x0f) plen 4Read Local Supported Commands (0x04|0x0002) status 0x01 ncmd 1 Error: Unknown HCI CommandThis is the reason why you're getting a timeout. Since the adapter claims to support Bluetooth version 1.2 it should also support this HCI command, so from that perspective it's not conforming to theApparently we check for "Bluetooth Core Specification 1.1"
Sorry, it is already checking for it. Discard the code below. Best regards Andrei Emeltchenko
quoted hunk ↗ jump to hunk
Shall we change to:diff --git a/net/bluetooth/hci_event.c b/net/bluetooth/hci_event.c index f0fbb02..ed55b33 100644 --- a/net/bluetooth/hci_event.c +++ b/net/bluetooth/hci_event.c@@ -562,7 +562,7 @@ static void hci_setup(struct hci_dev *hdev) { hci_setup_event_mask(hdev); - if (hdev->lmp_ver > 1) + if (hdev->lmp_ver > 2) hci_send_cmd(hdev, HCI_OP_READ_LOCAL_COMMANDS, 0, NULL); if (hdev->features[6] & LMP_SIMPLE_PAIR) {Reference: https://www.bluetooth.org/Technical/AssignedNumbers/link_manager.htm Best regards Andrei Emeltchenkoquoted
specification. Right now the kernel (lib/bluetooth/hci_event.c) is completely missing a command status handler for this command. If such a handler was in place instead of a timeout you would be getting an immediate error (the kernel maps this HCI status code to EBADRQC). However, since this is also not acceptable behavior (as the adapter still wouldn't work for you) I suspect the need for some adapter-specific quirk is in place or then the kernel should just ignore any errors for HCI_Read_Local_Supported_Commands. Johan -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html-- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html