Re: Virtual memory and pager
Farid Hajji <[email protected]> Mon, 11 Oct 2010 14:46:01 +0200
| Newsgroups | gmane.comp.micro-kernel.l4.l4ka.general |
|---|---|
| Message-ID | <[email protected]> |
On Sun, Oct 10, 2010 at 7:52 PM, BERTRAND Joel <[email protected]> wrote: > Hello, > > I'm trying to understand how L4 manages system memory. I have read a > lot of docs, but I'm not sure that I have understood very well. > > On my system, I have installed L4, default sigma0 and a hand made > roottask. Roottask must use sigma0 to map virtual addresses to real ones. If > I want to use virtual memory, I have to write a new memory manager. Right ? Yes, you need your own VM manager. I've tried to use NetBSD's VM subsystem in a L4Ka-based setup, but quickly stumbled across the lack of mutexes (esp. of the NetBSD or Solaris-like flavor, i.e. the adaptive mutexes). You need a lot of patience and perseverance here, before you can get a working virtual memory system. ;-) > This memory manager has to be split in two parts, a L4 server > launched by roottask (that includes pagefault management) and a client > library. Is there anywhere some memory management examples ? I have found > http://www.lg2.de/vm.html but I'm not sure that sources are available. I still think that NetBSD's VM subsystem would be a great fit, once the (lack of) mutex problem is solved (ideally in BSD-licensed code!). UVM is reasonably well self-contained, and doesn't depend on too many other parts (at least, nothing you couldn't replace with function stubs): http://www.netbsd.org/docs/kernel/uvm.html > Any URL or exhaustive documentation are welcome. > > Regards, > > JKB Kind regards, -Farid.