SWDEV-563752 - Allow hipMemLocationTypeHost in hipMemSetAccess even if memory was created on the device (#1620)
Co-authored-by: Rahul Manocha <rmanocha@amd.com>
This commit is contained in:
committed by
GitHub
parent
24cb8c4deb
commit
1dd0237cb2
@@ -388,10 +388,6 @@ hipError_t hipMemSetAccess(void* ptr, size_t size, const hipMemAccessDesc* desc,
|
||||
if (accessLocationType != hipMemLocationTypeDevice && accessLocationType != hipMemLocationTypeHost) {
|
||||
HIP_RETURN(hipErrorInvalidValue);
|
||||
}
|
||||
if (accessLocationType == hipMemLocationTypeHost &&
|
||||
memLocationType != hipMemLocationTypeHost) {
|
||||
HIP_RETURN(hipErrorInvalidValue)
|
||||
}
|
||||
|
||||
if (desc[desc_idx].location.id >= g_devices.size()) {
|
||||
HIP_RETURN(hipErrorInvalidValue)
|
||||
|
||||
Reference in New Issue
Block a user