kern: implement SetProcessMemoryPermission

This commit is contained in:
Michael Scire 2020-02-19 08:07:44 -08:00
parent b857153964
commit 28ea0b12a8
9 changed files with 317 additions and 9 deletions

View file

@ -90,11 +90,14 @@ namespace ams::kern {
}
/* Set the process's memory permissions. */
MESOSPHERE_TODO("Set process's memory permissions");
MESOSPHERE_R_ABORT_UNLESS(reader.SetMemoryPermissions(new_process->GetPageTable(), params));
/* Register the process. */
KProcess::Register(new_process);
/* Set the ideal core id. */
new_process->SetIdealCoreId(reader.GetIdealCoreId());
/* Save the process info. */
infos[i].process = new_process;
infos[i].stack_size = reader.GetStackSize();