Fix #1445, add conditional around priority sem test#1509
Merged
Conversation
The multi-thread sem tests (count + bin) have a test that relies on the priority taking effect, that the highest priority thread will get the sem first. However when running as non-root and in permissive mode, the priority is not applied and thus this becomes a race condtion. This adds a test and skips the test if priority is not enabled
4a10f96 to
b16cb4b
Compare
Contributor
Author
|
The failure in the cppcheck static analysis should be fixed by this: nasa/cFS#855 |
dzbaker
added a commit
that referenced
this pull request
Jul 15, 2025
dzbaker
added a commit
that referenced
this pull request
Jul 15, 2025
2 tasks
dzbaker
added a commit
to nasa/cFS
that referenced
this pull request
Jul 16, 2025
*Combines:* osal equuleus-rc1+dev123 **Includes:** *cFE* *osal* - nasa/osal#1509 - nasa/osal#1508 *PSP* Co-authored by: Joseph Hickey <[email protected]> Co-authored by: Abdullah Al Sharji <[email protected]>
dzbaker
added a commit
to nasa/cFS
that referenced
this pull request
Jul 16, 2025
*Combines:* osal equuleus-rc1+dev123 **Includes:** *osal* - nasa/osal#1509 - nasa/osal#1508 Co-authored by: Joseph Hickey <[email protected]> Co-authored by: Abdullah Al Sharji <[email protected]>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Checklist (Please check before submitting)
Describe the contribution
The multi-thread sem tests (count + bin) have a test that relies on the priority taking effect, that the highest priority thread will get the sem first. However when running as non-root and in permissive mode, the priority is not applied and thus this becomes a race condtion.
For now, just skip this test if priority is not activated.
Fixes #1445
Testing performed
Build and run with and without permissive mode
Expected behavior changes
Count sem and Bin sem tests should pass more reliably, not subject to randomness when permissive mode is used.
System(s) tested on
Debian
Contributor Info - All information REQUIRED for consideration of pull request
Joseph Hickey, Vantage Systems, Inc.