]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
15 months agoman: fix explanation for Credential= match in .link files
Дамјан Георгиевски [Mon, 23 Jan 2023 23:43:00 +0000 (00:43 +0100)] 
man: fix explanation for Credential= match in .link files

.link files are handled by systemd-udevd, not by systemd-networkd,
so fix the man page to say that the Credential= match uses credentials set
on the systemd-udevd.service

15 months agoMerge pull request #26167 from ldv-alt/docs-fixes
Zbigniew Jędrzejewski-Szmek [Tue, 24 Jan 2023 09:20:30 +0000 (10:20 +0100)] 
Merge pull request #26167 from ldv-alt/docs-fixes

docs: fix a few relatively trivial issues

15 months agoMerge pull request #26164 from mrc0mmand/test-bus-timeout
Frantisek Sumsal [Tue, 24 Jan 2023 08:49:29 +0000 (08:49 +0000)] 
Merge pull request #26164 from mrc0mmand/test-bus-timeout

test: bump the client-side timeout in sd-bus as well

15 months agoMerge pull request #26159 from keszybz/capacity-to-crash
Zbigniew Jędrzejewski-Szmek [Tue, 24 Jan 2023 06:52:36 +0000 (07:52 +0100)] 
Merge pull request #26159 from keszybz/capacity-to-crash

Resolve crash in systemd-sleep and other minor fixes

15 months agoMerge pull request #26110 from medhefgo/boot-no-gnu-efi
Luca Boccassi [Mon, 23 Jan 2023 23:51:49 +0000 (23:51 +0000)] 
Merge pull request #26110 from medhefgo/boot-no-gnu-efi

boot: Stop linking against libefi.a

15 months agodocs, man: consistently use comma after "For example" 26167/head
Dmitry V. Levin [Sun, 15 Jan 2023 08:00:00 +0000 (08:00 +0000)] 
docs, man: consistently use comma after "For example"

15 months agoMerge pull request #26162 from YHNdnzj/machinectl-check-target-enabled
Luca Boccassi [Mon, 23 Jan 2023 22:52:34 +0000 (22:52 +0000)] 
Merge pull request #26162 from YHNdnzj/machinectl-check-target-enabled

machinectl: also enable machines.target when enabling machines

15 months agodocs: fix formatting a bit
Dmitry V. Levin [Sun, 15 Jan 2023 08:00:00 +0000 (08:00 +0000)] 
docs: fix formatting a bit

15 months agodocs: fix grammar a bit
Dmitry V. Levin [Sun, 15 Jan 2023 08:00:00 +0000 (08:00 +0000)] 
docs: fix grammar a bit

15 months agodocs: fix a few typos
Dmitry V. Levin [Sun, 15 Jan 2023 08:00:00 +0000 (08:00 +0000)] 
docs: fix a few typos

15 months agoboot: Use objcopy with arm64
Callum Farmer [Thu, 12 Jan 2023 19:19:56 +0000 (19:19 +0000)] 
boot: Use objcopy with arm64

Binutils 2.38 added support for efi-app-aarch64
Still use binary mode if we have an older objcopy
Add check for incompatible gnu-efi crt0 containing the header section
which gets added by objcopy and if used results in duplicate header
and subsequently a broken binary

Signed-off-by: Callum Farmer <gmbr3@opensuse.org>
15 months agosleep: fix memleak 26159/head
Zbigniew Jędrzejewski-Szmek [Mon, 23 Jan 2023 14:50:36 +0000 (15:50 +0100)] 
sleep: fix memleak

Those hashmaps are created anew in each iteration of the loop. The
leak wasn't really a problem, because the loop is bounded and the
hashmaps were not huge, but it's nicer to be correct.

15 months agosleep: reduce double logging and improve messages and comments a bit
Zbigniew Jędrzejewski-Szmek [Mon, 23 Jan 2023 14:47:58 +0000 (15:47 +0100)] 
sleep: reduce double logging and improve messages and comments a bit

read_battery_capacity_percentage() was already logging, but with a slightly
different wording.

More could be done, I just touched the most noticable places. Especially
in debug messages, it is much more useful to be direct about what couldn't
be accessed or parsed, instead of providing "descriptive names" which are
not useful to the user at all, who then needs to read the code to figure out
what was the actual property name.

15 months agotest-sleep: add a very simple test that prints battery suspend estimates
Zbigniew Jędrzejewski-Szmek [Mon, 23 Jan 2023 14:44:33 +0000 (15:44 +0100)] 
test-sleep: add a very simple test that prints battery suspend estimates

15 months agosleep: do not abort if we try to query capacity of missing battery
Zbigniew Jędrzejewski-Szmek [Mon, 23 Jan 2023 14:43:35 +0000 (15:43 +0100)] 
sleep: do not abort if we try to query capacity of missing battery

Fixes #25584.

From the issue:
Assertion 'capacity >= 0' failed at src/shared/sleep-config.c:58, function PTR_TO_CAPACITY(). Aborting.

(gdb) bt

The problem is that PTR_TO_CAPACITY(hashmap_get(last_capacity, battery_name))
will abort if it's called with a name not present in the hashmap. We want to
skip the device silently in this case instead.

15 months agoMerge pull request #26153 from DaanDeMeyer/repart-remove-userns
Zbigniew Jędrzejewski-Szmek [Mon, 23 Jan 2023 20:46:55 +0000 (21:46 +0100)] 
Merge pull request #26153 from DaanDeMeyer/repart-remove-userns

mkfs-util: Remove user namespace owner => root mapping

15 months agocore: ensure init.scope is realized after drop-ins have been loaded
Luca Boccassi [Fri, 20 Jan 2023 23:00:38 +0000 (23:00 +0000)] 
core: ensure init.scope is realized after drop-ins have been loaded

If we add a drop-in for init.scope (e.g.: to set some memory limit),
it will be loaded long after the cgroup has already been realized.
Do it again when creating the special unit.

15 months agobuild: add some coloring to --version output
Lennart Poettering [Mon, 23 Jan 2023 15:23:45 +0000 (16:23 +0100)] 
build: add some coloring to --version output

Make it easier to discern enabled and disabled build options.

15 months agoMerge pull request #26157 from medhefgo/meson
Luca Boccassi [Mon, 23 Jan 2023 19:41:51 +0000 (19:41 +0000)] 
Merge pull request #26157 from medhefgo/meson

meson: Small improvements

15 months agoMerge pull request #25805 from yuwata/locale-xkb-save-vconsole
Luca Boccassi [Mon, 23 Jan 2023 19:40:12 +0000 (19:40 +0000)] 
Merge pull request #25805 from yuwata/locale-xkb-save-vconsole

locale: also save X11 keyboard settings to /etc/vconsole.conf

15 months agotest: bump the container spawn timeout to 60s 26164/head
Frantisek Sumsal [Mon, 23 Jan 2023 18:13:49 +0000 (19:13 +0100)] 
test: bump the container spawn timeout to 60s

As 30s might be not enough on busy systems (and we already bumped the
reboot timeout from 30s to 60s for this reason).

15 months agotest: bump the client-side timeout in sd-bus as well
Frantisek Sumsal [Mon, 23 Jan 2023 17:40:38 +0000 (18:40 +0100)] 
test: bump the client-side timeout in sd-bus as well

Since c78d18215b D-Bus services now have 60s to start, but the client
side (sd-bus) still waits only for 25s before giving up:

```
[  226.196380] testsuite-71.sh[556]: + assert_in 'Static hostname: H' ''
[  226.332965] testsuite-71.sh[576]: + set +ex
[  226.332965] testsuite-71.sh[576]: FAIL: 'Static hostname: H' not found in:
[  228.910782] sh[577]: + systemctl poweroff --no-block
[  232.255584] hostnamectl[565]: Failed to query system properties: Connection timed out
[  236.827514] systemd[1]: end.service: Consumed 2.131s CPU time.
[  237.476969] dbus-daemon[566]: [system] Successfully activated service 'org.freedesktop.hostname1'
[  237.516308] systemd[1]: system-modprobe.slice: Consumed 1.533s CPU time.
[  237.794635] systemd[1]: testsuite-71.service: Main process exited, code=exited, status=1/FAILURE
[  237.818469] systemd[1]: testsuite-71.service: Failed with result 'exit-code'.
[  237.931415] systemd[1]: Failed to start testsuite-71.service.
[  238.000833] systemd[1]: testsuite-71.service: Consumed 5.651s CPU time.
[  238.181030] systemd[1]: Reached target testsuite.target.
```

Let's override the timeout in sd-bus as well to mitigate this.

Follow-up to c78d18215b3e5b0f0896ddb1d0d72c666b5e830b.

15 months agomachinectl: remove unnecessary initialization 26162/head
Mike Yuan [Mon, 23 Jan 2023 16:32:33 +0000 (00:32 +0800)] 
machinectl: remove unnecessary initialization

15 months agomachinectl: also enable machines.target when enabling machines
Mike Yuan [Mon, 23 Jan 2023 16:13:23 +0000 (00:13 +0800)] 
machinectl: also enable machines.target when enabling machines

It's mostly desired to enable machines.target
along with the machine since only when both are
enabled it would really work.

15 months agorepart: Add note about UIDs/GIDs of copied files and directories 26153/head
Daan De Meyer [Mon, 23 Jan 2023 15:43:58 +0000 (16:43 +0100)] 
repart: Add note about UIDs/GIDs of copied files and directories

15 months agoRevert "repart: Ensure files end up owned by root in generated filesystems"
Daan De Meyer [Mon, 23 Jan 2023 13:47:00 +0000 (14:47 +0100)] 
Revert "repart: Ensure files end up owned by root in generated filesystems"

This reverts commit e59678b2cf42e4206ddabc959d3cf9a5a865ecdc.

We also modify the repart integration tests to make them pass with the
changes in this commit. In short, we have to make sure every file is
owned by the user executing repart. We use tee instead of cat since it
makes that easier. This also has the benefit of improving debugability
as seeing the config file contents on stdout makes it easier to know
which test is failing.

15 months agoMerge pull request #25168 from valentindavid/valentindavid/umount-move-recursive...
Lennart Poettering [Mon, 23 Jan 2023 14:24:13 +0000 (15:24 +0100)] 
Merge pull request #25168 from valentindavid/valentindavid/umount-move-recursive-list

shutdown: move busy mounts to not block parent mounts

15 months agomeson: Use python module for detection 26157/head
Jan Janssen [Mon, 23 Jan 2023 13:54:28 +0000 (14:54 +0100)] 
meson: Use python module for detection

15 months agoRevert "repart: Make sure all files in the image are owned by root"
Daan De Meyer [Mon, 23 Jan 2023 13:41:33 +0000 (14:41 +0100)] 
Revert "repart: Make sure all files in the image are owned by root"

This reverts commit d2ac7698cb43807a2dd0af727599db486180ebf1.

15 months agomeson: Move bootctl sources defintion to its own file
Jan Janssen [Mon, 23 Jan 2023 13:41:26 +0000 (14:41 +0100)] 
meson: Move bootctl sources defintion to its own file

The root meson.build file is already large enough.

15 months agoMerge pull request #25145 from yuwata/udevadm-trigger
Zbigniew Jędrzejewski-Szmek [Mon, 23 Jan 2023 12:49:20 +0000 (13:49 +0100)] 
Merge pull request #25145 from yuwata/udevadm-trigger

udev: make 'udevadm trigger --settle' work even if device is renamed

15 months agotest: fix TEST-73-LOCALE on Debian
Michael Biebl [Sun, 22 Jan 2023 21:49:06 +0000 (22:49 +0100)] 
test: fix TEST-73-LOCALE on Debian

Fix incorrection assumption about the Debian patch being buggy and
actually making TEST-73-LOCALE fail on Debian.

```
 # localectl set-locale LANG=C.UTF-8
 # cat /etc/default/locale
 LANG=C.UTF-8
```

15 months agolocale: also save XKB settings to vconsole.conf 25805/head
Yu Watanabe [Tue, 20 Dec 2022 18:09:58 +0000 (03:09 +0900)] 
locale: also save XKB settings to vconsole.conf

Closes #24228.
Replaces #25412.

15 months agolocale: make errors in writing files not critical
Yu Watanabe [Fri, 23 Dec 2022 01:34:36 +0000 (10:34 +0900)] 
locale: make errors in writing files not critical

Suggested at https://github.com/systemd/systemd/pull/25805#discussion_r1054871210

> we now write multiple files and we cannot possibly guarantee that
> either both updates worked or neither. unix fs apis simply have
> no concept that would allow us to implement that. hence I think
> we should update what we can, log about what we cannot, but return
> success as long as our in-memory state was updated.

15 months agolocale: merge vconsole_convert_to_x11_and_emit() with method_set_vc_keyboard()
Yu Watanabe [Tue, 20 Dec 2022 19:23:25 +0000 (04:23 +0900)] 
locale: merge vconsole_convert_to_x11_and_emit() with method_set_vc_keyboard()

Similary, this also merges x11_convert_to_vconsole_and_emit() with
method_set_x11_keyboard().

No functional changes, preparation for later commits.

15 months agolocale: split out XKB settings to X11Context
Yu Watanabe [Tue, 20 Dec 2022 16:54:55 +0000 (01:54 +0900)] 
locale: split out XKB settings to X11Context

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

15 months agolocale: rename context_free_vconsole() -> context_clear_vconsole()
Yu Watanabe [Tue, 20 Dec 2022 13:54:03 +0000 (22:54 +0900)] 
locale: rename context_free_vconsole() -> context_clear_vconsole()

Similary, this also renames context_free_x11() -> context_clear_x11(),
to make it clear that these functions do not free Context.

Also, this makes context_clear() support to be called more than once.

15 months agolocale: do not use alloca() for strings which can be potentially arbitrary
Yu Watanabe [Tue, 20 Dec 2022 13:42:20 +0000 (22:42 +0900)] 
locale: do not use alloca() for strings which can be potentially arbitrary

15 months agolocale: several coding style fixlets
Yu Watanabe [Tue, 20 Dec 2022 12:36:01 +0000 (21:36 +0900)] 
locale: several coding style fixlets

- add missing assertions,
- rename arguments for storing results,
- always initialize results on success,
- use _cleanup_ attribute at more places, etc.

15 months agoMerge pull request #26147 from keszybz/silence-gcc-13-warning
Luca Boccassi [Mon, 23 Jan 2023 00:44:41 +0000 (00:44 +0000)] 
Merge pull request #26147 from keszybz/silence-gcc-13-warning

Silence gcc-13 warning

15 months agoMerge pull request #26146 from keszybz/two-man-page-tweaks
Luca Boccassi [Sun, 22 Jan 2023 20:14:33 +0000 (20:14 +0000)] 
Merge pull request #26146 from keszybz/two-man-page-tweaks

Two man page tweaks

15 months agoResolves #26142 - Fix list of supported personalities
Steve Ramage [Sat, 21 Jan 2023 19:46:11 +0000 (11:46 -0800)] 
Resolves #26142 - Fix list of supported personalities

15 months agohwdb: Prevent activation of airplane mode on HP ENVY x360
DaPigGuy [Sun, 22 Jan 2023 04:59:28 +0000 (20:59 -0800)] 
hwdb: Prevent activation of airplane mode on HP ENVY x360

15 months agoshared/install: rework an assert to appease gcc-13 26147/head
Zbigniew Jędrzejewski-Szmek [Sun, 22 Jan 2023 17:21:13 +0000 (18:21 +0100)] 
shared/install: rework an assert to appease gcc-13

With the previous form, gcc is confused and thinks that .type might be unset.

Fixes #26118.

15 months agoshared/install: rework InstallChange to always have .path set
Zbigniew Jędrzejewski-Szmek [Sun, 22 Jan 2023 17:20:22 +0000 (18:20 +0100)] 
shared/install: rework InstallChange to always have .path set

We would set .path in all cases except INSTALL_CHANGE_AUXILIARY_FAILED, where
we would just just .source. This special case is just not worth it, because
we can't easily assert that .path is set. Let's remove this special case to
help the compiler know that .path is actually set.

Avoids a warning with gcc-13.0.1-0.1.fc38.x86_64.

15 months agoman/sd_notify: fix indentation in sample programs 26146/head
Zbigniew Jędrzejewski-Szmek [Sun, 22 Jan 2023 16:51:30 +0000 (17:51 +0100)] 
man/sd_notify: fix indentation in sample programs

Whether we use a newline at the beginning of <programlisting> or not doesn't
seem to have any effect. So let's use the newline in multi-line examples; it is
easier to get the indentation right this way.

15 months agoman: minor corrections
Zbigniew Jędrzejewski-Szmek [Tue, 17 Jan 2023 16:10:34 +0000 (17:10 +0100)] 
man: minor corrections

Two issues that were missed in 8b9f092112ce097dd5c72a58a092c4176458889c.

15 months agosd-path: export env. generators paths
David Tardon [Fri, 20 Jan 2023 14:17:50 +0000 (15:17 +0100)] 
sd-path: export env. generators paths

15 months agoMerge pull request #26139 from yuwata/test-load-fragment-fix-memleak
Lennart Poettering [Sat, 21 Jan 2023 09:50:07 +0000 (10:50 +0100)] 
Merge pull request #26139 from yuwata/test-load-fragment-fix-memleak

test-load-fragment: fix memleak

15 months agosystemctl,test: -EBADF instead of -EBADFD
Yu Watanabe [Sat, 21 Jan 2023 06:25:30 +0000 (15:25 +0900)] 
systemctl,test: -EBADF instead of -EBADFD

Follow-up for da20baaeccbcca78350bf64bdc069dec685c95bc.

15 months agoMerge pull request #26137 from poettering/timesyncd-touch-file-tweaks
Lennart Poettering [Sat, 21 Jan 2023 09:46:54 +0000 (10:46 +0100)] 
Merge pull request #26137 from poettering/timesyncd-touch-file-tweaks

timesync: some tweaks to saved timestamp file handling

15 months agologs-show: add a splash of colour to verbose output
Lennart Poettering [Thu, 19 Jan 2023 21:43:37 +0000 (22:43 +0100)] 
logs-show: add a splash of colour to verbose output

15 months agologs-show: minor modernizations
Lennart Poettering [Thu, 19 Jan 2023 10:37:06 +0000 (11:37 +0100)] 
logs-show: minor modernizations

15 months agosd-journal: validate monotonic timestamp before returning it
Lennart Poettering [Thu, 19 Jan 2023 19:28:34 +0000 (20:28 +0100)] 
sd-journal: validate monotonic timestamp before returning it

15 months agostring-util: add common implementation of function that converts sized character...
Lennart Poettering [Fri, 20 Jan 2023 14:36:09 +0000 (15:36 +0100)] 
string-util: add common implementation of function that converts sized character buffers to NUL terminated C strings

15 months agotest-load-fragment: shorten code a bit 26139/head
Yu Watanabe [Sat, 21 Jan 2023 06:08:04 +0000 (15:08 +0900)] 
test-load-fragment: shorten code a bit

15 months agotest-load-fragment: fix memleak
Yu Watanabe [Sat, 21 Jan 2023 06:03:45 +0000 (15:03 +0900)] 
test-load-fragment: fix memleak

Fixes a leak reported at https://github.com/systemd/systemd/pull/26115#issuecomment-1398026085.

15 months agohwdb: Add touchpad toggle mapping for System76 Pangolin 12
13r0ck [Fri, 20 Jan 2023 18:32:27 +0000 (11:32 -0700)] 
hwdb: Add touchpad toggle mapping for System76 Pangolin 12

15 months agologs-show: move strlen() handling into update_json_data() so that we can use SD_ID128...
Lennart Poettering [Thu, 19 Jan 2023 19:34:36 +0000 (20:34 +0100)] 
logs-show: move strlen() handling into update_json_data() so that we can use SD_ID128_TO_STRING()

15 months agotimesyncd: make sure to update mtime of clock file on each boot 26137/head
Lennart Poettering [Thu, 19 Jan 2023 19:41:25 +0000 (20:41 +0100)] 
timesyncd: make sure to update mtime of clock file on each boot

Let's make sure the timestamp file's mtime is guaranteed to change for
each boot, so that it is a useful indicator of time. Or in other words
this gurantees that systemd-timesyncd.service acts as a new kind of
milestone: that time definitely progressed on this boot even the machine
died abnormally imediately after.

15 months agotimesyncd: modernize load_clock_timestamp() a bit
Lennart Poettering [Thu, 19 Jan 2023 19:36:49 +0000 (20:36 +0100)] 
timesyncd: modernize load_clock_timestamp() a bit

Let's log more.

15 months agotimesyncd: write structured log messages whenever we bump the clock based on disk...
Lennart Poettering [Thu, 19 Jan 2023 19:23:11 +0000 (20:23 +0100)] 
timesyncd: write structured log messages whenever we bump the clock based on disk timestamp

It's useful being able to easily detect if a disk-based clock bump was
done, let's make it a structure message, the same way as acquiring an
NTP fix already is.

Also, set the clock to 1 µs further than the timestamp from the disk,
after all we know that that timestamp was current when it was written,
hence it can't be the right one right now anymore.

15 months agoMerge pull request #26131 from poettering/bootctl-help-text-fix
Lennart Poettering [Fri, 20 Jan 2023 21:21:17 +0000 (22:21 +0100)] 
Merge pull request #26131 from poettering/bootctl-help-text-fix

bootctl --help fixes

15 months agojournal: use compound initializors at one more place
Lennart Poettering [Mon, 16 Jan 2023 13:06:23 +0000 (14:06 +0100)] 
journal: use compound initializors at one more place

15 months agojournal: modernize match_make_string()
Lennart Poettering [Thu, 19 Jan 2023 19:27:26 +0000 (20:27 +0100)] 
journal: modernize match_make_string()

15 months agojournalctl: don't convert between strv/Set for each log line
Lennart Poettering [Thu, 19 Jan 2023 10:35:36 +0000 (11:35 +0100)] 
journalctl: don't convert between strv/Set for each log line

If output fields are specified, let's store this in a Set right-away,
instead of converting between strv and Set again and again for each
line.

This is not only faster, but also simpler and shorter.

15 months agologs-show: use json_variant_unref_many() where appropriate
Lennart Poettering [Thu, 19 Jan 2023 21:44:11 +0000 (22:44 +0100)] 
logs-show: use json_variant_unref_many() where appropriate

15 months agoMerge pull request #26126 from poettering/format-table-date
Lennart Poettering [Fri, 20 Jan 2023 20:45:28 +0000 (21:45 +0100)] 
Merge pull request #26126 from poettering/format-table-date

hostnamectl: show firmware date as date only, with now time

15 months agoboot: Stop linking against libefi.a 26110/head
Jan Janssen [Sun, 5 Jun 2022 15:35:03 +0000 (17:35 +0200)] 
boot: Stop linking against libefi.a

libefi.a just provided the c helper API that was slowly removed. As we
do not depend on anything provided by it anymore, it is safe to drop
now.

Since the ST/BS/RT pointers are very convenient and needed everywhere,
they are retained and initialized by us.

15 months agoboot: Introduce DEFINE_EFI_MAIN macro
Jan Janssen [Thu, 19 Jan 2023 15:13:03 +0000 (16:13 +0100)] 
boot: Introduce DEFINE_EFI_MAIN macro

15 months agoboot: Simplify debug hook
Jan Janssen [Thu, 19 Jan 2023 14:46:43 +0000 (15:46 +0100)] 
boot: Simplify debug hook

15 months agoboot: Rework GUID handling
Jan Janssen [Sun, 5 Jun 2022 15:30:45 +0000 (17:30 +0200)] 
boot: Rework GUID handling

This stops using global GUID variables provided by gnu-efi. The globals
presumably exist to make EFI calls easier. But these GUIDs are just
128bits, so it's cheap to just put them on the stack when needed. C99
compound literals makes this even easier.

This also adds a convenience macro to create GUID pointers and uses it
everywhere. Not forcing a GUID definition to be a compound literal makes
them easier to use when assigning them to variables:
    EFI_GUID before = *SOME_CONST_GUID;
    EFI_GUID after = SOME_GUID;

And MAKE_GUID_PTR() makes it more explicit what is happening. It was
easy to confuse the old code as a cast:
    before(&(EFI_GUID) SOME_GUID);
    after(MAKE_GUID_PTR(SOME));

15 months agoboot: Drop use of ValueToString
Jan Janssen [Sun, 5 Jun 2022 14:07:25 +0000 (16:07 +0200)] 
boot: Drop use of ValueToString

15 months agoboot: Drop use of GuidToString
Jan Janssen [Sun, 5 Jun 2022 14:01:40 +0000 (16:01 +0200)] 
boot: Drop use of GuidToString

15 months agobootctl: remove space that should not be there 26131/head
Lennart Poettering [Fri, 20 Jan 2023 17:40:57 +0000 (18:40 +0100)] 
bootctl: remove space that should not be there

15 months agobootctl: split out boot loader spec + boot loader interface commands in --help text
Lennart Poettering [Fri, 20 Jan 2023 17:36:31 +0000 (18:36 +0100)] 
bootctl: split out boot loader spec + boot loader interface commands in --help text

grub (at least on fedora) nowadays implements the boot loader spec, but
not the boot loader interface. Hence let's split out the commands
specific to each in two groups in the --help text. This way the first
group just covers boot lodaer spec stuff (i.e. stuff on disk in the
ESP/XBOOTLDR partition). And the other covers talking to the boot loader
via EFI var.

15 months agobootctl: realign column in --help text
Lennart Poettering [Fri, 20 Jan 2023 17:30:47 +0000 (18:30 +0100)] 
bootctl: realign column in --help text

for some reason the descriptions of the switches and the commands
weren't aligned, one space off. Fix that.

15 months agobootctl: change section title for kernel image commands
Lennart Poettering [Fri, 20 Jan 2023 17:30:06 +0000 (18:30 +0100)] 
bootctl: change section title for kernel image commands

Let's call them kernel *images*, not just *kernels*.

15 months agobootctl: drop full stop at end of --help texts
Lennart Poettering [Fri, 20 Jan 2023 17:29:13 +0000 (18:29 +0100)] 
bootctl: drop full stop at end of --help texts

We never do that, don't do so here either.

15 months agohostnamectl: show firmware date with date only, without time 26126/head
Lennart Poettering [Fri, 20 Jan 2023 15:52:39 +0000 (16:52 +0100)] 
hostnamectl: show firmware date with date only, without time

The source (usually DMI/SMBIOS) only has 24h granularity, hence don't
show time as well, it's useless.

15 months agoformat-table: add cell type for showing date only timestamps
Lennart Poettering [Fri, 20 Jan 2023 12:47:48 +0000 (13:47 +0100)] 
format-table: add cell type for showing date only timestamps

15 months agotime-util: add timestamp output style that shows dates only, no times
Lennart Poettering [Fri, 20 Jan 2023 12:47:11 +0000 (13:47 +0100)] 
time-util: add timestamp output style that shows dates only, no times

15 months agotime-util: condition size check based on utc mode
Lennart Poettering [Fri, 20 Jan 2023 15:54:22 +0000 (16:54 +0100)] 
time-util: condition size check based on utc mode

15 months agotime-util: simplify formatting of UNIX timestamps
Lennart Poettering [Fri, 20 Jan 2023 12:46:40 +0000 (13:46 +0100)] 
time-util: simplify formatting of UNIX timestamps

15 months agotime-util: move buffer size check after handling of UNIX timestamp style
Lennart Poettering [Fri, 20 Jan 2023 12:45:38 +0000 (13:45 +0100)] 
time-util: move buffer size check after handling of UNIX timestamp style

15 months agotime-util: if a date is unrepresentable, honour style to generate XXX string
Lennart Poettering [Fri, 20 Jan 2023 12:44:26 +0000 (13:44 +0100)] 
time-util: if a date is unrepresentable, honour style to generate XXX string

15 months agotime-util: use IN_SET() more
Lennart Poettering [Fri, 20 Jan 2023 12:16:19 +0000 (13:16 +0100)] 
time-util: use IN_SET() more

15 months agoboot: Properly strip EFI binaries
Jan Janssen [Fri, 20 Jan 2023 13:11:54 +0000 (14:11 +0100)] 
boot: Properly strip EFI binaries

Removing debugging related sections is apparently not enough to truely
strip a (PE) binary.
Better late than never. It gets rid of this pesky warning from sbsign:
    warning: data remaining[174080 vs 193173]: gaps between PE/COFF sections?

15 months agoMerge pull request #26114 from bluca/sd_login_pidfd
Lennart Poettering [Fri, 20 Jan 2023 16:28:13 +0000 (17:28 +0100)] 
Merge pull request #26114 from bluca/sd_login_pidfd

sd-login: add sd_pidfd_* APIs

15 months agostring-util: add new strdupcspn()/strdupspn()
Lennart Poettering [Fri, 20 Jan 2023 12:14:42 +0000 (13:14 +0100)] 
string-util: add new strdupcspn()/strdupspn()

These combine strndup() + strspn()/strcspn() into one.

There are a bunch of strndupa() calls that could use similar treatment
(or should be converted to strdup[c]spn(), but this commit doesn't
bother with that.

15 months agoMerge pull request #23309 from DaanDeMeyer/log-context
Luca Boccassi [Fri, 20 Jan 2023 15:01:03 +0000 (15:01 +0000)] 
Merge pull request #23309 from DaanDeMeyer/log-context

basic: Add log context

15 months agobootctl: add kernel-inspect to --help text
Gerd Hoffmann [Fri, 20 Jan 2023 12:30:48 +0000 (13:30 +0100)] 
bootctl: add kernel-inspect to --help text

15 months agohwdb: Add Chuwi Hi10X (N4120 version) iio matrix
Waltibaba [Fri, 20 Jan 2023 07:38:13 +0000 (08:38 +0100)] 
hwdb: Add Chuwi Hi10X (N4120 version) iio matrix

There is a later model version of the Chuwi Hi10X that has significantly changed components compared to the existing hwdb one. Differentiator (on Chuwi forums, in thesofproject, etc.) is the N4120 rather than the N4100 processor.
The svn and pn seem to be identical, my Chuwi Hi10X matches with the old model except for the changed KIOX000A* iio sensor.
With the added ACCEL_MOUNT_MATRIX, my device works on gnome and has the correct (right-up) output in monitor-sensors.

15 months agoukify: Downgrade required python version to 3.9
Daan De Meyer [Thu, 19 Jan 2023 12:14:29 +0000 (13:14 +0100)] 
ukify: Downgrade required python version to 3.9

15 months agosd-login: add sd_pidfd_* APIs 26114/head
Luca Boccassi [Thu, 19 Jan 2023 23:20:55 +0000 (23:20 +0000)] 
sd-login: add sd_pidfd_* APIs

Same as the sd_pid_* counterparts, but take a pid file descriptor instead of
a pid, so that the callers can be sure that the returned values are really
about the process they asked for, and not about a recycled PID.

15 months agoprocess-util: add helper to verify a pid via its pidfd
Luca Boccassi [Fri, 20 Jan 2023 12:13:22 +0000 (12:13 +0000)] 
process-util: add helper to verify a pid via its pidfd

15 months agoMerge pull request #26115 from yuwata/test-fix-memleak-fdleak
Luca Boccassi [Fri, 20 Jan 2023 11:00:53 +0000 (11:00 +0000)] 
Merge pull request #26115 from yuwata/test-fix-memleak-fdleak

test: fix memleak and fd leak

16 months agotree-wide: fix typo
Yu Watanabe [Fri, 20 Jan 2023 06:32:16 +0000 (15:32 +0900)] 
tree-wide: fix typo

16 months agotest-unit-name: fix fd leak 26115/head
Yu Watanabe [Fri, 20 Jan 2023 05:54:44 +0000 (14:54 +0900)] 
test-unit-name: fix fd leak

Fixes an issue reported at https://github.com/systemd/systemd/issues/22576#issuecomment-1396774385.

16 months agotest-ndisc: fix memleak and fd leak
Yu Watanabe [Fri, 20 Jan 2023 05:37:12 +0000 (14:37 +0900)] 
test-ndisc: fix memleak and fd leak

Fixes issues reported at #22576.