diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2013-11-24 22:08:26 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2013-11-24 22:08:26 +0000 |
commit | ab644ba2fceb296f7981110fb3a5ffad3964cfa8 (patch) | |
tree | e5f3db0fe2670a4bcf012b9452b15ce8f9e95c4c /sys/dev/ksyms.c | |
parent | e4ec95a467c44394ef93cf84c849fda6e6f248fa (diff) |
Rework pmap to use dynamic P0 and P1 region allocation, instead of allocating
the largest possible page table for every pmap; from NetBSD. This allows the
kernel to use much less memory for page tables.
Significant differences against the NetBSD code are:
- allocation of page table pages is done with a pool instead of allocating
whole logical pages from uvm and managing the freelist within pmap, never
releasing allocated pages.
- try to use pt_entry_t * rather than int * whenever possible.
- growth of P0 and P1 regions is allowed to fail, if invoked from
pmap_enter with the PMAP_CANFAIL flag. This will stall processes until
memory for the page tables can be obtained, rather than panicing, in
most cases.
- keep management of mappings for managed pages using pv lists tied to the
vm_page (using __HAVE_VM_PAGE_MD), rather than a global pv_list head.
- bound check against Sysmap[] in pmap_extract() when asked for a kernel
address.
As a result of this, bsd.rd can now install a working system on a 12MB machine
without needing to enable swap.
Diffstat (limited to 'sys/dev/ksyms.c')
0 files changed, 0 insertions, 0 deletions