Stub svcUnmapMemoryBlock

This commit is contained in:
wheremyfoodat 2024-01-24 19:04:55 +02:00
parent c108da5e02
commit 85a2ca1bf4
3 changed files with 11 additions and 0 deletions

View file

@ -137,6 +137,7 @@ public:
void duplicateHandle();
void exitThread();
void mapMemoryBlock();
void unmapMemoryBlock();
void queryMemory();
void getCurrentProcessorNumber();
void getProcessID();

View file

@ -50,6 +50,7 @@ void Kernel::serviceSVC(u32 svc) {
case 0x1D: svcClearTimer(); break;
case 0x1E: createMemoryBlock(); break;
case 0x1F: mapMemoryBlock(); break;
case 0x20: unmapMemoryBlock(); break;
case 0x21: createAddressArbiter(); break;
case 0x22: arbitrateAddress(); break;
case 0x23: svcCloseHandle(); break;

View file

@ -207,3 +207,12 @@ void Kernel::createMemoryBlock() {
regs[0] = Result::Success;
regs[1] = makeMemoryBlock(addr, size, myPermission, otherPermission);
}
void Kernel::unmapMemoryBlock() {
Handle block = regs[0];
u32 addr = regs[1];
logSVC("Unmap memory block (block handle = %X, addr = %08X)\n", block, addr);
Helpers::warn("Stubbed svcUnmapMemoryBlock!");
regs[0] = Result::Success;
}