xref: /netbsd-src/sys/arch/sandpoint/include/vmparam.h (revision 3b01aba77a7a698587faaae455bbfe740923c1f5)
1 /*	$NetBSD: vmparam.h,v 1.6 2001/06/21 16:30:05 briggs Exp $	*/
2 
3 #ifdef NEWPMAP
4 #include <powerpc/mpc6xx/vmparam.h>
5 #else
6 /*-
7  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
8  * Copyright (C) 1995, 1996 TooLs GmbH.
9  * All rights reserved.
10  *
11  * Redistribution and use in source and binary forms, with or without
12  * modification, are permitted provided that the following conditions
13  * are met:
14  * 1. Redistributions of source code must retain the above copyright
15  *    notice, this list of conditions and the following disclaimer.
16  * 2. Redistributions in binary form must reproduce the above copyright
17  *    notice, this list of conditions and the following disclaimer in the
18  *    documentation and/or other materials provided with the distribution.
19  * 3. All advertising materials mentioning features or use of this software
20  *    must display the following acknowledgement:
21  *	This product includes software developed by TooLs GmbH.
22  * 4. The name of TooLs GmbH may not be used to endorse or promote products
23  *    derived from this software without specific prior written permission.
24  *
25  * THIS SOFTWARE IS PROVIDED BY TOOLS GMBH ``AS IS'' AND ANY EXPRESS OR
26  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
27  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
28  * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
29  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
30  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
31  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
32  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
33  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
34  * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35  */
36 
37 #ifndef	_MACHINE_VMPARAM_H_
38 #define	_MACHINE_VMPARAM_H_
39 
40 #define	USRTEXT		NBPG
41 #define	USRSTACK	VM_MAXUSER_ADDRESS
42 
43 #ifndef	MAXTSIZ
44 #define	MAXTSIZ		(64*1024*1024)		/* max text size */
45 #endif
46 
47 #ifndef	DFLDSIZ
48 #define	DFLDSIZ		(128*1024*1024)		/* default data size */
49 #endif
50 
51 #ifndef	MAXDSIZ
52 #define	MAXDSIZ		(1*1024*1024*1024)	/* max data size */
53 #endif
54 
55 #ifndef	DFLSSIZ
56 #define	DFLSSIZ		(2*1024*1024)		/* default stack size */
57 #endif
58 
59 #ifndef	MAXSSIZ
60 #define	MAXSSIZ		(32*1024*1024)		/* max stack size */
61 #endif
62 
63 /*
64  * Size of shared memory map
65  */
66 #ifndef	SHMMAXPGS
67 #define	SHMMAXPGS	1024
68 #endif
69 
70 /*
71  * Size of User Raw I/O map
72  */
73 #define	USRIOSIZE	1024
74 
75 /*
76  * The time for a process to be blocked before being very swappable.
77  * This is a number of seconds which the system takes as being a non-trivial
78  * amount of real time.  You probably shouldn't change this;
79  * it is used in subtle ways (fractions and multiples of it are, that is, like
80  * half of a ``long time'', almost a long time, etc.)
81  * It is related to human patience and other factors which don't really
82  * change over time.
83  */
84 #define	MAXSLP 		20
85 
86 /*
87  * Would like to have MAX addresses = 0, but this doesn't (currently) work
88  */
89 #define	VM_MIN_ADDRESS		((vaddr_t)0)
90 #define	VM_MAXUSER_ADDRESS	((vaddr_t)0xfffff000)
91 #define	VM_MAX_ADDRESS		VM_MAXUSER_ADDRESS
92 #define	VM_MIN_KERNEL_ADDRESS	((vaddr_t)(KERNEL_SR << ADDR_SR_SHFT))
93 #define	VM_MAX_KERNEL_ADDRESS	(VM_MIN_KERNEL_ADDRESS + SEGMENT_LENGTH - 1)
94 
95 #define	VM_PHYS_SIZE		(USRIOSIZE * NBPG)
96 
97 #define	__HAVE_PMAP_PHYSSEG
98 
99 #ifndef _LOCORE
100 struct pmap_physseg {
101 	struct pv_entry *pvent;
102 	char *attrs;
103 };
104 #endif
105 
106 #define VM_PHYSSEG_MAX		32
107 #define VM_PHYSSEG_STRAT	VM_PSTRAT_BSEARCH
108 #define VM_PHYSSEG_NOADD		/* can't add RAM after vm_mem_init */
109 
110 #define VM_NFREELIST		1
111 #define VM_FREELIST_DEFAULT	0
112 
113 #endif /* _MACHINE_VMPARAM_H_ */
114 #endif
115