Cleanup pmapdump* commands
This commit is contained in:
parent
4e7deee132
commit
a9acaf0489
@ -409,7 +409,7 @@ AddrFromIJKL(uint64_t i, uint64_t j, uint64_t k, uint64_t l)
|
||||
}
|
||||
|
||||
void
|
||||
PMap_Dump(AS *space)
|
||||
PMap_DumpFull(AS *space)
|
||||
{
|
||||
int i = 0;
|
||||
int j = 0;
|
||||
@ -465,15 +465,15 @@ PMap_Dump(AS *space)
|
||||
}
|
||||
|
||||
static void
|
||||
Debug_PMapDump(int argc, const char *argv[])
|
||||
Debug_PMapDumpFull(int argc, const char *argv[])
|
||||
{
|
||||
PMap_Dump(currentAS[THISCPU()]);
|
||||
PMap_DumpFull(currentAS[THISCPU()]);
|
||||
}
|
||||
|
||||
REGISTER_DBGCMD(pmapdump, "Dump memory mappings", Debug_PMapDump);
|
||||
REGISTER_DBGCMD(pmapdumpfull, "Dump memory mappings", Debug_PMapDumpFull);
|
||||
|
||||
void
|
||||
PMap_DumpConcise(AS *space)
|
||||
PMap_Dump(AS *space)
|
||||
{
|
||||
int i = 0;
|
||||
int j = 0;
|
||||
@ -481,6 +481,7 @@ PMap_DumpConcise(AS *space)
|
||||
int l = 0;
|
||||
PageTable *root = space->root;
|
||||
|
||||
kprintf("%-18s %-18s %-5s\n", "Virtual", "Physical PTE", "Flags");
|
||||
for (i = 0; i < PAGETABLE_ENTRIES/2; i++) {
|
||||
PageEntry pte = root->entries[i];
|
||||
PageTable *l1 = (PageTable *)DMPA2VA(pte & PGNUMMASK);
|
||||
@ -507,7 +508,7 @@ PMap_DumpConcise(AS *space)
|
||||
PageEntry pte4 = l3->entries[l];
|
||||
|
||||
if (pte4 & PTE_P)
|
||||
kprintf("%016llx: %016llx P%c%c%c%c%c\n",
|
||||
kprintf("0x%016llx: 0x%016llx P%c%c%c%c%c\n",
|
||||
AddrFromIJKL(i, j, k, l),
|
||||
(uint64_t)pte4,
|
||||
(pte4 & PTE_W) ? 'W' : ' ',
|
||||
@ -525,11 +526,11 @@ PMap_DumpConcise(AS *space)
|
||||
}
|
||||
|
||||
static void
|
||||
Debug_PMapDumpConcise(int argc, const char *argv[])
|
||||
Debug_PMapDump(int argc, const char *argv[])
|
||||
{
|
||||
PMap_DumpConcise(currentAS[THISCPU()]);
|
||||
PMap_Dump(currentAS[THISCPU()]);
|
||||
}
|
||||
|
||||
REGISTER_DBGCMD(pmapdumpconcise, "Dump concise memory mappings", Debug_PMapDumpConcise);
|
||||
REGISTER_DBGCMD(pmapdump, "Dump memory mappings", Debug_PMapDump);
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user