From 28a9e4c1d55c66e99b5cf16fda00dcb75ab27fde Mon Sep 17 00:00:00 2001 From: Yuri Kunde Schlesner Date: Sat, 9 May 2015 03:08:11 -0300 Subject: Memory: Support more regions in the VAddr-PAddr translation functions Also adds better documentation and removes the one-off reimplementation of the function in pica.h. --- src/video_core/pica.h | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'src/video_core/pica.h') diff --git a/src/video_core/pica.h b/src/video_core/pica.h index 4c48b6bf..e4a91058 100644 --- a/src/video_core/pica.h +++ b/src/video_core/pica.h @@ -998,15 +998,4 @@ union CommandHeader { BitField<31, 1, u32> group_commands; }; -// TODO: Ugly, should fix PhysicalToVirtualAddress instead -inline static u32 PAddrToVAddr(u32 addr) { - if (addr >= Memory::VRAM_PADDR && addr < Memory::VRAM_PADDR + Memory::VRAM_SIZE) { - return addr - Memory::VRAM_PADDR + Memory::VRAM_VADDR; - } else if (addr >= Memory::FCRAM_PADDR && addr < Memory::FCRAM_PADDR + Memory::FCRAM_SIZE) { - return addr - Memory::FCRAM_PADDR + Memory::LINEAR_HEAP_VADDR; - } else { - return 0; - } -} - } // namespace -- cgit v1.2.3