Commit Graph
85681 Commits
Author SHA1 Message Date
Daan De Meyer 2e51ed7fcb sd-varlink: Add SD_VARLINK_ANY
This allows representing fields that can be either an integer or
a string, like the "value" field we'll be adding in
https://github.com/systemd/systemd/pull/39202.

Upstream spec change: https://github.com/varlink/varlink.github.io/pull/43
2026-01-16 14:32:43 +01:00
Zbigniew Jędrzejewski-Szmek 3a5b37e162 Split up the giant switch statement in homectl's parse_argv (#40059)
This is in preparation for later changes. The 1500+ line switch statement was very
hard to work with and had quite a bit of duplicated code. This is a rework that
splits outs parts into functions. I split this up into a bunch of commits so that it
can be reasonably reviewed. When viewed as one giant commit, diff just shows
a giant block of removed code and a giant block of added code.

In some cases I wasn't sure why one or the other of the identity arrays is used…
I preserved existing behaviour in all cases.
2026-01-16 14:31:08 +01:00
Luca Boccassi 1bbeb78ea2 manager: add EnqueueMarkedJobs varlink method
Same as the D-Bus method. Returns array of job IDs.
2026-01-16 12:45:48 +00:00
Daan De Meyer 3fa3a4fd15 vpick: Fix pick_filter_image_any
Currently, pick_filter_image_any matches any image
with any suffix, which is way more than it should
be doing. It should only be matching images with
the .raw suffix.

Let's address this shortcoming by allowing to pass
multiple filters to path_pick(), and define
pick_filter_image_any as the combination of the
raw and directory image filters.

Fixes #40083
2026-01-16 13:07:47 +01:00
Michael Vogt 3f958812fd sd-boot: allow setting the timeout via SMBIOS 11
Allow configuring the menu timeout used by sd-boot by setting
`io.systemd.boot.timeout=<value>` as SMBIOS type 11 string.

This takes precedence over the setting from the config file
and the EFI var.

Useful for e.g. integration tests that want to control that
a generic image boots faster.
2026-01-16 10:26:48 +01:00
Mike Yuan 5119063196 tree-wide: lock in all memory pages when mlockall() is utilized, and on demand
When employing MCL_FUTURE we don't actually want it to impose
immediate population of malloc()-ed pages. Hence let's set
MCL_ONFAULT everywhere.

Additionally, specify MCL_CURRENT to ensure future memory allocations
on already mapped pages are covered too. (Addresses
https://github.com/systemd/systemd/pull/40319#discussion_r2693726196)

Note that in shutdown the mlockall() is done to avoid keeping swap space
busy, hence a dedicated call w/ MCL_CURRENT and w/o MCL_ONFAULT is made.
2026-01-15 13:56:34 +01:00
Michal Sekletar bcbf80c43d core: only activate transaction that contain useful jobs
If no real jobs were added to the transaction, do not activate it.
The JOB_NOP anchor does not perform any useful work and activating
such transaction only wastes resources.

Fixes #9751
2026-01-15 12:53:50 +01:00
Zbigniew Jędrzejewski-Szmek 311fddcd8d man/systemd.service: Expand docs on RestartSteps (#40309) 2026-01-15 11:41:17 +01:00
Mike Yuan 1d69e36c44 boot/initrd: fix typo
Follow-up for 80ab99d4d2
2026-01-15 11:36:13 +01:00
Dirk Su 1ef107cb22 hwdb: add HP EliteBoard Mic mute key mapping 2026-01-15 11:34:14 +01:00
Lennart Poettering 80ab99d4d2 efi: use 'struct iovec' more, pass initrds down with it 2026-01-15 11:32:33 +01:00
Zbigniew Jędrzejewski-Szmek f7047b8c1c mailmap: deduplicate some frequent contributors 2026-01-14 17:07:18 +01:00
DaanDeMeyer 90e80b9e8b docs: Document practice of using comments for argument names 2026-01-14 16:52:58 +01:00
Yu Watanabe 18de7dd90f integration tests: do not adjust log level of udevd in the test script
Similar to 5c60d3011f, but for udevd.
2026-01-14 16:32:38 +01:00
Yu Watanabe 04f05d9bd7 network: drop fallback logic for kernel older than v5.6
Now our baseline is kernel v5.10.
2026-01-14 16:31:12 +01:00
Zbigniew Jędrzejewski-Szmek 6e78240e64 udev: silence notification failures (#40275)
Closes #39943.
2026-01-14 16:26:00 +01:00
Michael Vogt b6eabd21ea man: fix copy/paste issue in systemd-vmspawn.xml
The systemd-vmspawn man page has a note that the `--notify-ready`
defaults to "true" and then says that this is unlike "systemd-vmspawn"
where it defaults to "false". This appears to be a copy/paste issue
and here we want "unlike systemd-nspawn".
2026-01-14 17:15:20 +09:00
Christian Hesse d1bd940deb man: drop duplicate "the" 2026-01-14 10:14:31 +09:00
Zbigniew Jędrzejewski-Szmek f2c3ef9678 homectl: add argument comments 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek edd2a2a006 homectl: let drop_from_identity take multiple args
The only functional change should be that we deduplicate arg_identity_filter.
2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 37ad119451 homectl: trivial simplification 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek ed646a8d47 homectl: split out helpers parse_uid_field
Yet another very similar function, but without generics it's hard to deduplicate
those.
2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 47f631fda5 homectl: split out helpers parse_{fido2_device,pkcs11_token_uri}_field
Both implement the 'list' verb.
2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek b078b7f055 homectl: split out helper parse_tmpfs_limit_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 3f9c133922 homectl: split out helper parse_capability_set_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 0c2199b4cc homectl: split out helper parse_rebalance_weight 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek a161867b00 homectl: split out helper parse_auto_resize_mode_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek ed93b1ed14 homectl: split out helpers parse_{time,timestamp}_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 316e9887f2 homectl: split out helper parse_group_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 65cf26c72d homectl: split out helper parse_weight_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 12771c0cc6 homectl: split out helpers parse_{disk,sector}_size_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 873d38eac9 homectl: split out helper parse_language_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 0126bebccb homectl: split out helper parse_environment_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 47749fa762 homectl: split out helper parse_rlimit_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 2ef165ba1c homectl: fix confusion between "FOO" and "RLIMIT_FOO" as json keys
We parse RLIMIT_FOO, FOO, and LimitFOO all the same. But the keys in the
JSON dict are supposed to be "RLIMIT_FOO". We were creating such keys,
but then filtering them using "FOO", i.e. the filtering was not effective.

Using strjoina since both strings are under our control.
2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 56c05601f4 homectl: split out helper parse_nice_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 5db63f9de8 homectl: split out helpers that extend parse_string_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 9f4c9a6cd9 homectl: split out helper parse_mode_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek 2bcf520f31 homectl: split out helper parse_boolean_field 2026-01-13 17:59:54 +01:00
Zbigniew Jędrzejewski-Szmek b1982aada6 homectl: split out helpers parse_{unsigned,u64,size}_field 2026-01-13 17:59:54 +01:00
Yu Watanabe 49eb2d50b4 Bump kernel requirements to >= 5.10, and recommend >= 5.14 (#38977)
Then, this drops several unnecessary code for older kernels.
2026-01-13 12:18:15 +09:00
calm329 ac2b5f6cbf basic: move BPF_JMP_A to override/linux/bpf_insn.h
Move the BPF_JMP_A macro from override/linux/bpf.h to
override/linux/bpf_insn.h. The bpf.h override conflicts with libbpf's
-I/usr/include/bpf/uapi include path. Since bpf_insn.h is not typically
installed at /usr/include/linux/ or /usr/include/bpf/uapi/linux/, the
override works without conflicts.

Fixes #40331
2026-01-13 12:14:11 +09:00
Yu Watanabe fce7ad481b process-util: drop unnecessary E2BIG error handling
E2BIG is returned when the kernel does not support CLONE_INTO_CGROUP,
but the flag is supported since kernel v5.7.
2026-01-13 10:21:36 +09:00
Yu Watanabe 80c5b63db5 mount-setup: memory_recursiveprot is supported since kernel v5.7
Our baseline on kernel is 5.10. Hence we can unconditionally use it.
2026-01-13 10:21:36 +09:00
Yu Watanabe d58c826c54 fd-util: drop close_all_fds_by_proc()
With the previous commit, now the function is used only on OOM.
In that case, let's do like close_all_fds_without_malloc().
2026-01-13 10:21:36 +09:00
Yu Watanabe c471cca093 fd-util: close_range() is available since kernel 5.9
Our baseline on kernel is 5.10, hence we can always use it.
2026-01-13 10:21:36 +09:00
Yu Watanabe d377cc5244 stat-util: STATX_TYPE and STATX_INO should be always set 2026-01-13 10:21:05 +09:00
Yu Watanabe 7ecfa87c56 fd-util,mountpoint-util: STATX_MNT_ID is supported since kernel 5.10
Our baseline on kernel is 5.10, hence we can assume it works.
2026-01-13 10:21:05 +09:00
Yu Watanabe 7f6cf19513 mountpoint-util: make is_mount_point_at() take usual dir_fd + path style arguments 2026-01-13 10:21:05 +09:00
Yu Watanabe a98a6eb95c tree-wide: statx() supports STATX_ATTR_MOUNT_ROOT since kernel 5.8
Our baseline on kernel is 5.10, hence we can unconditionally use it.
2026-01-13 10:21:04 +09:00