summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSubv <subv2112@gmail.com>2017-08-07 20:37:16 +0200
committerSubv <subv2112@gmail.com>2017-09-15 21:26:18 +0200
commitf18a176b601c8dc15b372607a4e9f289bdc25ee4 (patch)
tree009f039d4ad8fb1fe98c0ac0686e930aa1f7cac7
parentKernel/Threads: Don't clear the CPU instruction cache when performing a context switch from an idle thread into a thread in the same process. (diff)
downloadyuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.tar
yuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.tar.gz
yuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.tar.bz2
yuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.tar.lz
yuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.tar.xz
yuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.tar.zst
yuzu-f18a176b601c8dc15b372607a4e9f289bdc25ee4.zip
-rw-r--r--src/core/memory.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/memory.cpp b/src/core/memory.cpp
index 4dcbf2274..4d16736f5 100644
--- a/src/core/memory.cpp
+++ b/src/core/memory.cpp
@@ -208,8 +208,7 @@ bool IsValidVirtualAddress(const VAddr vaddr) {
}
bool IsValidPhysicalAddress(const PAddr paddr) {
- boost::optional<VAddr> vaddr = PhysicalToVirtualAddress(paddr);
- return vaddr && IsValidVirtualAddress(*vaddr);
+ return GetPhysicalPointer(paddr) != nullptr;
}
u8* GetPointer(const VAddr vaddr) {