<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/bluetooth, branch v6.14</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v6.14</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v6.14'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2025-03-07T17:43:27Z</updated>
<entry>
<title>Bluetooth: btusb: Configure altsetting for HCI_USER_CHANNEL</title>
<updated>2025-03-07T17:43:27Z</updated>
<author>
<name>Hsin-chen Chuang</name>
<email>chharry@chromium.org</email>
</author>
<published>2025-02-27T17:14:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=75ddcd5ad40ecd9fbc9f5a7a2ed0e1e74921db3c'/>
<id>urn:sha1:75ddcd5ad40ecd9fbc9f5a7a2ed0e1e74921db3c</id>
<content type='text'>
Automatically configure the altsetting for HCI_USER_CHANNEL when a SCO
is connected.

The motivation is to enable the HCI_USER_CHANNEL user to send out SCO
data through USB Bluetooth chips, which is mainly used for bidirectional
audio transfer (voice call). This was not capable because:

- Per Bluetooth Core Spec v5, Vol 4, Part B, 2.1, the corresponding
  alternate setting should be set based on the air mode in order to
  transfer SCO data, but
- The Linux Bluetooth HCI_USER_CHANNEL exposes the Bluetooth Host
  Controller Interface to the user space, which is something above the
  USB layer. The user space is not able to configure the USB alt while
  keeping the channel open.

This patch intercepts the HCI_EV_SYNC_CONN_COMPLETE packets in btusb,
extracts the air mode, and configures the alt setting in btusb.

This patch is tested on ChromeOS devices. The USB Bluetooth models
(CVSD, TRANS alt3 and alt6) could work without a customized kernel.

Fixes: b16b327edb4d ("Bluetooth: btusb: add sysfs attribute to control USB alt setting")
Signed-off-by: Hsin-chen Chuang &lt;chharry@chromium.org&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>bluetooth: btusb: Initialize .owner field of force_poll_sync_fops</title>
<updated>2025-02-27T21:50:05Z</updated>
<author>
<name>Salah Triki</name>
<email>salah.triki@gmail.com</email>
</author>
<published>2025-02-21T21:32:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=cbf85b9cb80bec6345ffe0368dfff98386f4714f'/>
<id>urn:sha1:cbf85b9cb80bec6345ffe0368dfff98386f4714f</id>
<content type='text'>
Initialize .owner field of force_poll_sync_fops to THIS_MODULE in order to
prevent btusb from being unloaded while its operations are in use.

Fixes: 800fe5ec302e ("Bluetooth: btusb: Add support for queuing during polling interval")
Signed-off-by: Salah Triki &lt;salah.triki@gmail.com&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: Always allow SCO packets for user channel</title>
<updated>2025-02-20T18:25:08Z</updated>
<author>
<name>Hsin-chen Chuang</name>
<email>chharry@chromium.org</email>
</author>
<published>2025-02-14T11:17:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bd30e8d7bfa6e528f9e746c940e6f7246c7899d6'/>
<id>urn:sha1:bd30e8d7bfa6e528f9e746c940e6f7246c7899d6</id>
<content type='text'>
The SCO packets from Bluetooth raw socket are now rejected because
hci_conn_num is left 0. This patch allows such the usecase to enable
the userspace SCO support.

Fixes: b16b327edb4d ("Bluetooth: btusb: add sysfs attribute to control USB alt setting")
Signed-off-by: Hsin-chen Chuang &lt;chharry@chromium.org&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: btintel_pcie: Fix a potential race condition</title>
<updated>2025-02-13T16:14:04Z</updated>
<author>
<name>Kiran K</name>
<email>kiran.k@intel.com</email>
</author>
<published>2025-01-31T13:00:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=872274b992839ff64fe560767fe7ee5f942ccdb1'/>
<id>urn:sha1:872274b992839ff64fe560767fe7ee5f942ccdb1</id>
<content type='text'>
On HCI_OP_RESET command, firmware raises alive interrupt. Driver needs
to wait for this before sending other command. This patch fixes the potential
miss of alive interrupt due to which HCI_OP_RESET can timeout.

Expected flow:
If tx command is HCI_OP_RESET,
  1. set data-&gt;gp0_received = false
  2. send HCI_OP_RESET
  3. wait for alive interrupt

Actual flow having potential race:
If tx command is HCI_OP_RESET,
 1. send HCI_OP_RESET
   1a. Firmware raises alive interrupt here and in ISR
       data-&gt;gp0_received  is set to true
 2. set data-&gt;gp0_received = false
 3. wait for alive interrupt

Signed-off-by: Kiran K &lt;kiran.k@intel.com&gt;
Fixes: 05c200c8f029 ("Bluetooth: btintel_pcie: Add handshake between driver and firmware")
Reported-by: Bjorn Helgaas &lt;helgaas@kernel.org&gt;
Closes: https://patchwork.kernel.org/project/bluetooth/patch/20241001104451.626964-1-kiran.k@intel.com/
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: btnxpuart: Fix glitches seen in dual A2DP streaming</title>
<updated>2025-01-29T20:23:49Z</updated>
<author>
<name>Neeraj Sanjay Kale</name>
<email>neeraj.sanjaykale@nxp.com</email>
</author>
<published>2025-01-20T14:19:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7de119bb79a63f6a1959b83117a98734914fb0b0'/>
<id>urn:sha1:7de119bb79a63f6a1959b83117a98734914fb0b0</id>
<content type='text'>
This fixes a regression caused by previous commit for fixing truncated
ACL data, which is causing some intermittent glitches when running two
A2DP streams.

serdev_device_write_buf() is the root cause of the glitch, which is
reverted, and the TX work will continue to write until the queue is empty.

This change fixes both issues. No A2DP streaming glitches or truncated
ACL data issue observed.

Fixes: 8023dd220425 ("Bluetooth: btnxpuart: Fix driver sending truncated data")
Fixes: 689ca16e5232 ("Bluetooth: NXP: Add protocol support for NXP Bluetooth chipsets")
Signed-off-by: Neeraj Sanjay Kale &lt;neeraj.sanjaykale@nxp.com&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: Fix possible infinite recursion of btusb_reset</title>
<updated>2025-01-29T20:23:18Z</updated>
<author>
<name>Hsin-chen Chuang</name>
<email>chharry@chromium.org</email>
</author>
<published>2025-01-20T10:39:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0983fb4799e78b1783eb5ed0dfe324649c491bb7'/>
<id>urn:sha1:0983fb4799e78b1783eb5ed0dfe324649c491bb7</id>
<content type='text'>
The function enters infinite recursion if the HCI device doesn't support
GPIO reset: btusb_reset -&gt; hdev-&gt;reset -&gt; vendor_reset -&gt; btusb_reset...

btusb_reset shouldn't call hdev-&gt;reset after commit f07d478090b0
("Bluetooth: Get rid of cmd_timeout and use the reset callback")

Fixes: f07d478090b0 ("Bluetooth: Get rid of cmd_timeout and use the reset callback")
Signed-off-by: Hsin-chen Chuang &lt;chharry@chromium.org&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: btusb: mediatek: Add locks for usb_driver_claim_interface()</title>
<updated>2025-01-29T20:19:30Z</updated>
<author>
<name>Douglas Anderson</name>
<email>dianders@chromium.org</email>
</author>
<published>2025-01-16T03:36:36Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e9087e828827e5a5c85e124ce77503f2b81c3491'/>
<id>urn:sha1:e9087e828827e5a5c85e124ce77503f2b81c3491</id>
<content type='text'>
The documentation for usb_driver_claim_interface() says that "the
device lock" is needed when the function is called from places other
than probe(). This appears to be the lock for the USB interface
device. The Mediatek btusb code gets called via this path:

  Workqueue: hci0 hci_power_on [bluetooth]
  Call trace:
   usb_driver_claim_interface
   btusb_mtk_claim_iso_intf
   btusb_mtk_setup
   hci_dev_open_sync
   hci_power_on
   process_scheduled_works
   worker_thread
   kthread

With the above call trace the device lock hasn't been claimed. Claim
it.

Without this fix, we'd sometimes see the error "Failed to claim iso
interface". Sometimes we'd even see worse errors, like a NULL pointer
dereference (where `intf-&gt;dev.driver` was NULL) with a trace like:

  Call trace:
   usb_suspend_both
   usb_runtime_suspend
   __rpm_callback
   rpm_suspend
   pm_runtime_work
   process_scheduled_works

Both errors appear to be fixed with the proper locking.

Fixes: ceac1cb0259d ("Bluetooth: btusb: mediatek: add ISO data transmission functions")
Signed-off-by: Douglas Anderson &lt;dianders@chromium.org&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: qca: Fix poor RF performance for WCN6855</title>
<updated>2025-01-15T15:37:23Z</updated>
<author>
<name>Zijun Hu</name>
<email>quic_zijuhu@quicinc.com</email>
</author>
<published>2025-01-13T14:43:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a2fad248947d702ed3dcb52b8377c1a3ae201e44'/>
<id>urn:sha1:a2fad248947d702ed3dcb52b8377c1a3ae201e44</id>
<content type='text'>
For WCN6855, board ID specific NVM needs to be downloaded once board ID
is available, but the default NVM is always downloaded currently.

The wrong NVM causes poor RF performance, and effects user experience
for several types of laptop with WCN6855 on the market.

Fix by downloading board ID specific NVM if board ID is available.

Fixes: 095327fede00 ("Bluetooth: hci_qca: Add support for QTI Bluetooth chip wcn6855")
Cc: stable@vger.kernel.org # 6.4
Signed-off-by: Zijun Hu &lt;quic_zijuhu@quicinc.com&gt;
Tested-by: Johan Hovold &lt;johan+linaro@kernel.org&gt;
Reviewed-by: Johan Hovold &lt;johan+linaro@kernel.org&gt;
Tested-by: Steev Klimaszewski &lt;steev@kali.org&gt; #Thinkpad X13s
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: Get rid of cmd_timeout and use the reset callback</title>
<updated>2025-01-15T15:36:42Z</updated>
<author>
<name>Hsin-chen Chuang</name>
<email>chharry@chromium.org</email>
</author>
<published>2025-01-08T12:24:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f07d478090b0a03dda46fb45b5c6e089a8408351'/>
<id>urn:sha1:f07d478090b0a03dda46fb45b5c6e089a8408351</id>
<content type='text'>
The hdev-&gt;reset is never used now and the hdev-&gt;cmd_timeout actually
does reset. This patch changes the call path from
  hdev-&gt;cmd_timeout -&gt; vendor_cmd_timeout -&gt; btusb_reset -&gt; hdev-&gt;reset
, to
  hdev-&gt;reset -&gt; vendor_reset -&gt; btusb_reset
Which makes it clear when we export the hdev-&gt;reset to a wider usage
e.g. allowing reset from sysfs.

This patch doesn't introduce any behavior change.

Signed-off-by: Hsin-chen Chuang &lt;chharry@chromium.org&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
<entry>
<title>Bluetooth: Remove the cmd timeout count in btusb</title>
<updated>2025-01-15T15:36:26Z</updated>
<author>
<name>Hsin-chen Chuang</name>
<email>chharry@chromium.org</email>
</author>
<published>2025-01-08T12:24:42Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7c393421755daf35ae1e4e0016b99f308123751a'/>
<id>urn:sha1:7c393421755daf35ae1e4e0016b99f308123751a</id>
<content type='text'>
Remove the cmd timeout count in btusb since we only ever allow one
command in flight at a time. We should always reset after a single
command times out.

Signed-off-by: Hsin-chen Chuang &lt;chharry@chromium.org&gt;
Signed-off-by: Luiz Augusto von Dentz &lt;luiz.von.dentz@intel.com&gt;
</content>
</entry>
</feed>
