mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
Return a unique pointer for multiple calls to openIpcHandle
This to follow specification, which says: zeMemOpenIpcHandle: - Multiple calls to this function with the same IPC handle will return unique pointers. Signed-off-by: Jaime Arteaga <jaime.a.arteaga.molina@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
af82557e55
commit
99655d34f9
@@ -80,7 +80,7 @@ ze_result_t ImageCoreFamily<gfxCoreFamily>::initialize(Device *device, const ze_
|
||||
}
|
||||
if (lookupTable.sharedHandleType.isDMABUFHandle) {
|
||||
NEO::AllocationProperties properties(device->getRootDeviceIndex(), true, imgInfo, NEO::AllocationType::SHARED_IMAGE, device->getNEODevice()->getDeviceBitfield());
|
||||
allocation = device->getNEODevice()->getMemoryManager()->createGraphicsAllocationFromSharedHandle(lookupTable.sharedHandleType.fd, properties, false, false);
|
||||
allocation = device->getNEODevice()->getMemoryManager()->createGraphicsAllocationFromSharedHandle(lookupTable.sharedHandleType.fd, properties, false, false, true);
|
||||
device->getNEODevice()->getMemoryManager()->closeSharedHandle(allocation);
|
||||
} else if (lookupTable.sharedHandleType.isNTHandle) {
|
||||
auto verifyResult = device->getNEODevice()->getMemoryManager()->verifyHandle(NEO::toOsHandle(lookupTable.sharedHandleType.ntHnadle), device->getNEODevice()->getRootDeviceIndex(), true);
|
||||
|
||||
Reference in New Issue
Block a user