summaryrefslogtreecommitdiffstats
path: root/rules.d/80-drivers.rules (unfollow)
Commit message (Collapse)AuthorFilesLines
2023-10-26editorconfig: add NEWS whitespace configurationRonan Pigott1-0/+4
2023-10-26fd-uitl: rename PIPE_EBADF → EBADF_PAIR, and add EBADF_TRIPLETLennart Poettering58-83/+86
We use it for more than just pipe() arrays. For example also for socketpair(). Hence let's give it a generic name. Also add EBADF_TRIPLET to mirror this for things like stdin/stdout/stderr arrays, which we use a bunch of times.
2023-10-26nspawn: Make parameter provided_mac a const for setup_veth()Raul Cheleguini2-2/+2
2023-10-26core: do not post-process skipped mountsLuca Boccassi2-16/+56
When a mount is gracefully skipped (e.g.: BindReadOnlyPaths=-/nonexistent) we still post-process it, like making it read-only. Except if nothing has been mounted, the mount point will be made read-only for no reason. Track when mounts are skipped and avoid post-processing. One day we'll switch all of this to the new mount api and do these operations atomically or not at all. Fixes https://github.com/systemd/systemd/issues/29725
2023-10-26test: Skip test-recurse-dir on overlayfsRichard Maw1-7/+19
2023-10-26mkfs-util: Use actual UID/GID in protofile instead of rootDaan De Meyer1-3/+5
2023-10-26repart: do not ignore `tpm2-pcr-public-key.pem`Antonio Alvarez Feijoo1-2/+2
If `--tpm2-public-key=` is not specified, but `tpm2-pcr-public-key.pem` exists in /{etc,run,usr/lib}/systemd/, it's being ignored. Fixes 9e437994
2023-10-26test-fstab-generator: skip test impacted by /mnt symlinkDaniel P. Berrangé1-0/+8
On rpm-ostree distributions such as Fedora SilverBlue /mnt (and other well known paths) will be a symlink to a location under /var. The fstab generator emits correct output in this case, however, the data does not match the expected output stored in the source tree. Rather than trying to adapt the test data, just skip this single test scenario when we see /mnt is a symlink. Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2023-10-26test-systemd-tmpfiles: skip when /tmp has unexpected ownershipDaniel P. Berrangé1-0/+8
The systemd-tmpfiles binary will report a fatal error if /tmp is not owned either by root, or by the current user: Detected unsafe path transition /tmp (owned by nobody) → /tmp/test-systemd-tmpfiles.a8qc6n18 (owned by berrange) during canonicalization of tmp/test-systemd-tmpfiles.a8qc6n18/test-content.7chd7rdi When doing development inside a 'toolbox' container (which is required on a Fedora SilverBlue distro), /tmp is owned by 'nobody', because it has been passed through from the host and host UID 0 gets mapped to UID 65536 by usernamespaces. This triggers the unsafe path transition error message. Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2023-10-26test-blockdev-util: avoid abort when /home is a symlinkDaniel P. Berrangé1-2/+4
On rpm-ostree distributions like Fedora SilverBlue /home (and various other well known locations) are symlinks to somewhere beneath /var. The path_is_encrypted() method uses O_NOFOLLOW and as a result will return ELOOP on /home. This causes test-blockdev-util to abort. Add ELOOP to the ignorable set of errnos for testing. Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2023-10-26logind: introduce CreateSessionWithPIDFD()Michal Sekletar6-99/+411
This new D-Bus API uses pidfd to refer to the session leader. Also, pam_systemd will try to make use of it when pidfd support is available.
2023-10-26cryptenroll: fix bind default TPM2 signed policy to PCR 11Antonio Alvarez Feijoo2-2/+2
If `--tpm2-public-key=` is not specified, but `tpm2-pcr-public-key.pem` exists in /{etc,run,usr/lib}/systemd/, the default PCR 11 is not being set. Fixes 9e437994
2023-10-26varlink: make sure 'incomplete' bool is nullableLennart Poettering1-2/+2
This field is optional, it only makes sense for user records that actually have a privileged part to set.
2023-10-26test: add a simple test for PrivateNetwork=Yu Watanabe2-0/+10
2023-10-26core/namespace: check if we have enough privilege to mount sysfs or procfsYu Watanabe1-14/+27
If we do not have enough privilege to mount a new instance of sysfs or procfs, units e.g. with PrivateNetwork=yes may fail. Let's first try to mount sysfs or procfs anyway to check if we have enough privilege. Fixes #29526.
2023-10-26core/namespace: unify logic of mounting /proc and /sysYu Watanabe1-51/+40
No functional change, just refactoring.
2023-10-26cgroup-show: rework cgroup tree display to operate by fd onlyLennart Poettering1-12/+10
This restores display of the "delegate" flag of a cgroup. Previously we erroneously passed a full fs path where a cgroup path was expected (the difference being the /sys/fs/cgroup/ prefix), which meant we never read the xattr properly. Let's fix that by simply operating by fd on the cgroup and using it for all operations.
2023-10-26cgroup-util: add cg_is_delegated_fd() helperLennart Poettering2-10/+21
This is just like cg_is_delegate() but operates on an fd instead of a cgroup path. Sooner or later we should access cgroupfs mostly via fds rather than paths, but we aren't there yet. But let's at least get started.
2023-10-26tree-wide: port various users over to the new getxattr_at_bool() callLennart Poettering3-20/+7
2023-10-26xattr-util: add new getxattr_at_bool() helperLennart Poettering2-0/+17
This carefully combines getxattr_at_malloc() and parse_bool(), which is something we use at multiple places.
2023-10-26core/cgroup: ignore NFT sets for other sourcesTopi Miettinen1-0/+3
Partially fixes: #29678
2023-10-26core: do not reset tty if there's no tty configuredLuca Boccassi1-16/+17
Otherwise a lock is taken, which can be taken by multiple units at the same time, depending on each other, causing a deadlock. Fixes https://github.com/systemd/systemd/issues/29682
2023-10-26inotify-util: drop to use pointer outside of the bufferYu Watanabe2-14/+49
Hopefully fixes many Coverity issues.
2023-10-26tree-wide: fix typoYu Watanabe2-3/+2
2023-10-26test-network: suppress too much outputs of state fileYu Watanabe1-1/+0
Follow-up for 0f9efffaeb84964a3ab0f32271fba38f3bee2394.
2023-10-26network: update state file when DHCPv6 reply for INFORMATION-REQUEST is receivedYu Watanabe1-1/+5
Otherwise, received information, e.g. DNS servers, may not be saved in the state file, and will not be propagated to clients like resolved. Fixes the first issue of #29678.
2023-10-26dissect: insert missing spaceYu Watanabe1-1/+1
2023-10-25random-seed: terminate the option arrayFrantisek Sumsal1-0/+1
So we don't crash on invalid options: $ build/systemd-random-seed --foo Segmentation fault (core dumped)
2023-10-25man/systemd.unit: add PropagatesStopTo= to reverse property tableMike Yuan1-5/+14
2023-10-25test: slightly extend systemd-tpm2-setup's coverageFrantisek Sumsal1-1/+10
2023-10-25tpm2-setup: drop the COMMAND placeholder from the helpFrantisek Sumsal1-1/+1
Since systemd-tpm2-setup doesn't expect any arguments.
2023-10-25tpm2-setup: terminate the option arrayFrantisek Sumsal1-0/+1
Otherwise bad things happen: $ build/systemd-tpm2-setup --foo Segmentation fault (core dumped)
2023-10-25test: add a couple more tests for systemd-pcrextendFrantisek Sumsal2-0/+50
2023-10-25test: make the TPM event log checking a bit more robustFrantisek Sumsal1-11/+29
Don't hardcode the event number, so the test works correctly even if someone wrote to the event log before us. Also, explicitly pick the sha256 bank when checking digests, as the indexing may vary depending on current TPM's capabilities.
2023-10-25meson: Always build systemd-measureDaan De Meyer2-2/+1
Same idea as with bootctl, we might be doing image builds from a system that doesn't boot with UEFI but we still might want to measure stuff for the image we're building so let's not gate this behind ENABLE_BOOTLOADER.
2023-10-25meson: Always build bootctlDaan De Meyer5-5/+4
bootctl is rather useful to have, even if on a system without UEFI, as it has a number of verbs that are unrelated to UEFI (e.g kernel-identify), and more importantly, it supports --root to operate on directory trees (which could be intended to be deployed on UEFI) so let's make sure we always build it.
2023-10-25nspawn: allow user-specified MAC address on container sideRaul Cheleguini4-6/+27
Introduce the environment variable SYSTEMD_NSPAWN_NETWORK_MAC to allow user-specified MAC address on container side.
2023-10-25test: split TEST-70-TPM2 into subtestsFrantisek Sumsal8-448/+501
2023-10-25cryptsetup: remove redundant checkLennart Poettering1-4/+0
The immediately preceeding check already covered that. This removes and addition made back in aae6eb96117acd54ce5ac572aac6a11b34c4ad99. cc @williamcroberts
2023-10-25udev: strdupa() → strdupa_safe()Frantisek Sumsal1-1/+1
2023-10-25network: use timestamp_is_set() in one more placeFrantisek Sumsal1-1/+1
2023-10-25network: ENOTSUP → EOPNOTSUPPFrantisek Sumsal1-1/+1
2023-10-25core,journal: drop unnecessary !! castsFrantisek Sumsal2-2/+2
2023-10-25coccinelle: don't run iovec-make on iovec_done{,_erase}Frantisek Sumsal1-1/+5
As the result is a bit funky (but still valid), i.e.: static inline void iovec_done_erase(struct iovec *iovec) { assert(iovec); - iovec->iov_base = erase_and_free(iovec->iov_base); - iovec->iov_len = 0; + *iovec = IOVEC_MAKE(erase_and_free(iovec->iov_base), 0); }
2023-10-25tpm2-util: add line breaks in compound struct init, like we usually doLennart Poettering1-3/+9
2023-10-25cryptenroll: validate positional arguments before looking at detail parametersLennart Poettering1-12/+12
Let's switch the order in which we process positional arguments and analyze/tweak detail parameters. Let's look at the positional arguments first (i.e. the "big picture") and then look at the switches (i.e. "little details"). THis doesn't matter much, but makes for better error messages I think. At least I was very confused that a completely borked cmdline I passed to cryptenrolled complained about some detail and let the major fuckup pass...
2023-10-25cryptenroll: add section headers to --help textLennart Poettering1-11/+18
2023-10-25cryptenroll: add addition assertsLennart Poettering1-7/+13
2023-10-25repart: reduce scope of two variablesLennart Poettering1-11/+16
This replicates what 475c473d328c12f5e9fd43cee959154a0d0c78a4 did for cryptenroll for repart, which has very similar code for this.
2023-10-25tpm2-util: add line breaks in compound struct init, like we usually doLennart Poettering1-3/+9