vmparam.h revision 1.1.2.2 1 1.1.2.2 jdolecek /* $NetBSD: vmparam.h,v 1.1.2.2 2002/06/23 17:37:11 jdolecek Exp $ */
2 1.1.2.2 jdolecek
3 1.1.2.2 jdolecek /* $OpenBSD: vmparam.h,v 1.17 2001/09/22 18:00:09 miod Exp $ */
4 1.1.2.2 jdolecek
5 1.1.2.2 jdolecek /*
6 1.1.2.2 jdolecek * Copyright (c) 1988-1994, The University of Utah and
7 1.1.2.2 jdolecek * the Computer Systems Laboratory at the University of Utah (CSL).
8 1.1.2.2 jdolecek * All rights reserved.
9 1.1.2.2 jdolecek *
10 1.1.2.2 jdolecek * Permission to use, copy, modify and distribute this software is hereby
11 1.1.2.2 jdolecek * granted provided that (1) source code retains these copyright, permission,
12 1.1.2.2 jdolecek * and disclaimer notices, and (2) redistributions including binaries
13 1.1.2.2 jdolecek * reproduce the notices in supporting documentation, and (3) all advertising
14 1.1.2.2 jdolecek * materials mentioning features or use of this software display the following
15 1.1.2.2 jdolecek * acknowledgement: ``This product includes software developed by the
16 1.1.2.2 jdolecek * Computer Systems Laboratory at the University of Utah.''
17 1.1.2.2 jdolecek *
18 1.1.2.2 jdolecek * THE UNIVERSITY OF UTAH AND CSL ALLOW FREE USE OF THIS SOFTWARE IN ITS "AS
19 1.1.2.2 jdolecek * IS" CONDITION. THE UNIVERSITY OF UTAH AND CSL DISCLAIM ANY LIABILITY OF
20 1.1.2.2 jdolecek * ANY KIND FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
21 1.1.2.2 jdolecek *
22 1.1.2.2 jdolecek * CSL requests users of this software to return to csl-dist (at) cs.utah.edu any
23 1.1.2.2 jdolecek * improvements that they make and grant CSL redistribution rights.
24 1.1.2.2 jdolecek *
25 1.1.2.2 jdolecek * Utah $Hdr: vmparam.h 1.16 94/12/16$
26 1.1.2.2 jdolecek */
27 1.1.2.2 jdolecek
28 1.1.2.2 jdolecek #ifndef _HPPA_VMPARAM_H_
29 1.1.2.2 jdolecek #define _HPPA_VMPARAM_H_
30 1.1.2.2 jdolecek
31 1.1.2.2 jdolecek /*
32 1.1.2.2 jdolecek * Machine dependent constants for HP PA
33 1.1.2.2 jdolecek */
34 1.1.2.2 jdolecek /*
35 1.1.2.2 jdolecek * USRTEXT is the start of the user text/data space, while USRSTACK
36 1.1.2.2 jdolecek * is the top (end) of the user stack. LOWPAGES and HIGHPAGES are
37 1.1.2.2 jdolecek * the number of pages from the beginning of the P0 region to the
38 1.1.2.2 jdolecek * beginning of the text and from the beginning of the P1 region to the
39 1.1.2.2 jdolecek * beginning of the stack respectively.
40 1.1.2.2 jdolecek */
41 1.1.2.2 jdolecek #define USRTEXT 0x00002000 /* Start of user .text */
42 1.1.2.2 jdolecek #define USRSTACK 0x68FF3000 /* Start of user stack */
43 1.1.2.2 jdolecek #define LOWPAGES 0
44 1.1.2.2 jdolecek #define HIGHPAGES UPAGES
45 1.1.2.2 jdolecek #define SYSCALLGATE 0xC0000000 /* syscall gateway page */
46 1.1.2.2 jdolecek
47 1.1.2.2 jdolecek #define __HAVE_PMAP_PHYSSEG
48 1.1.2.2 jdolecek
49 1.1.2.2 jdolecek /* Alignment requirement for a uspace. */
50 1.1.2.2 jdolecek #define USPACE_ALIGN NBPG
51 1.1.2.2 jdolecek
52 1.1.2.2 jdolecek /*
53 1.1.2.2 jdolecek * Virtual memory related constants, all in bytes
54 1.1.2.2 jdolecek */
55 1.1.2.2 jdolecek #ifndef MAXTSIZ
56 1.1.2.2 jdolecek #define MAXTSIZ (0x40000000) /* max text size */
57 1.1.2.2 jdolecek #endif
58 1.1.2.2 jdolecek #ifndef DFLDSIZ
59 1.1.2.2 jdolecek #define DFLDSIZ (16*1024*1024) /* initial data size limit */
60 1.1.2.2 jdolecek #endif
61 1.1.2.2 jdolecek #ifndef MAXDSIZ
62 1.1.2.2 jdolecek #define MAXDSIZ (USRSTACK-MAXTSIZ) /* max data size */
63 1.1.2.2 jdolecek #endif
64 1.1.2.2 jdolecek #ifndef DFLSSIZ
65 1.1.2.2 jdolecek #define DFLSSIZ (512*1024) /* initial stack size limit */
66 1.1.2.2 jdolecek #endif
67 1.1.2.2 jdolecek #ifndef MAXSSIZ
68 1.1.2.2 jdolecek #define MAXSSIZ (UADDR-USRSTACK) /* max stack size */
69 1.1.2.2 jdolecek #endif
70 1.1.2.2 jdolecek
71 1.1.2.2 jdolecek #ifndef USRIOSIZE
72 1.1.2.2 jdolecek #define USRIOSIZE ((2*HPPA_PGALIAS)/PAGE_SIZE) /* 2mb */
73 1.1.2.2 jdolecek #endif
74 1.1.2.2 jdolecek
75 1.1.2.2 jdolecek /*
76 1.1.2.2 jdolecek * PTEs for system V style shared memory.
77 1.1.2.2 jdolecek * This is basically slop for kmempt which we actually allocate (malloc) from.
78 1.1.2.2 jdolecek */
79 1.1.2.2 jdolecek #ifndef SHMMAXPGS
80 1.1.2.2 jdolecek #define SHMMAXPGS ((1024*1024*10)/NBPG) /* 10mb */
81 1.1.2.2 jdolecek #endif
82 1.1.2.2 jdolecek
83 1.1.2.2 jdolecek /*
84 1.1.2.2 jdolecek * The time for a process to be blocked before being very swappable.
85 1.1.2.2 jdolecek * This is a number of seconds which the system takes as being a non-trivial
86 1.1.2.2 jdolecek * amount of real time. You probably shouldn't change this;
87 1.1.2.2 jdolecek * it is used in subtle ways (fractions and multiples of it are, that is, like
88 1.1.2.2 jdolecek * half of a ``long time'', almost a long time, etc.)
89 1.1.2.2 jdolecek * It is related to human patience and other factors which don't really
90 1.1.2.2 jdolecek * change over time.
91 1.1.2.2 jdolecek */
92 1.1.2.2 jdolecek #define MAXSLP 20
93 1.1.2.2 jdolecek
94 1.1.2.2 jdolecek /* user/kernel map constants */
95 1.1.2.2 jdolecek #define VM_MIN_ADDRESS ((vaddr_t)0)
96 1.1.2.2 jdolecek #define VM_MAXUSER_ADDRESS ((vaddr_t)0xc0000000)
97 1.1.2.2 jdolecek #define VM_MAX_ADDRESS VM_MAXUSER_ADDRESS
98 1.1.2.2 jdolecek #define VM_MIN_KERNEL_ADDRESS ((vaddr_t)0)
99 1.1.2.2 jdolecek #define VM_MAX_KERNEL_ADDRESS ((vaddr_t)0xf0000000)
100 1.1.2.2 jdolecek
101 1.1.2.2 jdolecek /* virtual sizes (bytes) for various kernel submaps */
102 1.1.2.2 jdolecek #define VM_PHYS_SIZE (USRIOSIZE*PAGE_SIZE)
103 1.1.2.2 jdolecek
104 1.1.2.2 jdolecek #define VM_PHYSSEG_MAX 8 /* this many physmem segments */
105 1.1.2.2 jdolecek #define VM_PHYSSEG_STRAT VM_PSTRAT_BIGFIRST
106 1.1.2.2 jdolecek
107 1.1.2.2 jdolecek #define VM_PHYSSEG_NOADD /* XXX until uvm code is fixed */
108 1.1.2.2 jdolecek
109 1.1.2.2 jdolecek #define VM_NFREELIST 2
110 1.1.2.2 jdolecek #define VM_FREELIST_DEFAULT 0
111 1.1.2.2 jdolecek #define VM_FREELIST_FIRST16 1
112 1.1.2.2 jdolecek
113 1.1.2.2 jdolecek #ifdef _KERNEL
114 1.1.2.2 jdolecek struct pmap_physseg {
115 1.1.2.2 jdolecek int pmap_table_off;
116 1.1.2.2 jdolecek };
117 1.1.2.2 jdolecek #endif
118 1.1.2.2 jdolecek
119 1.1.2.2 jdolecek #endif /* _HPPA_VMPARAM_H_ */
120 1.1.2.2 jdolecek
121