[OE-core] [PATCH] mesa: use x11 as egl_native_platform when the configure argument "platforms" contains x11
From: Quanyang Wang This fixes an issue that the mesa egl library detecting the wrong platform type. Signed-off-by: Quanyang Wang --- When mesa update from 19.1 to 20.0, there is an issue that the mesa egl will detect the wrong platform type, this issue results that in the sato X11 window system all opengl/opengles apps by using egl run into "Segmentation fault". I have filed a bug to mesa community: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3075#note_519060 Until now there is no response from the developers. There are several solutions to resolve it: 1) When running an openg/opengles app in sato, export EGL_PLATFORM="x11". 2) Adjust the configure argument order in mesa.inc to make "-Dplatforms=wayland,x11,drm,surfaceless" to be "-Dplatforms=x11,wayland,drm,surfaceless" to dodge this issue. 3) Apply this patch for a workaround then waiting for mesa development community to work out a perfect solution. ...-egl_native_platform-when-the-config.patch | 57 +++ meta/recipes-graphics/mesa/mesa.inc | 1 + 2 files changed, 58 insertions(+) create mode 100644 meta/recipes-graphics/mesa/files/0001-meson-use-x11-as-egl_native_platform-when-the-config.patch diff --git a/meta/recipes-graphics/mesa/files/0001-meson-use-x11-as-egl_native_platform-when-the-config.patch b/meta/recipes-graphics/mesa/files/0001-meson-use-x11-as-egl_native_platform-when-the-config.patch new file mode 100644 index 00..825dc988a0 --- /dev/null +++ b/meta/recipes-graphics/mesa/files/0001-meson-use-x11-as-egl_native_platform-when-the-config.patch @@ -0,0 +1,57 @@ +From 8fe9af6ba8477f6a3d7a85168bb47e7d953d090c Mon Sep 17 00:00:00 2001 +From: Quanyang Wang +Date: Tue, 9 Jun 2020 10:59:47 +0800 +Subject: [PATCH] meson: use x11 as egl_native_platform when the configure + argument "platforms" contains x11 + +When mesa is configured with argument "-Dplatforms=wayland,x11,drm,surfaceless", +in meson.build, the "wayland" is the first element of "platforms" and the +"egl_native_platform" will be "wayland", then in src/egl/meson.build, +_EGL_NATIVE_PLATFORM will be assigned to be _EGL_NATIVE_WAYLAND. And in the +commit 86d3a346 ("egl: fix _EGL_NATIVE_PLATFORM fallback"), the function +_eglNativePlatformDetectNativeDisplay delete the return value _EGL_PLATFORM_X11 +when detecting "wayland" and "gbm" failed, this will result that in _eglGetNativePlatform +the platform type will be _EGL_NATIVE_PLATFORM which is equal to be _EGL_NATIVE_WAYLAND +even if the app runs at a "X11" platform. + +So when an X11 app using egl: +x_dpy = XOpenDisplay(NULL); +... +dpy = eglGetDisplay((EGLNativeDisplayType) x_dpy); +eglGetDisplay will run into crash because libEGL.so detected the wrong platform type. + +root@genericx86-64:~# export DISPLAY=:0 +root@genericx86-64:~# eglgears_x11 +Segmentation fault + +When apps run at wayland or gbm platform, eglGetDisplay can detect the platform type +automatically, but x11 can't. So use x11 as egl_native_platform when the configure +argument "platforms" contains x11. + +Upstream-Status: Pending + +Signed-off-by: Quanyang Wang +--- + meson.build | 6 +- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/meson.build b/meson.build +index b25fa19..ae95e73 100644 +--- a/meson.build b/meson.build +@@ -307,7 +307,11 @@ if _platforms.length() != 0 and _platforms != [''] + error('Invalid argument list given to -Dplatforms, please fix.') + endif + with_platforms = true +- egl_native_platform = _platforms[0] ++ if with_platform_x11 ++egl_native_platform = 'x11' ++ else ++egl_native_platform = _platforms[0] ++ endif + endif + + _xlib_lease = get_option('xlib-lease') +-- +2.17.1 + diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc index 965e12d17e..ccaf42f9ad 100644 --- a/meta/recipes-graphics/mesa/mesa.inc +++ b/meta/recipes-graphics/mesa/mesa.inc @@ -21,6 +21,7 @@ SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \ file://0004-Revert-mesa-Enable-asm-unconditionally-now-that-gen_.patch \ file://0005-vc4-use-intmax_t-for-formatted-output-of-timespec-me.patch \ file://0001-meson-misdetects-64bit-atomics-on-mips-clang.patch \ + file://0001-meson-use-x11-as-egl_native_platform-when-the-config.patch \ " SRC_URI[md5sum] = "609cb7664204e031d4c65c602c652a28" -- 2.17.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#139356): https://lists.openembedded.org/g/openembedded-core/message/139356 Mute This Topic: https://lists.openembedded.org/mt/74771538/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[OE-core] [V2][PATCH] lttng-modules: fix NULL pointer deference error when testing rpc_task_running
From: Quanyang Wang This is a backport from upstream https://github.com/lttng/lttng-modules.git stable-2.10 to fix NULL pointer deference error when running kts testcase lttng_syscall_events. Signed-off-by: Quanyang Wang --- ...ops-when-trace-sunrpc_task-events-in.patch | 94 + ...rpc_clnt-dereference-in-rpc_task_que.patch | 44 ++ ...rpc-use-signed-integer-for-client-id.patch | 105 ++ ...nrpc-introduce-lttng_get_clid-helper.patch | 130 ++ .../lttng/lttng-modules_2.10.11.bb| 4 + 5 files changed, 377 insertions(+) create mode 100644 meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch create mode 100644 meta/recipes-kernel/lttng/lttng-modules/0002-Fix-sunrpc-null-rpc_clnt-dereference-in-rpc_task_que.patch create mode 100644 meta/recipes-kernel/lttng/lttng-modules/0003-Fix-sunrpc-use-signed-integer-for-client-id.patch create mode 100644 meta/recipes-kernel/lttng/lttng-modules/0004-sunrpc-introduce-lttng_get_clid-helper.patch diff --git a/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch b/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch new file mode 100644 index 00..bdbc4f811e --- /dev/null +++ b/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch @@ -0,0 +1,94 @@ +From 1ff7013bcf7f068cf4371d12d758f9c0fd16a619 Mon Sep 17 00:00:00 2001 +From: Quanyang Wang +Date: Thu, 5 Dec 2019 15:35:32 +0800 +Subject: [PATCH 1/4] Fix: SUNRPC: Fix oops when trace sunrpc_task events in + nfs client + +See upstream commit : + + commit 2ca310fc4160ed0420da65534a21ae77b24326a8 + Author: Ditang Chen + Date: Fri, 7 Mar 2014 13:27:57 +0800 + Subject: SUNRPC: Fix oops when trace sunrpc_task events in nfs client + + When tracking sunrpc_task events in nfs client, the clnt pointer may be NULL. + + [ 139.269266] BUG: unable to handle kernel NULL pointer dereference at 0004 + [ 139.269915] IP: [] ftrace_raw_event_rpc_task_running+0x86/0xf0 [sunrpc] + [ 139.269915] PGD 1d293067 PUD 1d294067 PMD 0 + [ 139.269915] Oops: [#1] SMP + [ 139.269915] Modules linked in: nfsv4 dns_resolver nfs lockd sunrpc fscache sg ppdev e1000 + serio_raw pcspkr parport_pc parport i2c_piix4 i2c_core microcode xfs libcrc32c sd_mod sr_mod + cdrom ata_generic crc_t10dif crct10dif_common pata_acpi ahci libahci ata_piix libata dm_mirror + dm_region_hash dm_log dm_mod + [ 139.269915] CPU: 0 PID: 59 Comm: kworker/0:2 Not tainted 3.10.0-84.el7.x86_64 #1 + [ 139.269915] Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006 + [ 139.269915] Workqueue: rpciod rpc_async_schedule [sunrpc] + [ 139.269915] task: 88001b598000 ti: 88001b632000 task.ti: 88001b632000 + [ 139.269915] RIP: 0010:[] [] ftrace_raw_event_rpc_task_running+0x86/0xf0 [sunrpc] + [ 139.269915] RSP: 0018:88001b633d70 EFLAGS: 00010206 + [ 139.269915] RAX: 88001dfc5338 RBX: 88001cc37a00 RCX: 88001dfc5334 + [ 139.269915] RDX: 88001dfc5338 RSI: RDI: 88001dfc533c + [ 139.269915] RBP: 88001b633db0 R08: 002c R09: 000a + [ 139.269915] R10: 00062180 R11: 0020759fb9dc R12: a0292c20 + [ 139.269915] R13: 88001dfc5334 R14: R15: + [ 139.269915] FS: () GS:88001fc0() knlGS: + [ 139.269915] CS: 0010 DS: ES: CR0: 8005003b + [ 139.269915] CR2: 0004 CR3: 1d29 CR4: 06f0 + [ 139.269915] DR0: DR1: DR2: + [ 139.269915] DR3: DR6: 0ff0 DR7: 0400 + [ 139.269915] Stack: + [ 139.269915] 1b633d98 0246 88001df1dc00 88001cc37a00 + [ 139.269915] 88001bc35e60 88001ffa0a48 88001bc35ee0 + [ 139.269915] 88001b633e08 a02704b5 0001 88001cc37a70 + [ 139.269915] Call Trace: + [ 139.269915] [] __rpc_execute+0x1d5/0x400 [sunrpc] + [ 139.269915] [] rpc_async_schedule+0x26/0x30 [sunrpc] + [ 139.269915] [] process_one_work+0x17b/0x460 + [ 139.269915] [] worker_thread+0x11b/0x400 + [ 139.269915] [] ? rescuer_thread+0x3e0/0x3e0 + [ 139.269915] [] kthread+0xc0/0xd0 + [ 139.269915] [] ? kthread_create_on_node+0x110/0x110 + [ 139.269915] [] ret_from_fork+0x7c/0xb0 + [ 139.269915] [] ? kthread_create_on_node+0x110/0x110 + [ 139.269915] Code: 4c 8b 45 c8 48 8d 7d d0 89 4d c4 41
[OE-core] [PATCH] lttng-modules: fix NULL pointer deference error when testing rpc_task_running
From: Quanyang Wang This fixes NULL pointer deference error when running kts testcase lttng_syscall_events. Upstream-Status: Pending Signed-off-by: Quanyang Wang --- ...ops-when-trace-sunrpc_task-events-in.patch | 93 +++ .../lttng/lttng-modules_2.10.11.bb| 1 + 2 files changed, 94 insertions(+) create mode 100644 meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch diff --git a/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch b/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch new file mode 100644 index 00..b46bf26dd4 --- /dev/null +++ b/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-SUNRPC-Fix-oops-when-trace-sunrpc_task-events-in.patch @@ -0,0 +1,93 @@ +From f79f32bffcd968748e744e273e73b6048c4668f4 Mon Sep 17 00:00:00 2001 +From: Quanyang Wang +Date: Thu, 5 Dec 2019 13:41:06 +0800 +Subject: [PATCH] Fix: SUNRPC: Fix oops when trace sunrpc_task events in nfs + client + +See upstream commit : + + commit 2ca310fc4160ed0420da65534a21ae77b24326a8 + Author: Ditang Chen + Date: Fri, 7 Mar 2014 13:27:57 +0800 + Subject: SUNRPC: Fix oops when trace sunrpc_task events in nfs client + + When tracking sunrpc_task events in nfs client, the clnt pointer may be NULL. + + [ 139.269266] BUG: unable to handle kernel NULL pointer dereference at 0004 + [ 139.269915] IP: [] ftrace_raw_event_rpc_task_running+0x86/0xf0 [sunrpc] + [ 139.269915] PGD 1d293067 PUD 1d294067 PMD 0 + [ 139.269915] Oops: [#1] SMP + [ 139.269915] Modules linked in: nfsv4 dns_resolver nfs lockd sunrpc fscache sg ppdev e1000 + serio_raw pcspkr parport_pc parport i2c_piix4 i2c_core microcode xfs libcrc32c sd_mod sr_mod + cdrom ata_generic crc_t10dif crct10dif_common pata_acpi ahci libahci ata_piix libata dm_mirror + dm_region_hash dm_log dm_mod + [ 139.269915] CPU: 0 PID: 59 Comm: kworker/0:2 Not tainted 3.10.0-84.el7.x86_64 #1 + [ 139.269915] Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006 + [ 139.269915] Workqueue: rpciod rpc_async_schedule [sunrpc] + [ 139.269915] task: 88001b598000 ti: 88001b632000 task.ti: 88001b632000 + [ 139.269915] RIP: 0010:[] [] ftrace_raw_event_rpc_task_running+0x86/0xf0 [sunrpc] + [ 139.269915] RSP: 0018:88001b633d70 EFLAGS: 00010206 + [ 139.269915] RAX: 88001dfc5338 RBX: 88001cc37a00 RCX: 88001dfc5334 + [ 139.269915] RDX: 88001dfc5338 RSI: RDI: 88001dfc533c + [ 139.269915] RBP: 88001b633db0 R08: 002c R09: 000a + [ 139.269915] R10: 00062180 R11: 0020759fb9dc R12: a0292c20 + [ 139.269915] R13: 88001dfc5334 R14: R15: + [ 139.269915] FS: () GS:88001fc0() knlGS: + [ 139.269915] CS: 0010 DS: ES: CR0: 8005003b + [ 139.269915] CR2: 0004 CR3: 1d29 CR4: 06f0 + [ 139.269915] DR0: DR1: DR2: + [ 139.269915] DR3: DR6: 0ff0 DR7: 0400 + [ 139.269915] Stack: + [ 139.269915] 1b633d98 0246 88001df1dc00 88001cc37a00 + [ 139.269915] 88001bc35e60 88001ffa0a48 88001bc35ee0 + [ 139.269915] 88001b633e08 a02704b5 0001 88001cc37a70 + [ 139.269915] Call Trace: + [ 139.269915] [] __rpc_execute+0x1d5/0x400 [sunrpc] + [ 139.269915] [] rpc_async_schedule+0x26/0x30 [sunrpc] + [ 139.269915] [] process_one_work+0x17b/0x460 + [ 139.269915] [] worker_thread+0x11b/0x400 + [ 139.269915] [] ? rescuer_thread+0x3e0/0x3e0 + [ 139.269915] [] kthread+0xc0/0xd0 + [ 139.269915] [] ? kthread_create_on_node+0x110/0x110 + [ 139.269915] [] ret_from_fork+0x7c/0xb0 + [ 139.269915] [] ? kthread_create_on_node+0x110/0x110 + [ 139.269915] Code: 4c 8b 45 c8 48 8d 7d d0 89 4d c4 41 89 c9 b9 28 00 00 00 e8 9d b4 e9 + e0 48 85 c0 49 89 c5 74 a2 48 89 c7 e8 9d 3f e9 e0 48 89 c2 <41> 8b 46 04 48 8b 7d d0 4c + 89 e9 4c 89 e6 89 42 0c 0f b7 83 d4 + [ 139.269915] RIP [] ftrace_raw_event_rpc_task_running+0x86/0xf0 [sunrpc] + [ 139.269915] RSP + [ 139.269915] CR2: 0004 + [ 140.946406] ---[ end trace ba486328b98d7622 ]--- + +Upstream-Status: Pending + +Signed-off-by: Quanyang Wang +--- + instrumentation/events/lttng-module/rpc.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/instrumentation/events/lttng-mo
[OE-core] [PATCH v2] kexec-tools: fix arm kexec failure for __NR_kexec_file_load
From: Wang Quanyang Once use kexec in arm arch, it will throw out the error info as below: Could not find a free area of memory of 0xc78e744 bytes... This is because that kexec use kexec_file_load to load image by default but arm doesn't support it. So add this patch to avoid use kexec_file_load in arm platforms. Signed-off-by: Quanyang Wang --- ...ndefine-__NR_kexec_file_load-for-arm.patch | 39 +++ .../kexec/kexec-tools_2.0.19.bb | 1 + 2 files changed, 40 insertions(+) create mode 100644 meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch diff --git a/meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch b/meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch new file mode 100644 index 00..1b11363191 --- /dev/null +++ b/meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch @@ -0,0 +1,40 @@ +From b54816eff272324320c490d62dc36b27d2838732 Mon Sep 17 00:00:00 2001 +From: Quanyang Wang +Date: Mon, 16 Sep 2019 10:49:05 +0800 +Subject: [PATCH] kexec/arm: undefine __NR_kexec_file_load for arm + +In the kernel upstream commit 4ab65ba7a5cb +("ARM: add kexec_file_load system call number"), +__NR_kexec_file_load for arm has been defined to be 401. +This results that even if kexec_file_load isn't implemented +for arm but the function is_kexec_file_load_implemented() +will still return true. So undef __NR_kexec_file_load for +arm architecture. + +Upstream-Status: Backport +[https://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git/commit/kexec/kexec-syscall.h?id=b54816eff272324320c490d62dc36b27d2838732] + +Signed-off-by: Quanyang Wang +Signed-off-by: Simon Horman +--- + kexec/kexec-syscall.h | 4 + 1 file changed, 4 insertions(+) + +diff --git a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h +index dac1c1f..92d51d3 100644 +--- a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h +@@ -56,6 +56,10 @@ + #endif + #endif /*ifndef __NR_kexec_load*/ + ++#ifdef __arm__ ++#undef __NR_kexec_file_load ++#endif ++ + #ifndef __NR_kexec_file_load + + #ifdef __x86_64__ +-- +2.17.1 + diff --git a/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb b/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb index 3439899070..c3f74359f1 100644 --- a/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb +++ b/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb @@ -18,6 +18,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz file://0003-kexec-ARM-Fix-add_buffer_phys_virt-align-issue.patch \ file://0004-x86_64-Add-support-to-build-kexec-tools-with-x32-ABI.patch \ file://0005-Disable-PIE-during-link.patch \ +file://0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch \ " SRC_URI[md5sum] = "052458f0a35c2a3b0d2302caa3318e9f" -- 2.22.0 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] kexec-tools: fix arm kexec failure for __NR_kexec_file_load
From: Wang Quanyang Once use kexec in arm arch, it will throw out the error info as below: Could not find a free area of memory of 0xc78e744 bytes... This is because that kexec use kexec_file_load to load image by default but arm doesn't support it. So add this patch to avoid use kexec_file_load in arm platforms. Signed-off-by: Quanyang Wang --- ...ndefine-__NR_kexec_file_load-for-arm.patch | 37 +++ .../kexec/kexec-tools_2.0.19.bb | 1 + 2 files changed, 38 insertions(+) create mode 100644 meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch diff --git a/meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch b/meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch new file mode 100644 index 00..1b11363191 --- /dev/null +++ b/meta/recipes-kernel/kexec/kexec-tools/0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch @@ -0,0 +1,37 @@ +From b54816eff272324320c490d62dc36b27d2838732 Mon Sep 17 00:00:00 2001 +From: Quanyang Wang +Date: Mon, 16 Sep 2019 10:49:05 +0800 +Subject: [PATCH] kexec/arm: undefine __NR_kexec_file_load for arm + +In the kernel upstream commit 4ab65ba7a5cb +("ARM: add kexec_file_load system call number"), +__NR_kexec_file_load for arm has been defined to be 401. +This results that even if kexec_file_load isn't implemented +for arm but the function is_kexec_file_load_implemented() +will still return true. So undef __NR_kexec_file_load for +arm architecture. + +Signed-off-by: Quanyang Wang +Signed-off-by: Simon Horman +--- + kexec/kexec-syscall.h | 4 + 1 file changed, 4 insertions(+) + +diff --git a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h +index dac1c1f..92d51d3 100644 +--- a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h +@@ -56,6 +56,10 @@ + #endif + #endif /*ifndef __NR_kexec_load*/ + ++#ifdef __arm__ ++#undef __NR_kexec_file_load ++#endif ++ + #ifndef __NR_kexec_file_load + + #ifdef __x86_64__ +-- +2.17.1 + diff --git a/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb b/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb index 3439899070..c3f74359f1 100644 --- a/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb +++ b/meta/recipes-kernel/kexec/kexec-tools_2.0.19.bb @@ -18,6 +18,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz file://0003-kexec-ARM-Fix-add_buffer_phys_virt-align-issue.patch \ file://0004-x86_64-Add-support-to-build-kexec-tools-with-x32-ABI.patch \ file://0005-Disable-PIE-during-link.patch \ +file://0006-kexec-arm-undefine-__NR_kexec_file_load-for-arm.patch \ " SRC_URI[md5sum] = "052458f0a35c2a3b0d2302caa3318e9f" -- 2.22.0 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] weston-init: run login before start weston.service
From: Wang Quanyang When systemd start the weston.service, the script "weston-start" will check if the dir "XDG_RUNTIME_DIR" (usually is /run/user/0) exits and create it. Then weston will create a socket file "wayland-0" for communications with clients in this dir. If systemd is built with enabling "pam" feature, the login will call "run-user-0.mount" to mount tmpfs at the dir "/run/user/0", then the socket file "wayland-0" will be missing since it is created in the old "/run/user/0". So add "PAMName=login" to let weston.service call login first, once tmpfs is mounted at "/run/user/0", then call weston-start to create a socket file in it. Signed-off-by: Quanyang Wang --- meta/recipes-graphics/wayland/weston-init/weston.service | 1 + 1 file changed, 1 insertion(+) diff --git a/meta/recipes-graphics/wayland/weston-init/weston.service b/meta/recipes-graphics/wayland/weston-init/weston.service index 689ce41..18f7262 100644 --- a/meta/recipes-graphics/wayland/weston-init/weston.service +++ b/meta/recipes-graphics/wayland/weston-init/weston.service @@ -4,6 +4,7 @@ RequiresMountsFor=/run [Service] User=root +PAMName=login EnvironmentFile=-/etc/default/weston ExecStart=/usr/bin/weston-start -v -e -- $OPTARGS -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core