]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
15 months agoMerge pull request #26341 from DaanDeMeyer/chase-fixes
Luca Boccassi [Fri, 17 Feb 2023 11:44:47 +0000 (11:44 +0000)] 
Merge pull request #26341 from DaanDeMeyer/chase-fixes

chase-symlinks fixes

15 months agoMerge pull request #26447 from poettering/sigqueue
Lennart Poettering [Fri, 17 Feb 2023 09:51:58 +0000 (10:51 +0100)] 
Merge pull request #26447 from poettering/sigqueue

pid1/systemctl: add ability to enqueue POSIX RT sigs with associated value to service processes

15 months agosocket-util: make connect_unix_path() work with a NULL path
Lennart Poettering [Fri, 10 Feb 2023 15:43:58 +0000 (16:43 +0100)] 
socket-util: make connect_unix_path() work with a NULL path

15 months agoMerge pull request #26343 from DaanDeMeyer/bus-debug
Lennart Poettering [Fri, 17 Feb 2023 09:50:19 +0000 (10:50 +0100)] 
Merge pull request #26343 from DaanDeMeyer/bus-debug

Bus debug

15 months agoMerge pull request #26450 from yuwata/fd-is-opath
Lennart Poettering [Fri, 17 Feb 2023 09:28:32 +0000 (10:28 +0100)] 
Merge pull request #26450 from yuwata/fd-is-opath

util: introduce fd_is_opath() and use it in xsetxattr()

15 months agotest: add test for new "systemctl --kill-value=" functionality 26447/head
Lennart Poettering [Thu, 16 Feb 2023 15:31:02 +0000 (16:31 +0100)] 
test: add test for new "systemctl --kill-value=" functionality

(as side-effect this also tests the new systemd-notify --exec switch)

15 months agoman: document new --exec switch for systemd-notify
Lennart Poettering [Thu, 16 Feb 2023 15:30:09 +0000 (16:30 +0100)] 
man: document new --exec switch for systemd-notify

15 months agonotify: add new --exec switch for chaining other commands to systemd-notify
Lennart Poettering [Thu, 16 Feb 2023 14:42:49 +0000 (15:42 +0100)] 
notify: add new --exec switch for chaining other commands to systemd-notify

This is useful in tests, so that we can first send a READY message and
then continue doing something else without changing PID.

15 months agostrv: add strv_copy_n() helper for copying part of a n strv
Lennart Poettering [Thu, 16 Feb 2023 14:41:55 +0000 (15:41 +0100)] 
strv: add strv_copy_n() helper for copying part of a n strv

15 months agoman: document new --kill-value= switch to systemctl
Lennart Poettering [Thu, 16 Feb 2023 15:20:48 +0000 (16:20 +0100)] 
man: document new --kill-value= switch to systemctl

15 months agosystemctl: add --kill-value= argument to systemctl
Lennart Poettering [Wed, 15 Feb 2023 09:51:33 +0000 (10:51 +0100)] 
systemctl: add --kill-value= argument to systemctl

This allows accompanying a signal with a value (as supported for Linux
Realtime signals). This is particularly useful as it allows us to do
stuff like this:

   systemctl kill --kill-whom=main --kill-value=0x300 systemd-journald

In order to ask journald to flush its allocation caches and compact
memory.

15 months agopid1: add a new D-Bus method for enquing POSIX signals with values to unit processes
Lennart Poettering [Wed, 15 Feb 2023 09:25:51 +0000 (10:25 +0100)] 
pid1: add a new D-Bus method for enquing POSIX signals with values to unit processes

This augments the existing KillUnit() + Kill() methods with
QueueSignalUnit() + QueueSignal(), which are what sigqueue() is to
kill().

This is useful for sending our new SIGRTMIN+18 control signals to system
services.

15 months agotest-execute: also mount tmpfs on /dev/shm
Yu Watanabe [Fri, 17 Feb 2023 01:21:58 +0000 (10:21 +0900)] 
test-execute: also mount tmpfs on /dev/shm

Otherwise, if /dev/shm has a directory that cannot be accessible by
unprivileged user, then we cannot pick a dynamic user, and test service
may fail with unexpected error code:
---
Failed to enter shared memory directory /dev/shm/systemd-watch-bind-BqAGlN: Permission denied
exec-dynamicuser-supplementarygroups.service: Failed to update dynamic user credentials: Device or resource busy
exec-dynamicuser-supplementarygroups.service: Failed at step USER spawning /bin/sh: Device or resource busy
src/test/test-execute.c:885:test_exec_dynamicuser: exec-dynamicuser-supplementarygroups.service: can_unshare=no: exit status 217, expected 216
---

Follow-up for 4e032f654b94c2544ccf937209303766dfa66c24.

15 months agocryptsetup: check the existence of salt by salt_size > 0
Yu Watanabe [Thu, 16 Feb 2023 23:24:54 +0000 (08:24 +0900)] 
cryptsetup: check the existence of salt by salt_size > 0

Follow-up for 504d0acf61c8472bc93c2a927e858074873b2eaf.

The function may be called with non-NULL salt and salt_size == 0.

15 months agoMerge pull request #26453 from yuwata/activate-main
Lennart Poettering [Fri, 17 Feb 2023 08:45:52 +0000 (09:45 +0100)] 
Merge pull request #26453 from yuwata/activate-main

activate: use DEFINE_MAIN_FUNCTION() macro

15 months agoMerge pull request #26452 from yuwata/journalctl-main-func
Lennart Poettering [Fri, 17 Feb 2023 08:44:19 +0000 (09:44 +0100)] 
Merge pull request #26452 from yuwata/journalctl-main-func

journalctl: use DEFINE_MAIN_FUNCTION() macro

15 months agotest: add tests for xsetxattr() 26450/head
Yu Watanabe [Fri, 17 Feb 2023 02:42:14 +0000 (11:42 +0900)] 
test: add tests for xsetxattr()

15 months agotest: use mkdtemp_open()
Yu Watanabe [Fri, 17 Feb 2023 02:12:13 +0000 (11:12 +0900)] 
test: use mkdtemp_open()

15 months agoactivate: use _cleanup_close_ attribute 26453/head
Yu Watanabe [Fri, 17 Feb 2023 00:49:01 +0000 (09:49 +0900)] 
activate: use _cleanup_close_ attribute

15 months agoactivate: use log_set_open_when_needed()
Yu Watanabe [Fri, 17 Feb 2023 00:31:01 +0000 (09:31 +0900)] 
activate: use log_set_open_when_needed()

Otherwise, several error logs may not be shown.

15 months agoactivate: fix typo
Yu Watanabe [Fri, 17 Feb 2023 00:26:34 +0000 (09:26 +0900)] 
activate: fix typo

15 months agoactivate: use DEFINE_MAIN_FUNC() macro
Yu Watanabe [Fri, 17 Feb 2023 00:25:21 +0000 (09:25 +0900)] 
activate: use DEFINE_MAIN_FUNC() macro

15 months agojournalctl: fix fd leak 26452/head
Yu Watanabe [Fri, 17 Feb 2023 00:11:28 +0000 (09:11 +0900)] 
journalctl: fix fd leak

15 months agojournalctl: use DEFINE_MAIN_FUNCTION() macro
Yu Watanabe [Fri, 17 Feb 2023 00:11:17 +0000 (09:11 +0900)] 
journalctl: use DEFINE_MAIN_FUNCTION() macro

15 months agoxattr-util: check if fd has O_PATH and do not try setxattr() twice
Yu Watanabe [Thu, 16 Feb 2023 22:34:13 +0000 (07:34 +0900)] 
xattr-util: check if fd has O_PATH and do not try setxattr() twice

Follow-up for a4d2461c46f40c9ae5002a2aea35b35ccb60ef9c.

15 months agofd-util: introduce a simple helper to check a file descriptor has O_PATH
Yu Watanabe [Thu, 16 Feb 2023 22:18:42 +0000 (07:18 +0900)] 
fd-util: introduce a simple helper to check a file descriptor has O_PATH

15 months agotest: avoid matching other fields than __SEQNUM=
Frantisek Sumsal [Thu, 16 Feb 2023 18:48:03 +0000 (19:48 +0100)] 
test: avoid matching other fields than __SEQNUM=

The current unanchored grep sometimes matches MESSAGE=/_CMDLINE= fields
that contain "__SEQNUM=" instead of just the __SEQNUM= field, causing
spurious test fails:

[  721.546372] testsuite-04.sh[1013]: ++ cut -d= -f2
[  721.555858] testsuite-04.sh[1011]: ++ journalctl -o export -n 1
[  721.573037] testsuite-04.sh[1012]: ++ grep -a __SEQNUM=
[  721.767294] testsuite-04.sh[562]: + SEQNUM1='495773
[  721.769671] testsuite-04.sh[562]: ++ grep -a __SEQNUM
[  721.771323] testsuite-04.sh[562]: grep -a __SEQNUM'
[  721.772938] testsuite-04.sh[562]: + systemd-cat echo yo
[  721.921413] testsuite-04.sh[562]: + journalctl --sync
[  722.088945] testsuite-04.sh[1018]: ++ journalctl -o export -n 1
[  722.104040] testsuite-04.sh[1019]: ++ grep -a __SEQNUM=
[  722.117239] testsuite-04.sh[1020]: ++ cut -d= -f2
[  722.314936] testsuite-04.sh[562]: + SEQNUM2=495786
[  722.317906] testsuite-04.sh[562]: + test 495786 -gt '495773
[  722.319737] testsuite-04.sh[562]: ++ grep -a __SEQNUM
[  722.321609] testsuite-04.sh[562]: grep -a __SEQNUM'
[  722.323536] testsuite-04.sh[562]: /usr/lib/systemd/tests/testdata/units/testsuite-04.sh: line 276: test: 495773
[  722.325744] testsuite-04.sh[562]: ++ grep -a __SEQNUM
[  722.327498] testsuite-04.sh[562]: grep -a __SEQNUM: integer expression expected
[  722.329528] testsuite-04.sh[562]: + journalctl --rotate --vacuum-size=16M

$ build/journalctl --file /var/tmp/systemd-test.0HpVjt/system.journal -o export | grep -a __SEQNUM=
...
__SEQNUM=214849
__SEQNUM=214850
MESSAGE=++ grep -a __SEQNUM=
_CMDLINE=grep -a __SEQNUM=
__SEQNUM=214851
...
__SEQNUM=214860
MESSAGE=++ grep -a __SEQNUM=
_CMDLINE=grep -a __SEQNUM=
__SEQNUM=214861
__SEQNUM=214862
__SEQNUM=214863
...

Let's anchor the expression to avoid this.

Follow-up to f28ed2c1be7.

15 months agoMerge pull request #26271 from d-hatayama/fix_sulogin_shell
Yu Watanabe [Thu, 16 Feb 2023 21:52:03 +0000 (06:52 +0900)] 
Merge pull request #26271 from d-hatayama/fix_sulogin_shell

sulogin: fix control lost of the current terminal when default.target…

15 months agoboot: Fix assertion failure
Jan Janssen [Thu, 16 Feb 2023 14:24:44 +0000 (15:24 +0100)] 
boot: Fix assertion failure

The TPM code expects a description unless the PCR index indicates that
no measurements have to take place. The assert was preempting this
check from happening.

Fixes: #26428
15 months agobootctl: Fix debug messages
Samanta Navarro [Thu, 16 Feb 2023 11:59:05 +0000 (11:59 +0000)] 
bootctl: Fix debug messages

Remove duplicate KERNEL_INSTALL_MACHINE_ID from message and also
specify the correct origin of layout variable.

Signed-off-by: Samanta Navarro <ferivoz@riseup.net>
15 months agolog: add common helper log_set_target_and_open()
Lennart Poettering [Tue, 14 Feb 2023 15:10:58 +0000 (16:10 +0100)] 
log: add common helper log_set_target_and_open()

quite often we want to set a log target and immediately open it. Add a
common helper for that.

15 months agoMerge pull request #26435 from poettering/pid1-seccomp-disable-fix
Luca Boccassi [Thu, 16 Feb 2023 14:49:52 +0000 (14:49 +0000)] 
Merge pull request #26435 from poettering/pid1-seccomp-disable-fix

pid1: fix handling of SystemCallArchitectures= if seccomp is off

15 months agocore/mount: fix default target for /sysusr/usr and its child
Yu Watanabe [Wed, 15 Feb 2023 05:23:34 +0000 (14:23 +0900)] 
core/mount: fix default target for /sysusr/usr and its child

Follow-up for 29a24ab28e9790680348b1ffab653a321fa49a67.

15 months agoman: Fix spelling mistake
Paul Barker [Thu, 16 Feb 2023 14:19:40 +0000 (14:19 +0000)] 
man: Fix spelling mistake

15 months agoupdate TODO
Lennart Poettering [Thu, 16 Feb 2023 13:07:03 +0000 (14:07 +0100)] 
update TODO

15 months agosulogin: fix control lost of the current terminal when default.target is rescue.target 26271/head
HATAYAMA Daisuke [Sun, 12 Feb 2023 12:15:08 +0000 (12:15 +0000)] 
sulogin: fix control lost of the current terminal when default.target is rescue.target

When default.target is rescue.target, exiting from the single-user shell
results in lost of the control of the current terminal. This is because the
operation performed to continue to boot is systemctl default but default.target
is now rescue.target and it is already active. Hence, no new process that
controls the current terminal is created. Users need to make hardware reset to
recover the situation.

This sounds like a bit corner case issue and some might feel configuring
default.target as rescue.target is odd because there are several other ways to
transition to rescue.mode without configuring default.target to rescue.target
such as systemctl rescue or systemd.unit=rescue.target something like
that. However, users unfamiliar with systemd operations tend to come up with
systemctl set-default rescue.target.

To fix this issue, let's transition to default.target only when default.target
is inactive. Otherwise, invoke the single-user shell again to keep control of
the current terminal for users.

This new logic depends on whether D-Bus working well. Exiting without any check
of result of systemctl default could lead to again the control lost of the
current terminal. Hence, add checking results of each D-Bus operations
including systemctl default and invoke the single-user shell if they fail.

15 months agoexecute: drop spurious empty line 26435/head
Lennart Poettering [Thu, 16 Feb 2023 09:59:16 +0000 (10:59 +0100)] 
execute: drop spurious empty line

15 months agopid1: generate compat warning for SystemCallArchitectures= if seccomp is off
Lennart Poettering [Thu, 16 Feb 2023 09:10:19 +0000 (10:10 +0100)] 
pid1: generate compat warning for SystemCallArchitectures= if seccomp is off

15 months agomkosi: configure multiarch libdir in debian/ubuntu builds
Luca Boccassi [Wed, 15 Feb 2023 22:06:26 +0000 (22:06 +0000)] 
mkosi: configure multiarch libdir in debian/ubuntu builds

Debian/Ubuntu use /usr/lib/<triplet> instead of /usr/lib64, so configure it
accordingly. This is especially important for cryptsetup token plugins,
as cryptsetup comes from the distro and is configured to look into those
directories.

15 months agotpm2: fix build failure without openssl
Dan Streetman [Fri, 20 Jan 2023 17:42:52 +0000 (12:42 -0500)] 
tpm2: fix build failure without openssl

15 months agomkosi: Enable debug logging in CI
Daan De Meyer [Wed, 15 Feb 2023 10:16:28 +0000 (11:16 +0100)] 
mkosi: Enable debug logging in CI

"Failed to dissect image: connection timed out" messages have been
appearing sporadically in mkosi CI. Let's enable debug logging to
help figure out why.

15 months agojournalctl: actually run the static destructors
Frantisek Sumsal [Wed, 15 Feb 2023 17:08:35 +0000 (18:08 +0100)] 
journalctl: actually run the static destructors

In journalctl we don't run the static destructors defined via
the STATIC_DESTRUCTOR_REGISTER() macro, since it requires a corresponding
static_destruct() call. In most cases this is handled by
the DEFINE_(TEST_)?MAIN*() macros, but journalctl defines its own main
function, so let's handle that as well.

$ valgrind --suppressions=valgrind.supp --show-leak-kinds=all --leak-check=full build/journalctl --no-pager -u system.slice -n 10 >/dev/null
==2778093== Memcheck, a memory error detector
==2778093== Copyright (C) 2002-2022, and GNU GPL'd, by Julian Seward et al.
==2778093== Using Valgrind-3.19.0 and LibVEX; rerun with -h for copyright info
==2778093== Command: build/journalctl --no-pager -u system.slice -n 10
==2778093==
==2778093==
==2778093== HEAP SUMMARY:
==2778093==     in use at exit: 8,221 bytes in 4 blocks
==2778093==   total heap usage: 458 allocs, 454 frees, 255,182 bytes allocated
==2778093==
==2778093== 13 bytes in 1 blocks are still reachable in loss record 1 of 4
==2778093==    at 0x484586F: malloc (vg_replace_malloc.c:381)
==2778093==    by 0x4DA256D: strdup (strdup.c:42)
==2778093==    by 0x4ADB747: strv_extend_with_size (strv.c:544)
==2778093==    by 0x405386: strv_extend (strv.h:45)
==2778093==    by 0x40816F: parse_argv (journalctl.c:933)
==2778093==    by 0x40EAB5: main (journalctl.c:2111)
==2778093==
==2778093== 16 bytes in 1 blocks are still reachable in loss record 2 of 4
==2778093==    at 0x484578A: malloc (vg_replace_malloc.c:380)
==2778093==    by 0x484A70B: realloc (vg_replace_malloc.c:1437)
==2778093==    by 0x4ADB2A3: strv_push_with_size (strv.c:423)
==2778093==    by 0x4ADB620: strv_consume_with_size (strv.c:496)
==2778093==    by 0x4ADB770: strv_extend_with_size (strv.c:548)
==2778093==    by 0x405386: strv_extend (strv.h:45)
==2778093==    by 0x40816F: parse_argv (journalctl.c:933)
==2778093==    by 0x40EAB5: main (journalctl.c:2111)
==2778093==
==2778093== LEAK SUMMARY:
==2778093==    definitely lost: 0 bytes in 0 blocks
==2778093==    indirectly lost: 0 bytes in 0 blocks
==2778093==      possibly lost: 0 bytes in 0 blocks
==2778093==    still reachable: 29 bytes in 2 blocks
==2778093==         suppressed: 8,192 bytes in 2 blocks
==2778093==
==2778093== For lists of detected and suppressed errors, rerun with: -s
==2778093== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)

15 months agoresolved: Fall back to TCP if UDP is blocked
Joan Bruguera [Sun, 12 Feb 2023 20:06:08 +0000 (20:06 +0000)] 
resolved: Fall back to TCP if UDP is blocked

If UDP is blocked on the system (e.g. by iptables or BPF), the kernel will
return EPERM on some or all of the system calls (connect, sendmsg, etc.).
In this case, try to fall back to TCP, which hopefully will not be blocked.

15 months agocore: add support for Startup memory limits
Luca Boccassi [Mon, 6 Feb 2023 14:13:09 +0000 (14:13 +0000)] 
core: add support for Startup memory limits

We support separate Startup configurations for CPU and I/O, so
add it for memory too. Only cover cgroupsv2 settings.

15 months agovconsole: allow setting default keymap through build option
Mike Yuan [Tue, 17 Jan 2023 17:21:59 +0000 (01:21 +0800)] 
vconsole: allow setting default keymap through build option

Allow defining the default keymap to be used by
vconsole-setup through a build option. A template
vconsole.conf also gets populated by tmpfiles if
it doesn't exist.

15 months agojournal: cat: set JOURNAL_STREAM before exec-ing
Mike Yuan [Tue, 7 Feb 2023 16:21:33 +0000 (00:21 +0800)] 
journal: cat: set JOURNAL_STREAM before exec-ing

Make the behavior of systemd-cat match
that of core/execute.

Closes #25880

15 months agoMerge pull request #26307 from yuwata/test-execute-credentials
Luca Boccassi [Wed, 15 Feb 2023 19:59:28 +0000 (19:59 +0000)] 
Merge pull request #26307 from yuwata/test-execute-credentials

test-execute: drop capabilities when testing with user manager

15 months agoMerge pull request #26213 from poettering/journal-rework-seqnum
Luca Boccassi [Wed, 15 Feb 2023 19:58:58 +0000 (19:58 +0000)] 
Merge pull request #26213 from poettering/journal-rework-seqnum

journal sequence number rework

15 months agoMerge pull request #26410 from DaanDeMeyer/xattr-symlink
Luca Boccassi [Wed, 15 Feb 2023 19:55:04 +0000 (19:55 +0000)] 
Merge pull request #26410 from DaanDeMeyer/xattr-symlink

Copy symlink xattrs

15 months agoNEWS: finalize v253
Luca Boccassi [Wed, 15 Feb 2023 18:11:21 +0000 (18:11 +0000)] 
NEWS: finalize

15 months agoMerge pull request #26427 from bluca/hwdb
Luca Boccassi [Wed, 15 Feb 2023 19:08:36 +0000 (19:08 +0000)] 
Merge pull request #26427 from bluca/hwdb

Update news and hwdb

15 months agohwdb: update 26427/head
Luca Boccassi [Wed, 15 Feb 2023 18:05:43 +0000 (18:05 +0000)] 
hwdb: update

15 months agoNEWS: update contributors list
Luca Boccassi [Wed, 15 Feb 2023 18:03:15 +0000 (18:03 +0000)] 
NEWS: update contributors list

15 months agocryptsetup: do not assert when unsealing token without salt
Luca Boccassi [Wed, 15 Feb 2023 00:44:01 +0000 (00:44 +0000)] 
cryptsetup: do not assert when unsealing token without salt

Salt was added in v253. We are not checking whether it was actually found
(non-zero size), so when an old tpm+pin enrollment is opened things go boom.
For good measure, check both the buffer and the size in both places.

Assertion 'saltlen > 0' failed at src/shared/tpm2-util.c:2490, function tpm2_util_pbkdf2_hmac_sha256(). Aborting.

15 months agoukify: fix padding length
Yu Watanabe [Wed, 15 Feb 2023 16:59:08 +0000 (01:59 +0900)] 
ukify: fix padding length

15 months agoMerge pull request #26417 from yuwata/sysusers-root-group
Luca Boccassi [Wed, 15 Feb 2023 17:03:59 +0000 (17:03 +0000)] 
Merge pull request #26417 from yuwata/sysusers-root-group

sysusers: also create root group

15 months agoMerge pull request #26424 from ldv-alt/fix-typos
Yu Watanabe [Wed, 15 Feb 2023 15:10:18 +0000 (00:10 +0900)] 
Merge pull request #26424 from ldv-alt/fix-typos

Fix a few typos in NEWS, docs and comments

15 months agoman/tc: Fix hexadecimals being with an O
Raul Tambre [Wed, 15 Feb 2023 14:21:21 +0000 (16:21 +0200)] 
man/tc: Fix hexadecimals being with an O

15 months agotreewide: fix a few typos in NEWS, docs and comments 26424/head
Dmitry V. Levin [Wed, 15 Feb 2023 08:00:00 +0000 (08:00 +0000)] 
treewide: fix a few typos in NEWS, docs and comments

15 months agoNEWS: mention that the default mDNS mode is now "yes"
Yu Watanabe [Wed, 15 Feb 2023 10:17:54 +0000 (19:17 +0900)] 
NEWS: mention that the default mDNS mode is now "yes"

C.f. issue #25252, PR #25255, and
RHBZ#2169786 (https://bugzilla.redhat.com/show_bug.cgi?id=2169786).

15 months agosrc: fix several typos in log messages
Dmitry V. Levin [Wed, 15 Feb 2023 08:00:00 +0000 (08:00 +0000)] 
src: fix several typos in log messages

15 months agosulogin: use DEFINE_MAIN_FUNCTION()
HATAYAMA Daisuke [Wed, 15 Feb 2023 03:10:13 +0000 (22:10 -0500)] 
sulogin: use DEFINE_MAIN_FUNCTION()

Let's use DEFINE_MAIN_FUNCTION() as the other commands for consistency.

This commit should be no functional change.

15 months agotest-sysusers: add test for basic.conf 26417/head
Yu Watanabe [Wed, 15 Feb 2023 01:49:14 +0000 (10:49 +0900)] 
test-sysusers: add test for basic.conf

15 months agosysusers: also add root group
Yu Watanabe [Wed, 15 Feb 2023 01:29:07 +0000 (10:29 +0900)] 
sysusers: also add root group

Follow-up for 49bb7fe5f88fc35b8529d7d8dfcd4c151a9aaf1a.

Fixes an issue reported at
https://github.com/systemd/systemd/pull/26270#issuecomment-1428945403.

15 months agohwdb: Add HP ENVY x360 2-in-1
Jean-Tiare Le Bigot [Tue, 14 Feb 2023 22:40:38 +0000 (23:40 +0100)] 
hwdb: Add HP ENVY x360 2-in-1

Since #26144, RFKILL events are disabled for HP ENVY x360 Convertible.
This commit adds a variation of the name.

15 months agobootctl: avoid using __WORDSIZE macro
Mike Gilbert [Tue, 14 Feb 2023 19:46:25 +0000 (14:46 -0500)] 
bootctl: avoid using __WORDSIZE macro

__WORDSIZE does not seem to be documented anywhere, and is probably
meant to be used internally by glibc headers.

In systemd, it was only being used in warning messages. We can avoid
using it by rewording the messages slightly.

Fixes a build error with musl libc.

Bug: https://bugs.gentoo.org/894430

15 months agotest-execute: add basic tests for LoadCredential= and SetCredential= 26307/head
Yu Watanabe [Fri, 3 Feb 2023 00:26:56 +0000 (09:26 +0900)] 
test-execute: add basic tests for LoadCredential= and SetCredential=

15 months agotest-execute: drop capabilities when testing with user manager
Yu Watanabe [Fri, 3 Feb 2023 03:28:31 +0000 (12:28 +0900)] 
test-execute: drop capabilities when testing with user manager

Before this, tests are split into two categories, system and user, but
both are running in fully privileged environment. Hence, unprivileged
user scope was mostly not covered by the test.

Let's run all tests in both system and user scopes, and drop capabilities
when Manager is running in user scope.

This also makes the host environment protected more from the test run.

15 months agocore/execute: fix comment
Yu Watanabe [Thu, 2 Feb 2023 18:15:13 +0000 (03:15 +0900)] 
core/execute: fix comment

15 months agotree-wide: fix typo and comment style update
Yu Watanabe [Wed, 15 Feb 2023 01:08:16 +0000 (10:08 +0900)] 
tree-wide: fix typo and comment style update

15 months agorepart: Remove outdated comment 26410/head
Daan De Meyer [Tue, 14 Feb 2023 14:09:54 +0000 (15:09 +0100)] 
repart: Remove outdated comment

15 months agomount-setup: Fix typo
Daan De Meyer [Tue, 14 Feb 2023 14:09:32 +0000 (15:09 +0100)] 
mount-setup: Fix typo

15 months agorepart: Initialize root directory metadata correctly
Daan De Meyer [Tue, 14 Feb 2023 10:19:43 +0000 (11:19 +0100)] 
repart: Initialize root directory metadata correctly

Let's make sure we copy the root directory metadata from an
appropriate source directory.

15 months agorepart: Create temporary root directory using var_tmp_dir()
Daan De Meyer [Tue, 14 Feb 2023 10:17:32 +0000 (11:17 +0100)] 
repart: Create temporary root directory using var_tmp_dir()

This allows users to override the directory used with environment
variables.

15 months agocopy: Copy symlink xattrs
Daan De Meyer [Mon, 13 Feb 2023 20:56:31 +0000 (21:56 +0100)] 
copy: Copy symlink xattrs

Symlinks can have xattrs as well, let's make sure we copy those
as well.

15 months agocopy: Make copy_xattr() more generic
Daan De Meyer [Mon, 13 Feb 2023 20:51:11 +0000 (21:51 +0100)] 
copy: Make copy_xattr() more generic

Let's make copy_xattr() a little more generic in preparation for
copying symlink xattrs.

15 months agoxattr-util: Add xsetxattr()
Daan De Meyer [Mon, 13 Feb 2023 20:49:38 +0000 (21:49 +0100)] 
xattr-util: Add xsetxattr()

Like getxattr_malloc() but for setxattr() and friends.

15 months agotest-boot-timestamp: Handle ERANGE error
Daan De Meyer [Mon, 13 Feb 2023 13:27:24 +0000 (14:27 +0100)] 
test-boot-timestamp: Handle ERANGE error

Timestampfs from sysfs files can be zero in which case ERANGE will
be returned so let's make sure we catch that.

15 months agoboot: Ensure raise() is not dropped by LTO
Jan Janssen [Sun, 12 Feb 2023 19:23:18 +0000 (20:23 +0100)] 
boot: Ensure raise() is not dropped by LTO

15 months agomkosi: Stop installing kernel headers to /usr
Daan De Meyer [Sun, 12 Feb 2023 17:16:06 +0000 (18:16 +0100)] 
mkosi: Stop installing kernel headers to /usr

The selftests automatically pick up the headers from the kernel
build directory so we don't have to install them to /usr ourselves.

15 months agoMerge pull request #26400 from ml-/fix-directory-and-typos
Yu Watanabe [Sun, 12 Feb 2023 08:33:41 +0000 (17:33 +0900)] 
Merge pull request #26400 from ml-/fix-directory-and-typos

Fix directory for user home bind mounts in log error and man page

15 months agoman: fix typos 26400/head
ml [Sat, 11 Feb 2023 23:54:07 +0000 (00:54 +0100)] 
man: fix typos

15 months agoman: fix directory for user home bind mounts
ml [Sat, 11 Feb 2023 23:30:28 +0000 (00:30 +0100)] 
man: fix directory for user home bind mounts

15 months agonspawn: fix directory in logged error
ml [Sat, 11 Feb 2023 23:22:52 +0000 (00:22 +0100)] 
nspawn: fix directory in logged error

15 months agoci(labeler): fix missing emoji in `dont-merge` label
Jan Macku [Sat, 11 Feb 2023 06:38:28 +0000 (07:38 +0100)] 
ci(labeler): fix missing emoji in `dont-merge` label

15 months agoci(labeler): fix missing emoji in `quick-review` label
Jan Macku [Sat, 11 Feb 2023 06:35:07 +0000 (07:35 +0100)] 
ci(labeler): fix missing emoji in `quick-review` label

15 months agoNEWS: update date v253-rc3
Luca Boccassi [Fri, 10 Feb 2023 17:12:31 +0000 (17:12 +0000)] 
NEWS: update date

15 months agoMerge pull request #26392 from bluca/news
Zbigniew Jędrzejewski-Szmek [Fri, 10 Feb 2023 17:05:17 +0000 (18:05 +0100)] 
Merge pull request #26392 from bluca/news

Update hwdb and news

15 months agodissect-image: unknown/unsupported diskseq is indicated by 0, not by UINT64_MAX
Lennart Poettering [Fri, 10 Feb 2023 15:03:46 +0000 (16:03 +0100)] 
dissect-image: unknown/unsupported diskseq is indicated by 0, not by UINT64_MAX

At almost all places if diskseq is not supported we encode this as
diskseq zero. But in two places we got the check for that wrong,
assuming it was UINT64_MAX.

Fix that.

15 months agohwdb: update database 26392/head
Luca Boccassi [Fri, 10 Feb 2023 16:17:24 +0000 (16:17 +0000)] 
hwdb: update database

15 months agoNEWS: update contributors list
Luca Boccassi [Fri, 10 Feb 2023 16:14:06 +0000 (16:14 +0000)] 
NEWS: update contributors list

15 months agocore: when isolating to a unit, also keep units running that are triggered by units...
Lennart Poettering [Fri, 10 Feb 2023 12:38:08 +0000 (13:38 +0100)] 
core: when isolating to a unit, also keep units running that are triggered by units we keep running

Inspired by: #26364

(this might even "fix" #26364, but without debug logs it's hard to make
such claims)

Fixes: #23055
15 months agouserdb: Use json_dispatch_user_group_name() to parse GetMembership fields
Samuel Cabrero [Fri, 10 Feb 2023 13:04:27 +0000 (14:04 +0100)] 
userdb: Use json_dispatch_user_group_name() to parse GetMembership fields

It allows to relax the checks and allow characters like '\', used by
windows to split the domain name and user name.

For reference, discussion in the systemd-devel mailing list:
https://lists.freedesktop.org/archives/systemd-devel/2023-February/048804.html

Signed-off-by: Samuel Cabrero <scabrero@suse.de>
15 months agomkosi: Use globs instead of prepare script to install extra packages
Daan De Meyer [Fri, 10 Feb 2023 14:33:31 +0000 (15:33 +0100)] 
mkosi: Use globs instead of prepare script to install extra packages

This allows us to install everything in the same dnf command instead
of having to use a prepare script to run dnf from within the image.

This is a hack until mkosi supports release specific dropin files.

15 months agoMerge pull request #26387 from bluca/swapon_util_linux
Luca Boccassi [Fri, 10 Feb 2023 14:23:16 +0000 (14:23 +0000)] 
Merge pull request #26387 from bluca/swapon_util_linux

README/NEWS: note that we now explicitly require util-linux's swapon due to new option

15 months agoNEWS: note that we require a swapon that supports --fixpgsz 26387/head
Luca Boccassi [Fri, 10 Feb 2023 12:00:21 +0000 (12:00 +0000)] 
NEWS: note that we require a swapon that supports --fixpgsz

15 months agoREADME: explicitly note that util-linux's mount/swap are required
Luca Boccassi [Fri, 10 Feb 2023 11:58:20 +0000 (11:58 +0000)] 
README: explicitly note that util-linux's mount/swap are required

These are the most visible and hard requirements, as we use options that
busybox does not provide, so list them explicitly to avoid surprises

15 months agocryptenroll: drop deadcode
Yu Watanabe [Fri, 10 Feb 2023 09:22:57 +0000 (18:22 +0900)] 
cryptenroll: drop deadcode

Follow-up for b0fc23fae51d244d2c33d70c10003aa5d5840223.

After the commit, 'signature_path' is now always non-NULL, hence the
condition can be dropped.

Fixes CID#1504492.

15 months agomkosi: Update to latest
Daan De Meyer [Thu, 9 Feb 2023 08:53:05 +0000 (09:53 +0100)] 
mkosi: Update to latest

Let's make sure we're testing unprivileged builds properly. Usage
of SourceFileTransfer= and SourceFileTransferFinal= are removed as
they were dropped by mkosi. SourceFileTransfer=mount is now the
default in mkosi so behavior for the build script is unchanged. We
stop copying sources in the final image until mkosi adds support
for virtiofs.

15 months agoboot: Fix undefined reference to raise() on arm
Jan Janssen [Thu, 9 Feb 2023 20:03:14 +0000 (21:03 +0100)] 
boot: Fix undefined reference to raise() on arm

This is just a workaround. Once we drop gnu-efi, the arm build system
for EFI binaries should be changed to use the arm-none-eabi toolchain,
which should not exhibit this behavior.