* [PATCH BlueZ v1 1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE
@ 2025-09-26 16:20 Luiz Augusto von Dentz
2025-09-26 16:20 ` [PATCH BlueZ v1 2/2] btdev: Fix advertisement state Luiz Augusto von Dentz
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Luiz Augusto von Dentz @ 2025-09-26 16:20 UTC (permalink / raw)
To: linux-bluetooth
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Checking for le_adv_enable alone is not valid considering the comments
itself states that peridic advertising shall be allowed.
---
emulator/btdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/emulator/btdev.c b/emulator/btdev.c
index 99e3e5cfa754..67c932d53d59 100644
--- a/emulator/btdev.c
+++ b/emulator/btdev.c
@@ -4273,7 +4273,7 @@ static int cmd_set_rl_enable(struct btdev *dev, const void *data, uint8_t len)
* • an HCI_LE_Create_Connection, HCI_LE_Extended_Create_Connection,
* or HCI_LE_Periodic_Advertising_Create_Sync command is outstanding.
*/
- if (dev->le_adv_enable || dev->le_scan_enable)
+ if ((dev->le_adv_enable && !dev->le_pa_enable) || dev->le_scan_enable)
return -EPERM;
/* Valid range for address resolution enable is 0x00 to 0x01 */
--
2.51.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH BlueZ v1 2/2] btdev: Fix advertisement state
2025-09-26 16:20 [PATCH BlueZ v1 1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE Luiz Augusto von Dentz
@ 2025-09-26 16:20 ` Luiz Augusto von Dentz
2025-09-26 18:05 ` [BlueZ,v1,1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE bluez.test.bot
2025-09-29 13:40 ` [PATCH BlueZ v1 1/2] " patchwork-bot+bluetooth
2 siblings, 0 replies; 4+ messages in thread
From: Luiz Augusto von Dentz @ 2025-09-26 16:20 UTC (permalink / raw)
To: linux-bluetooth
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
The LE Advertisement state shall be updated whenever an advertisement
is disabled since if all advertisments sets are disabled it shall be
reflected in le_adv_enable.
---
emulator/btdev.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/emulator/btdev.c b/emulator/btdev.c
index 67c932d53d59..1a0f9ef2de58 100644
--- a/emulator/btdev.c
+++ b/emulator/btdev.c
@@ -4789,9 +4789,17 @@ static bool match_ext_adv_handle(const void *data, const void *match_data)
return ext_adv->handle == handle;
}
+static bool match_ext_adv_enable(const void *data, const void *match_data)
+{
+ const struct le_ext_adv *ext_adv = data;
+
+ return ext_adv->enable;
+}
+
static void ext_adv_disable(void *data, void *user_data)
{
struct le_ext_adv *ext_adv = data;
+ struct btdev *btdev = ext_adv->dev;
uint8_t handle = PTR_TO_UINT(user_data);
if (handle && ext_adv->handle != handle)
@@ -4807,6 +4815,13 @@ static void ext_adv_disable(void *data, void *user_data)
}
ext_adv->enable = 0x00;
+
+ /* Consider le_adv_enable disabled if all advertising sets are
+ * disabled.
+ */
+ ext_adv = queue_find(btdev->le_ext_adv, match_ext_adv_enable, NULL);
+ if (!ext_adv)
+ btdev->le_adv_enable = 0x00;
}
static bool ext_adv_is_connectable(struct le_ext_adv *ext_adv)
--
2.51.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* RE: [BlueZ,v1,1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE
2025-09-26 16:20 [PATCH BlueZ v1 1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE Luiz Augusto von Dentz
2025-09-26 16:20 ` [PATCH BlueZ v1 2/2] btdev: Fix advertisement state Luiz Augusto von Dentz
@ 2025-09-26 18:05 ` bluez.test.bot
2025-09-29 13:40 ` [PATCH BlueZ v1 1/2] " patchwork-bot+bluetooth
2 siblings, 0 replies; 4+ messages in thread
From: bluez.test.bot @ 2025-09-26 18:05 UTC (permalink / raw)
To: linux-bluetooth, luiz.dentz
[-- Attachment #1: Type: text/plain, Size: 1492 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=1006636
---Test result---
Test Summary:
CheckPatch PENDING 0.36 seconds
GitLint PENDING 0.39 seconds
BuildEll PASS 18.51 seconds
BluezMake PASS 4365.77 seconds
MakeCheck PASS 19.86 seconds
MakeDistcheck PASS 175.19 seconds
CheckValgrind PASS 233.22 seconds
CheckSmatch WARNING 273.46 seconds
bluezmakeextell PASS 124.03 seconds
IncrementalBuild PENDING 0.45 seconds
ScanBuild PASS 866.50 seconds
Details
##############################
Test: CheckPatch - PENDING
Desc: Run checkpatch.pl script
Output:
##############################
Test: GitLint - PENDING
Desc: Run gitlint
Output:
##############################
Test: CheckSmatch - WARNING
Desc: Run smatch tool with source
Output:
emulator/btdev.c:456:29: warning: Variable length array is used.emulator/btdev.c:456:29: warning: Variable length array is used.
##############################
Test: IncrementalBuild - PENDING
Desc: Incremental build with the patches in the series
Output:
---
Regards,
Linux Bluetooth
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH BlueZ v1 1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE
2025-09-26 16:20 [PATCH BlueZ v1 1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE Luiz Augusto von Dentz
2025-09-26 16:20 ` [PATCH BlueZ v1 2/2] btdev: Fix advertisement state Luiz Augusto von Dentz
2025-09-26 18:05 ` [BlueZ,v1,1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE bluez.test.bot
@ 2025-09-29 13:40 ` patchwork-bot+bluetooth
2 siblings, 0 replies; 4+ messages in thread
From: patchwork-bot+bluetooth @ 2025-09-29 13:40 UTC (permalink / raw)
To: Luiz Augusto von Dentz; +Cc: linux-bluetooth
Hello:
This series was applied to bluetooth/bluez.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:
On Fri, 26 Sep 2025 12:20:01 -0400 you wrote:
> From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
>
> Checking for le_adv_enable alone is not valid considering the comments
> itself states that peridic advertising shall be allowed.
> ---
> emulator/btdev.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Here is the summary with links:
- [BlueZ,v1,1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE
https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=a6d35e91b80b
- [BlueZ,v1,2/2] btdev: Fix advertisement state
https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=e7c77f80787d
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] 4+ messages in thread
end of thread, other threads:[~2025-09-29 13:40 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-26 16:20 [PATCH BlueZ v1 1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE Luiz Augusto von Dentz
2025-09-26 16:20 ` [PATCH BlueZ v1 2/2] btdev: Fix advertisement state Luiz Augusto von Dentz
2025-09-26 18:05 ` [BlueZ,v1,1/2] btdev: Fix handling of BT_HCI_CMD_LE_SET_RESOLV_ENABLE bluez.test.bot
2025-09-29 13:40 ` [PATCH BlueZ v1 1/2] " 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