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

Disable stack overflow check for MPU ports #1231

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

aggarg
Copy link
Member

@aggarg aggarg commented Jan 23, 2025

Description

Stack overflow check is not straight forward to implement for MPU ports because of the following reasons:

  1. The context is stroed in TCB and as a result, pxTopOfStack member points to the context location in TCB.
  2. System calls are executed on a separate privileged only stack.

It is still okay because an MPU region is used to protect task stack which means task stack overflow will trigger an MPU fault.

Test Steps

Verified on Cortex-M33 hardware.

Checklist:

  • I have tested my changes. No regression in existing tests.
  • [NA] I have modified and/or added unit-tests to cover the code changes in this Pull Request.

Related Issue

#1195

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Stack overflow check is not straight forward to implement for MPU ports
because of the following reasons:
1. The context is stroed in TCB and as a result, pxTopOfStack member
   points to the context location in TCB.
2. System calls are executed on a separate privileged only stack.

It is still okay because an MPU region is used to protect task stack
which means task stack overflow will trigger an MPU fault.

Signed-off-by: Gaurav Aggarwal <[email protected]>
@aggarg aggarg requested a review from a team as a code owner January 23, 2025 15:53
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.

1 participant