[Kernel] Add memory mirroring function & throw warning on mprotect

This commit is contained in:
wheremyfoodat 2023-03-21 02:32:47 +02:00
parent 9b9f011f5b
commit 5d6bf24a9d
4 changed files with 35 additions and 0 deletions

View file

@ -79,6 +79,14 @@ void Kernel::controlMemory() {
break;
}
case Operation::Map:
mem.mirrorMapping(addr0, addr1, size);
break;
case Operation::Protect:
Helpers::warn("Ignoring mprotect! Hope nothing goes wrong but if the game accesses invalid memory or crashes then we prolly need to implement this\n");
break;
default: Helpers::panic("ControlMemory: unknown operation %X\n", operation);
}