[PATCH xf86-video-ati 4/4] Call radeon_drm_abort_entry on failure to flip to a scanout pixmap

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Michel Dänzer <michel.daenzer@xxxxxxx>

Fixes leaking the corresponding struct radeon_drm_queue list entry in
that case.

Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
---
 src/radeon_kms.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/radeon_kms.c b/src/radeon_kms.c
index 5764c20..48dec96 100644
--- a/src/radeon_kms.c
+++ b/src/radeon_kms.c
@@ -807,6 +807,7 @@ radeon_prime_scanout_flip(PixmapDirtyUpdatePtr ent)
 					  0, drm_queue_seq, 0) != 0) {
 	xf86DrvMsg(scrn->scrnIndex, X_WARNING, "flip queue failed in %s: %s\n",
 		   __func__, strerror(errno));
+	radeon_drm_abort_entry(drm_queue_seq);
 	return;
     }
 
@@ -1083,6 +1084,7 @@ radeon_scanout_flip(ScreenPtr pScreen, RADEONInfoPtr info,
 					  0, drm_queue_seq, 0) != 0) {
 	xf86DrvMsg(scrn->scrnIndex, X_WARNING, "flip queue failed in %s: %s\n",
 		   __func__, strerror(errno));
+	radeon_drm_abort_entry(drm_queue_seq);
 	return;
     }
 
-- 
2.10.2



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux