mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-21 09:14:47 +08:00
Add PhysicalAddressAllocator to PageTables
- Allocator is responsible for physical pages allocation Change-Id: I3a9034c87292484da8f4f0eb1d1e0cc5122a4d8a
This commit is contained in:
committed by
sys_ocldev
parent
8df30ceac1
commit
610eda5ad1
@@ -333,3 +333,14 @@ HWTEST_F(TbxCommandSteamSimpleTest, givenTbxCsrWhenWaitBeforeMakeNonResidentWhen
|
||||
EXPECT_TRUE(tbxCsr.makeCoherentCalled);
|
||||
EXPECT_EQ(6u, tag);
|
||||
}
|
||||
|
||||
HWTEST_F(TbxCommandSteamSimpleTest, whenTbxCommandStreamReceiverIsCreatedThenPPGTTAndGGTTCreatedHavePhysicalAddressAllocatorSet) {
|
||||
MockTbxCsr<FamilyType> tbxCsr(*platformDevices[0], *pDevice->executionEnvironment);
|
||||
|
||||
uintptr_t address = 0x20000;
|
||||
auto physicalAddress = tbxCsr.ppgtt->map(address, MemoryConstants::pageSize, PageTableHelper::memoryBankNotSpecified);
|
||||
EXPECT_NE(0u, physicalAddress);
|
||||
|
||||
physicalAddress = tbxCsr.ggtt->map(address, MemoryConstants::pageSize, PageTableHelper::memoryBankNotSpecified);
|
||||
EXPECT_NE(0u, physicalAddress);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user