summaryrefslogtreecommitdiff
path: root/src/amdgpu_drm_queue.h
diff options
context:
space:
mode:
authorMichel Dänzer <michel.daenzer@amd.com>2018-07-25 13:00:15 +0200
committerMichel Dänzer <michel@daenzer.net>2018-08-16 17:11:24 +0200
commit739181c8d3334ff14b5a607895dfdeb29b0d9020 (patch)
tree5336ab593724bd0cd933debdee087d936cd6339c /src/amdgpu_drm_queue.h
parent6029794e8a35417faf825491a89b85f713c77fc1 (diff)
Add amdgpu_drm_handle_event wrapper for drmHandleEvent
Instead of processing DRM events directly from drmHandleEvent's callbacks, there are three phases: 1. drmHandleEvent is called, and signalled events are re-queued to _signalled lists from its callbacks. 2. Signalled page flip completion events are processed. 3. Signalled vblank events are processed. This should make sure that we never call drmHandleEvent from one of its callbacks, which would usually result in blocking forever.
Diffstat (limited to 'src/amdgpu_drm_queue.h')
-rw-r--r--src/amdgpu_drm_queue.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/amdgpu_drm_queue.h b/src/amdgpu_drm_queue.h
index cb6d5ff..48ba9ab 100644
--- a/src/amdgpu_drm_queue.h
+++ b/src/amdgpu_drm_queue.h
@@ -49,6 +49,7 @@ uintptr_t amdgpu_drm_queue_alloc(xf86CrtcPtr crtc, ClientPtr client,
void amdgpu_drm_abort_client(ClientPtr client);
void amdgpu_drm_abort_entry(uintptr_t seq);
void amdgpu_drm_abort_id(uint64_t id);
+int amdgpu_drm_handle_event(int fd, drmEventContext *event_context);
void amdgpu_drm_wait_pending_flip(xf86CrtcPtr crtc);
void amdgpu_drm_queue_init(ScrnInfoPtr scrn);
void amdgpu_drm_queue_close(ScrnInfoPtr scrn);