summaryrefslogtreecommitdiff
path: root/recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch
diff options
context:
space:
mode:
authorGerard Salvatella <gerard.salvatella@toradex.com>2019-04-29 17:46:25 +0200
committerGerard Salvatella <gerard.salvatella@toradex.com>2019-05-02 14:28:45 +0200
commit04e18ad937f96c33dce8123b49de29bea67b49b3 (patch)
tree76178bc0be524a6d72eb68012eb21327fa3079c7 /recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch
parent838010d81f0a3a81be5efd65e5a4c59a1bf2b99d (diff)
weston: drop support for weston 1.x
Maintaining the current bbappend for weston 1.x versions generates an annoying warning in OE (new in thud), since we do not have any recipe for weston 1.x. Given that the current version of weston is 6.0, it doesn't make much sense to keep these patches. Signed-off-by: Gerard Salvatella <gerard.salvatella@toradex.com>
Diffstat (limited to 'recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch')
-rw-r--r--recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch181
1 files changed, 0 insertions, 181 deletions
diff --git a/recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch b/recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch
deleted file mode 100644
index cbd2cd5..0000000
--- a/recipes-graphics/wayland/files/0001-compositor-drm-Add-new-gbm-struct-to-allow-for-a-sep.patch
+++ /dev/null
@@ -1,181 +0,0 @@
-From 0719ed96aa2c41afe342f4c3c19e4ca91f270be2 Mon Sep 17 00:00:00 2001
-From: James Thomas <james.thomas@codethink.co.uk>
-Date: Fri, 20 Jun 2014 12:12:26 +0100
-Subject: [PATCH 1/6] compositor-drm: Add new gbm struct to allow for a
- separate gbm device
-
-This is needed for devices like tegra jetson where the gbm device is not
-the same as the drm device
----
- src/compositor-drm.c | 48 +++++++++++++++++++++++++++---------------------
- 1 file changed, 27 insertions(+), 21 deletions(-)
-
-diff --git a/src/compositor-drm.c b/src/compositor-drm.c
-index 893877d..5db86dc 100644
---- a/src/compositor-drm.c
-+++ b/src/compositor-drm.c
-@@ -90,8 +90,11 @@ struct drm_backend {
- int fd;
- char *filename;
- } drm;
-- struct gbm_device *gbm;
-- uint32_t *crtcs;
-+ struct {
-+ int fd;
-+ char *filename;
-+ } gbm;
-+ struct gbm_device *gbm_device; uint32_t *crtcs;
- int num_crtcs;
- uint32_t crtc_allocator;
- uint32_t connector_allocator;
-@@ -478,7 +481,7 @@ drm_output_prepare_scanout_view(struct drm_output *output,
-
- if (ev->geometry.x != output->base.x ||
- ev->geometry.y != output->base.y ||
-- buffer == NULL || b->gbm == NULL ||
-+ buffer == NULL || b->gbm_device == NULL ||
- buffer->width != output->base.current_mode->width ||
- buffer->height != output->base.current_mode->height ||
- output->base.transform != viewport->buffer.transform ||
-@@ -488,7 +491,7 @@ drm_output_prepare_scanout_view(struct drm_output *output,
- if (ev->geometry.scissor_enabled)
- return NULL;
-
-- bo = gbm_bo_import(b->gbm, GBM_BO_IMPORT_WL_BUFFER,
-+ bo = gbm_bo_import(b->gbm_device, GBM_BO_IMPORT_WL_BUFFER,
- buffer->resource, GBM_BO_USE_SCANOUT);
-
- /* Unable to use the buffer for scanout */
-@@ -923,7 +926,7 @@ drm_output_prepare_overlay_view(struct drm_output *output,
- uint32_t format;
- wl_fixed_t sx1, sy1, sx2, sy2;
-
-- if (b->gbm == NULL)
-+ if (b->gbm_device == NULL)
- return NULL;
-
- if (viewport->buffer.transform != output->base.transform)
-@@ -985,13 +988,13 @@ drm_output_prepare_overlay_view(struct drm_output *output,
- if (dmabuf->attributes.n_planes != 1 || dmabuf->attributes.offset[0] != 0)
- return NULL;
-
-- bo = gbm_bo_import(b->gbm, GBM_BO_IMPORT_FD, &gbm_dmabuf,
-+ bo = gbm_bo_import(b->gbm_device, GBM_BO_IMPORT_FD, &gbm_dmabuf,
- GBM_BO_USE_SCANOUT);
- #else
- return NULL;
- #endif
- } else {
-- bo = gbm_bo_import(b->gbm, GBM_BO_IMPORT_WL_BUFFER,
-+ bo = gbm_bo_import(b->gbm_device, GBM_BO_IMPORT_WL_BUFFER,
- buffer_resource, GBM_BO_USE_SCANOUT);
- }
- if (!bo)
-@@ -1091,7 +1094,7 @@ drm_output_prepare_cursor_view(struct drm_output *output,
- if (ev->transform.enabled &&
- (ev->transform.matrix.type > WESTON_MATRIX_TRANSFORM_TRANSLATE))
- return NULL;
-- if (b->gbm == NULL)
-+ if (b->gbm_device == NULL)
- return NULL;
- if (output->base.transform != WL_OUTPUT_TRANSFORM_NORMAL)
- return NULL;
-@@ -1493,6 +1496,9 @@ init_drm(struct drm_backend *b, struct udev_device *device)
- b->drm.fd = fd;
- b->drm.filename = strdup(filename);
-
-+ b->gbm.fd = fd;
-+ b->gbm.filename = b->drm.filename;
-+
- ret = drmGetCap(fd, DRM_CAP_TIMESTAMP_MONOTONIC, &cap);
- if (ret == 0 && cap == 1)
- clk_id = CLOCK_MONOTONIC;
-@@ -1579,7 +1585,7 @@ drm_backend_create_gl_renderer(struct drm_backend *b)
- n_formats = 3;
- if (gl_renderer->create(b->compositor,
- EGL_PLATFORM_GBM_KHR,
-- (void *)b->gbm,
-+ (void *)b->gbm_device,
- gl_renderer->opaque_attribs,
- format,
- n_formats) < 0) {
-@@ -1592,13 +1598,13 @@ drm_backend_create_gl_renderer(struct drm_backend *b)
- static int
- init_egl(struct drm_backend *b)
- {
-- b->gbm = create_gbm_device(b->drm.fd);
-+ b->gbm_device = create_gbm_device(b->gbm.fd);
-
-- if (!b->gbm)
-+ if (!b->gbm_device)
- return -1;
-
- if (drm_backend_create_gl_renderer(b) < 0) {
-- gbm_device_destroy(b->gbm);
-+ gbm_device_destroy(b->gbm_device);
- return -1;
- }
-
-@@ -1831,7 +1837,7 @@ drm_output_init_egl(struct drm_output *output, struct drm_backend *b)
- };
- int i, flags, n_formats = 1;
-
-- output->gbm_surface = gbm_surface_create(b->gbm,
-+ output->gbm_surface = gbm_surface_create(b->gbm_device,
- output->base.current_mode->width,
- output->base.current_mode->height,
- format[0],
-@@ -1862,7 +1868,7 @@ drm_output_init_egl(struct drm_output *output, struct drm_backend *b)
- continue;
-
- output->gbm_cursor_bo[i] =
-- gbm_bo_create(b->gbm, b->cursor_width, b->cursor_height,
-+ gbm_bo_create(b->gbm_device, b->cursor_width, b->cursor_height,
- GBM_FORMAT_ARGB8888, flags);
- }
-
-@@ -2703,8 +2709,8 @@ drm_destroy(struct weston_compositor *ec)
-
- weston_compositor_shutdown(ec);
-
-- if (b->gbm)
-- gbm_device_destroy(b->gbm);
-+ if (b->gbm_device)
-+ gbm_device_destroy(b->gbm_device);
-
- weston_launcher_destroy(ec->launcher);
-
-@@ -2989,8 +2995,8 @@ switch_to_gl_renderer(struct drm_backend *b)
-
- weston_log("Switching to GL renderer\n");
-
-- b->gbm = create_gbm_device(b->drm.fd);
-- if (!b->gbm) {
-+ b->gbm_device = create_gbm_device(b->drm.fd);
-+ if (!b->gbm_device) {
- weston_log("Failed to create gbm device. "
- "Aborting renderer switch\n");
- return;
-@@ -3002,7 +3008,7 @@ switch_to_gl_renderer(struct drm_backend *b)
- b->compositor->renderer->destroy(b->compositor);
-
- if (drm_backend_create_gl_renderer(b) < 0) {
-- gbm_device_destroy(b->gbm);
-+ gbm_device_destroy(b->gbm_device);
- weston_log("Failed to create GL renderer. Quitting.\n");
- /* FIXME: we need a function to shutdown cleanly */
- assert(0);
-@@ -3191,8 +3197,8 @@ err_drm_source:
- err_udev_input:
- udev_input_destroy(&b->input);
- err_sprite:
-- if (b->gbm)
-- gbm_device_destroy(b->gbm);
-+ if (b->gbm_device)
-+ gbm_device_destroy(b->gbm_device);
- destroy_sprites(b);
- err_udev_dev:
- udev_device_unref(drm_device);
---
-2.9.3
-