2021-07-26 20:23:25

by Tedd Ho-Jeong An

[permalink] [raw]
Subject: [PATCH] Bluetooth: mgmt: Fix wrong opcode in the response for add_adv cmd

From: Tedd Ho-Jeong An <[email protected]>

This patch fixes the MGMT add_advertising command repsones with the
wrong opcode when it is trying to return the not supported error.

Fixes: cbbdfa6f33198 ("Bluetooth: Enable controller RPA resolution using Experimental feature")
Signed-off-by: Tedd Ho-Jeong An <[email protected]>
---
net/bluetooth/mgmt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
index 3663f880df11..1e21e014efd2 100644
--- a/net/bluetooth/mgmt.c
+++ b/net/bluetooth/mgmt.c
@@ -7725,7 +7725,7 @@ static int add_advertising(struct sock *sk, struct hci_dev *hdev,
* advertising.
*/
if (hci_dev_test_flag(hdev, HCI_ENABLE_LL_PRIVACY))
- return mgmt_cmd_status(sk, hdev->id, MGMT_OP_SET_ADVERTISING,
+ return mgmt_cmd_status(sk, hdev->id, MGMT_OP_ADD_ADVERTISING,
MGMT_STATUS_NOT_SUPPORTED);

if (cp->instance < 1 || cp->instance > hdev->le_num_of_adv_sets)
--
2.26.3


2021-07-27 02:15:39

by bluez.test.bot

[permalink] [raw]
Subject: RE: Bluetooth: mgmt: Fix wrong opcode in the response for add_adv cmd

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

---Test result---

Test Summary:
CheckPatch FAIL 0.47 seconds
GitLint FAIL 0.11 seconds
BuildKernel PASS 649.82 seconds
TestRunner: Setup PASS 421.83 seconds
TestRunner: l2cap-tester PASS 2.96 seconds
TestRunner: bnep-tester PASS 2.03 seconds
TestRunner: mgmt-tester PASS 33.97 seconds
TestRunner: rfcomm-tester PASS 2.49 seconds
TestRunner: sco-tester PASS 2.44 seconds
TestRunner: smp-tester FAIL 2.98 seconds
TestRunner: userchan-tester PASS 2.43 seconds

Details
##############################
Test: CheckPatch - FAIL - 0.47 seconds
Run checkpatch.pl script with rule in .checkpatch.conf
Bluetooth: mgmt: Fix wrong opcode in the response for add_adv cmd
WARNING: Unknown commit id 'cbbdfa6f33198', maybe rebased or not pulled?
#10:
Fixes: cbbdfa6f33198 ("Bluetooth: Enable controller RPA resolution using Experimental feature")

total: 0 errors, 1 warnings, 0 checks, 8 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: mgmt: Fix wrong opcode in the response for add_adv" 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: mgmt: Fix wrong opcode in the response for add_adv cmd
6: B1 Line exceeds max length (95>80): "Fixes: cbbdfa6f33198 ("Bluetooth: Enable controller RPA resolution using Experimental feature")"


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


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


##############################
Test: TestRunner: l2cap-tester - PASS - 2.96 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 - 33.97 seconds
Run test-runner with mgmt-tester
Total: 448, Passed: 445 (99.3%), Failed: 0, Not Run: 3

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

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

##############################
Test: TestRunner: smp-tester - FAIL - 2.98 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.032 seconds

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



---
Regards,
Linux Bluetooth


Attachments:
l2cap-tester.log (43.35 kB)
bnep-tester.log (3.51 kB)
mgmt-tester.log (602.41 kB)
rfcomm-tester.log (11.44 kB)
sco-tester.log (9.71 kB)
smp-tester.log (11.47 kB)
userchan-tester.log (5.36 kB)
Download all attachments