summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorrrs <rrs@FreeBSD.org>2010-01-28 14:09:16 +0000
committerrrs <rrs@FreeBSD.org>2010-01-28 14:09:16 +0000
commitb8876b1cbe84dade81236ff32726ae694278f549 (patch)
tree2f9f71bcb7f29f05797aafbd3ee15b5d422a365b /sys
parent7fa7beba1ec476b298f337d4eabcdd93f0f4757f (diff)
downloadFreeBSD-src-b8876b1cbe84dade81236ff32726ae694278f549.zip
FreeBSD-src-b8876b1cbe84dade81236ff32726ae694278f549.tar.gz
Fix two of the extended memory hacks. The copy pages
routine in one place was setting the valid2 bit to 2 not 1. This meant the PTE was NOT valid and so you would crash. In Zero Page there was a incorrect setting of the valid bit AFTER the actual zero (opps).. Hopefully this will fix the 0xc0000000 crashes that I have been seeing (unless of course there are other problems with these old hacks of mine to get to memory above 512Meg)
Diffstat (limited to 'sys')
-rw-r--r--sys/mips/mips/pmap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/mips/mips/pmap.c b/sys/mips/mips/pmap.c
index 671413b..f11fc4a 100644
--- a/sys/mips/mips/pmap.c
+++ b/sys/mips/mips/pmap.c
@@ -2273,8 +2273,8 @@ pmap_zero_page(vm_page_t m)
PMAP_LGMEM_LOCK(sysm);
sched_pin();
sysm->CMAP1 = mips_paddr_to_tlbpfn(phys) | PTE_RW | PTE_V | PTE_G | PTE_W | PTE_CACHE;
- pmap_TLB_update_kernel((vm_offset_t)sysm->CADDR1, sysm->CMAP1);
sysm->valid1 = 1;
+ pmap_TLB_update_kernel((vm_offset_t)sysm->CADDR1, sysm->CMAP1);
bzero(sysm->CADDR1, PAGE_SIZE);
pmap_TLB_invalidate_kernel((vm_offset_t)sysm->CADDR1);
sysm->CMAP1 = 0;
@@ -2446,7 +2446,7 @@ pmap_copy_page(vm_page_t src, vm_page_t dst)
va_src = MIPS_PHYS_TO_CACHED(phy_src);
sysm->CMAP2 = mips_paddr_to_tlbpfn(phy_dst) | PTE_RW | PTE_V | PTE_G | PTE_W | PTE_CACHE;
pmap_TLB_update_kernel((vm_offset_t)sysm->CADDR2, sysm->CMAP2);
- sysm->valid2 = 2;
+ sysm->valid2 = 1;
va_dst = (vm_offset_t)sysm->CADDR2;
} else if (phy_dst < MIPS_KSEG0_LARGEST_PHYS) {
/* one side needs mapping - src */
OpenPOWER on IntegriCloud