2010-03-08 12:04:59 +01:00
|
|
|
#include <machine/vm.h>
|
2008-11-19 13:26:10 +01:00
|
|
|
|
|
|
|
/* As visible from the user space process, where is the top of the
|
|
|
|
* stack (first non-stack byte), when in paged mode?
|
|
|
|
*/
|
|
|
|
#define VM_STACKTOP 0x80000000
|
|
|
|
|
|
|
|
/* And what is the highest addressable piece of memory, when in paged
|
|
|
|
* mode? Some data for kernel and stack are subtracted from this, the
|
|
|
|
* final results stored in bytes in arch.vm_data_top.
|
|
|
|
*/
|
|
|
|
#define VM_DATATOP 0xFFFFF000
|
|
|
|
|
|
|
|
#define SLAB_PAGESIZE I386_PAGE_SIZE
|
|
|
|
#define VM_PAGE_SIZE I386_PAGE_SIZE
|
|
|
|
|
2009-05-11 21:11:37 +02:00
|
|
|
/* Where do processes start in linear (i.e. page table) memory? */
|
2009-09-21 16:49:49 +02:00
|
|
|
#define VM_PROCSTART (I386_BIG_PAGE_SIZE*100)
|
2009-05-11 21:11:37 +02:00
|
|
|
|
2008-11-19 13:26:10 +01:00
|
|
|
#define CLICKSPERPAGE (I386_PAGE_SIZE/CLICK_SIZE)
|
|
|
|
|
|
|
|
/* Where is the kernel? */
|
|
|
|
#define KERNEL_TEXT CLICK2ABS(vmproc[VMP_SYSTEM].vm_arch.vm_seg[T].mem_phys)
|
|
|
|
#define KERNEL_TEXT_LEN CLICK2ABS(vmproc[VMP_SYSTEM].vm_arch.vm_seg[T].mem_len)
|
|
|
|
#define KERNEL_DATA CLICK2ABS(vmproc[VMP_SYSTEM].vm_arch.vm_seg[D].mem_phys)
|
|
|
|
#define KERNEL_DATA_LEN CLICK2ABS(vmproc[VMP_SYSTEM].vm_arch.vm_seg[D].mem_len \
|
|
|
|
+ vmproc[VMP_SYSTEM].vm_arch.vm_seg[S].mem_len)
|
|
|
|
|