Fix locking resource logic for enqueue read/write buffer call

Change-Id: I261ed4904d617a2f4600ea2a5ec7fd34f534c191
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2019-04-09 13:16:36 +02:00
parent 5034c03f7c
commit 91a64c8518
4 changed files with 8 additions and 4 deletions

View File

@@ -416,6 +416,7 @@ HWTEST_F(EnqueueWriteBufferTypeTest, givenForcedCpuCopyWhenEnqueueWriteCompresse
nullptr);
EXPECT_EQ(CL_SUCCESS, retVal);
EXPECT_FALSE(buffer->getGraphicsAllocation()->isLocked());
EXPECT_FALSE(mockCmdQ->cpuDataTransferHandlerCalled);
buffer->getGraphicsAllocation()->setAllocationType(GraphicsAllocation::AllocationType::BUFFER);
@@ -430,6 +431,7 @@ HWTEST_F(EnqueueWriteBufferTypeTest, givenForcedCpuCopyWhenEnqueueWriteCompresse
nullptr);
EXPECT_EQ(CL_SUCCESS, retVal);
EXPECT_TRUE(buffer->getGraphicsAllocation()->isLocked());
EXPECT_TRUE(mockCmdQ->cpuDataTransferHandlerCalled);
}