mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-21 10:25:08 -04:00
stratosphere: use SdkMutex/SdkRecursiveMutex over Mutex
This commit is contained in:
parent
a4fe1bb5d8
commit
41ab4c2c68
70 changed files with 188 additions and 645 deletions
|
@ -21,15 +21,12 @@ namespace ams::lmem {
|
|||
HeapHandle CreateExpHeap(void *address, size_t size, u32 option) {
|
||||
HeapHandle handle = impl::CreateExpHeap(address, size, option);
|
||||
if (option & CreateOption_ThreadSafe) {
|
||||
os::InitializeMutex(std::addressof(handle->mutex), false, 0);
|
||||
os::InitializeSdkMutex(std::addressof(handle->mutex));
|
||||
}
|
||||
return handle;
|
||||
}
|
||||
|
||||
void DestroyExpHeap(HeapHandle handle) {
|
||||
if (handle->option & CreateOption_ThreadSafe) {
|
||||
os::FinalizeMutex(std::addressof(handle->mutex));
|
||||
}
|
||||
impl::DestroyExpHeap(handle);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue