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

#12855: Fix unpacker race condition by putting stall after MMIO #47

Merged
merged 1 commit into from
Nov 6, 2024

Conversation

amahmudTT
Copy link
Contributor

Fix the race condition by introducing a stall. Brought down the semaphore_post right before the stall as this is supposed to have no functional change. Since you cannot write to the address which is currently being used by the unpacker since there is a wait_for_next_context(2) right above it. Context can start from 0, then go to 1 and then come back to 0 and reach the MMIO writes when wait_for_next_context(2) passes, and that happens when the code that was previously working in context 0 has finished. Same argument for context 1.

@amahmudTT
Copy link
Contributor Author

@amahmudTT amahmudTT merged commit 9ee197a into main Nov 6, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants