aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeena Busireddy <neenareddy.busireddy@nxp.com>2016-05-06 11:00:54 -0300
committerArmin Kuster <akuster808@gmail.com>2016-05-09 19:05:03 -0700
commitd4b1497f8c0d9eb288045c3a03c24ac851624c26 (patch)
tree70e2b0a784d20e1eb95a33d09ef235849d07f431
parent4ee8ab7141b6f38b25d1853efd1b17529b4a6a66 (diff)
downloadmeta-openembedded-contrib-d4b1497f8c0d9eb288045c3a03c24ac851624c26.tar.gz
glmark2: wl_surface should be destoryed after destroying wl_window
If wl_surface is destroyed while work thread is still running, segmentation fault occurs. Signed-off-by: Neena Busireddy <neenareddy.busireddy@nxp.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r--meta-oe/recipes-benchmark/glmark2/files/0001-Fix-wl_surface-should-be-destoryed-after-the-wl_wind.patch34
-rw-r--r--meta-oe/recipes-benchmark/glmark2/glmark2_git.bb3
2 files changed, 36 insertions, 1 deletions
diff --git a/meta-oe/recipes-benchmark/glmark2/files/0001-Fix-wl_surface-should-be-destoryed-after-the-wl_wind.patch b/meta-oe/recipes-benchmark/glmark2/files/0001-Fix-wl_surface-should-be-destoryed-after-the-wl_wind.patch
new file mode 100644
index 0000000000..439508102a
--- /dev/null
+++ b/meta-oe/recipes-benchmark/glmark2/files/0001-Fix-wl_surface-should-be-destoryed-after-the-wl_wind.patch
@@ -0,0 +1,34 @@
+From 9c74ec83e2929b1d5ab65d5137b6ba42edeb332d Mon Sep 17 00:00:00 2001
+From: Yong Gan <b45748@freescale.com>
+Date: Tue, 27 Oct 2015 18:15:20 +0800
+Subject: [PATCH] Fix: wl_surface should be destoryed after the wl_window
+ destroyed.
+
+Upstream-Status: Submitted [https://github.com/glmark2/glmark2/issues/12]
+
+Signed-off-by: Yong Gan <b45748@freescale.com>
+
+---
+ src/native-state-wayland.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/native-state-wayland.cpp b/src/native-state-wayland.cpp
+index 41fc743..cdcdf34 100644
+--- a/src/native-state-wayland.cpp
++++ b/src/native-state-wayland.cpp
+@@ -56,10 +56,10 @@ NativeStateWayland::~NativeStateWayland()
+ wl_shell_surface_destroy(window_->shell_surface);
+ if (window_->opaque_reqion)
+ wl_region_destroy(window_->opaque_reqion);
+- if (window_->surface)
+- wl_surface_destroy(window_->surface);
+ if (window_->native)
+ wl_egl_window_destroy(window_->native);
++ if (window_->surface)
++ wl_surface_destroy(window_->surface);
+ delete window_;
+ }
+
+--
+1.9.1
+
diff --git a/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb b/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb
index 98ce3773f6..e29921b525 100644
--- a/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb
+++ b/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb
@@ -13,7 +13,8 @@ DEPENDS = "libpng12 jpeg"
PV = "2014.03+${SRCPV}"
SRC_URI = "git://github.com/glmark2/glmark2.git;protocol=https \
- file://build-Check-packages-to-be-used-by-the-enabled-flavo.patch"
+ file://build-Check-packages-to-be-used-by-the-enabled-flavo.patch \
+ file://0001-Fix-wl_surface-should-be-destoryed-after-the-wl_wind.patch"
SRCREV = "fa71af2dfab711fac87b9504b6fc9862f44bf72a"
S = "${WORKDIR}/git"