DRM Graphic allocation assigns original hostPtr as cpuPtr

Change-Id: I9ba282b130b5fb9b674e1ceb2f87183f218ab140
Signed-off-by: Dongwon Kim <dongwon.kim@intel.com>
This commit is contained in:
Dongwon Kim
2019-08-14 16:23:57 -07:00
committed by sys_ocldev
parent 04c45967b9
commit 25d9e4533d
5 changed files with 6 additions and 7 deletions

View File

@@ -2633,7 +2633,7 @@ TEST_F(DrmMemoryManagerBasic, givenDrmMemoryManagerWhenAllocateGraphicsMemoryFor
auto allocation = memoryManager->allocateGraphicsMemoryForNonSvmHostPtr(allocationData);
EXPECT_NE(nullptr, allocation);
EXPECT_EQ(0x5001u, reinterpret_cast<uint64_t>(allocation->getUnderlyingBuffer()) + allocation->getAllocationOffset());
EXPECT_EQ(0x5001u, reinterpret_cast<uint64_t>(allocation->getUnderlyingBuffer()));
EXPECT_EQ(13u, allocation->getUnderlyingBufferSize());
EXPECT_EQ(1u, allocation->getAllocationOffset());
@@ -2908,7 +2908,7 @@ TEST_F(DrmMemoryManagerBasic, givenDisabledHostPtrTrackingWhenAllocateGraphicsMe
auto allocation = memoryManager->allocateGraphicsMemoryForNonSvmHostPtr(allocationData);
EXPECT_NE(nullptr, allocation);
EXPECT_EQ(0x5001u, reinterpret_cast<uint64_t>(allocation->getUnderlyingBuffer()) + allocation->getAllocationOffset());
EXPECT_EQ(0x5001u, reinterpret_cast<uint64_t>(allocation->getUnderlyingBuffer()));
EXPECT_EQ(13u, allocation->getUnderlyingBufferSize());
EXPECT_EQ(1u, allocation->getAllocationOffset());