Commit Graph
81509 Commits
Author SHA1 Message Date
Eisuke Kawashima b9df3d6447 shell-completion: improve completion of systemd-tmpfiles 2025-05-16 14:04:09 +09:00
Lennart Poettering edecb56216 man: document how to hook stuff into system wakeup
Fixes: #6364
2025-05-15 22:01:12 +01:00
Daan De Meyer ef10d4b526 Bugprone argument comment - round 5 (#37481) 2025-05-15 20:33:50 +02:00
Yu Watanabe 9fd936df77 man: fix path to version.h
Follow-up for 30d20907bd.
2025-05-15 15:42:33 +02:00
Jelle van der Waa 346c62f9ca treewide: correct argument comments 2025-05-15 15:39:20 +02:00
Jelle van der Waa f15dcafdb1 discover-image: correct argument comments 2025-05-15 14:50:33 +02:00
Mike Yuan 7762e9bbb2 core: always enable CPU accounting; cgtop: drop cgv1 handling (#37448) 2025-05-15 14:41:07 +02:00
Yu Watanabe abbdc33bca hwdb: add PLUTO SDR (#37471)
The goal of this PR is to replace the rules in
https://github.com/analogdevicesinc/plutosdr-fw/commit/76aa80a6d86f7b3b2c0fe83cca51f351991ee852.

The original rules file have some rules for a device that is now
deprecated and so, are not part of this change. AFAIU, 'plugdev' is also
a thing of the past and we now use 'uaccess' which should be given to
all ID_SOFTWARE_RADIO devices. So yeah, hopefully what I have here is
equivalent to the orginal .rules.

The request for this was done here:
https://github.com/analogdevicesinc/plutosdr-fw/issues/101
2025-05-15 20:19:09 +09:00
Luca Boccassi a49f3c3890 Update hwdb (#37470)
Update hwdb, even though we are pretty far from a release in order to:
- incrementally test upstream additions to hwdb
- allow backports to stable branches
2025-05-15 12:09:03 +01:00
Luca Boccassi ed5c3f4436 core: use socket cookie for naming per-connection service instances + set $SO_COOKIE env var to it (#37469) 2025-05-15 11:11:21 +01:00
Tommy Unger ef3a0478bb test: write file from systemd service in transient unit
This integration test demonstrates that a containerized systemd instance can
write to a bind mounted file observable to the host. Specifically, the bash
script uses systemd-run to start a systemd instance as a transient unit
container. This systemd-run command bind mounts a directory the container will
share with the host, and runs an internal service which creates and writes to a
file from the container's view of this directory. When finished writing, the
service runs the exit target, terminating the internal systemd instance, and
ending the lifetime of the container.

The script waits for the container to finish running, then verifies that the
expected file contents were written on the host side of the filesystem mount.

This test employs a workaround, creating an unmasked procfs mount on the host
which enables the privileged guest to create its own mounts internally. This
may indicate a systemd bug, as the privileged container should not rely on
the existence of an unmasked procfs on the host in order to mount its own
filesystems internally.
2025-05-15 11:33:23 +02:00
Lennart Poettering 62e5b90a49 varlink: two tweaks for method call handling (#37466) 2025-05-15 11:28:58 +02:00
Jelle van der Waa d495a31f9b test: correct argument comments 2025-05-15 11:14:04 +02:00
Jelle van der Waa 274da0b67b terminal-util: rename openpt_allocate_* ret_peer argument
Make it consistent with its implementation.
2025-05-15 11:12:43 +02:00
Jelle van der Waa 5ae4d7c9ba tpm2-util: correct argument comments 2025-05-15 11:12:43 +02:00
Jelle van der Waa ccf379b46e sd-varlink: fix argument comment
Follow-up for 52068c1e9c
2025-05-15 11:12:43 +02:00
Jelle van der Waa 2f75e5efa1 tpm2-util: rename tpm2_unseal arguments
To make it consistent with its implementation.
2025-05-15 11:12:28 +02:00
Zbigniew Jędrzejewski-Szmek 7bd6626a43 hwdb: run "update-hwdb-autosuspend"
As usual, mostly additions and a few removals.
2025-05-15 10:51:28 +02:00
Zbigniew Jędrzejewski-Szmek f41c0fa11e hwdb: run "update-hwdb"
As usual, it seems to be mostly additions and corrections.

The last update was in 0d740f4bc0, Dec 10th. I
think it's reasonable to update the hwdb more often. In particular, I want to
push an update to the stable branches, but it should be updated in 'main'
first.
2025-05-15 10:50:28 +02:00
Nuno Sá 42957adf5c hwdb: append ID_MM_DEVICE_IGNORE to hwdb parser 2025-05-15 09:48:30 +01:00
Nuno Sá ab8e0c6c7c hwdb: add Analog Devices PLUTO SDR
Add hwdb entries for ADI PLUTO. Note that when in DFU (Device Firmware
mode) mode, the pid is different. Thus, the two entries.

We also want to make sure that no AT commands are sent to us and so we
set 'ID_MM_DEVICE_IGNORE=1'.
2025-05-15 09:46:16 +01:00
Lennart Poettering 1619918da7 update TODO 2025-05-15 09:53:30 +02:00
Yu Watanabe 6a4fe38f7f network: do not drop duplicated entries in loop
Fixes #37456.
2025-05-15 09:49:46 +02:00
Lennart Poettering 9be6e18444 core: name socket unit instances after the socket cookie
On linux sockets have a really good, unique identifier, the SO_COOKIE,
which is used by sockdiag and BPF and elsewhere. Let's expose this more
prominently in the service name of per-connection services invoked via
Accept=yes sockets.

This is really nice, because together with our $SO_COOKIE env var we can
now match up services, process execution contexts, and "ss" outputs, BPF
rules, and more.
2025-05-15 09:45:33 +02:00
Lennart Poettering bfb1f9e2c9 core: pass the socket cookie to invoked per-connection service instances as $SO_COOKIE env var
The socket cookie is just too useful for identifying connections, let's
emphasize this a bit and pass it as environment variable.
2025-05-15 09:45:32 +02:00
Lennart Poettering 272017d32a socket-util: add trivial socket_get_cookie() helper 2025-05-15 09:45:19 +02:00
Lennart Poettering 3bdcd994cd man: correct version information when $REMOTE_ADDR/$REMOTE_PORT where added
This was in commit 3b1c524154, i.e. in the
v220 cycle.
2025-05-15 09:45:19 +02:00
Lennart Poettering 99d52ab51f man: don't claim REMOTE_PORT= was initialized to the protocol for AF_RAW sockets
This claim has no basis in reality, not even in the original commit
where the sentence was added this was true, see
3b1c524154.

Hence removing.
2025-05-15 09:33:34 +02:00
Lennart Poettering 8d7d2edcbb bus-polkit: add a generic vtable for methods with no params, but with polkit 2025-05-15 09:31:27 +02:00
Lennart Poettering 231cab5c5e core: always handle method call params via sd_varlink_dispatch(), even if we accept none
This results in much more precise errors for the clients, and is what we
do everywhere else these days.
2025-05-15 09:31:27 +02:00
Mike Yuan 29da53dde3 core: always enable CPU accounting
Our baseline is v5.4 and cgroup v2 is enforced now,
which means CPU accounting is cheap everywhere without
requiring any controller, hence just remove the directive.
2025-05-15 02:19:16 +02:00
Mike Yuan 7d71b23304 man: don't duplicate version in History section 2025-05-15 02:19:16 +02:00
Mike Yuan 72594d6771 man/systemd-run: --wait shows more than CPU accounting data 2025-05-15 02:19:16 +02:00
Mike Yuan 5fde5c0399 systemctl-show: drop BlockIO* property formatter 2025-05-15 02:19:15 +02:00
Mike Yuan 3274ef6792 core: drop Manager.blockio_accounting
Follow-up for 98d64ff500
2025-05-15 02:19:15 +02:00
Mike Yuan 0fc54e2390 cgtop: drop v1 support 2025-05-15 02:19:15 +02:00
Mike Yuan 946eea7a7f mountpoint-util: remove unused TMPFS_LIMITS_SYS_FS_CGROUP
Follow-up for 6801a9d88a
2025-05-15 09:00:51 +09:00
Mike Yuan 68a2435cc2 cgroup-util: drop cg_kill() cgroup.threads kludge
Our baseline is v5.4 now.
2025-05-15 07:26:03 +09:00
Yu Watanabe 231557fe40 resolve: fix typo
Follow-up for 801ad6a6a9.
2025-05-15 07:19:24 +09:00
Daan De Meyer 3b21af5234 hashmap: Split out iterator.h
As preparation for #37344, let's split out iterator.h so we can
avoid including the entirety of hashmap.h where it's not needed.
2025-05-15 00:01:32 +02:00
Daan De Meyer a1ccfc420c tree-wide: Clean up includes (#37457) 2025-05-14 23:53:49 +02:00
Daan De Meyer 8857aa74e5 tree-wide: Clean up includes
This commit cleans up the includes for all the small tools across
the tree.

A few cases of returning EXIT_SUCCESS are replaced with returning
0 to avoid including <stdlib.h>.

Split out of #37344.
2025-05-14 22:34:02 +02:00
Daan De Meyer 0dc510ab03 tpm2-util: Make sure structs/enums are named and add to forward.h
We have to name structs/enums to be able to forward declare them, so
let's do that and add the missing ones to forward.h.
2025-05-14 22:34:02 +02:00
Daan De Meyer 08fd159db1 networkd-util: Avoid call to endswith()
Instead of recalculating the length of the string again after
reading it, let's make sd_netlink_message_read_string() return the
length of the string that we then use to check if the last character
is a dot or not.

This allows us to get rid of the string-util.h include in #37344.
2025-05-14 22:33:45 +02:00
Luca Boccassi 74acb358c5 test: fix assertion failure with CONFIG_UNIX_DIAG disabled
On OBS the build VM is heavily locked down, with network
disabled in various ways in the custom kernel, to isolate the
build, including disabling CONFIG_UNIX_DIAG.

[  456s] /* test_af_unix_get_qlen */
[  456s] src/test/test-socket-netlink.c:393: Assertion failed: Expected "af_unix_get_qlen(unix_fd, &q)" to succeed, but got error: No such file or directory

[  454s] /* test_sock_diag_unix */
[  454s] src/libsystemd/sd-netlink/test-netlink.c:727: Assertion failed: Expected "sd_netlink_call(nl, message, 0, &reply)" to succeed, but got error: No such file or directory

Follow-up for 89e546e927
Follow-up for 4a3bf440f2
2025-05-14 21:24:48 +01:00
Daan De Meyer 9ebbb785b0 serialize: Move some logic to the implementation file
This will allow removing the string-util.h include in #37344.
2025-05-15 04:25:47 +09:00
Yu Watanabe ff4814f60c validatefs: follow ups for recent change (#37447)
Follow-ups for #37434.
2025-05-15 04:25:28 +09:00
Yu Watanabe 1ef6cee327 Bugprone argument comment - round 4 (#37380)
Follow up from https://github.com/systemd/systemd/pull/37356
2025-05-15 03:36:16 +09:00
Daan De Meyer 17b0d165f6 capability-util: Ignore unknown capabilities instead of aborting
capability_quintet_mangle() can be called with capability sets
containing unknown capabilities. Let's not crash when this is the
case but instead ignore the unknown capabilities.

Fixes d5e12dc75e
2025-05-15 03:33:32 +09:00
Yu Watanabe 561f53c92b Small fixups after review for stable (#37442) 2025-05-15 03:30:41 +09:00