mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-05 06:26:49 +00:00
vm: add extern clear_range_locks function
Allows to wait for range locks to clear for specified range. vm::range_lock now monitors specified reservation lock as well.
This commit is contained in:
parent
0da24f21d6
commit
3419d15878
4 changed files with 32 additions and 15 deletions
|
|
@ -226,11 +226,8 @@ namespace vm
|
|||
return result;
|
||||
}
|
||||
|
||||
static void _lock_shareable_cache(u8 value, u32 addr, u32 size)
|
||||
void clear_range_locks(u32 addr, u32 size)
|
||||
{
|
||||
// Block new range locks
|
||||
g_addr_lock = addr | u64{size} << 32;
|
||||
|
||||
ASSUME(size);
|
||||
|
||||
const auto range = utils::address_range::start_length(addr, size);
|
||||
|
|
@ -259,6 +256,14 @@ namespace vm
|
|||
}
|
||||
}
|
||||
|
||||
static void _lock_shareable_cache(u8 value, u32 addr, u32 size)
|
||||
{
|
||||
// Block new range locks
|
||||
g_addr_lock = addr | u64{size} << 32;
|
||||
|
||||
clear_range_locks(addr, size);
|
||||
}
|
||||
|
||||
void passive_lock(cpu_thread& cpu)
|
||||
{
|
||||
bool ok = true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue