-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Revert "Fix MISRA C 2012 Rule 13.3 Violations" #995
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
Conversation
This reverts commit 4d34700.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #995 +/- ##
==========================================
+ Coverage 93.00% 93.53% +0.53%
==========================================
Files 6 6
Lines 3200 3200
Branches 879 889 +10
==========================================
+ Hits 2976 2993 +17
+ Misses 111 92 -19
- Partials 113 115 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Check also the other cases for similar race conditions. I think the post increments and pre-increments should be fine if these variables are in fact not race conditions, and if volatile is required then we need to carefully evaluate what happens when we do a read/modify/write in a non-atomic way on these variables? |
|
We can revert the changes made in the merged PR 988 , since these variables are not in race condition. These variables are only modified in a functionally atomic way ( within critical sections or with the scheduler suspended ) and are either passed by reference into a function or indexed via a volatile variable. The |
|
Reverts #988
After further discussion, this PR does not appropriately address this issue and that the use of the volatile qualifier with uxNumberOfItems should be updated to be configLIST_VOLATILE to be inline with the use of this macro across the rest of the file which will be done in a PR following this one.