[Prev][Next][Index][Thread]

Re:an error on swapon




On Mon, 1 Jul 2002, [iso-8859-1] zheng helen wrote:
> hi,suresh, thank you very much, if I only want to build an environment
> of virtual address space with paging. could you give me some advices ?

Hi Helen,

I have just started playing with Oskit, and am still learning the ropes.

For a minimal default VM/paging environment, you probably need liboskit,
liboskit_kern and liboskit_svm. (Note that liboskit_svm uses liboskit_lmm
and liboskit_amm.) If you use the quick start library, liboskit_startup,
it includes the default svm - among many other things.

Another alternative is to use liboskit_uvm, which provides more realistic
virtual memory than svm, but this is tied in with the thread library
liboskit_threads.  liboskit_sproc fills in the missing pieces - context
switch and system call mechanisms, to provide a minimal user mode
environment. sproc is a good example of how to use uvm.

Each of the above components has a separate chapter in the Oskit
documentation; http://www.netbsd.org/Documentation/kernel/uvm.html has
more details of the uvm.

The default environments don't utilize all of the x86 MMU features - eg.
they have a single linear address space/shared page tables etc. If you
want to build your own VM system, you need only the minimal support
provided in liboskit_kern. I would study either svm/uvm implementation to
see how to use the oskit_kern support in building your own VM.

Hope this helps.

--suresh


References: