linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc.
@ 2021-06-01  9:57 Zijun Hu
  2021-06-02 20:11 ` Marcel Holtmann
  0 siblings, 1 reply; 2+ messages in thread
From: Zijun Hu @ 2021-06-01  9:57 UTC (permalink / raw)
  To: marcel, johan.hedberg, luiz.dentz
  Cc: linux-kernel, linux-bluetooth, linux-arm-msm, bgodavar, c-hbandi,
	hemantg, mka, rjliao, zijuhu, tjiang

From: Tim Jiang <tjiang@codeaurora.org>

This is btsoc timing issue, after host start to downloading bt firmware,
ep2 need time to switch from function acl to function dfu, so host add
20ms delay as workaround.

Signed-off-by: Tim Jiang <tjiang@codeaurora.org>
---
 drivers/bluetooth/btusb.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index 5245714..bd5242f 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -4065,6 +4065,11 @@ static int btusb_setup_qca_download_fw(struct hci_dev *hdev,
 	sent += size;
 	count -= size;
 
+	/* ep2 need time to switch from function acl to function dfu,
+	 * so we add 20ms delay here.
+	 */
+	msleep(20);
+
 	while (count) {
 		size = min_t(size_t, count, QCA_DFU_PACKET_LEN);
 
-- 
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v3] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc.
  2021-06-01  9:57 [PATCH v3] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc Zijun Hu
@ 2021-06-02 20:11 ` Marcel Holtmann
  0 siblings, 0 replies; 2+ messages in thread
From: Marcel Holtmann @ 2021-06-02 20:11 UTC (permalink / raw)
  To: Zijun Hu
  Cc: Johan Hedberg, Luiz Augusto von Dentz, linux-kernel,
	linux-bluetooth, linux-arm-msm, bgodavar, c-hbandi, hemantg, mka,
	rjliao, tjiang

Hi Zijun,

> This is btsoc timing issue, after host start to downloading bt firmware,
> ep2 need time to switch from function acl to function dfu, so host add
> 20ms delay as workaround.
> 
> Signed-off-by: Tim Jiang <tjiang@codeaurora.org>
> ---
> drivers/bluetooth/btusb.c | 5 +++++
> 1 file changed, 5 insertions(+)

patch has been applied to bluetooth-next tree.

Regards

Marcel


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-06-02 20:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-01  9:57 [PATCH v3] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc Zijun Hu
2021-06-02 20:11 ` Marcel Holtmann

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).