[Memory] Refactor GetPhysicalAddress and use it for XMA, resolve #1448

This commit is contained in:
Triang3l
2019-08-24 17:40:59 +03:00
parent 3e6c2bb47c
commit 7e6bf8022f
6 changed files with 72 additions and 40 deletions

View File

@@ -113,9 +113,7 @@ X_STATUS XmaDecoder::Setup(kernel::KernelState* kernel_state) {
context_data_last_ptr_ =
context_data_first_ptr_ + (sizeof(XMA_CONTEXT_DATA) * kContextCount - 1);
register_file_[XE_XMA_REG_CONTEXT_ARRAY_ADDRESS].u32 =
memory()
->LookupHeap(context_data_first_ptr_)
->GetPhysicalAddress(context_data_first_ptr_);
memory()->GetPhysicalAddress(context_data_first_ptr_);
// Setup XMA contexts.
for (int i = 0; i < kContextCount; ++i) {