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

tmr,main: thread safe tmr handling #690

Merged
merged 7 commits into from
Feb 16, 2023
Merged

tmr,main: thread safe tmr handling #690

merged 7 commits into from
Feb 16, 2023

Conversation

sreimers
Copy link
Member

@sreimers sreimers commented Feb 10, 2023

It's possible that a worker thread can reuse a tmr (for example if turnc recv helper is executed from a different re poll thread and stun refresh tmr is updated). The new worker thread has to unlink the old tmr from main thread timer list. This needs thread safe mutex handling. The impact on performance is likely to be small because the competitive situation is low.

@sreimers sreimers added this to the v2.13.0 milestone Feb 10, 2023
@sreimers sreimers added the RX thread RX real-time thread label Feb 10, 2023
@sreimers sreimers marked this pull request as ready for review February 11, 2023 10:52
src/main/main.c Outdated Show resolved Hide resolved
src/tmr/tmr.c Outdated Show resolved Hide resolved
@sreimers sreimers merged commit 5983c22 into main Feb 16, 2023
@sreimers sreimers deleted the tmr_mtx branch February 16, 2023 08:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RX thread RX real-time thread
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants