-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
STACK_POINTER_RANDOM is not working on ARM for the main thread #23702
Comments
Possible solutions:
Other possibilities ? Thoughts ? |
(1) and (2) seem OK to me, (4) as well, if we don't care about the extra bytes... |
I haven't followed this up closely; but at first glance, this seems to be being addressed in #24714, is that correct? @ceolin @andrewboie |
@stephanosio yes correct, I incorporated @ceolin's idea into my series. My large stack overhaul PR is not landing until 2.4, so if we strongly desire a fix for 2.3 just use @ceolin's PR that he closed and I'll rebase on it later |
That's fine with me. |
This issue has been marked as stale because it has been open (more than) 60 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this issue will automatically be closed in 14 days. Note, that you can always re-open a closed issue at any time. |
@andrewboie pls, clarify if this issue can be consider closed after we merged #24714 |
yeah this shouldn't be a problem anymore. |
On arm (and possible others arch with custom swap to main) the main stack is not randomized, because
arch_switch_to_main_thread()
is called withK_THREAD_STACK_SIZEOF(z_main_stack)
in switch_to_main_thread(), completely ignoring the value that was previous randomized inz_setup_new_thread()
. The problem is that this value is not available anymore, except if it is build withCONFIG_THREAD_STACK_INFO
The text was updated successfully, but these errors were encountered: