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

Add double-lock detection for OSAL mutexes as a debug option #434

Open
jphickey opened this issue Apr 22, 2020 · 0 comments
Open

Add double-lock detection for OSAL mutexes as a debug option #434

jphickey opened this issue Apr 22, 2020 · 0 comments

Comments

@jphickey
Copy link
Contributor

Is your feature request related to a problem? Please describe.
A recent issue in nasa/cFE#591 was due to an application double-locking the same mutex from the same task. This wasn't detected during testing because POSIX allows this recursive locking. However, other RTOS's do not allow it, nor is it intended behavior.

Describe the solution you'd like
OSAL should check/enforce that a single task ID only takes a mutex once, and must release it before locking again. Violations of this pattern should be reported to the debug console, so they can be addressed by the developer.

As there is a small overhead cost to doing this, it can be selectively enabled as a debug feature, and remain off by default.

Additional context
See nasa/cFE#591

Requester Info
Joseph Hickey, Vantage Systems, Inc.

jphickey pushed a commit to jphickey/osal that referenced this issue Aug 10, 2022
Fix nasa#433, Release Prep
Document and copyright header changes only
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant