summaryrefslogtreecommitdiff
path: root/sys/arch/sparc/include/vmparam.h
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>1999-11-11 12:30:37 +0000
committerArtur Grabowski <art@cvs.openbsd.org>1999-11-11 12:30:37 +0000
commitd008d37303b86b5903650611c01e0c534529d791 (patch)
tree3c68c0e02858f365607f558f5706733f3d56752b /sys/arch/sparc/include/vmparam.h
parentc74d9193eb2dd970484a9d259d485126a5e805fc (diff)
General cleanup of pmap.
- MACHINE_NONCONTIG will no longer work and all code that is not MACHINE_NEW_NONCONTIG is removed. - Kill the pv_table hack which adds complexity to the code and wastes some memory, let the vm "handle" the pv lists through the vm_physmem array, this makes allocation a lot easier. - kill the managed() macro, since it was only used to see if pvhead would end up in a "hole" in pv_table. - pvhead() is now a function that returns NULL if the page is unmanaged. It also takes a page number as an argument instead of the physical address, since in most cases pvhead was called as pvhead(ptoa(pa)) anyway and it did an atop internally.
Diffstat (limited to 'sys/arch/sparc/include/vmparam.h')
-rw-r--r--sys/arch/sparc/include/vmparam.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/sys/arch/sparc/include/vmparam.h b/sys/arch/sparc/include/vmparam.h
index bd8b09d36bb..3ebb3f09a84 100644
--- a/sys/arch/sparc/include/vmparam.h
+++ b/sys/arch/sparc/include/vmparam.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: vmparam.h,v 1.12 1999/11/05 21:19:23 art Exp $ */
+/* $OpenBSD: vmparam.h,v 1.13 1999/11/11 12:30:36 art Exp $ */
/* $NetBSD: vmparam.h,v 1.13 1997/07/12 16:20:03 perry Exp $ */
/*
@@ -45,6 +45,9 @@
* @(#)vmparam.h 8.1 (Berkeley) 6/11/93
*/
+#ifndef _SPARC_VMPARAM_H_
+#define _SPARC_VMPARAM_H_
+
/*
* Machine dependent constants for Sun-4c SPARC
*/
@@ -145,8 +148,6 @@
#define MACHINE_NEW_NONCONTIG
-#ifdef MACHINE_NEW_NONCONTIG
-
#define VM_PHYSSEG_MAX 32 /* we only have one "hole" */
#define VM_PHYSSEG_STRAT VM_PSTRAT_BSEARCH
#define VM_PHYSSEG_NOADD /* can't add RAM after vm_mem_init */
@@ -155,16 +156,16 @@
* pmap specific data stored in the vm_physmem[] array
*/
struct pmap_physseg {
- /* NULL */
+ struct pvlist *pv_head;
};
#define VM_NFREELIST 1
#define VM_FREELIST_DEFAULT 0
-#endif
-
#if defined (_KERNEL) && !defined(_LOCORE)
struct vm_map;
vaddr_t dvma_mapin __P((struct vm_map *, vaddr_t, int, int));
void dvma_mapout __P((vaddr_t, vaddr_t, int));
#endif
+
+#endif /* _SPARC_VMPARAM_H_ */