diff options
author | Alex Sierra <[email protected]> | 2021-04-21 13:54:09 -0500 |
---|---|---|
committer | Alex Deucher <[email protected]> | 2021-04-23 17:16:37 -0400 |
commit | 63f1af83ae4614314834eab727ad94cd8d4278b0 (patch) | |
tree | 3f5195d3c81c68c1a0647496ad992bd05ff60877 | |
parent | b19dbb7a90b42e0ba22878e647cfb62e2b09ed13 (diff) |
drm/amdkfd: set attribute access for default ranges
Attribute access value for default ranges is set, based on
process xnack on/off.
XNACK ON has GPU access attribute for unregistered ranges through page
fault. While XNACK OFF has no access attribute for unregistered ranges.
Signed-off-by: Alex Sierra <[email protected]>
Reviewed-by: Felix Kuehling <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
-rw-r--r-- | drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_svm.c b/drivers/gpu/drm/amd/amdkfd/kfd_svm.c index 46591ce71b1c..cfd8065fe0f6 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_svm.c +++ b/drivers/gpu/drm/amd/amdkfd/kfd_svm.c @@ -2887,12 +2887,11 @@ svm_range_get_attr(struct kfd_process *p, uint64_t start, uint64_t size, pr_debug("range attrs not found return default values\n"); svm_range_set_default_attributes(&location, &prefetch_loc, &granularity, &flags); - /* TODO: Automatically create SVM ranges and map them on - * GPU page faults if (p->xnack_enabled) bitmap_fill(bitmap_access, MAX_GPU_INSTANCE); - */ - + else + bitmap_zero(bitmap_access, MAX_GPU_INSTANCE); + bitmap_zero(bitmap_aip, MAX_GPU_INSTANCE); goto fill_values; } bitmap_fill(bitmap_access, MAX_GPU_INSTANCE); |