summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2025-06-14 08:51:31 -0700
committerAlan Coopersmith <alan.coopersmith@oracle.com>2025-06-14 08:51:31 -0700
commit953a14f0103ef1d5ee19679213cf9d8d26487d70 (patch)
treebff72e652d493e1c99ad94b5beba3692a57a3a78
parent353b372ccbd338033cb4cd75841e60f88996e78e (diff)
Revert "use dixDestroyPixmap() instead of direct driver call"
-rw-r--r--src/amdgpu_dri2.c6
-rw-r--r--src/amdgpu_glamor.c7
-rw-r--r--src/amdgpu_kms.c3
-rw-r--r--src/drmmode_display.c4
-rw-r--r--src/drmmode_display.h2
5 files changed, 11 insertions, 11 deletions
diff --git a/src/amdgpu_dri2.c b/src/amdgpu_dri2.c
index 074617b..bfc14f3 100644
--- a/src/amdgpu_dri2.c
+++ b/src/amdgpu_dri2.c
@@ -200,7 +200,7 @@ amdgpu_dri2_create_buffer2(ScreenPtr pScreen,
error:
free(buffers);
- dixDestroyPixmap(pixmap, 0);
+ (*pScreen->DestroyPixmap) (pixmap);
return NULL;
}
@@ -224,7 +224,7 @@ amdgpu_dri2_destroy_buffer2(ScreenPtr pScreen,
private->refcnt--;
if (private->refcnt == 0) {
if (private->pixmap)
- dixDestroyPixmap(private->pixmap, 0);
+ (*pScreen->DestroyPixmap) (private->pixmap);
free(buffers->driverPrivate);
free(buffers);
@@ -558,7 +558,7 @@ static Bool update_front(DrawablePtr draw, DRI2BufferPtr front)
if (!amdgpu_get_flink_name(pAMDGPUEnt, pixmap, &front->name))
return FALSE;
- dixDestroyPixmap(priv->pixmap, 0);
+ (*draw->pScreen->DestroyPixmap) (priv->pixmap);
front->pitch = pixmap->devKind;
front->cpp = pixmap->drawable.bitsPerPixel / 8;
priv->pixmap = pixmap;
diff --git a/src/amdgpu_glamor.c b/src/amdgpu_glamor.c
index 98e36f9..4ecc335 100644
--- a/src/amdgpu_glamor.c
+++ b/src/amdgpu_glamor.c
@@ -157,7 +157,7 @@ static Bool amdgpu_glamor_destroy_pixmap(PixmapPtr pixmap)
#ifndef HAVE_GLAMOR_EGL_DESTROY_TEXTURED_PIXMAP
ScreenPtr screen = pixmap->drawable.pScreen;
AMDGPUInfoPtr info = AMDGPUPTR(xf86ScreenToScrn(screen));
- Bool ret = TRUE;
+ Bool ret;
#endif
if (pixmap->refcnt == 1) {
@@ -179,8 +179,7 @@ static Bool amdgpu_glamor_destroy_pixmap(PixmapPtr pixmap)
return TRUE;
#else
screen->DestroyPixmap = info->glamor.SavedDestroyPixmap;
- if (screen->DestroyPixmap)
- ret = screen->DestroyPixmap(pixmap);
+ ret = screen->DestroyPixmap(pixmap);
info->glamor.SavedDestroyPixmap = screen->DestroyPixmap;
screen->DestroyPixmap = amdgpu_glamor_destroy_pixmap;
@@ -338,7 +337,7 @@ amdgpu_glamor_set_pixmap_bo(DrawablePtr drawable, PixmapPtr pixmap)
0, 0, pixmap->devKind, NULL);
old->devPrivate.ptr = NULL;
- dixDestroyPixmap(pixmap, 0);
+ screen->DestroyPixmap(pixmap);
return old;
}
diff --git a/src/amdgpu_kms.c b/src/amdgpu_kms.c
index 03ce0ea..0b898b9 100644
--- a/src/amdgpu_kms.c
+++ b/src/amdgpu_kms.c
@@ -2338,7 +2338,8 @@ void AMDGPULeaveVT_KMS(ScrnInfoPtr pScrn)
}
}
}
- dixDestroyPixmap(black_scanout, 0);
+
+ pScreen->DestroyPixmap(black_scanout);
}
}
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index 7a86909..b74b237 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -402,7 +402,7 @@ create_pixmap_for_fbcon(drmmode_ptr drmmode,
if (!glamor_egl_create_textured_pixmap(pixmap, fbcon->handle,
pixmap->devKind)) {
- dixDestroyPixmap(pixmap, 0);
+ pScreen->DestroyPixmap(pixmap);
pixmap = NULL;
}
@@ -460,7 +460,7 @@ void drmmode_copy_fb(ScrnInfoPtr pScrn, drmmode_ptr drmmode)
FreeScratchGC(gc);
pScreen->canDoBGNoneRoot = TRUE;
- dixDestroyPixmap(src, 0);
+ pScreen->DestroyPixmap(src);
#endif
return;
diff --git a/src/drmmode_display.h b/src/drmmode_display.h
index 0d96dd8..462268f 100644
--- a/src/drmmode_display.h
+++ b/src/drmmode_display.h
@@ -240,7 +240,7 @@ drmmode_crtc_scanout_destroy(PixmapPtr *scanout)
if (!*scanout)
return;
- dixDestroyPixmap(*scanout, 0);
+ (*scanout)->drawable.pScreen->DestroyPixmap(*scanout);
(*scanout) = NULL;
}