Skip to content

Commit

Permalink
Core: Remove ROM_IN_MAPSPACE
Browse files Browse the repository at this point in the history
  • Loading branch information
project64 committed Jan 4, 2022
1 parent beb4c43 commit 226ebe6
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 23 deletions.
10 changes: 0 additions & 10 deletions Source/Project64-core/N64System/Mips/Dma.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -352,16 +352,6 @@ void CDMA::PI_DMA_WRITE()
{
uint32_t i;

#ifdef legacycode
#ifdef ROM_IN_MAPSPACE
if (WrittenToRom)
{
uint32_t OldProtect;
VirtualProtect(ROM,m_RomFileSize,PAGE_READONLY, &OldProtect);
}
#endif
#endif

uint8_t * ROM = g_Rom->GetRomAddress();
uint8_t * RDRAM = g_MMU->Rdram();
PI_CART_ADDR_REG -= 0x10000000;
Expand Down
13 changes: 0 additions & 13 deletions Source/Project64-core/N64System/Mips/MemoryVirtualMem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -765,13 +765,6 @@ bool CMipsMemoryVM::SW_NonMemory(uint32_t PAddr, uint32_t Value)
{
m_RomWrittenTo = true;
m_RomWroteValue = Value;
#ifdef ROM_IN_MAPSPACE
{
uint32_t OldProtect;
VirtualProtect(ROM, RomFileSize, PAGE_NOACCESS, &OldProtect);
}
#endif
//LogMessage("%X: Wrote To ROM %08X from %08X",PROGRAM_COUNTER,Value,PAddr);
}
else
{
Expand Down Expand Up @@ -1468,12 +1461,6 @@ void CMipsMemoryVM::Load32Rom(void)
m_MemLookupValue.UW[0] = g_MMU->m_RomWroteValue;
//LogMessage("%X: Read crap from ROM %08X from %08X",PROGRAM_COUNTER,*Value,PAddr);
g_MMU->m_RomWrittenTo = false;
#ifdef ROM_IN_MAPSPACE
{
uint32_t OldProtect;
VirtualProtect(ROM, RomFileSize, PAGE_READONLY, &OldProtect);
}
#endif
}
else if ((m_MemLookupAddress & 0xFFFFFFF) < g_MMU->m_RomSize)
{
Expand Down

0 comments on commit 226ebe6

Please sign in to comment.