From b3152ef3299d29f65fc1aad46a6afdf8d9d8e9f1 Mon Sep 17 00:00:00 2001 From: Naoto Yamaguchi Date: Mon, 8 Nov 2021 23:51:48 +0900 Subject: BUG FIX: Some guest apps don't show own GUI frequently Some guest apps don't show own GUI frequently. This bug is caused by wayland-wsegl, but it is depend on drm-lease environment use case. This bug was fixed in https://github.com/renesas-rcar/wayland-wsegl/commit/5a0a17bc0dafe577ec02ad2205c25bc8acb2c5e6 https://github.com/renesas-rcar/wayland-wsegl/commit/10c7f13a3d868d489054d8af4463bb68036055c6 But that fixed version can't use in Renesas BSP 5.5. This patch backport those patch to Renesas BSP 5.5 environment. Bug-AGL: SPEC-4134 Signed-off-by: Naoto Yamaguchi Change-Id: Ief99ced0cd83348583d8e578f101ec724eec0450 --- ...lient-Ensure-that-supported-DMAbuf-format.patch | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 meta-agl-drm-lease/dynamic-layers/meta-rcar-gen3/recipes-graphics/wayland/wayland-wsegl/0001-waylandws_client-Ensure-that-supported-DMAbuf-format.patch (limited to 'meta-agl-drm-lease/dynamic-layers/meta-rcar-gen3/recipes-graphics/wayland/wayland-wsegl/0001-waylandws_client-Ensure-that-supported-DMAbuf-format.patch') diff --git a/meta-agl-drm-lease/dynamic-layers/meta-rcar-gen3/recipes-graphics/wayland/wayland-wsegl/0001-waylandws_client-Ensure-that-supported-DMAbuf-format.patch b/meta-agl-drm-lease/dynamic-layers/meta-rcar-gen3/recipes-graphics/wayland/wayland-wsegl/0001-waylandws_client-Ensure-that-supported-DMAbuf-format.patch new file mode 100644 index 00000000..850099c8 --- /dev/null +++ b/meta-agl-drm-lease/dynamic-layers/meta-rcar-gen3/recipes-graphics/wayland/wayland-wsegl/0001-waylandws_client-Ensure-that-supported-DMAbuf-format.patch @@ -0,0 +1,55 @@ +From 5a0a17bc0dafe577ec02ad2205c25bc8acb2c5e6 Mon Sep 17 00:00:00 2001 +From: Damian Hobson-Garcia +Date: Mon, 25 Oct 2021 18:26:34 +0900 +Subject: [PATCH 1/3] waylandws_client: Ensure that supported DMAbuf formats + are received + +Explicitly check that the list of supported dmabuf formats have +been received from the server during initialization. At least +one pixel format must be supported in order to complete initialization +successfully. +--- + src/waylandws_client.c | 20 ++++++++++++++++++++ + 1 file changed, 20 insertions(+) + +diff --git a/src/waylandws_client.c b/src/waylandws_client.c +index e917347..20bfac9 100644 +--- a/src/waylandws_client.c ++++ b/src/waylandws_client.c +@@ -698,6 +698,20 @@ static bool setup_buffer_sharing(WLWSClientDisplay *display) + return authenticate_kms_device(display); + } + ++static bool ensure_supported_dmabuf_formats(WLWSClientDisplay *display) ++{ ++ if (!display->zlinux_dmabuf) ++ return true; ++ ++ if (wl_display_roundtrip_queue(display->wl_display, display->wl_queue) < 0 || ++ !display->enable_formats) { ++ /* No supported dmabuf pixel formats */ ++ return false; ++ } ++ ++ return true; ++} ++ + /*********************************************************************************** + Function Name : WSEGL_InitialiseDisplay + Inputs : hNativeDisplay +@@ -755,6 +769,12 @@ static WSEGLError WSEGLc_InitialiseDisplay(NativeDisplayType hNativeDisplay, + goto fail; + } + ++ /* Get the list of supported pixel formats */ ++ if (!ensure_supported_dmabuf_formats(display)) { ++ err = WSEGL_BAD_NATIVE_DISPLAY; ++ goto fail; ++ } ++ + /* XXX: should we wrap this with wl_kms client code? */ + if (kms_create(display->fd, &display->kms)) { + err = WSEGL_BAD_NATIVE_DISPLAY; +-- +2.25.1 + -- cgit 1.2.3-korg