aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c
diff options
context:
space:
mode:
authorAndres Rodriguez <andresx7@gmail.com>2017-06-26 16:12:10 -0400
committerAlex Deucher <alexander.deucher@amd.com>2017-10-09 16:30:23 -0400
commitf3d19bf80d6c7bfe5922c09604a402ef176da41f (patch)
tree07f6527df19b67d0c8f5d9990bc1a55e2ba85963 /drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c
parent9ebbaabee858dcecb251d64ecb1e639a1590fff6 (diff)
drm/amdgpu: introduce AMDGPU_CTX_PRIORITY_UNSET
Use _INVALID to identify bad parameters and _UNSET to represent the lack of interest in a specific value. Signed-off-by: Andres Rodriguez <andresx7@gmail.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c
index d3d63f78bec9..29eebdc30a4c 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c
@@ -230,6 +230,8 @@ static enum amd_sched_priority amdgpu_to_sched_priority(int amdgpu_priority)
230 case AMDGPU_CTX_PRIORITY_LOW_SW: 230 case AMDGPU_CTX_PRIORITY_LOW_SW:
231 case AMDGPU_CTX_PRIORITY_LOW_HW: 231 case AMDGPU_CTX_PRIORITY_LOW_HW:
232 return AMD_SCHED_PRIORITY_LOW; 232 return AMD_SCHED_PRIORITY_LOW;
233 case AMDGPU_CTX_PRIORITY_UNSET:
234 return AMD_SCHED_PRIORITY_UNSET;
233 default: 235 default:
234 WARN(1, "Invalid context priority %d\n", amdgpu_priority); 236 WARN(1, "Invalid context priority %d\n", amdgpu_priority);
235 return AMD_SCHED_PRIORITY_INVALID; 237 return AMD_SCHED_PRIORITY_INVALID;