-
Notifications
You must be signed in to change notification settings - Fork 6.9k
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
ARM: Cortex-M: Fixing Context Stacking Error Reporting #25609
Merged
carlescufi
merged 4 commits into
zephyrproject-rtos:master
from
ioannisg:arch_arm_mpu_guard_fixes
May 27, 2020
Merged
ARM: Cortex-M: Fixing Context Stacking Error Reporting #25609
carlescufi
merged 4 commits into
zephyrproject-rtos:master
from
ioannisg:arch_arm_mpu_guard_fixes
May 27, 2020
Conversation
This file contains 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
It is possible that MMFAR address is not written by the Cortex-M core; this occurs when the stacking error is not accompanied by a data access violation error (i.e. when stack overflows due to the exception entry frame stacking): z_check_thread_stack_fail() shall be able to handle the case of 'mmfar' holding the -EINVAL value. Add this node in mem_manage_fault() function to clarify that it is valid for z_check_thread_stack_fail() to be called with invalid mmfar address value. Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
ioannisg
changed the title
Arch arm mpu guard fixes
ARM: Cortex-M: Fixing Stacking Error Reporting
May 26, 2020
ioannisg
changed the title
ARM: Cortex-M: Fixing Stacking Error Reporting
ARM: Cortex-M: Fixing Context Stacking Error Reporting
May 26, 2020
zephyrbot
added
area: ARM
ARM (32-bit) Architecture
area: Tests
Issues related to a particular existing or missing test
labels
May 26, 2020
All checks passed. Tip: The bot edits this comment instead of posting a new one, so you can check the comment's history to see earlier messages. |
ioannisg
force-pushed
the
arch_arm_mpu_guard_fixes
branch
from
May 26, 2020 07:18
02a895a
to
5cfff97
Compare
ioannisg
added
area: Memory Protection
bug
The issue is a bug, or the PR is fixing a bug
labels
May 26, 2020
We add a test case to verify that the Cortex-M fault handling is able to catch stacking errors explicitly due to exception entry frame stacking (that is, when the Cortex-M MCU does not report Data Access Violation MemManage fault with a valid MMFAR value, but only a Stacking MemManage fault). We update the README file accordingly. Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
ioannisg
force-pushed
the
arch_arm_mpu_guard_fixes
branch
from
May 26, 2020 07:28
5cfff97
to
630f698
Compare
Enhance the sample console output of the arm_interrupt test, to reflect recent changes in test context as well as kernel fault handling log output format. Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
We fix (by inverting) the logic of the IS_MPU_GUARD_VIOLATION macro, with respect to the value of the supplied 'fault_addr'. We shall only be inspecting the fault_addr value if it is not set to -EINVAL. Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
ioannisg
force-pushed
the
arch_arm_mpu_guard_fixes
branch
from
May 26, 2020 10:21
600e8b5
to
bbd3e9a
Compare
andrewboie
approved these changes
May 26, 2020
MaureenHelm
approved these changes
May 26, 2020
stephanosio
reviewed
May 27, 2020
stephanosio
previously requested changes
May 27, 2020
carlescufi
approved these changes
May 27, 2020
17 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area: ARM
ARM (32-bit) Architecture
area: Memory Protection
area: Tests
Issues related to a particular existing or missing test
bug
The issue is a bug, or the PR is fixing a bug
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.
Fixes #25612