Re: mapping pages into new address spaces
| Newsgroups | gmane.comp.micro-kernel.l4.l4ka.general |
|---|---|
| Message-ID | <[email protected]> |
Hi Josh, > Here's the only solution I can see: start the new thread executing on > a page that I *know* is unmapped, let it page fault on the first > instruction, and then map the page on demand. Is this the right way > to do it? Am I thinking about this in the right way? Yes, you're right (except that I don't understand why you want a page of which you know that it's not mapped, in a newly created address space, this should be the case for every (user) page, I think). Once the new thread's state is set to active, it waits for a startup IPC from its pager. This IPC contains IP and SP for the thread. Upon receiving the IPC, the thread will start running at the specified IP and raise a page fault. The pager can now reply with the needed page. -Philipp