diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2007-04-13 18:12:17 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2007-04-13 18:12:17 +0000 |
commit | 4334f84bd6d2b2d546e95eda5985c701441287af (patch) | |
tree | d98ba9c870d5fb9ebb88ea6caa64b3f6016dc91c /sys/arch/powerpc | |
parent | 64beb5f733a23f027dc8265f5b39edeb08a34dbf (diff) |
Relax the cache flags logic in pmap_kenter_pa, to make sure that mappings
entered before vm_physmem[] are initialized will be cached. This is a
temporary measure until this pmap implements pmap_steal_memory().
Help and ok drahn@
Diffstat (limited to 'sys/arch/powerpc')
-rw-r--r-- | sys/arch/powerpc/powerpc/pmap.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/arch/powerpc/powerpc/pmap.c b/sys/arch/powerpc/powerpc/pmap.c index cd3c307bfed..eb2687587d3 100644 --- a/sys/arch/powerpc/powerpc/pmap.c +++ b/sys/arch/powerpc/powerpc/pmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pmap.c,v 1.97 2007/02/22 20:34:46 thib Exp $ */ +/* $OpenBSD: pmap.c,v 1.98 2007/04/13 18:12:16 miod Exp $ */ /* * Copyright (c) 2001, 2002 Dale Rahn. @@ -694,7 +694,6 @@ _pmap_kenter_pa(vaddr_t va, paddr_t pa, vm_prot_t prot, int flags, int cache) struct pte_desc *pted; int s; pmap_t pm; - struct pted_pv_head *pvh; pm = pmap_kernel(); @@ -717,9 +716,8 @@ _pmap_kenter_pa(vaddr_t va, paddr_t pa, vm_prot_t prot, int flags, int cache) pmap_vp_enter(pm, va, pted); } - pvh = pmap_find_pvh(pa); if (cache == PMAP_CACHE_DEFAULT) { - if (pvh != NULL) + if (pa < 0x80000000 || pmap_find_pvh(pa) != NULL) cache = PMAP_CACHE_WB; /* managed memory is cacheable */ else cache = PMAP_CACHE_CI; |