From 5eefd0819c0a8e4b896f519e51225750cc5692f5 Mon Sep 17 00:00:00 2001 From: jc_gargma Date: Tue, 7 Sep 2021 16:23:11 -0700 Subject: Updated to 5.13.14 --- ...ditions-before-enabling-USB-ALT-3-for-WBS.patch | 49 ---------------------- 1 file changed, 49 deletions(-) delete mode 100644 0002-Bluetooth-btusb-check-conditions-before-enabling-USB-ALT-3-for-WBS.patch (limited to '0002-Bluetooth-btusb-check-conditions-before-enabling-USB-ALT-3-for-WBS.patch') diff --git a/0002-Bluetooth-btusb-check-conditions-before-enabling-USB-ALT-3-for-WBS.patch b/0002-Bluetooth-btusb-check-conditions-before-enabling-USB-ALT-3-for-WBS.patch deleted file mode 100644 index 7aa972f..0000000 --- a/0002-Bluetooth-btusb-check-conditions-before-enabling-USB-ALT-3-for-WBS.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c -index 6d23308119d1..5cec719f6cba 100644 ---- a/drivers/bluetooth/btusb.c -+++ b/drivers/bluetooth/btusb.c -@@ -516,6 +516,7 @@ static const struct dmi_system_id btusb_needs_reset_resume_table[] = { - #define BTUSB_HW_RESET_ACTIVE 12 - #define BTUSB_TX_WAIT_VND_EVT 13 - #define BTUSB_WAKEUP_DISABLE 14 -+#define BTUSB_ALT3_OK_FOR_WBS 15 - - struct btusb_data { - struct hci_dev *hdev; -@@ -1748,16 +1749,20 @@ static void btusb_work(struct work_struct *work) - /* Bluetooth USB spec recommends alt 6 (63 bytes), but - * many adapters do not support it. Alt 1 appears to - * work for all adapters that do not have alt 6, and -- * which work with WBS at all. -+ * which work with WBS at all. Some devices prefer -+ * alt 3 (HCI payload >= 60 Bytes let air packet -+ * data satisfy 60 bytes), requiring -+ * MTU >= 3 (packets) * 25 (size) - 3 (headers) = 72 -+ * see also Core spec 5, vol 4, B 2.1.1 & Table 2.1. - */ -- new_alts = btusb_find_altsetting(data, 6) ? 6 : 1; -- /* Because mSBC frames do not need to be aligned to the -- * SCO packet boundary. If support the Alt 3, use the -- * Alt 3 for HCI payload >= 60 Bytes let air packet -- * data satisfy 60 bytes. -- */ -- if (new_alts == 1 && btusb_find_altsetting(data, 3)) -+ if (btusb_find_altsetting(data, 6)) -+ new_alts = 6; -+ else if (test_bit(BTUSB_ALT3_OK_FOR_WBS, &data->flags) && -+ hdev->sco_mtu >= 72 && -+ btusb_find_altsetting(data, 3)) - new_alts = 3; -+ else -+ new_alts = 1; - } - - if (btusb_switch_alt_setting(hdev, new_alts) < 0) -@@ -4733,6 +4738,7 @@ static int btusb_probe(struct usb_interface *intf, - * (DEVICE_REMOTE_WAKEUP) - */ - set_bit(BTUSB_WAKEUP_DISABLE, &data->flags); -+ set_bit(BTUSB_ALT3_OK_FOR_WBS, &data->flags); - } - - if (!reset) -- cgit v1.2.1