Home | History | Annotate | Line # | Download | only in include
vmparam.h revision 1.10
      1 /*	$NetBSD: vmparam.h,v 1.10 2002/12/10 05:14:32 thorpej Exp $	*/
      2 
      3 #ifndef OLDPMAP
      4 #define	USER_SR		11
      5 #include <powerpc/mpc6xx/vmparam.h>
      6 #else
      7 /*-
      8  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
      9  * Copyright (C) 1995, 1996 TooLs GmbH.
     10  * All rights reserved.
     11  *
     12  * Redistribution and use in source and binary forms, with or without
     13  * modification, are permitted provided that the following conditions
     14  * are met:
     15  * 1. Redistributions of source code must retain the above copyright
     16  *    notice, this list of conditions and the following disclaimer.
     17  * 2. Redistributions in binary form must reproduce the above copyright
     18  *    notice, this list of conditions and the following disclaimer in the
     19  *    documentation and/or other materials provided with the distribution.
     20  * 3. All advertising materials mentioning features or use of this software
     21  *    must display the following acknowledgement:
     22  *	This product includes software developed by TooLs GmbH.
     23  * 4. The name of TooLs GmbH may not be used to endorse or promote products
     24  *    derived from this software without specific prior written permission.
     25  *
     26  * THIS SOFTWARE IS PROVIDED BY TOOLS GMBH ``AS IS'' AND ANY EXPRESS OR
     27  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
     28  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
     29  * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
     30  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
     31  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
     32  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
     33  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
     34  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
     35  * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     36  */
     37 
     38 #ifndef	_MACHINE_VMPARAM_H_
     39 #define	_MACHINE_VMPARAM_H_
     40 
     41 #define	USRSTACK	VM_MAXUSER_ADDRESS
     42 
     43 #ifndef	MAXTSIZ
     44 #define	MAXTSIZ		(16*1024*1024)		/* max text size */
     45 #endif
     46 
     47 #ifndef	DFLDSIZ
     48 #define	DFLDSIZ		(32*1024*1024)		/* default data size */
     49 #endif
     50 
     51 #ifndef	MAXDSIZ
     52 #define	MAXDSIZ		(512*1024*1024)		/* max data size */
     53 #endif
     54 
     55 #ifndef	DFLSSIZ
     56 #define	DFLSSIZ		(1*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  * Would like to have MAX addresses = 0, but this doesn't (currently) work
     77  */
     78 #define	VM_MIN_ADDRESS		((vaddr_t)0)
     79 #define	VM_MAXUSER_ADDRESS	((vaddr_t)0xfffff000)
     80 #define	VM_MAX_ADDRESS		VM_MAXUSER_ADDRESS
     81 #define	VM_MIN_KERNEL_ADDRESS	((vaddr_t)(KERNEL_SR << ADDR_SR_SHFT))
     82 #define	VM_MAX_KERNEL_ADDRESS	(VM_MIN_KERNEL_ADDRESS + SEGMENT_LENGTH - 1)
     83 
     84 /* XXX max. amount of KVM to be used by buffers. */
     85 #ifndef VM_MAX_KERNEL_BUF
     86 #define	VM_MAX_KERNEL_BUF	(SEGMENT_LENGTH * 7 / 10)
     87 #endif
     88 
     89 /*
     90  * Override the default pager_map size, there's not enough KVA.
     91  */
     92 #define	PAGER_MAP_SIZE		(4 * 1024 * 1024)
     93 
     94 #define	VM_PHYS_SIZE		(USRIOSIZE * NBPG)
     95 
     96 #define	__HAVE_PMAP_PHYSSEG
     97 
     98 #ifndef _LOCORE
     99 struct pmap_physseg {
    100 	struct pv_entry *pvent;
    101 	char *attrs;
    102 };
    103 #endif /* _LOCORE */
    104 
    105 #define VM_PHYSSEG_MAX		32
    106 #define VM_PHYSSEG_STRAT	VM_PSTRAT_BSEARCH
    107 #define VM_PHYSSEG_NOADD		/* can't add RAM after vm_mem_init */
    108 
    109 #define VM_NFREELIST		1
    110 #define VM_FREELIST_DEFAULT	0
    111 
    112 #endif /* _MACHINE_VMPARAM_H_ */
    113 #endif
    114