mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
fix: Add bind info for allocation from ipc handle in xe
Related-To: NEO-7996 Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
d4f80fb957
commit
1ab0467301
@@ -1601,3 +1601,15 @@ TEST(IoctlHelperXeTest, whenXeShowBindTableIsCalledThenBindLogsArePrinted) {
|
||||
)";
|
||||
EXPECT_STREQ(expectedOutput.c_str(), output.c_str());
|
||||
}
|
||||
|
||||
TEST(IoctlHelperXeTest, whenFillBindInfoForIpcHandleIsCalledThenBindInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
DrmMock drm{*executionEnvironment->rootDeviceEnvironments[0]};
|
||||
auto xeIoctlHelper = std::make_unique<MockIoctlHelperXe>(drm);
|
||||
uint32_t handle = 100;
|
||||
size_t size = 1024u;
|
||||
xeIoctlHelper->fillBindInfoForIpcHandle(handle, size);
|
||||
auto bindInfo = xeIoctlHelper->bindInfo[0];
|
||||
EXPECT_EQ(bindInfo.handle, handle);
|
||||
EXPECT_EQ(bindInfo.size, size);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user