Subject: memory, booting, etc..
To: None <>
From: None <newsham@uhunix.uhcc.Hawaii.Edu>
List: amiga-dev
Date: 03/10/1994 13:41:37

  I have NetBSD running on a system with 5megs of 32 wide ram
and 4 megs of 16 wide ram.  My machine does alot of swapping since
in BSD it can only use 5 megs and I've decided since no one else
is working at getting BSD to use non-contiguous memory I'd give
it a shot.  I've been reading through some of the low level code
and have some questions and would like to make sure what I understand
from it is infact correct.  First a question about 16 bit ram:

When I was using just 16 bit ram there was a bug that came up
while using gcc that was attributed to the 16 bit ram.  More recently
I remember some discussion about certain operations on 16-bit ram
on GVP devices across page boundaries or at odd byte-addresses.  Has
this problem been resolved yet?  I suppose there is little use in
using 16-bit ram if its going to start breaking things.

Ok..  from what I understand:

  loadbsd goes through the (amigados) memory list and finds the biggest
chunk of fastram.  It stores this as well as the other config information
(with the other memory chunks) at the end of the kernel when booting
into BSD.  It malloc()'s a location in memory, reads in the kernel
image, turns off the MMU and does some other magic before copying
the entire BSD image to address 0.  After the copy it does a jump
to the entry point of the kernel (I assume in locore.s).  End loadbsd.

Now in BSD we go through some intializing.  Part of this initializing
is a call to start_c from within locore.s.  This passes the chunk of
memory which is to be used by BSD.  start_c then makes up some
translation buffers for the mmu so that address 0(virtual) refers
to the start of the fastram(physical).  It copies the kernel to
this address and turns on the mmu.  Start_c also sets up other
tables for mmu translation.

Ok..  so now about this being the only memory used...  Why is this
the only memory used?  When memory is needed for a process how is
it taken?  Would changing the system to use non-contiguous memory
be a major design change or would it simply involve keeping track
of the various chunks in a list and filling out some page tables?
Is/has anyone else been working on this?

                                  Tim N.