kern: add minimum alignment support to KMemoryManager

This commit is contained in:
Michael Scire authored and SciresM committed 2024-10-15 21:48:59 -07:00
1 parent ff38a32a9b
commit 912b84c4e3
7 files changed
+58 -16

No files matched your search

@@ -924,7 +924,6 @@ namespace ams::kern {
MESOSPHERE_ABORT_UNLESS(m_main_thread_stack_size == 0);
/* Ensure that we're allocating a valid stack. */
stack_size = util::AlignUp(stack_size, PageSize);
R_UNLESS(stack_size + m_code_size <= m_max_process_memory, svc::ResultOutOfMemory());
R_UNLESS(stack_size + m_code_size >= m_code_size, svc::ResultOutOfMemory());