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