summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichel Dänzer <michel.daenzer@amd.com>2017-03-03 16:19:11 +0900
committerMichel Dänzer <michel.daenzer@amd.com>2017-03-03 16:19:11 +0900
commitf4719bb473df897012f8830f46e99cb781d67b6f (patch)
tree9a3b103f6167b88b3dc01dea49d3a691037b5cd8 /src
parentaf0b24c1aca4cba2692d5aa410e63cb536478dbe (diff)
Use drmmode_crtc_scanout_free in drmmode_fini
We were leaking drmmode_crtc->scanout_damage, which caused trouble on server reset. Fixes server reset with active separate scanout pixmaps. (Cherry picked from radeon commit 0c29deb5a97d9a57e994cc0053c49ddf7aca6ecb) Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'src')
-rw-r--r--src/drmmode_display.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index 40439dd..406b5ee 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -2415,13 +2415,8 @@ void drmmode_fini(ScrnInfoPtr pScrn, drmmode_ptr drmmode)
#endif
}
- for (c = 0; c < config->num_crtc; c++) {
- xf86CrtcPtr crtc = config->crtc[c];
- drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private;
-
- drmmode_crtc_scanout_destroy(&info->drmmode, &drmmode_crtc->scanout[0]);
- drmmode_crtc_scanout_destroy(&info->drmmode, &drmmode_crtc->scanout[1]);
- }
+ for (c = 0; c < config->num_crtc; c++)
+ drmmode_crtc_scanout_free(config->crtc[c]->driver_private);
}
void drmmode_set_cursor(ScrnInfoPtr scrn, drmmode_ptr drmmode, int id,