-
Notifications
You must be signed in to change notification settings - Fork 6.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tests: bluetooth: tester: Move bt_mesh_init call to BTP_MESH_INIT cmd #63556
Merged
carlescufi
merged 2 commits into
zephyrproject-rtos:main
from
PavelVPV:move_mesh_init_to_init_cmd
Oct 5, 2023
Merged
tests: bluetooth: tester: Move bt_mesh_init call to BTP_MESH_INIT cmd #63556
carlescufi
merged 2 commits into
zephyrproject-rtos:main
from
PavelVPV:move_mesh_init_to_init_cmd
Oct 5, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In some RPR tests we need to pass alternative composition data when testing CDP128. When bt_mesh_init is called from mesh service registration callback, we can't pass any arguments. Therefore we need to move bt_mesh_init call out from mesh service registration to BTP_MESH_INIT command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
Remove this command as composition can only be set in bt_mesh_init call which is called before settings are loaded. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
PavelVPV
requested review from
alwa-nordic,
jhedberg,
Vudentz and
sjanc
as code owners
October 5, 2023 06:22
PavelVPV
added
bug
The issue is a bug, or the PR is fixing a bug
area: Bluetooth Mesh
labels
Oct 5, 2023
jhedberg
approved these changes
Oct 5, 2023
alxelax
approved these changes
Oct 5, 2023
sjanc
requested changes
Oct 5, 2023
@@ -79,6 +79,10 @@ struct btp_mesh_provision_node_cmd_v2 { | |||
} __packed; | |||
|
|||
#define BTP_MESH_INIT 0x04 | |||
struct btp_mesh_init_cmd { | |||
bool comp_alt; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this shall be uint8_t
and I'd make it a bit more future proof, ie "uint8_t composition_data", with value 0x00, 0x01 etc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will be addressed here: #63561
PavelVPV
added a commit
to PavelVPV/zephyr
that referenced
this pull request
Oct 6, 2023
This fixes regression introduced in zephyrproject-rtos#63556 In the PR above bt_mesh_init call was moved to BTP_MESH_INIT command to allow to select alternative composition data in the stack. AutoPTS sends BTP_MESH_CONFIG_PROVISIONING command before BTP_MESH_INIT to prepare provisioning context. But because bt_mesh_init is now called in BTP_MESH_INIT command, this configuration is reset to default which makes PTS tests to fail. To solve this, this commit calls introduces a new command BTP_MESH_START, which will be used only for starting the stack by loading the settings and either enabling provisionig or self-provisioning the device. bt_mesh_init will stay in BTP_MESH_INIT command which will be called only at the initialization of a test case in AutoPTS. Previous calls to BTP_MESH_INIT in AutoPTS will be replaced with BTP_MESH_START. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
PavelVPV
added a commit
to PavelVPV/zephyr
that referenced
this pull request
Oct 7, 2023
This fixes regression introduced in zephyrproject-rtos#63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
This was referenced Oct 7, 2023
jhedberg
pushed a commit
that referenced
this pull request
Oct 9, 2023
This fixes regression introduced in #63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
m-alperen-sener
pushed a commit
to m-alperen-sener/sdk-zephyr
that referenced
this pull request
Oct 10, 2023
This fixes regression introduced in zephyrproject-rtos/zephyr#63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no> (cherry picked from commit 94bd09b) Signed-off-by: Alperen Şener <alperen.sener@nordicsemi.no>
kartben
pushed a commit
to kartben/zephyr
that referenced
this pull request
Oct 10, 2023
This fixes regression introduced in zephyrproject-rtos#63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
coreboot-org-bot
pushed a commit
to coreboot/zephyr-cros
that referenced
this pull request
Oct 10, 2023
This fixes regression introduced in zephyrproject-rtos/zephyr#63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. (cherry picked from commit 94bd09b) Original-Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no> GitOrigin-RevId: 94bd09b Change-Id: I71f97a36a011f511abc4ca001262f20af598a175 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/4924326 Commit-Queue: Keith Short <keithshort@chromium.org> Tested-by: ChromeOS Prod (Robot) <chromeos-ci-prod@chromeos-bot.iam.gserviceaccount.com> Reviewed-by: Keith Short <keithshort@chromium.org> Tested-by: Keith Short <keithshort@chromium.org>
rlubos
pushed a commit
to nrfconnect/sdk-zephyr
that referenced
this pull request
Oct 11, 2023
This fixes regression introduced in zephyrproject-rtos/zephyr#63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no> (cherry picked from commit 94bd09b) Signed-off-by: Alperen Şener <alperen.sener@nordicsemi.no>
cvinayak
pushed a commit
to cvinayak/sdk-zephyr
that referenced
this pull request
Oct 20, 2023
This fixes regression introduced in zephyrproject-rtos/zephyr#63556 In the PR above `bt_mesh_init()` call was moved to `BTP_MESH_INIT` command to allow to select alternative composition data when starting the stack. AutoPTS sends `BTP_MESH_CONFIG_PROVISIONING` command before `BTP_MESH_INIT` to prepare the provisioning context. But because `bt_mesh_init()` is now called after `BTP_MESH_CONFIG_PROVISIONING` command is sent, this configuration is reset to the default which makes PTS tests to fail. To solve this, this commit calls introduces a new command, `BTP_MESH_START`, which will replace the original `BTP_MESH_INIT` command. `bt_mesh_init()` will stay in `BTP_MESH_INIT` while the stack will be started in `BTP_MESH_START` command. Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no> (cherry picked from commit 94bd09b) Signed-off-by: Alperen Şener <alperen.sener@nordicsemi.no> (cherry picked from commit 83ea074)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In some RPR tests we need to pass alternative composition data when
testing CDP128. When bt_mesh_init is called from mesh service
registration callback, we can't pass any arguments. Therefore we need
to move bt_mesh_init call out from mesh service registration to
BTP_MESH_INIT command. BTP_MESH_SET_COMP_ALT can then be removed as
it won't work as it was assumed initially.
Corresponding PR to AutoPTS: auto-pts/auto-pts#1018