Correct IPC fragment validation.
IPC create must only be used on whole ROCr allocations. Fragments were allowing handle creation with offsets. Change-Id: I1faa96d36bc7a6199bdc2e3ff1b8871d1a36a2fa
Este cometimento está contido em:
@@ -889,6 +889,8 @@ hsa_status_t Runtime::IPCCreate(void* ptr, size_t len, hsa_amd_ipc_memory_t* han
|
||||
info.size = sizeof(info);
|
||||
if (PtrInfo(ptr, &info, nullptr, nullptr, nullptr, &block) != HSA_STATUS_SUCCESS)
|
||||
return HSA_STATUS_ERROR_INVALID_ARGUMENT;
|
||||
if ((info.agentBaseAddress != ptr) || (info.sizeInBytes != len))
|
||||
return HSA_STATUS_ERROR_INVALID_ARGUMENT;
|
||||
if ((block.base != ptr) || (block.length != len)) {
|
||||
if (!IsMultipleOf(block.base, 2 * 1024 * 1024)) {
|
||||
assert(false && "Fragment's block not aligned to 2MB!");
|
||||
|
||||
Criar uma nova questão referindo esta
Bloquear um utilizador