memory: Add more debug messages for CoW related functions

This commit is contained in:
EnderIce2 2024-11-18 04:07:08 +02:00
parent 9f34bd0192
commit 3a68b28c13
Signed by untrusted user who does not match committer: enderice2
GPG Key ID: EACC3AD603BAB4DD
2 changed files with 3 additions and 0 deletions

View File

@ -168,7 +168,9 @@ namespace Memory
return (void *)-EPERM; return (void *)-EPERM;
} }
debug("unmapping %#lx-%#lx", Address, (uintptr_t)Address + Length);
vmm.Unmap(Address, Length); vmm.Unmap(Address, Length);
debug("mapping cow at %#lx-%#lx", Address, (uintptr_t)Address + Length);
vmm.Map(Address, nullptr, Length, PTFlag::CoW); vmm.Map(Address, nullptr, Length, PTFlag::CoW);
debug("CoW region created at range %#lx-%#lx for pt %#lx", debug("CoW region created at range %#lx-%#lx for pt %#lx",
Address, (uintptr_t)Address + Length, this->Table); Address, (uintptr_t)Address + Length, this->Table);

View File

@ -1023,6 +1023,7 @@ static void *linux_mmap(SysFrm *, void *addr, size_t length, int prot,
void *ret = vma->CreateCoWRegion(addr, length, void *ret = vma->CreateCoWRegion(addr, length,
p_Read, p_Write, p_Exec, p_Read, p_Write, p_Exec,
m_Fixed, m_Shared); m_Fixed, m_Shared);
debug("ret: %#lx", ret);
return (void *)ret; return (void *)ret;
} }
#undef __FENNIX_KERNEL_SYSCALLS_LIST_H__ #undef __FENNIX_KERNEL_SYSCALLS_LIST_H__