summaryrefslogtreecommitdiff
path: root/drivers/bluetooth/btrtl.c
diff options
context:
space:
mode:
authorHilda Wu <hildawu@realtek.com>2022-10-05 11:43:31 +0300
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2022-12-13 01:19:23 +0300
commita479e71322ced3e663b0baf17a6d250c973454c8 (patch)
treeeead798a49f685795c2c642b2bc0bd5cdd4aa103 /drivers/bluetooth/btrtl.c
parent5b355944b19011011dd3fd4187444c5ff1d76ad2 (diff)
downloadlinux-a479e71322ced3e663b0baf17a6d250c973454c8.tar.xz
Bluetooth: btusb: Ignore zero length of USB packets on ALT 6 for specific chip
For USB ALT 6 settings some Realtek chips need to transmit mSBC data continuously without the zero length of USB packets. In this commit, create BTUSB_ALT6_CONTINUOUS_TX to manage the behavior. Therefore, create REALTEK_ALT6_CONTINUOUS_TX_CHIP to manage the specific chip model for the behavior. Signed-off-by: Max Chou <max.chou@realtek.com> Signed-off-by: Hilda Wu <hildawu@realtek.com> Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Diffstat (limited to 'drivers/bluetooth/btrtl.c')
-rw-r--r--drivers/bluetooth/btrtl.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/bluetooth/btrtl.c b/drivers/bluetooth/btrtl.c
index fb52313a1d45..69c3fe649ca7 100644
--- a/drivers/bluetooth/btrtl.c
+++ b/drivers/bluetooth/btrtl.c
@@ -781,6 +781,13 @@ void btrtl_set_quirks(struct hci_dev *hdev, struct btrtl_device_info *btrtl_dev)
case CHIP_ID_8852C:
set_bit(HCI_QUIRK_VALID_LE_STATES, &hdev->quirks);
set_bit(HCI_QUIRK_WIDEBAND_SPEECH_SUPPORTED, &hdev->quirks);
+
+ /* RTL8852C needs to transmit mSBC data continuously without
+ * the zero length of USB packets for the ALT 6 supported chips
+ */
+ if (btrtl_dev->project_id == CHIP_ID_8852C)
+ btrealtek_set_flag(hdev, REALTEK_ALT6_CONTINUOUS_TX_CHIP);
+
hci_set_aosp_capable(hdev);
break;
default: