diff --git a/kaleid/kernel/mm/paging.c b/kaleid/kernel/mm/paging.c index c8f581a..af127e2 100644 --- a/kaleid/kernel/mm/paging.c +++ b/kaleid/kernel/mm/paging.c @@ -166,7 +166,7 @@ void MmInitPaging(void) MmPT[index] = 0; } - KeFlushTlbSingle(curAddrPT); + //KeFlushTlbSingle(curAddrPT); } } } diff --git a/kaleid/kernel/sh/testcmds.c b/kaleid/kernel/sh/testcmds.c index 9fb9b11..00a68a3 100644 --- a/kaleid/kernel/sh/testcmds.c +++ b/kaleid/kernel/sh/testcmds.c @@ -112,7 +112,7 @@ error_t CmdDumpATASect(int argc, char **argv, char *cmdline) error_t CmdDumpMem(int argc, char **argv, char *cmdline) { char sector[1024] = {0}; - char *address = (char*)atol(argv[1]); + char *address = (char*)strtoul(argv[1], NULL, 16); int nb = 1; //atoi(argv[2]); int x = 0; int step = 16; @@ -193,7 +193,7 @@ error_t CmdPageTranslateVirtToPhy(int argc, char **argv, char *cmdline) { void *address = (void*)atoul(argv[1]); - if (!(void*)atoul(argv[1])) { + if (!(void*)strtoul(argv[1], NULL, 16)) { KernLog("No argument : translating the userspace address\n"); address = (void *)0x80000000; } @@ -219,8 +219,8 @@ enum error_t CmdPageMap(int argc, char **argv, char *cmdline) { - void *virtual = (void*)atoul(argv[1]); - void *physical = (void*)atoul(argv[2]); + void *virtual = (void*)strtoul(argv[1], NULL, 16); + void *physical = (void*)strtoul(argv[2], NULL, 16); MmMapPage(virtual, physical, PRESENT | READWRITE); @@ -229,7 +229,7 @@ error_t CmdPageMap(int argc, char **argv, char *cmdline) error_t CmdPageUnmap(int argc, char **argv, char *cmdline) { - void *virtual = (void*)atoul(argv[1]); + void *virtual = (void*)strtoul(argv[1], NULL, 16); MmUnmapPage(virtual); @@ -238,7 +238,7 @@ error_t CmdPageUnmap(int argc, char **argv, char *cmdline) error_t CmdPageTranslatePhyToVirt(int argc, char **argv, char *cmdline) { - void *address = (void*)atoul(argv[1]); + void *address = (void*)strtoul(argv[1], NULL, 16); /* if (!(void*)atoul(argv[1])) { */ /* address = (ulong *)0x80000000; */ @@ -252,7 +252,7 @@ error_t CmdPageTranslatePhyToVirt(int argc, char **argv, char *cmdline) error_t CmdPF(int argc, char **argv, char *cmdline) { - ulong *address = (ulong*)(ulong)atoul(argv[1]); + ulong *address = (ulong*)(ulong)strtoul(argv[1], NULL, 16); KernLog("Provoking Page Fault at %#x\n", address);