Skip to content
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

chip-repl hits the Code is unsafe/racy assert when BLE commissioning is started #26338

Merged
merged 6 commits into from
May 5, 2023

Conversation

tehampson
Copy link
Contributor

@tehampson tehampson commented May 2, 2023

Fixes: #26265

PR #26180 added assert on the task ownership of the chip Stack lock on some SystemLayer timer calls.

The Linux ChipDeviceScanner starts a SystemLayer timer on the BLE connection which now asserts.

This pr fix the assert on SystemLayer().StartTimer call by acquiring the chipStack Lock before the call (and releasing it after)

Tested the fix by successfully starting to scan chip-repl

@github-actions
Copy link

github-actions bot commented May 2, 2023

PR #26338: Size comparison from 8f66f42 to 22d4958

Increases (1 build for cc32xx)
platform target config section 8f66f42 22d4958 change % change
cc32xx lock CC3235SF_LAUNCHXL .debug_info 19511283 19511285 2 0.0
Full report (1 build for cc32xx)
platform target config section 8f66f42 22d4958 change % change
cc32xx lock CC3235SF_LAUNCHXL 0 0 0 0.0
(read only) 604426 604426 0 0.0
(read/write) 204156 204156 0 0.0
.ARM.attributes 44 44 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 197568 197568 0 0.0
.comment 206 206 0 0.0
.data 1468 1468 0 0.0
.debug_abbrev 956872 956872 0 0.0
.debug_aranges 101056 101056 0 0.0
.debug_frame 341168 341168 0 0.0
.debug_info 19511283 19511285 2 0.0
.debug_line 2664965 2664965 0 0.0
.debug_line_str 513 513 0 0.0
.debug_loc 33340 33340 0 0.0
.debug_loclists 1486884 1486884 0 0.0
.debug_ranges 4984 4984 0 0.0
.debug_rnglists 94239 94239 0 0.0
.debug_str 3068127 3068127 0 0.0
.ramVecs 780 780 0 0.0
.resetVecs 64 64 0 0.0
.rodata 104298 104298 0 0.0
.shstrtab 265 265 0 0.0
.stack 2048 2048 0 0.0
.strtab 480350 480350 0 0.0
.symtab 287024 287024 0 0.0
.text 498004 498004 0 0.0

@andy31415 andy31415 merged commit da37e59 into project-chip:master May 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] [PYTHON] BLE Scan crash
3 participants