kern: fix use of plr vs plr_heap, fix close/unlock order in ArbitrateLock

This commit is contained in:
Michael Scire 2021-10-19 01:19:31 -07:00
parent 52c914afcc
commit 42b6c2dd95
4 changed files with 21 additions and 15 deletions

View file

@ -21,7 +21,7 @@ namespace ams::kern {
constexpr inline s32 TerminatingThreadPriority = ams::svc::SystemThreadPriorityHighest - 1;
constexpr bool IsKernelAddressKey(KProcessAddress key) {
constexpr ALWAYS_INLINE bool IsKernelAddressKey(KProcessAddress key) {
const uintptr_t key_uptr = GetInteger(key);
return KernelVirtualAddressSpaceBase <= key_uptr && key_uptr <= KernelVirtualAddressSpaceLast && (key_uptr & 1) == 0;
}