2023-12-08 17:17:37

by quic_zijuhu

[permalink] [raw]
Subject: [PATCH v1] Bluetooth: hci_conn: Remove a redundant check for HFP offload

Remove a redundant check !hdev->get_codec_config_data.

Signed-off-by: Zijun Hu <[email protected]>
---
net/bluetooth/hci_conn.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c
index a41d2693f4d8..a4c96bd202fd 100644
--- a/net/bluetooth/hci_conn.c
+++ b/net/bluetooth/hci_conn.c
@@ -300,13 +300,13 @@ static int configure_datapath_sync(struct hci_dev *hdev, struct bt_codec *codec)
__u8 vnd_len, *vnd_data = NULL;
struct hci_op_configure_data_path *cmd = NULL;

+ /* Do not take below 2 checks as error since the 1st means user do not
+ * want to use HFP offload mode and the 2nd means the vendor controller
+ * do not need to send below HCI command for offload mode.
+ */
if (!codec->data_path || !hdev->get_codec_config_data)
return 0;

- /* Do not take me as error */
- if (!hdev->get_codec_config_data)
- return 0;
-
err = hdev->get_codec_config_data(hdev, ESCO_LINK, codec, &vnd_len,
&vnd_data);
if (err < 0)
--
The Qualcomm Innovation Center



2023-12-08 17:57:02

by bluez.test.bot

[permalink] [raw]
Subject: RE: [v1] Bluetooth: hci_conn: Remove a redundant check for HFP offload

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=808336

---Test result---

Test Summary:
CheckPatch PASS 0.62 seconds
GitLint PASS 0.32 seconds
SubjectPrefix PASS 0.12 seconds
BuildKernel PASS 27.52 seconds
CheckAllWarning PASS 30.56 seconds
CheckSparse PASS 35.92 seconds
CheckSmatch PASS 98.80 seconds
BuildKernel32 PASS 26.81 seconds
TestRunnerSetup PASS 422.30 seconds
TestRunner_l2cap-tester PASS 22.94 seconds
TestRunner_iso-tester PASS 45.47 seconds
TestRunner_bnep-tester PASS 6.99 seconds
TestRunner_mgmt-tester PASS 167.73 seconds
TestRunner_rfcomm-tester PASS 11.47 seconds
TestRunner_sco-tester PASS 14.60 seconds
TestRunner_ioctl-tester PASS 12.41 seconds
TestRunner_mesh-tester PASS 8.83 seconds
TestRunner_smp-tester PASS 10.05 seconds
TestRunner_userchan-tester PASS 7.31 seconds
IncrementalBuild PASS 25.60 seconds



---
Regards,
Linux Bluetooth

2024-04-22 14:47:05

by quic_zijuhu

[permalink] [raw]
Subject: [PATCH v1 RESEND] Bluetooth: hci_conn: Remove a redundant check for HFP offload

Remove a redundant check !hdev->get_codec_config_data.

Signed-off-by: Zijun Hu <[email protected]>
---
net/bluetooth/hci_conn.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c
index a3b226255eb9..81166a5bc034 100644
--- a/net/bluetooth/hci_conn.c
+++ b/net/bluetooth/hci_conn.c
@@ -242,13 +242,13 @@ static int configure_datapath_sync(struct hci_dev *hdev, struct bt_codec *codec)
__u8 vnd_len, *vnd_data = NULL;
struct hci_op_configure_data_path *cmd = NULL;

+ /* Do not take below 2 checks as error since the 1st means user do not
+ * want to use HFP offload mode and the 2nd means the vendor controller
+ * do not need to send below HCI command for offload mode.
+ */
if (!codec->data_path || !hdev->get_codec_config_data)
return 0;

- /* Do not take me as error */
- if (!hdev->get_codec_config_data)
- return 0;
-
err = hdev->get_codec_config_data(hdev, ESCO_LINK, codec, &vnd_len,
&vnd_data);
if (err < 0)
--
2.7.4


2024-04-22 15:34:31

by bluez.test.bot

[permalink] [raw]
Subject: RE: [v1,RESEND] Bluetooth: hci_conn: Remove a redundant check for HFP offload

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=846706

---Test result---

Test Summary:
CheckPatch PASS 0.46 seconds
GitLint PASS 0.20 seconds
SubjectPrefix PASS 0.06 seconds
BuildKernel PASS 31.11 seconds
CheckAllWarning PASS 33.50 seconds
CheckSparse PASS 39.85 seconds
CheckSmatch FAIL 37.98 seconds
BuildKernel32 PASS 30.35 seconds
TestRunnerSetup PASS 540.23 seconds
TestRunner_l2cap-tester PASS 18.63 seconds
TestRunner_iso-tester PASS 31.08 seconds
TestRunner_bnep-tester PASS 4.60 seconds
TestRunner_mgmt-tester FAIL 110.73 seconds
TestRunner_rfcomm-tester PASS 7.21 seconds
TestRunner_sco-tester PASS 14.86 seconds
TestRunner_ioctl-tester PASS 7.52 seconds
TestRunner_mesh-tester PASS 5.68 seconds
TestRunner_smp-tester PASS 6.76 seconds
TestRunner_userchan-tester PASS 4.78 seconds
IncrementalBuild PASS 27.79 seconds

Details
##############################
Test: CheckSmatch - FAIL
Desc: Run smatch tool with source
Output:

Segmentation fault (core dumped)
make[4]: *** [scripts/Makefile.build:244: net/bluetooth/hci_core.o] Error 139
make[4]: *** Deleting file 'net/bluetooth/hci_core.o'
make[3]: *** [scripts/Makefile.build:485: net/bluetooth] Error 2
make[2]: *** [scripts/Makefile.build:485: net] Error 2
make[2]: *** Waiting for unfinished jobs....
Segmentation fault (core dumped)
make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/bcm203x.o] Error 139
make[4]: *** Deleting file 'drivers/bluetooth/bcm203x.o'
make[4]: *** Waiting for unfinished jobs....
Segmentation fault (core dumped)
make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/bpa10x.o] Error 139
make[4]: *** Deleting file 'drivers/bluetooth/bpa10x.o'
make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2
make[2]: *** [scripts/Makefile.build:485: drivers] Error 2
make[1]: *** [/github/workspace/src/src/Makefile:1919: .] Error 2
make: *** [Makefile:240: __sub-make] Error 2
##############################
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
Pairing Acceptor - SMP over BR/EDR 1 Timed out 1.806 seconds


---
Regards,
Linux Bluetooth

2024-04-22 15:39:15

by patchwork-bot+bluetooth

[permalink] [raw]
Subject: Re: [PATCH v1 RESEND] Bluetooth: hci_conn: Remove a redundant check for HFP offload

Hello:

This patch was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <[email protected]>:

On Mon, 22 Apr 2024 22:46:34 +0800 you wrote:
> Remove a redundant check !hdev->get_codec_config_data.
>
> Signed-off-by: Zijun Hu <[email protected]>
> ---
> net/bluetooth/hci_conn.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)

Here is the summary with links:
- [v1,RESEND] Bluetooth: hci_conn: Remove a redundant check for HFP offload
https://git.kernel.org/bluetooth/bluetooth-next/c/ebe00bbb01f3

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