* [PATCH 1/2] readyfd2sd: add recipe @ 2026-07-02 18:20 Lucas Stach 2026-07-02 18:20 ` [PATCH 2/2] seatd: use readyfd2sd to get rid of systemd service startup races Lucas Stach 2026-07-05 8:21 ` [OE-core] [PATCH 1/2] readyfd2sd: add recipe Mathieu Dubois-Briand 0 siblings, 2 replies; 3+ messages in thread From: Lucas Stach @ 2026-07-02 18:20 UTC (permalink / raw) To: openembedded-core; +Cc: yocto Some services, such as seatd, only implement the s6 init ready notifications. readyfd2sd translates those notifications to the systemd-notify format, to make them usable with the systemd init system. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> --- meta/recipes-core/readyfd2sd/readyfd2sd_git.bb | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 meta/recipes-core/readyfd2sd/readyfd2sd_git.bb diff --git a/meta/recipes-core/readyfd2sd/readyfd2sd_git.bb b/meta/recipes-core/readyfd2sd/readyfd2sd_git.bb new file mode 100644 index 000000000000..5d4b23212d3a --- /dev/null +++ b/meta/recipes-core/readyfd2sd/readyfd2sd_git.bb @@ -0,0 +1,14 @@ +SUMMARY = "s6 readyfd to systemd sd_notify adapter" +HOMEPAGE = "https://git.sr.ht/~kennylevinsen/readyfd2sd" +DESCRIPTION = "${SUMMARY}" +SECTION = "base" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=c50481d620cb912754d78d319eeec30a" + +DEPENDS = "systemd" + +PV = "0.1+git" +SRC_URI = "git://git.sr.ht/~kennylevinsen/readyfd2sd;protocol=https;branch=master" +SRCREV = "87c99ce10dca3f3c3e5c3a0d994ee7892e952b61" + +inherit meson pkgconfig systemd -- 2.47.3 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] seatd: use readyfd2sd to get rid of systemd service startup races 2026-07-02 18:20 [PATCH 1/2] readyfd2sd: add recipe Lucas Stach @ 2026-07-02 18:20 ` Lucas Stach 2026-07-05 8:21 ` [OE-core] [PATCH 1/2] readyfd2sd: add recipe Mathieu Dubois-Briand 1 sibling, 0 replies; 3+ messages in thread From: Lucas Stach @ 2026-07-02 18:20 UTC (permalink / raw) To: openembedded-core; +Cc: yocto Currently systemd has no insight into the startup state of the seatd server process, so it might start dependant services too early, causing them to fail due to being unable to connect to seatd. Use the readyfd2sd adapter to convert the seatd s6 ready notification to systemd-notify and switch the service to the notify type to allow systemd to defer dependant service startup until seatd is ready to accept requests. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> --- ...yfd2sd-to-notify-systemd-about-servi.patch | 34 +++++++++++++++++++ meta/recipes-core/seatd/seatd_0.9.3.bb | 3 +- 2 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-core/seatd/seatd/0001-systemd-use-readyfd2sd-to-notify-systemd-about-servi.patch diff --git a/meta/recipes-core/seatd/seatd/0001-systemd-use-readyfd2sd-to-notify-systemd-about-servi.patch b/meta/recipes-core/seatd/seatd/0001-systemd-use-readyfd2sd-to-notify-systemd-about-servi.patch new file mode 100644 index 000000000000..59b880bb6f13 --- /dev/null +++ b/meta/recipes-core/seatd/seatd/0001-systemd-use-readyfd2sd-to-notify-systemd-about-servi.patch @@ -0,0 +1,34 @@ +From b4aa488bd43577ebbf4df5eb1272c724b32bffa9 Mon Sep 17 00:00:00 2001 +From: Lucas Stach <l.stach@pengutronix.de> +Date: Fri, 7 Nov 2025 21:37:01 +0100 +Subject: [PATCH] systemd: use readyfd2sd to notify systemd about service + startup + +Currently the example systemd service is racy, as systemd has no insight +into the startup state of the seatd process. Use the readyfd2sd adapter +in the service file to let systemd know when seatd is operational. + +Upstream-Status: Submitted [https://lists.sr.ht/~kennylevinsen/seatd-devel/patches/70377] +--- + contrib/systemd/seatd.service | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/contrib/systemd/seatd.service b/contrib/systemd/seatd.service +index 0460e9e20644..d0b45933b463 100644 +--- a/contrib/systemd/seatd.service ++++ b/contrib/systemd/seatd.service +@@ -3,9 +3,9 @@ Description=Seat management daemon + Documentation=man:seatd(1) + + [Service] +-Type=simple ++Type=notify + # Specify the group you'd like to grant access to seatd +-ExecStart=seatd -g seat ++ExecStart=readyfd2sd -- seatd -g seat -n %%n + Restart=always + RestartSec=1 + +-- +2.47.3 + diff --git a/meta/recipes-core/seatd/seatd_0.9.3.bb b/meta/recipes-core/seatd/seatd_0.9.3.bb index d0802eee6041..304f72ab0846 100644 --- a/meta/recipes-core/seatd/seatd_0.9.3.bb +++ b/meta/recipes-core/seatd/seatd_0.9.3.bb @@ -7,6 +7,7 @@ LICENSE = "MIT" LIC_FILES_CHKSUM = "file://LICENSE;md5=715a99d2dd552e6188e74d4ed2914d5a" SRC_URI = "git://git.sr.ht/~kennylevinsen/seatd;protocol=https;branch=master \ + file://0001-systemd-use-readyfd2sd-to-notify-systemd-about-servi.patch \ file://init" SRCREV = "daa8196e10b180b8b0caeafa8e5f860eb1bd6706" @@ -29,7 +30,7 @@ PACKAGECONFIG ?= " \ " PACKAGECONFIG[libseat-builtin] = "-Dlibseat-builtin=enabled,-Dlibseat-builtin=disabled" -PACKAGECONFIG[systemd] = "-Dlibseat-logind=systemd,,systemd" +PACKAGECONFIG[systemd] = "-Dlibseat-logind=systemd,,systemd,readyfd2sd" do_install:append() { if [ "${VIRTUAL-RUNTIME_init_manager}" != "systemd" ]; then -- 2.47.3 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [OE-core] [PATCH 1/2] readyfd2sd: add recipe 2026-07-02 18:20 [PATCH 1/2] readyfd2sd: add recipe Lucas Stach 2026-07-02 18:20 ` [PATCH 2/2] seatd: use readyfd2sd to get rid of systemd service startup races Lucas Stach @ 2026-07-05 8:21 ` Mathieu Dubois-Briand 1 sibling, 0 replies; 3+ messages in thread From: Mathieu Dubois-Briand @ 2026-07-05 8:21 UTC (permalink / raw) To: Lucas Stach, openembedded-core; +Cc: yocto On Thu Jul 2, 2026 at 8:20 PM CEST, Lucas Stach wrote: > Some services, such as seatd, only implement the s6 init ready notifications. > readyfd2sd translates those notifications to the systemd-notify format, to > make them usable with the systemd init system. > > Signed-off-by: Lucas Stach <l.stach@pengutronix.de> > --- Hi Lucas, Thanks for your patch. It looks like this is failing with non-systemd distro. WARNING: Nothing PROVIDES 'systemd' (but /srv/pokybuild/yocto-worker/qemuarm64-armhost/build/layers/openembedded-core/meta/recipes-core/readyfd2sd/readyfd2sd_git.bb DEPENDS on or otherwise requires it) systemd was skipped: using DISTRO 'poky', which is missing required DISTRO_FEATURES: 'systemd usrmerge' https://autobuilder.yoctoproject.org/valkyrie/#/builders/8/builds/4108 https://autobuilder.yoctoproject.org/valkyrie/#/builders/6/builds/4095 https://autobuilder.yoctoproject.org/valkyrie/#/builders/3/builds/4133 https://autobuilder.yoctoproject.org/valkyrie/#/builders/37/builds/4314 https://autobuilder.yoctoproject.org/valkyrie/#/builders/59/builds/4097 Can eadyfd2sd be built without systemd? Also, please add the corresponding entry in meta/conf/distro/include/maintainers.inc. Thanks, Mathieu -- Mathieu Dubois-Briand, Bootlin Embedded Linux and Kernel engineering https://bootlin.com ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-07-05 8:21 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2026-07-02 18:20 [PATCH 1/2] readyfd2sd: add recipe Lucas Stach 2026-07-02 18:20 ` [PATCH 2/2] seatd: use readyfd2sd to get rid of systemd service startup races Lucas Stach 2026-07-05 8:21 ` [OE-core] [PATCH 1/2] readyfd2sd: add recipe Mathieu Dubois-Briand
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox