summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/src/9/pc/mmu.c3
-rw-r--r--sys/src/9/pc64/mmu.c2
2 files changed, 1 insertions, 4 deletions
diff --git a/sys/src/9/pc/mmu.c b/sys/src/9/pc/mmu.c
index edcf866db..c0b13674a 100644
--- a/sys/src/9/pc/mmu.c
+++ b/sys/src/9/pc/mmu.c
@@ -524,8 +524,7 @@ mmuwalk(ulong* pdb, ulong va, int level, int create)
panic("mmuwalk2: va %luX entry %luX", va, *table);
if(!(*table & PTEVALID)){
map = rampage();
- if(map == nil)
- panic("mmuwalk: page alloc failed");
+ memset(map, 0, BY2PG);
*table = PADDR(map)|PTEWRITE|PTEVALID;
}
table = KADDR(PPN(*table));
diff --git a/sys/src/9/pc64/mmu.c b/sys/src/9/pc64/mmu.c
index 78725b3e4..f7c8bb7e5 100644
--- a/sys/src/9/pc64/mmu.c
+++ b/sys/src/9/pc64/mmu.c
@@ -299,8 +299,6 @@ ptesplit(uintptr* table, uintptr va)
if(pte == nil || (*pte & PTESIZE) == 0 || (va & PGLSZ(1)-1) == 0)
return;
table = rampage();
- if(table == nil)
- panic("ptesplit: out of memory\n");
va &= -PGLSZ(1);
pa = *pte & ~PTESIZE;
for(off = 0; off < PGLSZ(1); off += PGLSZ(0))