[PATCH xf86-video-modesetting] Track X server API changes for DamageUnregister

Keith Packard keithp at keithp.com
Thu Nov 14 00:09:42 PST 2013


DamageUnregister takes only one argument now.

Signed-off-by: Keith Packard <keithp at keithp.com>
---

Here's a fix for the X server API change

 src/driver.c          | 4 ++--
 src/drmmode_display.c | 3 +--
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/driver.c b/src/driver.c
index cc526f6..2065e3c 100644
--- a/src/driver.c
+++ b/src/driver.c
@@ -478,7 +478,7 @@ static void dispatch_dirty(ScreenPtr pScreen)
     ret = dispatch_dirty_region(scrn, pixmap, ms->damage, fb_id);
     if (ret == -EINVAL || ret == -ENOSYS) {
 	ms->dirty_enabled = FALSE;
-	DamageUnregister(&pScreen->GetScreenPixmap(pScreen)->drawable, ms->damage);
+	DamageUnregister(ms->damage);
 	DamageDestroy(ms->damage);
 	ms->damage = NULL;
 	xf86DrvMsg(scrn->scrnIndex, X_INFO, "Disabling kernel dirty updates, not required.\n");
@@ -1029,7 +1029,7 @@ CloseScreen(CLOSE_SCREEN_ARGS_DECL)
     modesettingPtr ms = modesettingPTR(pScrn);
 
     if (ms->damage) {
-	DamageUnregister(&pScreen->GetScreenPixmap(pScreen)->drawable, ms->damage);
+	DamageUnregister(ms->damage);
 	DamageDestroy(ms->damage);
 	ms->damage = NULL;
     }
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index 4fb4d21..e9bfc3e 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -514,8 +514,7 @@ drmmode_set_scanout_pixmap(xf86CrtcPtr crtc, PixmapPtr ppix)
 			drmModeRmFB(drmmode->fd, ppriv->fb_id);
 		}
 		if (drmmode_crtc->slave_damage) {
-			DamageUnregister(&crtc->randr_crtc->scanout_pixmap->drawable,
-					 drmmode_crtc->slave_damage);
+			DamageUnregister(drmmode_crtc->slave_damage);
 			drmmode_crtc->slave_damage = NULL;
 		}
 		return TRUE;
-- 
1.8.4.2



More information about the xorg-devel mailing list