SWDEV-281062 - hipIpcOpenMemHandle should return the base ptr

hipIpcOpenMemHandle should return the device pointer which is
similar to the base ptr of the original allocation even if the offset
to the original pointer is passed to hipIpcGetMemHandle

Change-Id: I99c0553e8c67c15b5fed880b6a4c74bce39c3aee


[ROCm/clr commit: 88fca7bf9e]
이 커밋은 다음에 포함됨:
Satyanvesh Dittakavi가 2021-04-22 02:59:05 -04:00를 커밋했습니다
1 부모 0d43d02b1e
커밋 f97bc7f6f2
1 파일이 변경됨
+2 -2
+2 -2
파일 보기
@@ -2126,8 +2126,8 @@ bool Device::IpcAttach(const void* handle, size_t mem_size, size_t mem_offset,
//Make sure the mem_offset doesnt overflow the allocated memory
guarantee((mem_offset < mem_size) && "IPC mem offset greater than allocated size");
// Return offsetted device pointer and maintain offsetted_ptr to orig_dev_ptr in map
*dev_ptr = reinterpret_cast<address>(orig_dev_ptr) + mem_offset;
// Return orig_dev_ptr
*dev_ptr = reinterpret_cast<address>(orig_dev_ptr);
return true;
}