When reading the support debug features failed, there are not available
features init. Continue to set the debug features is illogical, we should
skip btintel_set_debug_features(), even if check it by "if (!features)".
Fixes: c453b10c2b28 ("Bluetooth: btusb: Configure Intel debug feature based on
available support")
Signed-off-by: Jun Miao <[email protected]>
---
drivers/bluetooth/btusb.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index 7f6ba2c975ed..a3c027d17745 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -2889,10 +2889,11 @@ static int btusb_setup_intel_new(struct hci_dev *hdev)
/* Read the Intel supported features and if new exception formats
* supported, need to load the additional DDC config to enable.
*/
- btintel_read_debug_features(hdev, &features);
-
- /* Set DDC mask for available debug features */
- btintel_set_debug_features(hdev, &features);
+ err = btintel_read_debug_features(hdev, &features);
+ if (!err) {
+ /* Set DDC mask for available debug features */
+ btintel_set_debug_features(hdev, &features);
+ }
/* Read the Intel version information after loading the FW */
err = btintel_read_version(hdev, &ver);
@@ -2985,10 +2986,11 @@ static int btusb_setup_intel_newgen(struct hci_dev *hdev)
/* Read the Intel supported features and if new exception formats
* supported, need to load the additional DDC config to enable.
*/
- btintel_read_debug_features(hdev, &features);
-
- /* Set DDC mask for available debug features */
- btintel_set_debug_features(hdev, &features);
+ err = btintel_read_debug_features(hdev, &features);
+ if (!err) {
+ /* Set DDC mask for available debug features */
+ btintel_set_debug_features(hdev, &features);
+ }
/* Read the Intel version information after loading the FW */
err = btintel_read_version_tlv(hdev, &version);
--
2.25.1
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=513119
---Test result---
Test Summary:
CheckPatch FAIL 0.48 seconds
GitLint FAIL 0.11 seconds
BuildKernel PASS 554.29 seconds
TestRunner: Setup PASS 359.14 seconds
TestRunner: l2cap-tester PASS 2.65 seconds
TestRunner: bnep-tester PASS 1.99 seconds
TestRunner: mgmt-tester PASS 30.97 seconds
TestRunner: rfcomm-tester PASS 2.16 seconds
TestRunner: sco-tester PASS 2.09 seconds
TestRunner: smp-tester FAIL 2.12 seconds
TestRunner: userchan-tester PASS 2.01 seconds
Details
##############################
Test: CheckPatch - FAIL - 0.48 seconds
Run checkpatch.pl script with rule in .checkpatch.conf
Bluetooth: btusb: Fix a unspported condition to set available debug features
WARNING: Unknown commit id 'c453b10c2b28', maybe rebased or not pulled?
#11:
Fixes: c453b10c2b28 ("Bluetooth: btusb: Configure Intel debug feature based on
total: 0 errors, 1 warnings, 30 lines checked
NOTE: For some of the reported defects, checkpatch may be able to
mechanically convert to the typical style using --fix or --fix-inplace.
"[PATCH] Bluetooth: btusb: Fix a unspported condition to set available" has style problems, please review.
NOTE: If any of the errors are false positives, please report
them to the maintainer, see CHECKPATCH in MAINTAINERS.
##############################
Test: GitLint - FAIL - 0.11 seconds
Run gitlint with rule in .gitlint
Bluetooth: btusb: Fix a unspported condition to set available debug features
1: T1 Title exceeds max length (76>72): "Bluetooth: btusb: Fix a unspported condition to set available debug features"
##############################
Test: BuildKernel - PASS - 554.29 seconds
Build Kernel with minimal configuration supports Bluetooth
##############################
Test: TestRunner: Setup - PASS - 359.14 seconds
Setup environment for running Test Runner
##############################
Test: TestRunner: l2cap-tester - PASS - 2.65 seconds
Run test-runner with l2cap-tester
Total: 40, Passed: 40 (100.0%), Failed: 0, Not Run: 0
##############################
Test: TestRunner: bnep-tester - PASS - 1.99 seconds
Run test-runner with bnep-tester
Total: 1, Passed: 1 (100.0%), Failed: 0, Not Run: 0
##############################
Test: TestRunner: mgmt-tester - PASS - 30.97 seconds
Run test-runner with mgmt-tester
Total: 446, Passed: 443 (99.3%), Failed: 0, Not Run: 3
##############################
Test: TestRunner: rfcomm-tester - PASS - 2.16 seconds
Run test-runner with rfcomm-tester
Total: 9, Passed: 9 (100.0%), Failed: 0, Not Run: 0
##############################
Test: TestRunner: sco-tester - PASS - 2.09 seconds
Run test-runner with sco-tester
Total: 8, Passed: 8 (100.0%), Failed: 0, Not Run: 0
##############################
Test: TestRunner: smp-tester - FAIL - 2.12 seconds
Run test-runner with smp-tester
Total: 8, Passed: 7 (87.5%), Failed: 1, Not Run: 0
Failed Test Cases
SMP Client - SC Request 2 Failed 0.020 seconds
##############################
Test: TestRunner: userchan-tester - PASS - 2.01 seconds
Run test-runner with userchan-tester
Total: 3, Passed: 3 (100.0%), Failed: 0, Not Run: 0
---
Regards,
Linux Bluetooth
Hi Jun,
> When reading the support debug features failed, there are not available
> features init. Continue to set the debug features is illogical, we should
> skip btintel_set_debug_features(), even if check it by "if (!features)".
>
> Fixes: c453b10c2b28 ("Bluetooth: btusb: Configure Intel debug feature based on
> available support")
> Signed-off-by: Jun Miao <[email protected]>
> ---
> drivers/bluetooth/btusb.c | 18 ++++++++++--------
> 1 file changed, 10 insertions(+), 8 deletions(-)
patch has been applied to bluetooth-next tree.
Regards
Marcel