* [PATCH V2] Bluetooth: mgmt: Fix Experimental Feature Changed event
@ 2021-10-06 16:32 Tedd Ho-Jeong An
2021-10-06 17:25 ` [V2] " bluez.test.bot
2021-10-06 17:36 ` [PATCH V2] " Marcel Holtmann
0 siblings, 2 replies; 4+ messages in thread
From: Tedd Ho-Jeong An @ 2021-10-06 16:32 UTC (permalink / raw)
To: linux-bluetooth; +Cc: Tedd Ho-Jeong An
From: Tedd Ho-Jeong An <tedd.an@intel.com>
This patch fixes the controller index in the Experimental Features
Changed event for the offload_codec and the quality_report features to
use the actual hdev index instead of non-controller index(0xffff) so the
client can receive the event and know which controller the event is for.
Fixes: 9332efdf02e9 ("Bluetooth: Add offload feature under experimental flag")
Fixes: 50a75f15531a ("Bluetooth: Support the quality report events")
Signed-off-by: Tedd Ho-Jeong An <tedd.an@intel.com>
---
net/bluetooth/mgmt.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
index 3e5283607b97..44683443300c 100644
--- a/net/bluetooth/mgmt.c
+++ b/net/bluetooth/mgmt.c
@@ -3927,7 +3927,9 @@ static int exp_debug_feature_changed(bool enabled, struct sock *skip)
}
#endif
-static int exp_quality_report_feature_changed(bool enabled, struct sock *skip)
+static int exp_quality_report_feature_changed(bool enabled,
+ struct hci_dev *hdev,
+ struct sock *skip)
{
struct mgmt_ev_exp_feature_changed ev;
@@ -3935,7 +3937,7 @@ static int exp_quality_report_feature_changed(bool enabled, struct sock *skip)
memcpy(ev.uuid, quality_report_uuid, 16);
ev.flags = cpu_to_le32(enabled ? BIT(0) : 0);
- return mgmt_limited_event(MGMT_EV_EXP_FEATURE_CHANGED, NULL,
+ return mgmt_limited_event(MGMT_EV_EXP_FEATURE_CHANGED, hdev,
&ev, sizeof(ev),
HCI_MGMT_EXP_FEATURE_EVENTS, skip);
}
@@ -4156,14 +4158,15 @@ static int set_quality_report_func(struct sock *sk, struct hci_dev *hdev,
&rp, sizeof(rp));
if (changed)
- exp_quality_report_feature_changed(val, sk);
+ exp_quality_report_feature_changed(val, hdev, sk);
unlock_quality_report:
hci_req_sync_unlock(hdev);
return err;
}
-static int exp_offload_codec_feature_changed(bool enabled, struct sock *skip)
+static int exp_offload_codec_feature_changed(bool enabled, struct hci_dev *hdev,
+ struct sock *skip)
{
struct mgmt_ev_exp_feature_changed ev;
@@ -4171,7 +4174,7 @@ static int exp_offload_codec_feature_changed(bool enabled, struct sock *skip)
memcpy(ev.uuid, offload_codecs_uuid, 16);
ev.flags = cpu_to_le32(enabled ? BIT(0) : 0);
- return mgmt_limited_event(MGMT_EV_EXP_FEATURE_CHANGED, NULL,
+ return mgmt_limited_event(MGMT_EV_EXP_FEATURE_CHANGED, hdev,
&ev, sizeof(ev),
HCI_MGMT_EXP_FEATURE_EVENTS, skip);
}
@@ -4229,7 +4232,7 @@ static int set_offload_codec_func(struct sock *sk, struct hci_dev *hdev,
&rp, sizeof(rp));
if (changed)
- exp_offload_codec_feature_changed(val, sk);
+ exp_offload_codec_feature_changed(val, hdev, sk);
return err;
}
--
2.25.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* RE: [V2] Bluetooth: mgmt: Fix Experimental Feature Changed event
2021-10-06 16:32 [PATCH V2] Bluetooth: mgmt: Fix Experimental Feature Changed event Tedd Ho-Jeong An
@ 2021-10-06 17:25 ` bluez.test.bot
2021-10-06 17:36 ` [PATCH V2] " Marcel Holtmann
1 sibling, 0 replies; 4+ messages in thread
From: bluez.test.bot @ 2021-10-06 17:25 UTC (permalink / raw)
To: linux-bluetooth, hj.tedd.an
[-- Attachment #1: Type: text/plain, Size: 1295 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=558633
---Test result---
Test Summary:
CheckPatch PASS 1.82 seconds
GitLint PASS 0.91 seconds
BuildKernel PASS 530.86 seconds
TestRunner: Setup PASS 391.74 seconds
TestRunner: l2cap-tester PASS 8.89 seconds
TestRunner: bnep-tester PASS 4.81 seconds
TestRunner: mgmt-tester FAIL 76.10 seconds
TestRunner: rfcomm-tester PASS 5.88 seconds
TestRunner: sco-tester PASS 6.07 seconds
TestRunner: smp-tester PASS 6.04 seconds
TestRunner: userchan-tester PASS 5.11 seconds
Details
##############################
Test: TestRunner: mgmt-tester - FAIL - 76.10 seconds
Run test-runner with mgmt-tester
Total: 463, Passed: 461 (99.6%), Failed: 2, Not Run: 0
Failed Test Cases
Suspend/Resume - Success 5 (Pairing - Legacy) Failed 1.115 seconds
Suspend/Resume - Success 6 (Pairing - SSP) Failed 1.122 seconds
---
Regards,
Linux Bluetooth
[-- Attachment #2: l2cap-tester.log --]
[-- Type: application/octet-stream, Size: 44356 bytes --]
[-- Attachment #3: bnep-tester.log --]
[-- Type: application/octet-stream, Size: 3563 bytes --]
[-- Attachment #4: mgmt-tester.log --]
[-- Type: application/octet-stream, Size: 638180 bytes --]
[-- Attachment #5: rfcomm-tester.log --]
[-- Type: application/octet-stream, Size: 11683 bytes --]
[-- Attachment #6: sco-tester.log --]
[-- Type: application/octet-stream, Size: 13923 bytes --]
[-- Attachment #7: smp-tester.log --]
[-- Type: application/octet-stream, Size: 11828 bytes --]
[-- Attachment #8: userchan-tester.log --]
[-- Type: application/octet-stream, Size: 6371 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH V2] Bluetooth: mgmt: Fix Experimental Feature Changed event
2021-10-06 16:32 [PATCH V2] Bluetooth: mgmt: Fix Experimental Feature Changed event Tedd Ho-Jeong An
2021-10-06 17:25 ` [V2] " bluez.test.bot
@ 2021-10-06 17:36 ` Marcel Holtmann
2021-10-06 17:41 ` An, Tedd
1 sibling, 1 reply; 4+ messages in thread
From: Marcel Holtmann @ 2021-10-06 17:36 UTC (permalink / raw)
To: Tedd Ho-Jeong An; +Cc: linux-bluetooth, Tedd Ho-Jeong An
Hi Tedd,
> This patch fixes the controller index in the Experimental Features
> Changed event for the offload_codec and the quality_report features to
> use the actual hdev index instead of non-controller index(0xffff) so the
> client can receive the event and know which controller the event is for.
>
> Fixes: 9332efdf02e9 ("Bluetooth: Add offload feature under experimental flag")
> Fixes: 50a75f15531a ("Bluetooth: Support the quality report events")
>
> Signed-off-by: Tedd Ho-Jeong An <tedd.an@intel.com>
> ---
> net/bluetooth/mgmt.c | 15 +++++++++------
> 1 file changed, 9 insertions(+), 6 deletions(-)
patch has been applied to bluetooth-next tree, but I had to fix the commit ids.
Regards
Marcel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH V2] Bluetooth: mgmt: Fix Experimental Feature Changed event
2021-10-06 17:36 ` [PATCH V2] " Marcel Holtmann
@ 2021-10-06 17:41 ` An, Tedd
0 siblings, 0 replies; 4+ messages in thread
From: An, Tedd @ 2021-10-06 17:41 UTC (permalink / raw)
To: marcel; +Cc: linux-bluetooth
Hi Marcel,
On Wed, 2021-10-06 at 19:36 +0200, Marcel Holtmann wrote:
> Hi Tedd,
>
> > This patch fixes the controller index in the Experimental Features
> > Changed event for the offload_codec and the quality_report features to
> > use the actual hdev index instead of non-controller index(0xffff) so the
> > client can receive the event and know which controller the event is for.
> >
> > Fixes: 9332efdf02e9 ("Bluetooth: Add offload feature under experimental flag")
> > Fixes: 50a75f15531a ("Bluetooth: Support the quality report events")
> >
> > Signed-off-by: Tedd Ho-Jeong An <tedd.an@intel.com>
> > ---
> > net/bluetooth/mgmt.c | 15 +++++++++------
> > 1 file changed, 9 insertions(+), 6 deletions(-)
>
> patch has been applied to bluetooth-next tree, but I had to fix the commit ids.
>
I should have rebased the tree before get the commit it. Thanks!
> Regards
>
> Marcel
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-10-06 17:44 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-06 16:32 [PATCH V2] Bluetooth: mgmt: Fix Experimental Feature Changed event Tedd Ho-Jeong An
2021-10-06 17:25 ` [V2] " bluez.test.bot
2021-10-06 17:36 ` [PATCH V2] " Marcel Holtmann
2021-10-06 17:41 ` An, Tedd
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.