Commit Graph
85347 Commits
Author SHA1 Message Date
Zbigniew Jędrzejewski-Szmek 54492552a1 meson: allow .standalone version to be always built
Allow .standalone version to be built on-demand, even if -Dstandalone=false
is configured. In other words, this changes the meson option from a hard
disablement to a soft "build is on/off by default".

The meson config was originally written in this way but we lost this feature
after the transition to templates. It is nice to build additional targets on
demand during development, so add this back.
2025-12-19 13:14:19 +01:00
Zbigniew Jędrzejewski-Szmek 9e104bd3aa meson: put src/import source lists directly in templates
The indirection through variables doesn't seem that useful here:
OTOH, the lists are short, and OTOH, there is a bunch of different
programs with similar names. Overall, it's all easier to follow if
the lists are inline.
2025-12-19 13:12:35 +01:00
Luca Boccassi 9ca433482f Finalize meson.version for v259 2025-12-17 23:02:36 +00:00
Luca Boccassi b262ded0bd Boot loader menu docs and tweaks (#39842) 2025-12-17 23:00:59 +00:00
Zbigniew Jędrzejewski-Szmek 3cdd80d3e0 sd-boot: correct typos 2025-12-17 22:55:38 +01:00
Zbigniew Jędrzejewski-Szmek 221a33c412 TODO: remove resolved entry
Done in https://github.com/uapi-group/specifications/commit/677b722bb8b84625b68162ba201c8461497f9585.
2025-12-17 22:55:38 +01:00
Zbigniew Jędrzejewski-Szmek 755637b04a docs/BLI: add missing descriptions of feature bits
Follow up for 2553a5482c,
92bb46c464,
e15d18b4c6,
a67f22c4a7,
e1f1b5fc62.
2025-12-17 22:55:38 +01:00
Zbigniew Jędrzejewski-Szmek 3e2b026da3 man/systemd-boot: say that /EFI/systemd/drivers is for hardware
In aad0d11e7c we stopped supporting XBOOTLDR
with a different fs driver. This was the primary example that comes to mind
when we talk about loading filesystem drivers in the firmware. Since we don't
want people to do load such drivers, use a different example.
2025-12-17 22:55:38 +01:00
Zbigniew Jędrzejewski-Szmek 1228429908 docs/BOOT_LOADER_INTERFACE: use full variable names once
We said in the header that "all EFI variables use the vendor UUID
4a67b082-0a4c-41cf-b6c7-440b29bb8c4f", but people not familiar with
UEFI might not know that this is concatenated with the variable name.
Let's use the full form once — when introducing the variable — to
make it easier to grep and search for.

While at it, use sembreaks in the document. This makes subsequent
changes much easier to review. (It also shows that some sentences
are rather long and thus hard to understand.)
2025-12-17 22:55:23 +01:00
Luca Boccassi 676c098d0a Chores for v259 (#40120) 2025-12-17 18:39:40 +00:00
Luca Boccassi cf0d7f8330 NEWS: finalize 2025-12-17 13:35:38 +00:00
Luca Boccassi f1a862a26d NEWS: update contributors list 2025-12-17 13:34:57 +00:00
Luca Boccassi 28c5929e90 Update syscalls table
ninja -C build update-syscall-tables update-syscall-header
2025-12-17 13:33:26 +00:00
Luca Boccassi d2e4162b51 Update hwdb
ninja -C build update-hwdb
2025-12-17 13:32:00 +00:00
QuickSwift315490 f9425092c6 hwdb: fix unstable button triggering on Mipad 2 under GNOME (#40071)
Change unknown key mappings to reserved.

A KEY_RESERVED button is marked as reserved and passed to the kernel. This will stop the kernel from passing this keystroke event to user space.

If unknown, the key is set to KEY_UNKNOWN and the event is passed to user space, which we want to avoid.
2025-12-17 13:26:47 +00:00
Haiyue Wang 568fe0294d meson: fix BPF build warnings due to MS extensions
Fix BPF program build warnings on Linux-6.19.0-rc1, more detail is [1]:

A). clang-bpf

[781/2458] Generating src/network/bpf/sysctl-monitor/sysctl-monitor.bpf.unstripped.o with a custom command
In file included from ../src/network/bpf/sysctl-monitor/sysctl-monitor.bpf.c:3:
./vmlinux.h:60263:3: warning: declaration does not declare anything [-Wmissing-declarations]
 60263 |                 struct ns_tree;
       |                 ^~~~~~~~~~~~~~
./vmlinux.h:80251:2: warning: declaration does not declare anything [-Wmissing-declarations]
 80251 |         struct __fs_path;
       |         ^~~~~~~~~~~~~~~~
./vmlinux.h:96184:2: warning: declaration does not declare anything [-Wmissing-declarations]
 96184 |         struct freelist_tid;
       |         ^~~~~~~~~~~~~~~~~~~
./vmlinux.h:114441:2: warning: declaration does not declare anything [-Wmissing-declarations]
 114441 |         struct renamedata;
        |         ^~~~~~~~~~~~~~~~~
./vmlinux.h:118480:2: warning: declaration does not declare anything [-Wmissing-declarations]
 118480 |         union pipe_index;
        |         ^~~~~~~~~~~~~~~~
./vmlinux.h:130452:4: warning: declaration does not declare anything [-Wmissing-declarations]
 130452 |                         struct freelist_counters;
        |                         ^~~~~~~~~~~~~~~~~~~~~~~~
6 warnings generated.

B). gcc-bpf

meson setup -Dbpf-compiler=gcc build

[1040/2458] Generating src/network/bpf/sysctl-monitor/sysctl-monitor.bpf.unstripped.o with a custom command
In file included from ../src/network/bpf/sysctl-monitor/sysctl-monitor.bpf.c:3:
./vmlinux.h:60263:31: warning: declaration does not declare anything
60263 |                 struct ns_tree;
      |                               ^
./vmlinux.h:80251:25: warning: declaration does not declare anything
80251 |         struct __fs_path;
      |                         ^
./vmlinux.h:96184:28: warning: declaration does not declare anything
96184 |         struct freelist_tid;
      |                            ^
./vmlinux.h:114441:26: warning: declaration does not declare anything
114441 |         struct renamedata;
       |                          ^
./vmlinux.h:118480:25: warning: declaration does not declare anything
118480 |         union pipe_index;
       |                         ^
./vmlinux.h:130452:49: warning: declaration does not declare anything
130452 |                         struct freelist_counters;
       |                                                 ^

[1] https://git.kernel.org/torvalds/c/639f58a0f480
    "bpftool: Fix build warnings due to MS extensions"

Signed-off-by: Haiyue Wang <haiyuewa@163.com>
2025-12-17 12:58:33 +00:00
Andrew Halaney 0927356f8e man/systemd.exec: Make EnvironmentFile error conditions more explicit
It is not entirely clear what happens when EnvironmentFile fails in the
prior wording. With the new wording it should now be clear that if it
fails to process the file the service will fail, and if it is prefixed
with "-" all errors are silently ignored.

Signed-off-by: Andrew Halaney <ahalaney@netflix.com>
2025-12-17 11:56:52 +01:00
Luca Boccassi 8fba2ed258 test: fix race condition in TEST-80-NOTIFYACCESS
In some cases systemd is faster to send the SIGHUP
than the script is to start the 'sleep' and background
it, so it never gets interrupted later and the test
is left hanging waiting for it.

[ 5028.410588] systemd[1]: Starting reload-timeout.service...
[ 5028.429544] reload-timeout.sh[165]: + set -o pipefail
[ 5028.429544] reload-timeout.sh[165]: + COUNTER=0
[ 5028.429841] reload-timeout.sh[165]: + trap sighup_handler SIGHUP
[ 5028.429841] reload-timeout.sh[165]: + export SYSTEMD_LOG_LEVEL=debug
[ 5028.429841] reload-timeout.sh[165]: + SYSTEMD_LOG_LEVEL=debug
[ 5028.429841] reload-timeout.sh[165]: + systemd-notify --ready
[ 5028.432891] systemd[1]: reload-timeout.service: Got notification message from PID 165: READY=1
[ 5028.432908] systemd[1]: reload-timeout.service: Changed start -> running
[ 5028.432983] systemd[1]: reload-timeout.service: Job 409 reload-timeout.service/start finished, result=done
[ 5028.432997] systemd[1]: Started reload-timeout.service.
[ 5028.433941] TEST-80-NOTIFYACCESS.sh[164]: Job for reload-timeout.service finished.
[ 5028.433941] TEST-80-NOTIFYACCESS.sh[164]: Got result done/Success for job reload-timeout.service.
[ 5028.433941] TEST-80-NOTIFYACCESS.sh[164]: Bus n/a: changing state RUNNING → CLOSED
[ 5028.436949] TEST-80-NOTIFYACCESS.sh[99]: + systemctl reload --no-block reload-timeout.service
[ 5028.444523] TEST-80-NOTIFYACCESS.sh[167]: Bus n/a: changing state UNSET → OPENING
[ 5028.444523] TEST-80-NOTIFYACCESS.sh[167]: sd-bus: starting bus by connecting to /run/systemd/private...
[ 5028.444523] TEST-80-NOTIFYACCESS.sh[167]: Bus n/a: changing state OPENING → AUTHENTICATING
[ 5028.444523] TEST-80-NOTIFYACCESS.sh[167]: Executing dbus call org.freedesktop.systemd1.Manager ReloadUnit(reload-timeout.service, replace)
[ 5028.444523] TEST-80-NOTIFYACCESS.sh[167]: Bus n/a: changing state AUTHENTICATING → RUNNING
[ 5028.445202] reload-timeout.sh[165]: + wait_for_signal
[ 5028.445586] reload-timeout.sh[169]: + sleep infinity
[ 5028.447285] reload-timeout.sh[165]: ++ sighup_handler
[ 5028.447285] reload-timeout.sh[165]: ++ echo hup1
[ 5028.444886] systemd[1]: reload-timeout.service: Trying to enqueue job reload-timeout.service/reload/replace
[ 5028.445228] systemd[1]: reload-timeout.service: Installed new job reload-timeout.service/reload as 491
[ 5028.445240] systemd[1]: reload-timeout.service: Enqueued job reload-timeout.service/reload as 491
[ 5028.446601] systemd[1]: reload-timeout.service: Service has no extensions to reload.
[ 5028.446799] systemd[1]: reload-timeout.service: Changed running -> reload-signal
[ 5028.446881] systemd[1]: Reloading reload-timeout.service...
[ 5028.451343] TEST-80-NOTIFYACCESS.sh[167]: Bus n/a: changing state RUNNING → CLOSED
[ 5028.452421] TEST-80-NOTIFYACCESS.sh[99]: + timeout 10 bash -c 'until [[ $(systemctl show reload-timeout.service -P SubState) == "reload-signal" ]]; do sleep .5; done'
[ 5028.460676] TEST-80-NOTIFYACCESS.sh[172]: Bus n/a: changing state UNSET → OPENING
[ 5028.460676] TEST-80-NOTIFYACCESS.sh[172]: sd-bus: starting bus by connecting to /run/systemd/private...
[ 5028.462029] TEST-80-NOTIFYACCESS.sh[172]: Bus n/a: changing state OPENING → AUTHENTICATING
[ 5028.462029] TEST-80-NOTIFYACCESS.sh[172]: Showing one /org/freedesktop/systemd1/unit/reload_2dtimeout_2eservice
[ 5028.463759] TEST-80-NOTIFYACCESS.sh[172]: Bus n/a: changing state AUTHENTICATING → RUNNING
[ 5028.470322] TEST-80-NOTIFYACCESS.sh[172]: Bus n/a: changing state RUNNING → CLOSED
[ 5028.472991] TEST-80-NOTIFYACCESS.sh[99]: + sync_in hup1
[ 5028.472991] TEST-80-NOTIFYACCESS.sh[99]: + read -r x
[ 5028.473839] reload-timeout.sh[165]: + wait 169
[ 5028.473996] TEST-80-NOTIFYACCESS.sh[99]: + test hup1 = hup1
[ 5028.473996] TEST-80-NOTIFYACCESS.sh[99]: + timeout 10 bash -c 'until [[ $(systemctl show reload-timeout.service -P SubState) == "reload-notify" ]]; do sleep .5; done'
[ 5038.477383] systemd[1]: TEST-80-NOTIFYACCESS.service: Failed with result 'exit-code'.

(note how the 'wait' is long after SIGHUP has been processed already)

Fixes https://github.com/systemd/systemd/issues/39581

Follow-up for ca8658120e
2025-12-17 18:41:59 +09:00
Yu Watanabe b6abe84602 core: fix extensions refreshing (dlopen() shenanigans) (#40112) 2025-12-17 18:41:23 +09:00
Vivian Wang 2e8985113b stub: Use log_debug if addons has no applicable sections
This can happen expectedly if an addon purely provides .dtbauto
sections, and there's no match for this machine. Reduce the log message
of this case to "debug" level.
2025-12-17 18:37:49 +09:00
Priit Jõerüüt b5a920cee1 po: Translated using Weblate (Estonian)
Currently translated at 91.6% (242 of 264 strings)

Co-authored-by: Priit Jõerüüt <jrtkbfdr@users.noreply.translate.fedoraproject.org>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/et/
Translation: systemd/main
2025-12-17 14:21:20 +09:00
Mike Yuan 5a2340aeb3 core/exec-credential: fix credentials plain dir exchanging (#40108)
Follow-ups for #39637

Split out from #40093
2025-12-17 00:25:11 +01:00
Mike Yuan 4d136f1462 core: dlopen() libcryptsetup in extensions refreshing
Follow-up for a08f2ea02d

This fixes extensions refreshing + verity-protected DDIs.
TEST-50-DISSECT previously passed because confext refreshing
is tested after live mount, the latter of which used to
load libcryptsetup in pid1.
2025-12-16 22:11:45 +01:00
Yu Watanabe 650fc62526 TEST-70-TPM2: re-enable tpm2-setup test on Alpine/postmarketOS
After 64b5c5f593, the test passes on
Alpine/postmarketOS.

This partially reverts 9fafe89bcc.
2025-12-16 21:10:12 +00:00
Mike Yuan 12df39fadf core/service: defer cryptsetup dlopen to helper process
This should still be safe, as we block dlopen() in namespace_fork().

Partially reverts 9252e26f4c.
2025-12-16 21:57:37 +01:00
Mike Yuan 8f397d5922 core/unit: add unit_fork_helper_process_full() that takes ForkFlags 2025-12-16 21:30:36 +01:00
Mike Yuan 3602308480 TEST-54-CREDS: add test case for #40108 2025-12-16 21:28:19 +01:00
Mike Yuan 6c1bcdd614 core/exec-credential: fix credentials plain dir exchanging
Follow-up for d796c6b7c6

rename() may yield ENOTEMPTY rather than EEXIST for existing dir,
so catch that too. Also, both the source and target must be
writable when exchanging.

Test coverage for this logic (i.e. user units with ExecStartPre=)
will be added later.
2025-12-16 21:25:51 +01:00
Mike Yuan 29a823b3b6 process-util: add a flag for retaining dlopen()-ability
While blocking dlopen() in child generally makes sense, it does
also lead to misery - in the very case of extension/cred refreshing
it then enforces loading of libcryptsetup/libacl in pid1, which
are otherwise never used. Let's add a flag to opt out hence, but
still prohibit it in namespace_fork/enter().
2025-12-16 21:07:20 +01:00
Mike Yuan 5188da568c acl-util: systematically fall back to fchmod() if acl is not available
Same as 2a64b56da4, but for
fd_acl_make_writable().

While at it, un-export fd_acl_make_{read_only,writable}_fallback(),
instead apply ifdeffery in .c
2025-12-16 20:16:58 +01:00
Mike Yuan 4abf7ee02e Revert "acl-util: drop now unused fd_acl_make_writable()"
This reverts commit 4175cd4f40.

It turned out that we still need this. Preparation for later commits.
2025-12-16 20:16:57 +01:00
Mike Yuan e6e001cdd4 acl-util: treat pointer type as a whole
Follow-up for 4976d6e9ac
2025-12-16 20:16:57 +01:00
Mike Yuan 552822992c core/service: do not honor SuccessExitStatus= for our own helpers
They're exclusively under our control, hence errors should not be
suppressed based on external user input.
2025-12-17 04:04:02 +09:00
Luca Boccassi c78d18096d mkosi: drop gh from mkosi-tools debian/ubuntu
It was removed from testing so building images fails
2025-12-16 17:54:15 +00:00
Luca Boccassi 830275f343 mkosi: update mkosi commit reference to 9e31235211d975bae25622d6205a8396d104335e
* 9e31235211 pacman: Make sure hookdir exists
* 20009b7f48 make_image: log systemd-repart *.conf files at the --debug level
* b94b415db9 run: Increase string limit for strace when debugging sandbox
* 9f6d9405d6 Ring the terminal bell after the last image has been built
* b509b4246d Add glob in default initrd to exclude some exotic drivers
* 189394b8b9 Allow KernelModules= globs to also match relative to modules root dir
* 92bd086e4e zypper: add --force-resolution flag
* 3637749702 kmod: Only add fully resolved fw path if it exists
* d41ac276c9 Add details to KernelModulesInitrd= doc
* 1b6960ddb1 Fix SplitArtifacts=repart-definitions for addons
* 07464f38d6 Add log_step call in build_kernel_modules_initrd
* 18f5885362 Use proper constants for ansi colors
* 454c1602b6 mkosi-obs: add SplitArtifacts=repart-definitions and use it
* 9e57461af6 Copy repart definitions to staging directory
* 1acab18874 Add SplitArtifacts=repart-definitions
* c5c5c225e8 mkosi-obs: always include verity certificate
* ac5babb8e0 Revert "Use Path.relative_to instead of Path.parts"
* cbb1daeb76 action: Use environment variables instead of inputs
* 97c81eef72 portable: support split roothash
2025-12-16 15:59:02 +00:00
Lennart Poettering 200f792b3e tpm2-util: create leading dirs for anchor secret
Fixes #40087
2025-12-16 22:28:10 +09:00
Lennart Poettering 64b5c5f593 test: prefer tests with PCR 16 over PCR 11
PCR 16 is intended for debugging purposes, and is the only PCR that can
be reset by software. Let's prefer that for testing.

PCR 11 has a purpose (i.e. kernel is measured there on UKI systems, as
are the boot phases), hence let's not use that for testing.

That should remove any interference of boot time ordering and testing
our tpm code, as we will write to PCR 16 only, and reset it before we
rely on it.

This likely, kind of fixes #39582, but the issue mixes two things, PCR
11 issues on real-life hardware, and PCR 11 isues in our artificial
tests. Only the latter is addressed by this PR, the other issue needs
more debugging, but without logs we cannot do much.
2025-12-16 22:28:10 +09:00
Zbigniew Jędrzejewski-Szmek 3310f979f8 Sync kernel headers and add GUEST_MEMFD_MAGIC (#40104) 2025-12-16 14:04:03 +01:00
Mike Yuan 4f25248b6e core/service: set unit log context in helper processes that bypass cgroup
Since these helper processes aren't spawned in the unit cgroup,
let's explicitly attach unit log context so that all logging gets
attributed to the unit, including the ones done in library calls.
2025-12-16 12:49:06 +01:00
Luca Boccassi f9a6c04d14 basic: add GUEST_MEMFD_MAGIC from 6.19
1/1815 systemd:kernel-filesystem-magics FAIL 0.05s exit status 1
――――――――――――――――――――――――――――――――――――― ✀  ―――――――――――――――――――
stderr:
kernel knows additional filesystem magics: GUEST_MEMFD_MAGIC
2025-12-16 11:44:43 +00:00
Luca Boccassi e20e9d2968 include: update kernel headers from v6.19~rc1 2025-12-16 11:43:29 +00:00
Mike Yuan fd99348353 bus-unit-util: ReloadSignal is a Service property
Follow-up for c133545430
2025-12-16 10:37:09 +01:00
Luca Boccassi 6066106b3c ci: remove --quiet from mkosi integration suite run
Given the integration tests take a while to run, it is useful to see
at which point it is while it is running. Sometimes only a test
script or such subset is changed, which means there's no need to
wait for the entire suite to run, especially with the sanitizers
job which is super slow.

Partially reverts 9848f56cc6
2025-12-16 09:11:06 +01:00
Luca Boccassi b5032cf979 Translations update from Fedora Weblate (#40097)
Translations update from [Fedora
Weblate](https://translate.fedoraproject.org) for
[systemd/main](https://translate.fedoraproject.org/projects/systemd/main/).



Current translation status:

![Weblate translation
status](https://translate.fedoraproject.org/widget/systemd/main/horizontal-auto.svg)
2025-12-15 20:51:04 +00:00
Priit Jõerüüt eb307eebb0 po: Translated using Weblate (Estonian)
Currently translated at 90.1% (238 of 264 strings)

Co-authored-by: Priit Jõerüüt <jrtkbfdr@users.noreply.translate.fedoraproject.org>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/et/
Translation: systemd/main
2025-12-15 19:58:24 +00:00
Henri Aunin 56ae796774 po: Translated using Weblate (Estonian)
Currently translated at 90.1% (238 of 264 strings)

Co-authored-by: Henri Aunin <contact+fedora@hen.ee>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/et/
Translation: systemd/main
2025-12-15 19:58:23 +00:00
Nick Rosbrook 39d3f63782 mkosi: use qemu from noble-proposed instead of ppa
This is also temporary, but demonstrates that the version of qemu
currently in noble-proposed fixes https://launchpad.net/bugs/2127974,
which will ultimately allow for the fix to be released to noble-updates.
2025-12-15 19:16:57 +00:00
Yu Watanabe fd2cdadc14 integration-test: check tools distribution rather than image distribution
The tools and image distributions may be different.

This also fixes invalid escape sequence.

Follow-up for 9b42cc3b12.
2025-12-15 23:11:47 +09:00
Yu Watanabe 2960889a2c mount-util: fix typo
Follow-up for 273c6bc045.
2025-12-15 11:20:29 +09:00
Yu Watanabe 82e3f6c5f9 sysext: Fix config file section docs and --root= (#40063) 2025-12-15 09:45:29 +09:00