Add debugging message on memory

Add pr_debug to all memory APIs and pr_err to some failure cases.

Change-Id: I8b519a1228cc19e6c04118fd87432e7f48f3cbf9
Signed-off-by: Amber Lin <Amber.Lin@amd.com>
此提交包含在:
Amber Lin
2017-08-17 15:38:06 -04:00
父節點 00250f7686
當前提交 73707766ef
共有 2 個檔案被更改,包括 60 行新增9 行删除
+1 -3
查看文件
@@ -2283,7 +2283,7 @@ static HSAKMT_STATUS dgpu_mem_init(uint32_t gpu_mem_id, void **base, void **limi
munmap(ret_addr, len);
}
if (!ret_addr) {
pr_err("Failed to reserve %uGB for SVM ...\n",
pr_warn("Failed to reserve %uGB for SVM ...\n",
(unsigned int)(len >> 30));
continue;
}
@@ -2871,7 +2871,6 @@ HSAKMT_STATUS fmm_map_to_gpu_nodes(void *address, uint64_t size,
if (!num_of_nodes || !nodes_to_map || !address)
return HSAKMT_STATUS_INVALID_PARAMETER;
/* Find object by address */
if ((address >= svm.dgpu_aperture.base) &&
(address <= svm.dgpu_aperture.limit))
@@ -2882,7 +2881,6 @@ HSAKMT_STATUS fmm_map_to_gpu_nodes(void *address, uint64_t size,
else {
aperture = &svm.dgpu_aperture;
userptr = true;
}
pthread_mutex_lock(&aperture->fmm_mutex);