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

[Backport v3.6-branch] kernel: Update k_wakeup() #69436

Merged
merged 1 commit into from
Mar 12, 2024

Conversation

zephyrbot
Copy link
Collaborator

@zephyrbot zephyrbot commented Feb 26, 2024

Backport 51ae993 from #69255.

Fixes: #69148

This commit does two things to k_wakeup():

1. It locks the scheduler before marking the thread as not suspended.
As the the clearing of the _THREAD_SUSPENDED bit is not atomic, this
helps ensure that neither another thread nor ISR interrupts this
action (resulting in a corrupted thread_state).

2. The call to flag_ipi() has been removed as it is already being
made within ready_thread().

Signed-off-by: Peter Mitsis <[email protected]>
(cherry picked from commit 51ae993)
@zephyrbot zephyrbot added Backport Backport PR and backport failure issues area: Kernel labels Feb 26, 2024
@henrikbrixandersen henrikbrixandersen added this to the v3.6.1 milestone Feb 26, 2024
@henrikbrixandersen
Copy link
Member

@andyross Please review.

Copy link
Contributor

@andyross andyross left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks correct. Just in general I don't know that it's worth waiting on me to confirm obvious backports when the author approves.

@henrikbrixandersen henrikbrixandersen merged commit cd21e04 into v3.6-branch Mar 12, 2024
26 checks passed
@nashif nashif deleted the backport-69255-to-v3.6-branch branch November 16, 2024 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Kernel Backport Backport PR and backport failure issues
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

5 participants