Skip to contentSkip to conversation

Bail early from drm_wait_pending_flip if there's no pending flip

PATCH In review Michel Dänzer 2 participants 2 messages Sep 7, 2018 – Sep 11, 2018 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Bail early from drm_wait_pending_flip if there's no pending flip

From: Michel Dänzer <[email protected]>

No need to process any events in that case.

(Ported from amdgpu commit ca5eb9894fff153c0a1df7bdc4a4745713309e27)

---
 src/radeon_drm_queue.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
src/radeon_drm_queue.c +2 -1
index bf1650ea9..ea78e8e2b 100644
@@ -284,7 +284,8 @@ void radeon_drm_wait_pending_flip(xf86CrtcPtr crtc)
 
     drmmode_crtc->wait_flip_nesting_level++;
 
-    while (!xorg_list_is_empty(&radeon_drm_flip_signalled)) {
+    while (drmmode_crtc->flip_pending &&
+	   !xorg_list_is_empty(&radeon_drm_flip_signalled)) {
 	e = xorg_list_first_entry(&radeon_drm_flip_signalled,
 				  struct radeon_drm_queue_entry, list);
 	radeon_drm_queue_handle_one(e);
Signature · 6 lines
2.19.0.rc1

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 20180907162239.22199-1-michel-otUistvHUpPR7s880joybQ@public.gmane.org

Acked-by
#2 lore raw
Quoted 8 lines · Michel Dänzer

From: Michel Dänzer <[email protected]>

No need to process any events in that case.

(Ported from amdgpu commit ca5eb9894fff153c0a1df7bdc4a4745713309e27)

Quoted 21 lines
---
 src/radeon_drm_queue.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
src/radeon_drm_queue.c +2 -2
index bf1650ea9..ea78e8e2b 100644
@@ -284,7 +284,8 @@ void radeon_drm_wait_pending_flip(xf86CrtcPtr crtc)
 
     drmmode_crtc->wait_flip_nesting_level++;
 
-    while (!xorg_list_is_empty(&radeon_drm_flip_signalled)) {
+    while (drmmode_crtc->flip_pending &&
+          !xorg_list_is_empty(&radeon_drm_flip_signalled)) {
        e = xorg_list_first_entry(&radeon_drm_flip_signalled,
                                  struct radeon_drm_queue_entry, list);
        radeon_drm_queue_handle_one(e);
--

2.19.0.rc1

Quoted 4 lines

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx