linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] Bluetooth: btusb: Fix triggering coredump implementation for QCA
@ 2024-02-04  5:14 Zijun Hu
  2024-02-04  6:07 ` [v1] " bluez.test.bot
  2024-02-23  2:46 ` [PATCH v2] " Zijun Hu
  0 siblings, 2 replies; 6+ messages in thread
From: Zijun Hu @ 2024-02-04  5:14 UTC (permalink / raw)
  To: luiz.dentz, marcel; +Cc: linux-bluetooth, Zijun Hu

btusb_coredump_qca() uses __hci_cmd_sync() to send a vendor-specific
command to trigger firmware coredump, but the command does not have event
HCI_Command_Status or HCI_Command_Complete as its response, actually, it
does not have any sync response event at all, so it is not suitable to
use __hci_cmd_sync(), fixed by using __hci_cmd_send().

Fixes: 20981ce2d5a5 ("Bluetooth: btusb: Add WCN6855 devcoredump support")
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
---
 drivers/bluetooth/btusb.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index edfb49bbaa28..ff282cc25710 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -3469,13 +3469,12 @@ static void btusb_dump_hdr_qca(struct hci_dev *hdev, struct sk_buff *skb)
 
 static void btusb_coredump_qca(struct hci_dev *hdev)
 {
+	int err;
 	static const u8 param[] = { 0x26 };
-	struct sk_buff *skb;
 
-	skb = __hci_cmd_sync(hdev, 0xfc0c, 1, param, HCI_CMD_TIMEOUT);
-	if (IS_ERR(skb))
-		bt_dev_err(hdev, "%s: triggle crash failed (%ld)", __func__, PTR_ERR(skb));
-	kfree_skb(skb);
+	err = __hci_cmd_send(hdev, 0xfc0c, 1, param);
+	if (err < 0)
+		bt_dev_err(hdev, "%s: triggle crash failed (%d)", __func__, err);
 }
 
 /*
-- 
2.7.4


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

* RE: [v1] Bluetooth: btusb: Fix triggering coredump implementation for QCA
  2024-02-04  5:14 [PATCH v1] Bluetooth: btusb: Fix triggering coredump implementation for QCA Zijun Hu
@ 2024-02-04  6:07 ` bluez.test.bot
  2024-02-23  2:46 ` [PATCH v2] " Zijun Hu
  1 sibling, 0 replies; 6+ messages in thread
From: bluez.test.bot @ 2024-02-04  6:07 UTC (permalink / raw)
  To: linux-bluetooth, quic_zijuhu

[-- Attachment #1: Type: text/plain, Size: 2016 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=822830

---Test result---

Test Summary:
CheckPatch                    PASS      0.61 seconds
GitLint                       PASS      0.28 seconds
SubjectPrefix                 PASS      0.10 seconds
BuildKernel                   PASS      28.02 seconds
CheckAllWarning               PASS      30.64 seconds
CheckSparse                   PASS      36.48 seconds
CheckSmatch                   PASS      99.47 seconds
BuildKernel32                 PASS      27.02 seconds
TestRunnerSetup               PASS      496.23 seconds
TestRunner_l2cap-tester       PASS      17.02 seconds
TestRunner_iso-tester         PASS      33.58 seconds
TestRunner_bnep-tester        PASS      4.78 seconds
TestRunner_mgmt-tester        FAIL      106.91 seconds
TestRunner_rfcomm-tester      PASS      7.31 seconds
TestRunner_sco-tester         PASS      11.23 seconds
TestRunner_ioctl-tester       PASS      7.78 seconds
TestRunner_mesh-tester        PASS      5.89 seconds
TestRunner_smp-tester         PASS      6.83 seconds
TestRunner_userchan-tester    PASS      4.95 seconds
IncrementalBuild              PASS      25.80 seconds

Details
##############################
Test: TestRunner_mgmt-tester - FAIL
Desc: Run mgmt-tester with test-runner
Output:
Total: 497, Passed: 486 (97.8%), Failed: 5, Not Run: 6

Failed Test Cases
Read Ext Controller Info 1                           Failed       0.082 seconds
Read Ext Controller Info 2                           Failed       0.091 seconds
Read Ext Controller Info 3                           Failed       0.085 seconds
Read Ext Controller Info 4                           Failed       0.081 seconds
Read Ext Controller Info 5                           Failed       0.099 seconds


---
Regards,
Linux Bluetooth


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

* [PATCH v2] Bluetooth: btusb: Fix triggering coredump implementation for QCA
  2024-02-04  5:14 [PATCH v1] Bluetooth: btusb: Fix triggering coredump implementation for QCA Zijun Hu
  2024-02-04  6:07 ` [v1] " bluez.test.bot
@ 2024-02-23  2:46 ` Zijun Hu
  2024-03-25  8:11   ` [PATCH v2 RESEND] " Zijun Hu
  1 sibling, 1 reply; 6+ messages in thread
From: Zijun Hu @ 2024-02-23  2:46 UTC (permalink / raw)
  To: luiz.dentz, marcel; +Cc: linux-bluetooth, Zijun Hu

btusb_coredump_qca() uses __hci_cmd_sync() to send a vendor-specific
command to trigger firmware coredump, but the command does not
have any event as its sync response, so it is not suitable to use
__hci_cmd_sync(), fixed by using __hci_cmd_send().

Fixes: 20981ce2d5a5 ("Bluetooth: btusb: Add WCN6855 devcoredump support")
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
---
Changes since v1:
 - Correct commit message

 drivers/bluetooth/btusb.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index edfb49bbaa28..ff282cc25710 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -3469,13 +3469,12 @@ static void btusb_dump_hdr_qca(struct hci_dev *hdev, struct sk_buff *skb)
 
 static void btusb_coredump_qca(struct hci_dev *hdev)
 {
+	int err;
 	static const u8 param[] = { 0x26 };
-	struct sk_buff *skb;
 
-	skb = __hci_cmd_sync(hdev, 0xfc0c, 1, param, HCI_CMD_TIMEOUT);
-	if (IS_ERR(skb))
-		bt_dev_err(hdev, "%s: triggle crash failed (%ld)", __func__, PTR_ERR(skb));
-	kfree_skb(skb);
+	err = __hci_cmd_send(hdev, 0xfc0c, 1, param);
+	if (err < 0)
+		bt_dev_err(hdev, "%s: triggle crash failed (%d)", __func__, err);
 }
 
 /*
-- 
2.7.4


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

* [PATCH v2 RESEND] Bluetooth: btusb: Fix triggering coredump implementation for QCA
  2024-02-23  2:46 ` [PATCH v2] " Zijun Hu
@ 2024-03-25  8:11   ` Zijun Hu
  2024-03-25 10:57     ` [v2,RESEND] " bluez.test.bot
  2024-04-11 14:39     ` [PATCH v2 RESEND] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 6+ messages in thread
From: Zijun Hu @ 2024-03-25  8:11 UTC (permalink / raw)
  To: luiz.dentz, marcel; +Cc: linux-bluetooth, Zijun Hu

btusb_coredump_qca() uses __hci_cmd_sync() to send a vendor-specific
command to trigger firmware coredump, but the command does not
have any event as its sync response, so it is not suitable to use
__hci_cmd_sync(), fixed by using __hci_cmd_send().

Fixes: 20981ce2d5a5 ("Bluetooth: btusb: Add WCN6855 devcoredump support")
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
---
V1 -> V2: Correct commit message

 drivers/bluetooth/btusb.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index c391e612b83b..9e9b9fc84211 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -3485,13 +3485,12 @@ static void btusb_dump_hdr_qca(struct hci_dev *hdev, struct sk_buff *skb)
 
 static void btusb_coredump_qca(struct hci_dev *hdev)
 {
+	int err;
 	static const u8 param[] = { 0x26 };
-	struct sk_buff *skb;
 
-	skb = __hci_cmd_sync(hdev, 0xfc0c, 1, param, HCI_CMD_TIMEOUT);
-	if (IS_ERR(skb))
-		bt_dev_err(hdev, "%s: triggle crash failed (%ld)", __func__, PTR_ERR(skb));
-	kfree_skb(skb);
+	err = __hci_cmd_send(hdev, 0xfc0c, 1, param);
+	if (err < 0)
+		bt_dev_err(hdev, "%s: triggle crash failed (%d)", __func__, err);
 }
 
 /*
-- 
2.7.4


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

* RE: [v2,RESEND] Bluetooth: btusb: Fix triggering coredump implementation for QCA
  2024-03-25  8:11   ` [PATCH v2 RESEND] " Zijun Hu
@ 2024-03-25 10:57     ` bluez.test.bot
  2024-04-11 14:39     ` [PATCH v2 RESEND] " patchwork-bot+bluetooth
  1 sibling, 0 replies; 6+ messages in thread
From: bluez.test.bot @ 2024-03-25 10:57 UTC (permalink / raw)
  To: linux-bluetooth, quic_zijuhu

[-- Attachment #1: Type: text/plain, Size: 1962 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=837786

---Test result---

Test Summary:
CheckPatch                    PASS      1.06 seconds
GitLint                       PASS      0.20 seconds
SubjectPrefix                 PASS      0.07 seconds
BuildKernel                   PASS      28.98 seconds
CheckAllWarning               PASS      31.31 seconds
CheckSparse                   PASS      36.60 seconds
CheckSmatch                   PASS      100.76 seconds
BuildKernel32                 PASS      27.90 seconds
TestRunnerSetup               PASS      526.29 seconds
TestRunner_l2cap-tester       PASS      18.03 seconds
TestRunner_iso-tester         PASS      30.78 seconds
TestRunner_bnep-tester        PASS      4.81 seconds
TestRunner_mgmt-tester        FAIL      117.35 seconds
TestRunner_rfcomm-tester      PASS      7.38 seconds
TestRunner_sco-tester         PASS      15.03 seconds
TestRunner_ioctl-tester       PASS      8.02 seconds
TestRunner_mesh-tester        FAIL      6.13 seconds
TestRunner_smp-tester         PASS      7.42 seconds
TestRunner_userchan-tester    PASS      4.96 seconds
IncrementalBuild              PASS      27.28 seconds

Details
##############################
Test: TestRunner_mgmt-tester - FAIL
Desc: Run mgmt-tester with test-runner
Output:
Total: 492, Passed: 489 (99.4%), Failed: 1, Not Run: 2

Failed Test Cases
LL Privacy - Remove Device 4 (Disable Adv)           Timed out    2.643 seconds
##############################
Test: TestRunner_mesh-tester - FAIL
Desc: Run mesh-tester with test-runner
Output:
Total: 10, Passed: 9 (90.0%), Failed: 1, Not Run: 0

Failed Test Cases
Mesh - Send cancel - 1                               Failed       0.108 seconds


---
Regards,
Linux Bluetooth


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

* Re: [PATCH v2 RESEND] Bluetooth: btusb: Fix triggering coredump implementation for QCA
  2024-03-25  8:11   ` [PATCH v2 RESEND] " Zijun Hu
  2024-03-25 10:57     ` [v2,RESEND] " bluez.test.bot
@ 2024-04-11 14:39     ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 6+ messages in thread
From: patchwork-bot+bluetooth @ 2024-04-11 14:39 UTC (permalink / raw)
  To: Zijun Hu; +Cc: luiz.dentz, marcel, linux-bluetooth

Hello:

This patch was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Mon, 25 Mar 2024 16:11:49 +0800 you wrote:
> btusb_coredump_qca() uses __hci_cmd_sync() to send a vendor-specific
> command to trigger firmware coredump, but the command does not
> have any event as its sync response, so it is not suitable to use
> __hci_cmd_sync(), fixed by using __hci_cmd_send().
> 
> Fixes: 20981ce2d5a5 ("Bluetooth: btusb: Add WCN6855 devcoredump support")
> Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
> 
> [...]

Here is the summary with links:
  - [v2,RESEND] Bluetooth: btusb: Fix triggering coredump implementation for QCA
    https://git.kernel.org/bluetooth/bluetooth-next/c/e00fc2700a3f

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2024-04-11 14:39 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-04  5:14 [PATCH v1] Bluetooth: btusb: Fix triggering coredump implementation for QCA Zijun Hu
2024-02-04  6:07 ` [v1] " bluez.test.bot
2024-02-23  2:46 ` [PATCH v2] " Zijun Hu
2024-03-25  8:11   ` [PATCH v2 RESEND] " Zijun Hu
2024-03-25 10:57     ` [v2,RESEND] " bluez.test.bot
2024-04-11 14:39     ` [PATCH v2 RESEND] " patchwork-bot+bluetooth

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