X86: Explain what really didn't work with unmapped addresses in SE mode.
This commit is contained in:
parent
53086dfefe
commit
44e912c6bd
1 changed files with 13 additions and 3 deletions
|
@ -632,12 +632,22 @@ TLB::translate(RequestPtr req, ThreadContext *tc, Translation *translation,
|
||||||
Process *p = tc->getProcessPtr();
|
Process *p = tc->getProcessPtr();
|
||||||
TlbEntry newEntry;
|
TlbEntry newEntry;
|
||||||
bool success = p->pTable->lookup(vaddr, newEntry);
|
bool success = p->pTable->lookup(vaddr, newEntry);
|
||||||
if(!success && mode != Execute) {
|
if (!success && mode != Execute) {
|
||||||
p->checkAndAllocNextPage(vaddr);
|
p->checkAndAllocNextPage(vaddr);
|
||||||
success = p->pTable->lookup(vaddr, newEntry);
|
success = p->pTable->lookup(vaddr, newEntry);
|
||||||
}
|
}
|
||||||
if(!success) {
|
if (!success) {
|
||||||
panic("Tried to execute unmapped address %#x.\n", vaddr);
|
const char *modeStr = "";
|
||||||
|
if (mode == Execute)
|
||||||
|
modeStr = "execute";
|
||||||
|
else if (mode == Read)
|
||||||
|
modeStr = "read";
|
||||||
|
else if (mode == Write)
|
||||||
|
modeStr = "write";
|
||||||
|
else
|
||||||
|
modeStr = "?";
|
||||||
|
panic("Tried to %s unmapped address %#x.\n",
|
||||||
|
modeStr, vaddr);
|
||||||
} else {
|
} else {
|
||||||
Addr alignedVaddr = p->pTable->pageAlign(vaddr);
|
Addr alignedVaddr = p->pTable->pageAlign(vaddr);
|
||||||
DPRINTF(TLB, "Mapping %#x to %#x\n", alignedVaddr,
|
DPRINTF(TLB, "Mapping %#x to %#x\n", alignedVaddr,
|
||||||
|
|
Loading…
Reference in a new issue