1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-09 01:18:19 +03:00
Commit Graph

74841 Commits

Author SHA1 Message Date
Daan De Meyer
b5eaa52d49 test: Add missing --no-rebuild to doc
Otherwise meson will try to rebuild all targets.
2024-07-05 16:17:40 +02:00
GwynBleidD
1bd5db86f5 hwdb: Added StarLabs StarLite position sensor mapping
Default mapping for position sensor in StarLabs StarLite does
not match screen orientation. Added fixed mapping matrix.
2024-07-05 01:01:49 +02:00
Edson Juliano Drosdeck
3faee9928d
Fix key toggle touchpad button for multilaser ul154 (#33630) 2024-07-04 23:38:38 +01:00
Luca Boccassi
4f1d4d7454
Merge pull request #33629 from YHNdnzj/labeler-no-stable
labeler: some cleanups
2024-07-04 21:01:40 +02:00
Mike Yuan
5dfc88c12f
workflows/labeler: do not set labels on stable backport PRs 2024-07-04 20:55:53 +02:00
Mike Yuan
a3370d5d94
labeler: match all mkosi files 2024-07-04 20:55:42 +02:00
Mike Yuan
5e12de940a
labeler: remove matches for dropped files (Makefile) 2024-07-04 20:55:36 +02:00
Davide Cavalca
c1eb4cdd3b hwdb: add more AV controllers 2024-07-04 20:09:38 +02:00
tfg13
34c6d8fe40
stub: mem fixes in devicetree addon handling (#33624)
* stub: mem fixes in devicetree addon handling

Two bugs here: The elements are of size `DevicetreeAddon`, not `size_t`,
and `[]` binds stronger than `*`. This means the first element is ok,
but the second corrupts the stack.

Found this while refactoring #32463
2024-07-04 19:08:55 +01:00
Lennart Poettering
44ec70489f vmm: make sure we can handle smbios objects without variable part
An smbios object with no variable part is a special case, it's just
suffixed with two NUL btes. handle that properly.

This is inspired by a similar fix from https://github.com/systemd/systemd/pull/29726
2024-07-04 20:08:09 +02:00
Daan De Meyer
6a4fcf8cef meson: Fix various versions
Follow up for 8b3b01c4b7

We switch to PROJECT_VERSION instead of PROJECT_VERSION_FULL where
we report our version and which is likely being parsed to avoid
breaking compat. If we didn't, the output would change from systemd
255 to systemd 255.1 which could break various tools.
2024-07-04 19:28:12 +02:00
Luca Boccassi
a79b6dc070 README: update requirements for signed dm-verity
The newest kconfig enabling DB-verified dm-verity images is queued
for 6.11:

https://patchwork.kernel.org/project/dm-devel/patch/20240617220037.594792-1-luca.boccassi@gmail.com/
2024-07-04 19:04:58 +02:00
Luca Boccassi
fc9938d6f8 sysusers: handle NSS errors gracefully
If the io.systemd.DynamicUser or io.systemd.Machine files exist,
but nothing is listening on them, the nss-systemd module returns
ECONNREFUSED and systemd-sysusers fails to creat the user/group.

This is problematic when ran by packaging scripts, as the package
assumes that after this has run, the user/group exist and can
be used. adduser does not fail in the same situation.

Change sysusers to print a loud warning but otherwise continue
when NSS returns an error.
2024-07-04 16:43:51 +02:00
Lennart Poettering
74cbe244ec
Merge pull request #33589 from poettering/file-hiearchy-no-version
man: drop version info from file hiearchy man page
2024-07-04 16:43:31 +02:00
Lennart Poettering
72a6296b16 man: fully adopt ~/.local/state/
The XDG base dir spec adopted ~/.local/state/ as a thing a while back,
and we updated our docs in b4d6bc63e6, but
forgot to to update the table at the bottom to fully reflect the update.
Fix that.
2024-07-04 15:26:17 +02:00
Lennart Poettering
39aafbd42a man: mention that distinction between /usr/lib/ and /usr/share/ is really about shared *ownership* 2024-07-04 15:26:17 +02:00
Lennart Poettering
26db8fe247 man: drop version info from file hiearchy man page
This file doesn't document features of systemd, but is more a of a
general description that generalizes/modernizes FHS. As such, the items
listed in it weren't "added" in systemd versions, they simply reflect
general concepts independent of any specific systemd version. hence
let's drop this misleading and confusing version info.

Or in other words, the man page currently claims under "/usr/": "Added
in version 215." – Which of course is rubbish, the directory existed
since time began.

This also rebreaks all paragaphs this touches.

No content changes.
2024-07-04 15:26:17 +02:00
Luca Boccassi
4ac314a81f
Merge pull request #33567 from poettering/boot-fixlets
sd-boot,sd-stub: a variety of smaller fixes
2024-07-04 13:00:56 +02:00
Luca Boccassi
92d1fe3efa os-util: avoid matching on the wrong extension-release file
The previous commit tries to extract a substring from the
extension-release suffix, but that is not right, it's only the
images that need to be versioned and extracted, use the extension-release
suffix as-is. Otherwise if it happens to contain a prefix that
matches the wrong image, it will be taken into account.

Follow-up for 37543971af
2024-07-04 12:49:28 +02:00
Daan De Meyer
96110261ee mkosi: Build a disk image by default again
Now that we have a way to rebuild and reinstall systemd without
having to rebuild the image, let's default to building a disk image
again.
2024-07-04 12:43:50 +02:00
Chen Qi
646ed5af00 src/boot/efi/meson.build: ensure VERSION_TAG exists in case of cross build
The GIT_VERSION is changed to use VERSION_TAG, but in case of cross build
for src/boot/efi, it's not set, causing build error because the compiler cannot
know it's a macro thus treating it as some variable and error out.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
2024-07-04 12:42:35 +02:00
Daan De Meyer
8b3b01c4b7 meson: Deal with potential stable versions
The meson.version file might contain e.g. 256.2~devel in a stable
branch so let's make sure we deal with that.
2024-07-04 12:03:45 +02:00
Topi Miettinen
e81025970f load-fragment: allow MountImages= with paths starting with /dev
For MountImages=, if the source is a block device, it will most likely reside
in /dev. It should be also possible to mount a static device file system in
place of (or part of) /dev. So let's allow paths starting with /dev as an
exception for MountImages=.
2024-07-04 09:36:04 +00:00
Luca Boccassi
92d9d5ca70 test: skip TEST-69-SHUTDOWN on Debian
There is a regression in the login package, skip the test until
it is fixed. https://bugs.debian.org/1075733
2024-07-04 09:07:22 +02:00
Ronan Pigott
ef98603f4b zsh: add run0 completions 2024-07-04 01:21:43 +02:00
Luca Boccassi
08b64666cd
Merge pull request #33608 from DaanDeMeyer/hacking
docs: Update HACKING
2024-07-04 01:19:58 +02:00
Daan De Meyer
a2403af329 docs: Update HACKING
Let's mention the new way to install the latest changes without
rebuilding the image. Let's also remove the duplicate info about
distribution packages that is already mentioned in its own section.
2024-07-03 22:59:40 +02:00
Daan De Meyer
18c98a839f mkosi: Install zypper in opensuse images 2024-07-03 22:48:37 +02:00
Daan De Meyer
d1bbeeea4c mkosi: Fix sync script git command
Let's make sure we actually operate on the packaging git repo.
2024-07-03 22:40:31 +02:00
James Hilliard
aa329b8922 README: add missing CONFIG_MEMCG kernel config option for oomd
We need to enable this otherwise systemd-oomd.service fails to start.

Fixes:
ConditionControlGroupController=memory was not met
2024-07-03 22:11:24 +02:00
Daan De Meyer
cd98453908 mkosi: update arch commit reference
* d74b24c7c6 meson options: vcs-tag=false
* 7424fedef0 upgpkg: 256.1-1: new upstream release
* 6016864c99 upgpkg: 256-3: rebuild to fix man pages...
* 6f6d48b221 upgpkg: 256-2: update shells
* b9ce44e766 drop systemd-stable repository, build from main one
* baf4803252 upgpkg: 256-1: new upstream release
* 1d75e7ddaa add an install hint on NEWS
* 6f17a23127 Ups, inverted...
* d76029f7cc update meson options
* 6e7929dd98 upgpkg: 256rc4-1: new upstream pre-release - testing only!
* 7b70e7b0e7 upgpkg: 256rc3-2: fast-forward to current git main, non-official testing
* a438b879e2 upgpkg: 256rc3-1: new upstream pre-release, non-official testing
* ff30a600c9 upgpkg: 256rc2-1: new upstream pre-release, non-official testing
2024-07-03 22:04:18 +02:00
Daan De Meyer
2f6046f66b mkosi: Clean up old packages from the build directory 2024-07-03 21:05:55 +02:00
Luca Boccassi
ce513c6c6c mkosi: remove conflicting deb packages from builddir
These are not actually needed or installed, so delete them from the
build directory, so that inside an image one can do:

apt install --reinstall /work/build/*.deb

Follow-up for 690a85b1d4
2024-07-03 21:05:14 +02:00
Daan De Meyer
a7856c8182 load-fragment: Remove faulty assertion
Followup for 453cb5d01e

Fixes the following assertion:

"""
x86 130 ~/systemd ❯❯❯ meson compile -C build
ninja: Entering directory `/home/tfleig/systemd/build'
[2/5] Generating export-dbus-interfaces with a custom command
FAILED: interfaces
/home/tfleig/systemd/tools/dbus_exporter.py interfaces /home/tfleig/systemd/build/systemd /home/tfleig/systemd/build/systemd-homed /home/tfleig/systemd/build/systemd-hostnamed /home/tfleig/systemd/build/systemd-importd /home/tfleig/systemd/build/systemd-localed /home/tfleig/systemd/build/systemd-logind /home/tfleig/systemd/build/systemd-machined /home/tfleig/systemd/build/systemd-networkd /home/tfleig/systemd/build/systemd-oomd /home/tfleig/systemd/build/systemd-portabled /home/tfleig/systemd/build/systemd-resolved /home/tfleig/systemd/build/systemd-timedated
Assertion '__unique_prefix__expr_91' failed at src/core/load-fragment.c:3912, function config_parse_tasks_max(). Aborting.
Traceback (most recent call last):
  File "/home/tfleig/systemd/tools/dbus_exporter.py", line 45, in <module>
    main()
  File "/home/tfleig/systemd/tools/dbus_exporter.py", line 42, in main
    extract_interfaces_xml(args.output, exe)
  File "/home/tfleig/systemd/tools/dbus_exporter.py", line 9, in extract_interfaces_xml
    proc = run(
  File "/usr/lib64/python3.9/subprocess.py", line 528, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '[PosixPath('/home/tfleig/systemd/build/systemd'), '--bus-introspect', 'list']' died with <Signals.SIGABRT: 6>.
[4/5] Generating man/systemd.index.xml with a custom command
ninja: build stopped: subcommand failed.
"""
2024-07-03 20:49:44 +02:00
Lennart Poettering
89ed34459e ukify: bring order of EFI sections in man + --help into same order as spec
Previously, the order was quite chaotic, even sometimes interleaved with
entirely unrelated switches. Let's clean this up and use the same order
as in the spec.

This doesn't change anything real, but I think it's a worthy clean-up in
particular as this order is documented as the PCR measurement order of
these sections, hence there's actually a bit of relevance to always
communicate the same order everywhere.
2024-07-03 16:21:34 +02:00
Lennart Poettering
38faff48e5 boot: don't set OsIndications field if already set correctly 2024-07-03 16:15:04 +02:00
Brenton Simpson
2fda6f5fff boot: cover for hardware keys on phones/tablets
The patch is originally from Brenton Simpson, I (Lennart) just added some
comments and rebased it.

I didn't test this, but the patch looks so obviously right to me, that
I think we should just merge it, instead of delaying this further. In
the worst case noone notices, in the best case this makes sd-boot work
reasonably nicely on devices that only have a hadware power key + volume
rocker.

Fixes: #30598
Replaces: #31135
2024-07-03 16:15:04 +02:00
Lennart Poettering
ea22cbc327 ukify: suffix switches that take parameters with = in log output 2024-07-03 16:15:04 +02:00
Lennart Poettering
c8bcf7ecf7 measure: drop incomplete support for PCRs != 11
At this point we have a clearer model:

* systemd-measure should be used for measuring UKIs on vendor build
  systems, i.e. only cover stuff predictable by the OS vendor, and
  identical on all systems. And that is pretty much only PCR 11.

* systemd-pcrlock should cover the other PCRs, which carry inherently
  local information, and can only be predicted locally and not already
  on vendor build systems.

Because of that, let's not bother with any PCRs except for 11 in
systemd-measure. This was added at a time where systemd-pcrlock didn't
exist yet, and hence it wasn't clear how this will play out in the end.
2024-07-03 16:15:04 +02:00
Lennart Poettering
759cf7e10a boot: compare auto- prefix case-insensitively 2024-07-03 16:15:04 +02:00
Lennart Poettering
76c8c0b264 boot: split out inner part of config_load_type2_entries()
Let's simplify the code a bit, and parse Type 2 entries in a function of
its own, separate from the directory enumeration.

This closely follows a similar split we did a long time ago for Type 1.

This is just refactoring, no real code change.
2024-07-03 16:15:04 +02:00
Lennart Poettering
b8ed6e22f0 boot: indent error code path, but leave main code path unindented 2024-07-03 16:15:04 +02:00
Lennart Poettering
6c741d8f50 efi: don't non-chalantly drop const from memory buffer 2024-07-03 16:15:04 +02:00
Lennart Poettering
1beaaeab2f efi: drop "ret_" prefix from "ret_sections[]" parameter
While we write data to this parameter, it's not really a return
parameter, we after all do not fully set it, we just fill in some
fields. Hence it must be initialized beforehand.

According to our coding style only parameters that are purely used for
returning something should be named "ret_xyz", hence this one should not
be.

(We'll later rely on the current behaviour that it leaves array entries
for which we find no sections untouched, hence leave behaviour as is,
just rename the parameters to something more appropriate).

(Since we are dropping the "ret_" prefix of "ret_sections", let's rename
the old "section" parameter at the same time to "section_names", to make
clearer what it is about).
2024-07-03 16:15:04 +02:00
Lennart Poettering
d30b89c7fc efi: fix mangle_stub_cmdline() for empty strings 2024-07-03 16:15:04 +02:00
Lennart Poettering
596731db99 efi: add limit on how large files can be we load into memory at once 2024-07-03 16:15:04 +02:00
Daan De Meyer
90a255779d repart: Allow overriding fstype per partition designator
$SYSTEMD_REPART_OVERRIDE_FSTYPE is too invasive. Often you want to
override the fstype only for a specific designator, so let's support
that as well.
2024-07-03 15:45:51 +02:00
Daan De Meyer
690a85b1d4 mkosi: Copy packages to the build directory as well
With the latest mkosi, mkosi -t none can be used to rerun the build
script without messing with a previously built image. This allows
one to run "mkosi -t disk -f qemu" in one terminal to build and boot
an image in qemu and then run "mkosi -t none" in another terminal to
rebuild the packages. If one then has "RuntimeBuildSources=yes" set
in their mkosi configuration, the build directory is mounted into the
virtual machine, which means that one can then run "dnf upgrade
/work/build/*.rpm" from within the VM to install the new packages.

This allows for quickly iterating on changes without having to rebuild
the image all the time.

We'll probably want to document this at some point, but let's start
with making it possible by copying the built packages to the build directory.
2024-07-03 15:44:27 +02:00
Daan De Meyer
2fe6ad5a64 mkosi: Make sure we don't hide errors from git merge-base
Currently if git merge-base fails we'll hide the error and exit with
exit status 0. Let's make we only exit early if git merge-base exits
with 1 which indicates the current commit is not on the target branch.
Any other error is considered fatal.
2024-07-03 15:42:12 +02:00
Anton Golubev
4ee0ac1ae4 hwdb: Add some HP IR cameras
Two very similar devices, with two functions - a regular camera and IR.
The peculiarity of their infrared camera is that it uses a color image
format (YUYV), although it is essentially black and white.

The IR camera interface differs from the regular camera interface by name:

"HP Wide Vision FHD Camera: HP W" for the regular camera and
"HP Wide Vision FHD Camera: HP I" for an infrared camera

Therefore, glob *I is used to separate the IR camera
2024-07-03 13:51:52 +02:00