mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-06 00:56:21 +00:00
kernel: Implement gettimeofday + other misc fixes (#187)
* kernel: Add gettimeofday * kernel: Move sceKernelReleaseDirectMemory where it belongs * savedata: Stub sceSaveDataDialogUpdateStatus to return finished * memory: Add lock to VirtualQuery and remove debug print * clang format * fixed linux build? * special case for sceKernelWrite (stdin,stdout,stderr) * special case for case savedata mount * reduced mutex spamming * added missing default rwlock attributes init * kernel: Add more sleep functions * file_system: Add some functions * memory: Missed adding some functions * kernel: Moved some functions to time * kernel: Fix build error --------- Co-authored-by: georgemoralis <giorgosmrls@gmail.com>
This commit is contained in:
parent
7b1a317b09
commit
8ce58389ad
13 changed files with 189 additions and 107 deletions
|
@ -135,8 +135,6 @@ void MemoryManager::UnmapMemory(VAddr virtual_addr, size_t size) {
|
|||
"Attempting to unmap partially mapped range");
|
||||
|
||||
const auto type = it->second.type;
|
||||
fmt::print("{}\n", u32(type));
|
||||
std::fflush(stdout);
|
||||
const PAddr phys_addr = type == VMAType::Direct ? it->second.phys_base : -1;
|
||||
if (type == VMAType::Direct) {
|
||||
UnmapVulkanMemory(virtual_addr, size);
|
||||
|
@ -168,6 +166,8 @@ int MemoryManager::QueryProtection(VAddr addr, void** start, void** end, u32* pr
|
|||
|
||||
int MemoryManager::VirtualQuery(VAddr addr, int flags,
|
||||
Libraries::Kernel::OrbisVirtualQueryInfo* info) {
|
||||
std::scoped_lock lk{mutex};
|
||||
|
||||
auto it = FindVMA(addr);
|
||||
if (it->second.type == VMAType::Free && flags == 1) {
|
||||
it++;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue