From d202fd6596c08fb8cbd745192f547d98f3e5ec84 Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Sun, 22 Apr 2018 16:48:15 +0200 Subject: [PATCH] egl: drop unused _EGLDriver from CopyBuffers() MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Eric Engestrom Reviewed-by: Marek Olšák Part-of: --- src/egl/drivers/dri2/egl_dri2.c | 5 ++--- src/egl/drivers/dri2/egl_dri2.h | 4 ++-- src/egl/drivers/dri2/platform_x11.c | 5 +---- src/egl/drivers/dri2/platform_x11_dri3.c | 3 +-- src/egl/main/eglapi.c | 2 +- src/egl/main/egldriver.h | 4 ++-- 6 files changed, 9 insertions(+), 14 deletions(-) diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c index 8cf286229b6..0825e1c6541 100644 --- a/src/egl/drivers/dri2/egl_dri2.c +++ b/src/egl/drivers/dri2/egl_dri2.c @@ -2074,13 +2074,12 @@ dri2_post_sub_buffer(const _EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf } static EGLBoolean -dri2_copy_buffers(const _EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf, - void *native_pixmap_target) +dri2_copy_buffers(_EGLDisplay *disp, _EGLSurface *surf, void *native_pixmap_target) { struct dri2_egl_display *dri2_dpy = dri2_egl_display(disp); if (!dri2_dpy->vtbl->copy_buffers) return _eglError(EGL_BAD_NATIVE_PIXMAP, "no support for native pixmaps"); - return dri2_dpy->vtbl->copy_buffers(drv, disp, surf, native_pixmap_target); + return dri2_dpy->vtbl->copy_buffers(disp, surf, native_pixmap_target); } static EGLint diff --git a/src/egl/drivers/dri2/egl_dri2.h b/src/egl/drivers/dri2/egl_dri2.h index 0f8d941f5d0..063e7ee80e8 100644 --- a/src/egl/drivers/dri2/egl_dri2.h +++ b/src/egl/drivers/dri2/egl_dri2.h @@ -136,8 +136,8 @@ struct dri2_egl_display_vtbl { EGLint width, EGLint height); /* optional */ - EGLBoolean (*copy_buffers)(const _EGLDriver *drv, _EGLDisplay *disp, - _EGLSurface *surf, void *native_pixmap_target); + EGLBoolean (*copy_buffers)(_EGLDisplay *disp, _EGLSurface *surf, + void *native_pixmap_target); /* optional */ EGLint (*query_buffer_age)(const _EGLDriver *drv, _EGLDisplay *disp, diff --git a/src/egl/drivers/dri2/platform_x11.c b/src/egl/drivers/dri2/platform_x11.c index 9fb9423123b..c4633864816 100644 --- a/src/egl/drivers/dri2/platform_x11.c +++ b/src/egl/drivers/dri2/platform_x11.c @@ -992,8 +992,7 @@ dri2_x11_swap_interval(_EGLDisplay *disp, _EGLSurface *surf, EGLint interval) } static EGLBoolean -dri2_x11_copy_buffers(const _EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf, - void *native_pixmap_target) +dri2_x11_copy_buffers(_EGLDisplay *disp, _EGLSurface *surf, void *native_pixmap_target) { struct dri2_egl_display *dri2_dpy = dri2_egl_display(disp); struct dri2_egl_surface *dri2_surf = dri2_egl_surface(surf); @@ -1003,8 +1002,6 @@ dri2_x11_copy_buffers(const _EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *sur STATIC_ASSERT(sizeof(uintptr_t) == sizeof(native_pixmap_target)); target = (uintptr_t) native_pixmap_target; - (void) drv; - dri2_dpy->flush->flush(dri2_surf->dri_drawable); gc = xcb_generate_id(dri2_dpy->conn); diff --git a/src/egl/drivers/dri2/platform_x11_dri3.c b/src/egl/drivers/dri2/platform_x11_dri3.c index b15b06b098f..7a90d73dec1 100644 --- a/src/egl/drivers/dri2/platform_x11_dri3.c +++ b/src/egl/drivers/dri2/platform_x11_dri3.c @@ -423,8 +423,7 @@ dri3_swap_buffers(_EGLDisplay *disp, _EGLSurface *draw) } static EGLBoolean -dri3_copy_buffers(const _EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf, - void *native_pixmap_target) +dri3_copy_buffers(_EGLDisplay *disp, _EGLSurface *surf, void *native_pixmap_target) { struct dri3_egl_surface *dri3_surf = dri3_egl_surface(surf); xcb_pixmap_t target; diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c index 5b78c9bae26..229e7860dea 100644 --- a/src/egl/main/eglapi.c +++ b/src/egl/main/eglapi.c @@ -1478,7 +1478,7 @@ eglCopyBuffers(EGLDisplay dpy, EGLSurface surface, EGLNativePixmapType target) native_pixmap_ptr = (void*) target; _EGL_CHECK_SURFACE(disp, surf, EGL_FALSE, drv); - ret = drv->CopyBuffers(drv, disp, surf, native_pixmap_ptr); + ret = drv->CopyBuffers(disp, surf, native_pixmap_ptr); RETURN_EGL_EVAL(disp, ret); } diff --git a/src/egl/main/egldriver.h b/src/egl/main/egldriver.h index 5341b3a336e..9a8f1db8450 100644 --- a/src/egl/main/egldriver.h +++ b/src/egl/main/egldriver.h @@ -118,8 +118,8 @@ struct _egl_driver EGLBoolean (*SwapInterval)(_EGLDisplay *disp, _EGLSurface *surf, EGLint interval); EGLBoolean (*SwapBuffers)(_EGLDisplay *disp, _EGLSurface *draw); - EGLBoolean (*CopyBuffers)(const _EGLDriver *drv, _EGLDisplay *disp, - _EGLSurface *surface, void *native_pixmap_target); + EGLBoolean (*CopyBuffers)(_EGLDisplay *disp, _EGLSurface *surface, + void *native_pixmap_target); EGLBoolean (*SetDamageRegion)(const _EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surface, EGLint *rects, EGLint n_rects); -- 2.30.2