From: bugzilla-daemon@kernel.org
To: linux-bluetooth@vger.kernel.org
Subject: [Bug 217651] BCM20702B0 Bluetooth device in MacBook no longer working
Date: Wed, 12 Jul 2023 22:59:51 +0000 [thread overview]
Message-ID: <bug-217651-62941-Hk3dwMQ6SC@https.bugzilla.kernel.org/> (raw)
In-Reply-To: <bug-217651-62941@https.bugzilla.kernel.org/>
https://bugzilla.kernel.org/show_bug.cgi?id=217651
--- Comment #14 from johnbholland@icloud.com ---
I believe I have identified the problem and a fix. Commit
c13380a55522bf14e54779a142487c224509db95 is the cause, found by bisecting and
testing. Without it (built from immediately prior commit) the problem goes
away. Also, in the current code, this change is there and the latest version
6.5.0-rc1 has the issue, and it can be fixed by reverting this change. The
change in question is:
diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index 5c536151ef83..4ca91c033d2f 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -3831,13 +3831,9 @@ static int btusb_probe(struct usb_interface *intf,
BT_DBG("intf %p id %p", intf, id);
- /* interface numbers are hardcoded in the spec */
- if (intf->cur_altsetting->desc.bInterfaceNumber != 0) {
- if (!(id->driver_info & BTUSB_IFNUM_2))
- return -ENODEV;
- if (intf->cur_altsetting->desc.bInterfaceNumber != 2)
- return -ENODEV;
- }
+ if ((id->driver_info & BTUSB_IFNUM_2) &&
+ (intf->cur_altsetting->desc.bInterfaceNumber != 2))
+ return -ENODEV;
ifnum_base = intf->cur_altsetting->desc.bInterfaceNumber;
( - is the code that works, + is the code that doesn't).
Looking at the code, it looks like it was meant to remove the outer if
statement and turn the inner part into something simpler. I think it is missing
an ! and uses && instead of || if that is what it intends.
When I changed it to that though, the problem still existed. So what worked for
me was to revert this block of code to the previous version, in both 6.3 and
6.5. In 6.5 this file has changed a lot, but this block is the same as the
commit made it.
My 2014 Macbook Pro is perhaps an obscure bit of hardware and I don't know
whether this change was fixing something on other hardware. On my Macbook,
though, it causes the internal Bluetooth controller to not be seen.
I will also send an email to the people in the commit,
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
next prev parent reply other threads:[~2023-07-12 22:59 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-09 22:56 [Bug 217651] New: BCM20702B0 Bluetooth device in MacBook no longer working bugzilla-daemon
2023-07-09 22:57 ` [Bug 217651] " bugzilla-daemon
2023-07-10 3:33 ` bugzilla-daemon
2023-07-10 12:08 ` bugzilla-daemon
2023-07-10 12:09 ` bugzilla-daemon
2023-07-10 12:09 ` bugzilla-daemon
2023-07-10 12:10 ` bugzilla-daemon
2023-07-10 12:11 ` bugzilla-daemon
2023-07-10 12:13 ` bugzilla-daemon
2023-07-10 12:14 ` bugzilla-daemon
2023-07-10 18:50 ` bugzilla-daemon
2023-07-11 1:18 ` bugzilla-daemon
2023-07-11 14:37 ` bugzilla-daemon
2023-07-11 16:13 ` bugzilla-daemon
2023-07-12 22:59 ` bugzilla-daemon [this message]
2023-07-12 23:13 ` [Bug,217651] " bluez.test.bot
2023-07-13 4:18 ` [Bug 217651] " bugzilla-daemon
2023-07-13 5:36 ` bugzilla-daemon
2023-07-13 5:45 ` bugzilla-daemon
2023-07-13 6:17 ` [Bug,217651] " bluez.test.bot
2023-07-13 5:58 ` [Bug 217651] " bugzilla-daemon
2023-07-13 11:31 ` bugzilla-daemon
2023-07-13 11:46 ` bugzilla-daemon
2023-07-13 11:54 ` bugzilla-daemon
2023-07-13 12:24 ` [Bug,217651] " bluez.test.bot
2023-08-28 20:34 ` [Bug 217651] " bugzilla-daemon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-217651-62941-Hk3dwMQ6SC@https.bugzilla.kernel.org/ \
--to=bugzilla-daemon@kernel.org \
--cc=linux-bluetooth@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).