linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc.
@ 2021-05-26  5:51 Zijun Hu
  2021-05-26  6:39 ` [v2] " bluez.test.bot
  2021-05-26 15:15 ` [PATCH v2] " Marcel Holtmann
  0 siblings, 2 replies; 3+ messages in thread
From: Zijun Hu @ 2021-05-26  5:51 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 | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index 5245714..b0743db 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -4064,6 +4064,7 @@ static int btusb_setup_qca_download_fw(struct hci_dev *hdev,
 
 	sent += size;
 	count -= size;
+	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] 3+ messages in thread

* RE: [v2] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc.
  2021-05-26  5:51 [PATCH v2] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc Zijun Hu
@ 2021-05-26  6:39 ` bluez.test.bot
  2021-05-26 15:15 ` [PATCH v2] " Marcel Holtmann
  1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2021-05-26  6:39 UTC (permalink / raw)
  To: linux-bluetooth, zijuhu

[-- Attachment #1: Type: text/plain, Size: 2938 bytes --]

This is automated email and please do not reply to this email!

Dear submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=488581

---Test result---

Test Summary:
CheckPatch                    PASS      0.81 seconds
GitLint                       FAIL      0.13 seconds
BuildKernel                   PASS      582.56 seconds
TestRunner: Setup             PASS      389.93 seconds
TestRunner: l2cap-tester      PASS      3.02 seconds
TestRunner: bnep-tester       PASS      2.03 seconds
TestRunner: mgmt-tester       PASS      29.93 seconds
TestRunner: rfcomm-tester     PASS      2.20 seconds
TestRunner: sco-tester        PASS      2.22 seconds
TestRunner: smp-tester        PASS      2.30 seconds
TestRunner: userchan-tester   PASS      2.04 seconds

Details
##############################
Test: CheckPatch - PASS - 0.81 seconds
Run checkpatch.pl script with rule in .checkpatch.conf


##############################
Test: GitLint - FAIL - 0.13 seconds
Run gitlint with rule in .gitlint
Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc.
1: T1 Title exceeds max length (73>72): "Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc."
1: T3 Title has trailing punctuation (.): "Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc."


##############################
Test: BuildKernel - PASS - 582.56 seconds
Build Kernel with minimal configuration supports Bluetooth


##############################
Test: TestRunner: Setup - PASS - 389.93 seconds
Setup environment for running Test Runner


##############################
Test: TestRunner: l2cap-tester - PASS - 3.02 seconds
Run test-runner with l2cap-tester
Total: 40, Passed: 40 (100.0%), Failed: 0, Not Run: 0

##############################
Test: TestRunner: bnep-tester - PASS - 2.03 seconds
Run test-runner with bnep-tester
Total: 1, Passed: 1 (100.0%), Failed: 0, Not Run: 0

##############################
Test: TestRunner: mgmt-tester - PASS - 29.93 seconds
Run test-runner with mgmt-tester
Total: 427, Passed: 412 (96.5%), Failed: 0, Not Run: 15

##############################
Test: TestRunner: rfcomm-tester - PASS - 2.20 seconds
Run test-runner with rfcomm-tester
Total: 9, Passed: 9 (100.0%), Failed: 0, Not Run: 0

##############################
Test: TestRunner: sco-tester - PASS - 2.22 seconds
Run test-runner with sco-tester
Total: 8, Passed: 8 (100.0%), Failed: 0, Not Run: 0

##############################
Test: TestRunner: smp-tester - PASS - 2.30 seconds
Run test-runner with smp-tester
Total: 8, Passed: 8 (100.0%), Failed: 0, Not Run: 0

##############################
Test: TestRunner: userchan-tester - PASS - 2.04 seconds
Run test-runner with userchan-tester
Total: 3, Passed: 3 (100.0%), Failed: 0, Not Run: 0



---
Regards,
Linux Bluetooth


[-- Attachment #2: l2cap-tester.log --]
[-- Type: application/octet-stream, Size: 44350 bytes --]

[-- Attachment #3: bnep-tester.log --]
[-- Type: application/octet-stream, Size: 3555 bytes --]

[-- Attachment #4: mgmt-tester.log --]
[-- Type: application/octet-stream, Size: 560805 bytes --]

[-- Attachment #5: rfcomm-tester.log --]
[-- Type: application/octet-stream, Size: 11677 bytes --]

[-- Attachment #6: sco-tester.log --]
[-- Type: application/octet-stream, Size: 9911 bytes --]

[-- Attachment #7: smp-tester.log --]
[-- Type: application/octet-stream, Size: 11823 bytes --]

[-- Attachment #8: userchan-tester.log --]
[-- Type: application/octet-stream, Size: 5453 bytes --]

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

* Re: [PATCH v2] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc.
  2021-05-26  5:51 [PATCH v2] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc Zijun Hu
  2021-05-26  6:39 ` [v2] " bluez.test.bot
@ 2021-05-26 15:15 ` Marcel Holtmann
  1 sibling, 0 replies; 3+ messages in thread
From: Marcel Holtmann @ 2021-05-26 15:15 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 | 1 +
> 1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
> index 5245714..b0743db 100644
> --- a/drivers/bluetooth/btusb.c
> +++ b/drivers/bluetooth/btusb.c
> @@ -4064,6 +4064,7 @@ static int btusb_setup_qca_download_fw(struct hci_dev *hdev,
> 
> 	sent += size;
> 	count -= size;

you need a comment here explain why this is needed.

> +	msleep(20);
> 
> 	while (count) {
> 		size = min_t(size_t, count, QCA_DFU_PACKET_LEN);

Regards

Marcel


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

end of thread, other threads:[~2021-05-26 15:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-05-26  5:51 [PATCH v2] Bluetooth: btusb: fix bt fiwmare downloading failure issue for qca btsoc Zijun Hu
2021-05-26  6:39 ` [v2] " bluez.test.bot
2021-05-26 15:15 ` [PATCH v2] " 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).