@@ -2122,18 +2122,16 @@ TEST_F(DrmMemoryManagerTest, givenSharedAllocationWithSmallerThenRealSizeWhenCre
21222122}
21232123
21242124TEST_F (DrmMemoryManagerTest, givenMemoryManagerSupportingVirutalPaddingWhenItIsRequiredThenNewGraphicsAllocationIsCreated) {
2125- mock->ioctl_expected .gemUserptr = 3 ;
2126- mock->ioctl_expected .gemWait = 3 ;
2127- mock->ioctl_expected .gemClose = 3 ;
2125+ mock->ioctl_expected .gemUserptr = 2 ;
2126+ mock->ioctl_expected .gemWait = 2 ;
2127+ mock->ioctl_expected .gemClose = 2 ;
21282128 // first let's create normal buffer
21292129 auto bufferSize = MemoryConstants::pageSize;
21302130 auto buffer = memoryManager->allocateGraphicsMemoryWithProperties (MockAllocationProperties{bufferSize});
21312131
21322132 // buffer should have size 16
21332133 EXPECT_EQ (bufferSize, buffer->getUnderlyingBufferSize ());
21342134
2135- EXPECT_EQ (nullptr , memoryManager->peekPaddingAllocation ());
2136-
21372135 auto bufferWithPaddingSize = 8192u ;
21382136 auto paddedAllocation = memoryManager->createGraphicsAllocationWithPadding (buffer, 8192u );
21392137 EXPECT_NE (nullptr , paddedAllocation);
@@ -2277,10 +2275,10 @@ TEST_F(DrmMemoryManagerTest, givenMemoryManagerWhenAskedForInternalAllocationWit
22772275}
22782276
22792277TEST_F (DrmMemoryManagerTest, givenMemoryManagerSupportingVirutalPaddingWhenAllocUserptrFailsThenReturnsNullptr) {
2280- mock->ioctl_expected .gemUserptr = 3 ;
2281- mock->ioctl_expected .gemWait = 2 ;
2282- mock->ioctl_expected .gemClose = 2 ;
2283- this ->ioctlResExt = {mock->ioctl_cnt .total + 2 , -1 };
2278+ mock->ioctl_expected .gemUserptr = 2 ;
2279+ mock->ioctl_expected .gemWait = 1 ;
2280+ mock->ioctl_expected .gemClose = 1 ;
2281+ this ->ioctlResExt = {mock->ioctl_cnt .total + 1 , -1 };
22842282 mock->ioctl_res_ext = &ioctlResExt;
22852283
22862284 // first let's create normal buffer
@@ -2290,8 +2288,6 @@ TEST_F(DrmMemoryManagerTest, givenMemoryManagerSupportingVirutalPaddingWhenAlloc
22902288 // buffer should have size 16
22912289 EXPECT_EQ (bufferSize, buffer->getUnderlyingBufferSize ());
22922290
2293- EXPECT_EQ (nullptr , memoryManager->peekPaddingAllocation ());
2294-
22952291 auto bufferWithPaddingSize = 8192u ;
22962292 auto paddedAllocation = memoryManager->createGraphicsAllocationWithPadding (buffer, bufferWithPaddingSize);
22972293 EXPECT_EQ (nullptr , paddedAllocation);
0 commit comments