]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
2 years agosleep-config: add explanatory comment on "modes" 29265/head
Mike Yuan [Sun, 24 Sep 2023 10:28:54 +0000 (18:28 +0800)] 
sleep-config: add explanatory comment on "modes"

2 years agosleep-config: several cleanups
Mike Yuan [Thu, 21 Sep 2023 06:59:26 +0000 (14:59 +0800)] 
sleep-config: several cleanups

* Rename free_sleep_config to sleep_config_free
* Rearrange functions
* Make SleepConfig.modes and .states only contain
  operations that needs configuration
* Add missing assert

2 years agosleep/battery-capacity: rearrange functions
Mike Yuan [Thu, 21 Sep 2023 05:45:05 +0000 (13:45 +0800)] 
sleep/battery-capacity: rearrange functions

2 years agosleep/battery-capacity: drop unused error-handling
Mike Yuan [Thu, 21 Sep 2023 05:43:31 +0000 (13:43 +0800)] 
sleep/battery-capacity: drop unused error-handling

2 years agosleep/battery-capacity: don't report we have trip alarm if no battery is found
Mike Yuan [Wed, 20 Sep 2023 13:49:31 +0000 (21:49 +0800)] 
sleep/battery-capacity: don't report we have trip alarm if no battery is found

2 years agosleep-util: split into sleep-config and hibernate-util
Mike Yuan [Wed, 27 Sep 2023 13:35:45 +0000 (21:35 +0800)] 
sleep-util: split into sleep-config and hibernate-util

2 years agosleep-util: split battery-capacity into sleep/
Mike Yuan [Wed, 27 Sep 2023 13:35:19 +0000 (21:35 +0800)] 
sleep-util: split battery-capacity into sleep/

This is only used by sleep.c. Let's start shrinking down
the "mixed" sleep-util.

2 years agosleep: rebreak lines in check_wakeup_type
Mike Yuan [Fri, 22 Sep 2023 14:52:56 +0000 (22:52 +0800)] 
sleep: rebreak lines in check_wakeup_type

2 years agosleep-util: move check_wakeup_type to sleep/sleep
Mike Yuan [Wed, 20 Sep 2023 13:19:07 +0000 (21:19 +0800)] 
sleep-util: move check_wakeup_type to sleep/sleep

2 years agoMerge pull request #29296 from yuwata/sd-journal-several-cleanups-for-boot-id
Zbigniew Jędrzejewski-Szmek [Wed, 27 Sep 2023 12:56:48 +0000 (14:56 +0200)] 
Merge pull request #29296 from yuwata/sd-journal-several-cleanups-for-boot-id

2 years agotest: introduce TEST-09-REBOOT
Frantisek Sumsal [Sat, 23 Sep 2023 16:17:04 +0000 (18:17 +0200)] 
test: introduce TEST-09-REBOOT

To test stuff involving state preserved across (multiple) reboots, like
journal boot IDs.

2 years agoMerge pull request #29296 from keszybz/make-cryptsetup-offical-and-add-docs
Luca Boccassi [Wed, 27 Sep 2023 12:31:11 +0000 (13:31 +0100)] 
Merge pull request #29296 from keszybz/make-cryptsetup-offical-and-add-docs

Make cryptsetup offical and add docs

2 years agounits/blockdev@.target: conflict with umount.target
Mike Yuan [Tue, 26 Sep 2023 22:26:38 +0000 (06:26 +0800)] 
units/blockdev@.target: conflict with umount.target

Follow-up for d120ce478dc0043c89899799b5c1aaf62901bea9

blockdev@.target is used as a synchronization point between
the mount unit and corresponding systemd-cryptsetup@.service.
After the mentioned commit, it doesn't get a stop job enqueued
during shutdown, and thus the stop job for systemd-cryptsetup@.service
could be run before the mount unit is stopped.

Therefore, let's make blockdev@.target conflict with umount.target,
which is also what systemd-cryptsetup@.service does.

Fixes #29336

2 years agondisc: Also set link hoplimit
Susant Sahani [Fri, 8 Sep 2023 09:00:38 +0000 (14:30 +0530)] 
ndisc: Also set link hoplimit

The per route hop limit does not place the hop limit in the IPv6 header.
https://github.com/systemd/systemd/issues/28437#issuecomment-1711055181

2 years agoRevert "userdbd: Order systemd-userdbd.service after systemd-remount-fs.service"
Lennart Poettering [Tue, 5 Sep 2023 08:17:41 +0000 (10:17 +0200)] 
Revert "userdbd: Order systemd-userdbd.service after systemd-remount-fs.service"

This reverts commit 9dd88582813b6dbeea6ce336f70cae681e6cbfc6.

2 years agofix typo in NEWS
Christian Hesse [Wed, 27 Sep 2023 07:16:06 +0000 (09:16 +0200)] 
fix typo in NEWS

Looks like `-a change` is a typo and should have been `-c change` to
match on the action.

2 years agopo: Translated using Weblate (Hungarian)
Balázs Úr [Wed, 27 Sep 2023 01:36:03 +0000 (03:36 +0200)] 
po: Translated using Weblate (Hungarian)

Currently translated at 100.0% (227 of 227 strings)

Co-authored-by: Balázs Úr <balazs@urbalazs.hu>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/hu/
Translation: systemd/main

2 years agoupdate-dbus-docs: Test that items are documented in the History section
Abderrahim Kitouni [Sun, 24 Sep 2023 08:13:45 +0000 (09:13 +0100)] 
update-dbus-docs: Test that items are documented in the History section

This also adds an ignore list, which currently contains the whole API as of
version 250, since that's the base we used for dbus interfaces.

See d9d2d16aeaf7c18a7b2486cd7c2db484c99050df

2 years agonetwork: Rename json_append_one() and move to json.h
Daan De Meyer [Tue, 26 Sep 2023 14:47:52 +0000 (16:47 +0200)] 
network: Rename json_append_one() and move to json.h

2 years agojournal: Stop trying to open runtime journal once flushed
Daan De Meyer [Tue, 26 Sep 2023 13:59:23 +0000 (15:59 +0200)] 
journal: Stop trying to open runtime journal once flushed

Once we've flushed the runtime journal to /var, stop trying to open
it since that will just fail with ENOENT all the time.

2 years agomeson: Fix version script handling
Jan Janssen [Tue, 26 Sep 2023 13:14:38 +0000 (15:14 +0200)] 
meson: Fix version script handling

Build targets should have a link dependency on the version scripts they
use. This also uses absolute paths in anticipation for meson 1.3
needlessly deprecating file to string conversions.

2 years agosystemd-hwdb: fix unsigned and signed comparison problem
huyubiao [Tue, 26 Sep 2023 06:46:55 +0000 (14:46 +0800)] 
systemd-hwdb: fix unsigned and signed comparison problem
...
uint8_t c;
struct trie_node *child;

for (p = 0; (c = trie->strings->buf[node->prefix_off + p]); p++) {
        _cleanup_free_ struct trie_node *new_child = NULL;
        _cleanup_free_ char *s = NULL;
        ssize_t off;
if (c == search[i + p])
        continue;
...
When '®' is present in search, c is 194, search[i + p] is -62, c is not equal to search[i + p], but c should be equal to search[i + p].

2 years agoman: rename systemd-cryptsetup@.service → systemd-cryptsetup 29296/head
Zbigniew Jędrzejewski-Szmek [Sat, 23 Sep 2023 11:43:55 +0000 (13:43 +0200)] 
man: rename systemd-cryptsetup@.service → systemd-cryptsetup

We already had the other name as alias, so this just changes what is the "main"
name. The text is adjusted to describe the command briefly.

2 years agoTEST-70: use new cryptsetup path
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 16:50:37 +0000 (18:50 +0200)] 
TEST-70: use new cryptsetup path

2 years agomeson: add comments to compat symlinks
Zbigniew Jędrzejewski-Szmek [Tue, 26 Sep 2023 15:03:15 +0000 (17:03 +0200)] 
meson: add comments to compat symlinks

2 years agomeson: move systemd-cryptsetup to /usr/bin
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 16:47:05 +0000 (18:47 +0200)] 
meson: move systemd-cryptsetup to /usr/bin

This was requested, though I think an issue was never filed. If people are
supposed to invoke it, even for testing, then it's reasonable to make it
"public".

2 years agocryptsetup: fail with error if extraneous arguments are specified
Zbigniew Jędrzejewski-Szmek [Sat, 23 Sep 2023 09:59:55 +0000 (11:59 +0200)] 
cryptsetup: fail with error if extraneous arguments are specified

So far the program would silently ignore those… I think it's better to fail.

2 years agocryptsetup: add parse_argv() and implement --version
Zbigniew Jędrzejewski-Szmek [Sat, 23 Sep 2023 09:56:13 +0000 (11:56 +0200)] 
cryptsetup: add parse_argv() and implement --version

All public programs are expected to have that. The --help output is adjusted to
follow the usual style (highlighting, listing of options). The OPTIONS
positional argument is renamed to "CONFIG", because we now also have "OPTIONS…"
to describe the non-positional options.

2 years agocryptenroll: align tables
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 18:36:44 +0000 (20:36 +0200)] 
cryptenroll: align tables

2 years agoman/crypttab: fix indentation
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 16:37:55 +0000 (18:37 +0200)] 
man/crypttab: fix indentation

2 years agoman/crypttab: add a more comprehensive example of encrypted device setup
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 16:37:49 +0000 (18:37 +0200)] 
man/crypttab: add a more comprehensive example of encrypted device setup

2 years agoman/crypttab: do not recommend using /dev/sdX symlinks in /etc/crypttab
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 16:27:10 +0000 (18:27 +0200)] 
man/crypttab: do not recommend using /dev/sdX symlinks in /etc/crypttab

This is just wrong. Quering the symlink names with udevadm is not the
easiest, but I think that's the safest way for a documented example.

2 years agoman/cryptenroll: link to crypttab(5) for examples
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 15:55:39 +0000 (17:55 +0200)] 
man/cryptenroll: link to crypttab(5) for examples

I was missing an example of how to use cryptenroll. We have that, but in
another page. Instead of repeating, let's just direct the user to the right
place.

Also, reformat synopsis to the "official" non-nested syntax.

2 years agoadd support for hp pavilion gaming 15 lid switch (#29304)
beh_10257 [Tue, 26 Sep 2023 12:32:03 +0000 (12:32 +0000)] 
add support for hp pavilion gaming 15 lid switch (#29304)

Tested together with kernel patch: https://lore.kernel.org/linux-acpi/20230920130506.8595-1-hdegoede@redhat.com/
but the d7 key is still interpreted as a wlan key switch, so an hwdb update is needed.

Raw dmi:

dmi:bvnInsyde:bvrF.45:bd07/07/2023:br15.45:efr2.51:svnHP:pnHPPavilionGamingLaptop15-dk1xxx:pvrType1ProductConfigId:rvnHP:rn8742:rvr02.51:cvnHP:ct10:cvrChassisVersion:sku20T68EA#BH4::

Related to: https://github.com/systemd/systemd/issues/28942

2 years agoRevert "man: Add /usr/local/lib path to Synopsis section for modules-load"
Lennart Poettering [Tue, 26 Sep 2023 08:05:20 +0000 (10:05 +0200)] 
Revert "man: Add /usr/local/lib path to Synopsis section for modules-load"

This reverts commit 17811767687fcee3b96333f724c5cdf3df11ae86.

2 years agoudev: raise RLIMIT_NOFILE as high as we can
Lennart Poettering [Tue, 26 Sep 2023 07:52:05 +0000 (09:52 +0200)] 
udev: raise RLIMIT_NOFILE as high as we can

We might need a lot of fds on large systems, hence raise RLIMIT_NOFILE
to what the service manager allows us, which is quite a lot these days.

udev already sets FORK_RLIMIT_NOFILE_SAFE when forking of chilren, thus
ensuring that forked off processes get their RLIMIT_NOFILE soft limit
reset to 1K for compat with crappy old select().

Replaces: #29298
Fixes: #28583
2 years agovarlink: remove duplicate varlink_clear_current()
Lennart Poettering [Tue, 26 Sep 2023 07:38:12 +0000 (09:38 +0200)] 
varlink: remove duplicate varlink_clear_current()

2 years agocore/service: log the next restart usec only when we're arming timer
Mike Yuan [Mon, 25 Sep 2023 15:23:29 +0000 (23:23 +0800)] 
core/service: log the next restart usec only when we're arming timer

service_restart_usec_next() is also called when querying
'RestartUSecNext' dbus property. Let's avoid the redundant
logging triggered every time user does a 'systemctl status'.

2 years agoman: Add /usr/local/lib path to Synopsis section for modules-load
Raul Cheleguini [Tue, 26 Sep 2023 01:57:05 +0000 (22:57 -0300)] 
man: Add /usr/local/lib path to Synopsis section for modules-load

2 years agotest: add test case that journal file with unreferenced _BOOT_ID data
Yu Watanabe [Sun, 24 Sep 2023 17:57:31 +0000 (02:57 +0900)] 
test: add test case that journal file with unreferenced _BOOT_ID data

For issue #29275.

2 years agosd-journal: always fallback to find entry by realtime
Yu Watanabe [Sun, 24 Sep 2023 17:00:41 +0000 (02:00 +0900)] 
sd-journal: always fallback to find entry by realtime

Consider the following situation:
- There are two journal files (x and y), that contains entries for two boots (X and Y).
- The journal file x contains entries of the boot X, and y contains
  entries of Y.
- Nevertheless x does not contains entries of boot Y, it contains
  the _BOOT_ID= data object of boot Y. Of course, the data object is not
  referenced by any entries in the journal file x.

In such situation, when the current location of sd_journal is the head
of journal y, that is, the first entry of the boot Y,
sd_journal_previous() failed without this change, and
'journalctl --boot -NUM' for boot X failed.

Fixes #29275.

2 years agotest: add tests for journal_find_boot_by_offset() and friends
Yu Watanabe [Sat, 23 Sep 2023 06:14:18 +0000 (15:14 +0900)] 
test: add tests for journal_find_boot_by_offset() and friends

2 years agologs-show: use sd_journal_step_one()
Yu Watanabe [Sat, 23 Sep 2023 18:31:14 +0000 (03:31 +0900)] 
logs-show: use sd_journal_step_one()

2 years agologs-show: move journal_find_boot_by_offset() and friends from journalctl.c
Yu Watanabe [Sat, 23 Sep 2023 00:55:45 +0000 (09:55 +0900)] 
logs-show: move journal_find_boot_by_offset() and friends from journalctl.c

2 years agojournalctl: several cleanups for find_boot_by_offset()/_by_id()
Yu Watanabe [Sat, 23 Sep 2023 00:35:55 +0000 (09:35 +0900)] 
journalctl: several cleanups for find_boot_by_offset()/_by_id()

- their names are prefixed with "journal_",
- make them not directly use global variables,
- simplifies the loop counter in find_boot_by_offset().

2 years agosd-journal: refuse to write entry without boot ID
Yu Watanabe [Fri, 22 Sep 2023 19:14:31 +0000 (04:14 +0900)] 
sd-journal: refuse to write entry without boot ID

To make journal entries always contain valid boot ID.

2 years agosd-journal: boot_id is always non-NULL
Yu Watanabe [Fri, 22 Sep 2023 17:42:31 +0000 (02:42 +0900)] 
sd-journal: boot_id is always non-NULL

The two callers of journal_file_append_entry_internal() always pass
non-NULL boot ID.

2 years agosd-journal: also verify tail_entry_boot_id and friends in journal_file_verify_header()
Yu Watanabe [Fri, 22 Sep 2023 18:14:40 +0000 (03:14 +0900)] 
sd-journal: also verify tail_entry_boot_id and friends in journal_file_verify_header()

Then, we can drop the redundant check in journal_file_read_tail_timestamp().

2 years agotest: fix header verification
Yu Watanabe [Fri, 22 Sep 2023 17:28:04 +0000 (02:28 +0900)] 
test: fix header verification

2 years agoman: document SystemState's possible values
Luca Boccassi [Mon, 25 Sep 2023 18:14:58 +0000 (19:14 +0100)] 
man: document SystemState's possible values

2 years agoman: add version information for udev functions
Abderrahim Kitouni [Tue, 19 Sep 2023 08:04:56 +0000 (09:04 +0100)] 
man: add version information for udev functions

2 years agoMerge pull request #29314 from YHNdnzj/firstboot-fixup
Luca Boccassi [Mon, 25 Sep 2023 21:29:24 +0000 (22:29 +0100)] 
Merge pull request #29314 from YHNdnzj/firstboot-fixup

Small fixups for first boot

2 years agoMerge pull request #29309 from poettering/resolved-varlink-tweaks
Lennart Poettering [Mon, 25 Sep 2023 21:27:33 +0000 (23:27 +0200)] 
Merge pull request #29309 from poettering/resolved-varlink-tweaks

resolved: minor varlink API tweaks

2 years agooomd: correct listening sockets
Lennart Poettering [Mon, 25 Sep 2023 16:10:50 +0000 (18:10 +0200)] 
oomd: correct listening sockets

So, unfortunately oomd uses "io.system." rather than "io.systemd." as
prefix for its sockets. This is a mistake, and doesn't match the
Varlink interface naming or anything else in oomd.

hence, let's fix that.

Given that this is an internal protocol between PID1 and oomd let's
simply change this without retaining compat.

2 years agovarlink: move O_NONBLOCK setting to varlink_server_listen_fd(), and set O_CLOEXEC too
Lennart Poettering [Mon, 25 Sep 2023 14:04:01 +0000 (16:04 +0200)] 
varlink: move O_NONBLOCK setting to varlink_server_listen_fd(), and set O_CLOEXEC too

Let's move setting of O_NONBLOCK into varlink_server_listen_fd() and out
of varlink_server_create_listen_fd_socket(). The latter has two callers:
varlink_server_listen_fd() and varlink_server_listen_address(), which
guarantees O_CLOEXEC+O_NONBLOCK anyway, hence no neet to repeat the
logic.

2 years agoMerge pull request #29315 from poettering/strgrowpad0
Lennart Poettering [Mon, 25 Sep 2023 21:26:47 +0000 (23:26 +0200)] 
Merge pull request #29315 from poettering/strgrowpad0

string-util: make strgrowpad0() safer

2 years agoMerge pull request #29308 from aafeijoo-suse/dissect-fix
Luca Boccassi [Mon, 25 Sep 2023 18:16:08 +0000 (19:16 +0100)] 
Merge pull request #29308 from aafeijoo-suse/dissect-fix

dissect: fix man and bash-completion

2 years agorepart: add extra safety check that the verity signature fits in the partition we... 29315/head
Lennart Poettering [Mon, 25 Sep 2023 17:07:09 +0000 (19:07 +0200)] 
repart: add extra safety check that the verity signature fits in the partition we want to write

2 years agostring-util: make strgrowpad0() a bit safer
Lennart Poettering [Mon, 25 Sep 2023 17:06:06 +0000 (19:06 +0200)] 
string-util: make strgrowpad0() a bit safer

Let#s make sure we never shorten the allocation leaving an invalid
string (i.e. a memory allocation without a trailing NUL) around.

2 years agoman/systemd-firstboot: /etc/ empty -> unpopulated 29314/head
Mike Yuan [Mon, 25 Sep 2023 17:01:57 +0000 (01:01 +0800)] 
man/systemd-firstboot: /etc/ empty -> unpopulated

We use the phrase "unpopulated" in systemd.unit(5) too.
And "/etc/ is empty" is simply spurious.

2 years agocore/main: log that we assume first boot if failed to read machine-id
Mike Yuan [Mon, 25 Sep 2023 17:00:23 +0000 (01:00 +0800)] 
core/main: log that we assume first boot if failed to read machine-id

2 years agoalloc-util: remove duplicate empty line
Lennart Poettering [Fri, 22 Sep 2023 20:21:45 +0000 (22:21 +0200)] 
alloc-util: remove duplicate empty line

2 years agoresolved: rename varlink function to match exposed method name 29309/head
Lennart Poettering [Fri, 22 Sep 2023 20:38:06 +0000 (22:38 +0200)] 
resolved: rename varlink function to match exposed method name

2 years agoresolved: also expose interface index in server JSON data
Lennart Poettering [Fri, 22 Sep 2023 20:37:37 +0000 (22:37 +0200)] 
resolved: also expose interface index in server JSON data

2 years agoMerge pull request #29301 from poettering/pcr-extend-rename
Lennart Poettering [Mon, 25 Sep 2023 16:28:03 +0000 (18:28 +0200)] 
Merge pull request #29301 from poettering/pcr-extend-rename

rename pcrphase binary to pcrextend

2 years agoman: briefly document that we are now keeping an event log in userspace for out measu... 29301/head
Lennart Poettering [Mon, 25 Sep 2023 09:09:34 +0000 (11:09 +0200)] 
man: briefly document that we are now keeping an event log in userspace for out measurements

2 years agopcrextend: make PCR index configurable
Lennart Poettering [Mon, 25 Sep 2023 08:51:56 +0000 (10:51 +0200)] 
pcrextend: make PCR index configurable

Let's make the tool a tiny bit more generic by allowing the PCR index to
measure into to be configurable.

2 years agopcrphase: rename binary to pcrextend
Lennart Poettering [Mon, 25 Sep 2023 08:38:01 +0000 (10:38 +0200)] 
pcrphase: rename binary to pcrextend

The tool initially just measured the boot phase, but was subsequently
extended to measure file system and machine IDs, too. At AllSystemsGo
there were request to add more, and make the tool generically
accessible.

Hence, let's rename the binary (but not the pcrphase services), to make
clear the tool is not just measureing the boot phase, but a lot of other
things too.

The tool is located in /usr/lib/ and still relatively new, hence let's
just rename the binary and be done with it, while keeping the unit names
stable.

While we are at it, also move the tool out of src/boot/ and into its own
src/pcrextend/ dir, since it's not really doing boot related stuff
anymore.

2 years agobash-completion: add missing commands and options to systemd-dissect 29308/head
Antonio Alvarez Feijoo [Mon, 25 Sep 2023 14:46:11 +0000 (16:46 +0200)] 
bash-completion: add missing commands and options to systemd-dissect

2 years agotest: enable debug logs for the user instances as well
Frantisek Sumsal [Mon, 25 Sep 2023 11:25:27 +0000 (13:25 +0200)] 
test: enable debug logs for the user instances as well

To make debugging [0], hopefully, easier.

[0] https://github.com/systemd/systemd/issues/28504

2 years agoMerge pull request #29303 from abderrahim/syntax-fixes
Luca Boccassi [Mon, 25 Sep 2023 14:23:48 +0000 (15:23 +0100)] 
Merge pull request #29303 from abderrahim/syntax-fixes

man: a couple of small fixes

2 years agoman/systemd-dissect: various fixes
Antonio Alvarez Feijoo [Mon, 25 Sep 2023 14:16:41 +0000 (16:16 +0200)] 
man/systemd-dissect: various fixes

- Add synopsis to `--discover` and `--validate` options.
- `-l` is for `--list`, not for `--mtree`.

2 years agoman: fix docbook syntax for function docs 29303/head
Abderrahim Kitouni [Mon, 25 Sep 2023 12:14:13 +0000 (13:14 +0100)] 
man: fix docbook syntax for function docs

This fixes sd_bus_error_add_map and man/sd_uid_get_state

2 years agoman/kernel-command-line: don't refer early_core_pattern to systemd
Abderrahim Kitouni [Mon, 25 Sep 2023 12:12:46 +0000 (13:12 +0100)] 
man/kernel-command-line: don't refer early_core_pattern to systemd

It is defined later in the same file

2 years agodocs/FDS: add missing article and reword sentence
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 13:14:40 +0000 (15:14 +0200)] 
docs/FDS: add missing article and reword sentence

2 years agoupdate TODO
Lennart Poettering [Mon, 25 Sep 2023 10:23:12 +0000 (12:23 +0200)] 
update TODO

2 years agomkosi: Run meson and ninja as the user invoking mkosi
Daan De Meyer [Mon, 25 Sep 2023 09:02:13 +0000 (11:02 +0200)] 
mkosi: Run meson and ninja as the user invoking mkosi

Latest mkosi sets $MKOSI_UID and $MKOSI_GID to the uid/gid of the
user running mkosi. Let's make use of this to run meson setup and
ninja as the user running mkosi, so that if we execute git as a
subprocess during meson setup, it doesn't complain about unsafe
directories. This also makes sure all the build artifacts are owned
on the host by the user running mkosi.

2 years agopo: Translated using Weblate (Korean)
김인수 [Mon, 25 Sep 2023 03:36:02 +0000 (05:36 +0200)] 
po: Translated using Weblate (Korean)

Currently translated at 100.0% (227 of 227 strings)

Co-authored-by: 김인수 <simmon@nplob.com>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/ko/
Translation: systemd/main

2 years agosd-dhcp-client: reject NAKs from servers that we did not send an offer to (#29290)
Alexandre Peixoto Ferreira [Mon, 25 Sep 2023 02:46:41 +0000 (21:46 -0500)] 
sd-dhcp-client: reject NAKs from servers that we did not send an offer to (#29290)

To support multiple DHCP servers in a network.

2 years agohwdb: ieee1394-unit-function: add Miglia Technology Harmony Audio (HA02)
Takashi Sakamoto [Sun, 24 Sep 2023 03:14:25 +0000 (12:14 +0900)] 
hwdb: ieee1394-unit-function: add Miglia Technology Harmony Audio (HA02)

This commit adds hwdb entry for Miglia Technology Harmony Audio (HA02).
The device is an application of OXford Semiconductor FW970 and will be
supported by ALSA oxfw driver in future.

2 years agotest: wait for the swtpm socket to appear
Frantisek Sumsal [Sat, 23 Sep 2023 07:13:56 +0000 (09:13 +0200)] 
test: wait for the swtpm socket to appear

On slower/overloaded systems it may take a bit for the swtpm socket
to show up:

I: Started swtpm as PID 189419 with state dir /tmp/tmp.pWqUutuGUj
I: Configured emulated TPM2 device tpm-spapr
+ tee /var/tmp/systemd-test-TEST-70-TPM2_1/console.log
+ timeout --foreground 1200 /bin/qemu-system-ppc64le -smp 4 ...
qemu-system-ppc64le: -chardev socket,id=chrtpm,path=/tmp/tmp.pWqUutuGUj/sock: Failed to connect to '/tmp/tmp.pWqUutuGUj/sock': No such file or directory
E: qemu failed with exit code 1

Spotted regularly in the ppc64le cron job and in some Ubuntu CI/CentOS CI
pr runs [0].

[0] https://github.com/systemd/systemd/pull/29183#issuecomment-1721727927

2 years agotest: don't panic on soft lockups
Frantisek Sumsal [Fri, 22 Sep 2023 19:41:34 +0000 (21:41 +0200)] 
test: don't panic on soft lockups

We can't do anything about them anyway, and most importantly this seems
to alleviate systemd/systemd-centos-ci#660, which should make the CIs
a bit less angry (at least until the issue is addressed properly).

2 years agoMerge pull request #29254 from yuwata/sd-ndisc-use-usec_t
Luca Boccassi [Fri, 22 Sep 2023 20:46:50 +0000 (21:46 +0100)] 
Merge pull request #29254 from yuwata/sd-ndisc-use-usec_t

sd-ndisc: make sd_ndisc return time values in usec

2 years agoMerge pull request #29258 from yuwata/sd-dhcp-client-split-out
Luca Boccassi [Fri, 22 Sep 2023 20:46:31 +0000 (21:46 +0100)] 
Merge pull request #29258 from yuwata/sd-dhcp-client-split-out

sd-dhcp-client: preparation for later PR

2 years agosd-dhcp-client: split out client_parse_message() 29258/head
Yu Watanabe [Wed, 20 Sep 2023 19:39:49 +0000 (04:39 +0900)] 
sd-dhcp-client: split out client_parse_message()

No functional change, just refactoring and preparation for later
commits.

2 years agosd-dhcp-client: introduce dhcp_lease_unref_and_replace()
Yu Watanabe [Wed, 20 Sep 2023 19:37:18 +0000 (04:37 +0900)] 
sd-dhcp-client: introduce dhcp_lease_unref_and_replace()

2 years agosd-dhcp-client: do not set fallback subnet mask if it is already set
Yu Watanabe [Wed, 20 Sep 2023 05:32:38 +0000 (14:32 +0900)] 
sd-dhcp-client: do not set fallback subnet mask if it is already set

2 years agosd-dhcp-client: split out client_enter_requesting()
Yu Watanabe [Wed, 20 Sep 2023 04:37:53 +0000 (13:37 +0900)] 
sd-dhcp-client: split out client_enter_requesting()

No functional change, just refactoring and preparation for later
commits.

2 years agosd-dhcp-client: split out client_enter_bound()
Yu Watanabe [Wed, 20 Sep 2023 03:23:54 +0000 (12:23 +0900)] 
sd-dhcp-client: split out client_enter_bound()

No functional change, just refactoring and preparation for later
commits.

2 years agosd-ndisc: make sd_ndisc return time values in usec 29254/head
Yu Watanabe [Thu, 21 Sep 2023 17:18:06 +0000 (02:18 +0900)] 
sd-ndisc: make sd_ndisc return time values in usec

This also introduces sd_ndisc_router_get_lifetime_timestamp() and
friends that return timestamp rather than timespan.

2 years agobtrfs-util: fix one memory leak
Mike Yuan [Tue, 19 Sep 2023 16:37:11 +0000 (00:37 +0800)] 
btrfs-util: fix one memory leak

Follow-up for efb6a76a2a097132087ee30720421136cba9e708

2 years agoAdd recommended initramfs regeneration
RoepLuke [Thu, 21 Sep 2023 21:52:04 +0000 (23:52 +0200)] 
Add recommended initramfs regeneration

I recently tried adding a FIDO2-Device as an unlocking method to the LUKS2 partition containing my Fedora install.
When trying to do this, I stumbled upon the here edited man files detailing how to do this.
I however could not unlock my partition with my FIDO2-Device after editing /etc/crypttab and rebooting.
As I found out after a while, I needed to regenerate / update my currently running / used initramfs (https://unix.stackexchange.com/a/705809).
This would have most likely solved itself for me with the next kernel update install (as far as I understand).
So I propose changing the files edited here to recommend or at least inform the user about this.

2 years agorepart: Don't fail on boot if we can't find the root block device
Daan De Meyer [Fri, 22 Sep 2023 11:47:14 +0000 (13:47 +0200)] 
repart: Don't fail on boot if we can't find the root block device

When booting from virtiofs, we won't be able to find a root block
device. Let's gracefully handle this similar to how we don't fail
if we can't find a GPT partition table.

2 years agoMerge pull request #29282 from YHNdnzj/hibernate-resume-meson
Luca Boccassi [Fri, 22 Sep 2023 14:46:09 +0000 (15:46 +0100)] 
Merge pull request #29282 from YHNdnzj/hibernate-resume-meson

hibernate-resume: minor follow-up for meson and header file

2 years agohibernate-resume: add missing #pragma once 29282/head
Mike Yuan [Fri, 22 Sep 2023 13:03:48 +0000 (21:03 +0800)] 
hibernate-resume: add missing #pragma once

2 years agohibernate-resume: break lines in meson.build files()
Mike Yuan [Fri, 22 Sep 2023 13:02:55 +0000 (21:02 +0800)] 
hibernate-resume: break lines in meson.build files()

2 years agoMerge pull request #29224 from keszybz/netdev-config-parsing
Zbigniew Jędrzejewski-Szmek [Fri, 22 Sep 2023 12:29:47 +0000 (14:29 +0200)] 
Merge pull request #29224 from keszybz/netdev-config-parsing

Use a helper to simplify parsing of ranges in netdev config and related changes

2 years agomkosi: Don't skip initrd dependency when building a directory image
Daan De Meyer [Fri, 22 Sep 2023 11:10:28 +0000 (13:10 +0200)] 
mkosi: Don't skip initrd dependency when building a directory image

mkosi now supports booting directory images in qemu using virtiofs.
However, until distribution kernels build the virtiofs driver directly
into the kernel, we need an initrd to make this work, so make sure to
pull in the initrd preset when building a directory image that could be
bootable to make this work.

2 years agonetdev/wireguard: define iterator variable in the loop 29224/head
Zbigniew Jędrzejewski-Szmek [Thu, 21 Sep 2023 10:56:37 +0000 (12:56 +0200)] 
netdev/wireguard: define iterator variable in the loop

2 years agonetwork: make DEFINE_NETDEV_CAST() assert on input and output
Zbigniew Jędrzejewski-Szmek [Thu, 21 Sep 2023 10:52:26 +0000 (12:52 +0200)] 
network: make DEFINE_NETDEV_CAST() assert on input and output

The macro used to return NULL if input was NULL or had the wrong type. Now
it asserts that input is nonnull and it has the expected type.

There are a few places where a missing or mismatched type was OK, but in a
majority of places, we would do both of the asserts. In various places we'd
only do one, but that was by ommission/mistake. So moving the asserts into the
macro allows us to save some lines.