cellgcm/sys_rsx: fix multiple io maps at the same effective address and vice verse

from hw testing, as long as the io address is valid, it returns CELL_OK, even when it doesn't make much sense
This commit is contained in:
eladash 2018-05-22 21:05:07 +03:00 committed by kd-11
parent 97515a0941
commit c2b2dee56d

View file

@ -51,17 +51,6 @@ bool VirtualMemoryBlock::Map(u32 realaddr, u32 size, u32 addr)
return false;
}
for (u32 i = 0; i<m_mapped_memory.size(); ++i)
{
if (addr >= m_mapped_memory[i].addr && addr + size - 1 <= m_mapped_memory[i].addr + m_mapped_memory[i].size - 1)
{
// it seems mapping another range inside a previous one is legit on ps3
// as long as it's coherent aliasing : offset from EA must match IO offset
// example game using this pattern : BCES01584 - the last of us
return (addr - m_mapped_memory[i].addr) == (realaddr - m_mapped_memory[i].realAddress);
}
}
m_mapped_memory.emplace_back(addr, realaddr, size);
return true;
}