mirror of
https://github.com/skyline-emu/skyline.git
synced 2025-01-17 04:47:55 +03:00
Handle unmapped blocks in CachedMappedBufferView
This commit is contained in:
parent
5c0e4a839d
commit
33f16ca26e
@ -12,6 +12,12 @@ namespace skyline::gpu::interconnect::maxwell3d {
|
|||||||
if (address < blockMappingStartAddr || address >= blockMappingEndAddr) {
|
if (address < blockMappingStartAddr || address >= blockMappingEndAddr) {
|
||||||
u64 blockOffset{};
|
u64 blockOffset{};
|
||||||
std::tie(blockMapping, blockOffset) = ctx.channelCtx.asCtx->gmmu.LookupBlock(address);
|
std::tie(blockMapping, blockOffset) = ctx.channelCtx.asCtx->gmmu.LookupBlock(address);
|
||||||
|
if (!blockMapping.valid()) {
|
||||||
|
view = {};
|
||||||
|
blockMappingEndAddr = 0;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
blockMappingStartAddr = address - blockOffset;
|
blockMappingStartAddr = address - blockOffset;
|
||||||
blockMappingEndAddr = blockMappingStartAddr + blockMapping.size();
|
blockMappingEndAddr = blockMappingStartAddr + blockMapping.size();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user