From 6497fa0339d02d32934933ed7612f5f039772d18 Mon Sep 17 00:00:00 2001 From: David Yat Sin <77975354+dayatsin-amd@users.noreply.github.com> Date: Mon, 27 Oct 2025 15:12:06 -0400 Subject: [PATCH] rocr: Fix wrong args in memory copy functions (#1520) Fix incorrect arguments passed into system_region->Lock --- .../rocr-runtime/runtime/hsa-runtime/core/runtime/runtime.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/runtime.cpp b/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/runtime.cpp index a3ab769020..e5b2d879a3 100644 --- a/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/runtime.cpp +++ b/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/runtime.cpp @@ -552,7 +552,7 @@ hsa_status_t Runtime::CopyMemory(void* dst, const void* src, size_t size) { const auto& locked_copy = [&](void*& ptr, core::Agent* locking_agent) { void* tmp; hsa_agent_t agent = locking_agent->public_handle(); - hsa_status_t err = system_region->Lock(1, &agent, ptr, 0, size, &tmp); + hsa_status_t err = system_region->Lock(1, &agent, ptr, size, 0, &tmp); if (err != HSA_STATUS_SUCCESS) throw AMD::hsa_exception(err, "Lock failed in hsa_memory_copy."); gpuPtr = ptr; ptr = tmp;