diff --git a/projects/rocr-runtime/include/hsakmttypes.h b/projects/rocr-runtime/include/hsakmttypes.h index ad5b565361..57f4a855de 100644 --- a/projects/rocr-runtime/include/hsakmttypes.h +++ b/projects/rocr-runtime/include/hsakmttypes.h @@ -1303,8 +1303,9 @@ typedef enum _HSA_POINTER_TYPE { HSA_POINTER_ALLOCATED = 1, // Allocated with hsaKmtAllocMemory (except scratch) HSA_POINTER_REGISTERED_USER = 2, // Registered user pointer HSA_POINTER_REGISTERED_GRAPHICS = 3, // Registered graphics buffer - HSA_POINTER_REGISTERED_SHARED = 4 // Registered shared buffer (IPC) + HSA_POINTER_REGISTERED_SHARED = 4, // Registered shared buffer (IPC) // (hsaKmtRegisterGraphicsToNodes) + HSA_POINTER_RESERVED_ADDR = 5 // address-only reservation VA } HSA_POINTER_TYPE; typedef struct _HsaPointerInfo { diff --git a/projects/rocr-runtime/src/events.c b/projects/rocr-runtime/src/events.c index 1c5b03dcf2..512abc2be0 100644 --- a/projects/rocr-runtime/src/events.c +++ b/projects/rocr-runtime/src/events.c @@ -339,6 +339,9 @@ static void analysis_memory_exception(struct kfd_hsa_memory_exception_data * pr_err("Memory is allocated using hsaKmtAllocMemory\n"); pr_err("CPU address of the memory is %p\n", info.CPUAddress); break; + case HSA_POINTER_RESERVED_ADDR: + pr_err("Memory is allocated by OnlyAddress mode\n"); + break; default: pr_err("Invalid memory type %d\n", info.Type); break; diff --git a/projects/rocr-runtime/src/fmm.c b/projects/rocr-runtime/src/fmm.c index 59639a2cc0..4e8293fbcf 100644 --- a/projects/rocr-runtime/src/fmm.c +++ b/projects/rocr-runtime/src/fmm.c @@ -3963,6 +3963,8 @@ HSAKMT_STATUS fmm_get_mem_info(const void *address, HsaPointerInfo *info) info->Type = HSA_POINTER_REGISTERED_GRAPHICS; else if (vm_obj->userptr) info->Type = HSA_POINTER_REGISTERED_USER; + else if (vm_obj->handle == 0) + info->Type = HSA_POINTER_RESERVED_ADDR; else info->Type = HSA_POINTER_ALLOCATED;