From a815a4337f89769a6bf5d43cf26caf16b2ae4f50 Mon Sep 17 00:00:00 2001 From: Yair Shachar Date: Sun, 7 Feb 2016 17:56:40 +0200 Subject: [PATCH] Disable scratch Host allocation - via debug registration flags. Change-Id: Ia6e5f86ec3979c4a49800f7af4509442a4e5be27 Signed-off-by: Yair Shachar --- src/debug.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/debug.c b/src/debug.c index ff7ec7fb33..327fbbcacb 100644 --- a/src/debug.c +++ b/src/debug.c @@ -73,10 +73,9 @@ hsaKmtDbgRegister( args.gpu_id = gpu_id; long err = kmtIoctl(kfd_fd, AMDKFD_IOC_DBG_REGISTER, &args); - if (err == 0) { - is_device_debugged[NodeId] = true; + if (err == 0) result = HSAKMT_STATUS_SUCCESS; - } else + else result = HSAKMT_STATUS_ERROR; return (result); @@ -105,10 +104,9 @@ hsaKmtDbgUnregister( memset(&args, 0, sizeof(args)); args.gpu_id = gpu_id; long err = kmtIoctl(kfd_fd, AMDKFD_IOC_DBG_UNREGISTER, &args); - if (err == 0) { - is_device_debugged[NodeId] = false; + if (err == 0) result = HSAKMT_STATUS_SUCCESS; - } else + else result = HSAKMT_STATUS_ERROR; return (result);