pc: zero rampage() memory (thanks LordCreepity)
memory returned by rampage() is not zeroed, so we have to zero it ourselfs. apparently, this bug didnt show up as we where zeroing conventional low memory before the new memory map code. also rampage() never returns nil.
This commit is contained in:
parent
0ba0820070
commit
a35cd0f861
|
@ -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));
|
||||
|
|
Loading…
Reference in a new issue