aboutsummaryrefslogtreecommitdiffstats
path: root/meta-agl-profile-graphical/recipes-graphics
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2020-11-30 19:09:37 -0500
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2020-12-03 16:17:33 +0000
commit4dc1ce1252b8ef430777519b80221c144331e6e9 (patch)
treeb983bee4a8ad417c6091cfdc05ba859d23e3feab /meta-agl-profile-graphical/recipes-graphics
parent33a6a7e30ff000fbc1fc554c78e6cb56da447585 (diff)
meta-agl-profile-graphical: backport weston drm tear-down fix
As part of the fixes for compositor start up failures on UpSquared, backport the fix for cleaning up the DRM backend when start up fails. This does result in start up working on the UpSquared, but usually after one or more failures, so a systemd dependency to avoid that will also be added via another change. However, this particular fix still seems worth applying as it may be potentially useful for AGL members that roll their own customized distributions. Bug-AGL: SPEC-3518 Signed-off-by: Scott Murray <scott.murray@konsulko.com> Change-Id: I9a0bcea279c0da80ff3c25bd0e6ab3f137cb6ef1 Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl/+/25674 Tested-by: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org> ci-image-build: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org> ci-image-boot-test: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org> Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
Diffstat (limited to 'meta-agl-profile-graphical/recipes-graphics')
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-correctly-tear-down-drm-backend.patch37
-rw-r--r--meta-agl-profile-graphical/recipes-graphics/wayland/weston_8.0.%.bbappend1
2 files changed, 38 insertions, 0 deletions
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-correctly-tear-down-drm-backend.patch b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-correctly-tear-down-drm-backend.patch
new file mode 100644
index 000000000..cb122590b
--- /dev/null
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston/0005-correctly-tear-down-drm-backend.patch
@@ -0,0 +1,37 @@
+commit 5130a8c21a9deea54e8f7c96a3a5049e2d60a210
+Author: Marius Vlad <marius.vlad@collabora.com>
+Date: Thu Jul 30 14:47:32 2020 +0300
+
+backend-drm: Correctly tear down the DRM backend
+
+It seem that we skipped to put back in TEXT mode the tty, in case a DRM
+device node wasn't present at that time, or it isn't present at all. This
+orders the destroy part correctly as to handle that case as well.
+
+As a side effect, as the tty will still be set to GRAPHICS mode we will
+require a manual change of the tty number, which might be not possible
+on all systems. Properly putting back the tty to TEXT mode should avoid
+that, and allows to re-use the same tty no in case the DRM device has
+been created at a later point in time.
+
+Upstream-Status: Backport
+Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
+Signed-off-by: Scott Murray <scott.murray@konsulko.com>
+
+diff --git a/libweston/backend-drm/drm.c b/libweston/backend-drm/drm.c
+index 980a12da..1cf61a33 100644
+--- a/libweston/backend-drm/drm.c
++++ b/libweston/backend-drm/drm.c
+@@ -3031,10 +3031,10 @@ err_sprite:
+ destroy_sprites(b);
+ err_udev_dev:
+ udev_device_unref(drm_device);
+-err_launcher:
+- weston_launcher_destroy(compositor->launcher);
+ err_udev:
+ udev_unref(b->udev);
++err_launcher:
++ weston_launcher_destroy(compositor->launcher);
+ err_compositor:
+ weston_compositor_shutdown(compositor);
+ free(b);
diff --git a/meta-agl-profile-graphical/recipes-graphics/wayland/weston_8.0.%.bbappend b/meta-agl-profile-graphical/recipes-graphics/wayland/weston_8.0.%.bbappend
index 99fe64bd1..d681aa133 100644
--- a/meta-agl-profile-graphical/recipes-graphics/wayland/weston_8.0.%.bbappend
+++ b/meta-agl-profile-graphical/recipes-graphics/wayland/weston_8.0.%.bbappend
@@ -4,6 +4,7 @@ SRC_URI_append = "\
file://0001-Allow-regular-users-to-launch-Weston_7.0.0.patch \
file://0001-libweston-Expose-weston_output_damage-in-libweston.patch \
file://0001-libweston-Migrate-weston_seat_init-release-to-public.patch \
+ file://0005-correctly-tear-down-drm-backend.patch \
file://smack-weston \
"