Port-m68k archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
kmem changes in -current
The kmem changes in -current have caused problems in the m68k ports using
the common pmap_motorola.c pmap. This is caused by the pmap_init()
routine allocating kernel memory for some of its data structures before
the pmap initialization was complete. This has worked in the past because
the various m68k ports initialzation of the mmu data had mapped sufficient
space in the kernel mmu tables to handle this small allocation and
whatever else the various ports needed to set up for initial kernel
address space allocations.
The new kmem routines are now allocating a somewhat large segment of
kernel address space for the kmem arena, which I think replaced the
segment of memory that the kmem_map had allocated. The kmem_map
allocation was done after pmap_init() ran, so the pmap routines could
handle the mmu table updates properly. The kmem arena is now allocated
before pmap_init() runs, so the memory allocation pmap_init() attempts
fails because the m68k pmap has not been initialized yet.
I believe that the solution for this is for each m68k port to allocated
extra kernel pt pages during their mmu setup. A simple calculation of
physical memory size in pages divided by the number of PTEs per page.
That should provide enough kernel address space to allow pmap_init() to
allocate the memory for the pmap initialization. [The current default
size of the kmem arena is roughly 2/3 the size of the physical memory, so
a closer approximation could include that in the calculation.]
Mike
--
Michael L. Hitch mhitch%montana.edu@localhost
Computer Consultant
Information Technology Center
Montana State University Bozeman, MT USA
Home |
Main Index |
Thread Index |
Old Index