summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorSharat Masetty <smasetty@codeaurora.org>2018-11-29 15:35:20 +0530
committerAlex Deucher <alexander.deucher@amd.com>2018-12-05 17:56:16 -0500
commit1db8c142b6c557a951e8f9866b98953fe91cbdd6 (patch)
treee93983882976af32506fdde4336f930c1fb761d8 /include/drm
parent9afd07566b6c908324cb4072102e2ce96bce986a (diff)
drm/scheduler: Add drm_sched_suspend/resume_timeout()
This patch adds two new functions to help client drivers suspend and resume the scheduler job timeout. This can be useful in cases where the hardware has preemption support enabled. Using this, it is possible to have the timeout active only for the ring which is active on the ringbuffer. This patch also makes the job_list_lock IRQ safe. Suggested-by: Christian Koenig <Christian.Koenig@amd.com> Signed-off-by: Sharat Masetty <smasetty@codeaurora.org> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/gpu_scheduler.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/drm/gpu_scheduler.h b/include/drm/gpu_scheduler.h
index 926379d53484..47e19796c450 100644
--- a/include/drm/gpu_scheduler.h
+++ b/include/drm/gpu_scheduler.h
@@ -331,4 +331,8 @@ struct drm_sched_fence *drm_sched_fence_create(
void drm_sched_fence_scheduled(struct drm_sched_fence *fence);
void drm_sched_fence_finished(struct drm_sched_fence *fence);
+unsigned long drm_sched_suspend_timeout(struct drm_gpu_scheduler *sched);
+void drm_sched_resume_timeout(struct drm_gpu_scheduler *sched,
+ unsigned long remaining);
+
#endif