mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-12-23 12:01:52 +01:00
Prevent truncation of big page start in GetVaRegions
This commit is contained in:
parent
f650f32bf0
commit
cd0b2636e5
@ -243,6 +243,7 @@ namespace skyline::service::nvdrv::device::nvhost {
|
||||
if (!vm.initialised)
|
||||
return PosixResult::InvalidArgument;
|
||||
|
||||
bufSize = 2 * sizeof(VaRegion);
|
||||
vaRegions = std::array<VaRegion, 2> {
|
||||
VaRegion{
|
||||
.pageSize = VM::PageSize,
|
||||
@ -252,7 +253,7 @@ namespace skyline::service::nvdrv::device::nvhost {
|
||||
VaRegion{
|
||||
.pageSize = vm.bigPageSize,
|
||||
.pages = vm.bigPageAllocator->vaLimit - vm.bigPageAllocator->vaStart,
|
||||
.offset = vm.bigPageAllocator->vaStart << vm.bigPageSizeBits,
|
||||
.offset = static_cast<u64>(vm.bigPageAllocator->vaStart) << vm.bigPageSizeBits,
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user