[Zion] Map user stacks in as regular MemoryObjects.
This allows us to easily track the physical memory so it can be freed when the thread exits. It also simplifies the page fault handler as it just needs to check regular mappings to find a user stack.
This commit is contained in:
parent
ba1b4df702
commit
2dd69f5844
6 changed files with 29 additions and 42 deletions
|
|
@ -21,10 +21,7 @@ class UserStackManager {
|
|||
UserStackManager(const UserStackManager&) = delete;
|
||||
|
||||
uint64_t NewUserStack();
|
||||
void FreeUserStack(uint64_t stack_ptr);
|
||||
|
||||
// Used to check if we should page in this address.
|
||||
bool IsValidStack(uint64_t vaddr);
|
||||
void FreeUserStack(uint64_t stack_base);
|
||||
|
||||
private:
|
||||
uint64_t next_stack_ = kUserStackMax;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue