Commit Graph
61259 Commits
Author SHA1 Message Date
dependabot[bot] 054f47defc build(deps): bump ninja from 1.10.2.4 to 1.11.1 in /.github/workflows
Bumps [ninja](https://github.com/ninja-build/ninja) from 1.10.2.4 to 1.11.1.
- [Release notes](https://github.com/ninja-build/ninja/releases)
- [Commits](https://github.com/ninja-build/ninja/commits/v1.11.1)

---
updated-dependencies:
- dependency-name: ninja
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-01 11:59:45 +00:00
Lennart Poettering f0c24a0ed8 Merge pull request #25554 from enr0n/follow-on-25509
oomd: only check prefix_uid when uid != 0
2022-12-01 12:04:23 +01:00
Lennart Poettering 73d88b806b dissect: rework DISSECT_IMAGE_ADD_PARTITION_DEVICES + DISSECT_IMAGE_OPEN_PARTITION_DEVICES
Curently, these two flags were implied by dissect_loop_device(), but
that's not right, because this means systemd-gpt-auto-generator will
dissect the root block device with these flags set and that's not
desirable: the generator should not cause the partition devices to be
created (we don't intend to use them right-away after all, but expect
udev to find/probe them first, and then mount them though .mount units).
And there's no point in opening the partition devices, since we do not
intend to mount them via fds either.

Hence, rework this: instead of implying the flags, specify them
explicitly.

While we are at it, let's also rename the flags to make them more
descriptive:

DISSECT_IMAGE_MANAGE_PARTITION_DEVICES becomes
DISSECT_IMAGE_ADD_PARTITION_DEVICES, since that's really all this does:
add the partition devices via BLKPG.

DISSECT_IMAGE_OPEN_PARTITION_DEVICES becomes
DISSECT_IMAGE_PIN_PARTITION_DEVICES, since we not only open the devices,
but keep the devices open continously (i.e. we "pin" them).

Also, drop the DISSECT_IMAGE_BLOCK_DEVICE combination flag, since it is
misleading, i.e. it suggests it was appropriate to specify on all
dissected blocking devices, but that's precisely not the case, see the
systemd-gpt-auto-generator case. My guess is that the confusion around
this was actually the cause for this bug we are addressing here.

Fixes: #25528
2022-12-01 11:32:30 +01:00
Ray Strode 9fe26523a1 terminal-util: Set OPOST when setting ONLCR
reset_terminal_fd sets certain minimum required terminal attributes
that systemd relies on.

One of those attributes is `ONLCR` which ensures that when a new line
is sent to the terminal, that the cursor not only moves to the next
line, but also moves to the very beginning of that line.

In order for `ONLCR` to work, the terminal needs to perform output
post-processing. That requires an additional attribute, `OPOST`,
which reset_terminal_fd currently fails to ensure is set.

In most cases `OPOST` (and `ONLCR` actually) are both set anyway, so
it's not an issue, but it could be a problem if, e.g., the terminal was
put in raw mode by a program and the program unexpectedly died before
restoring settings.

This commit ensures when `ONLCR` is set `OPOST` is set too, which is
the only thing that really makes sense to do.
2022-12-01 11:29:21 +01:00
dependabot[bot] 80dd9e2de7 build(deps): bump meson from 0.63.3 to 0.64.1 in /.github/workflows
Bumps [meson](https://github.com/mesonbuild/meson) from 0.63.3 to 0.64.1.
- [Release notes](https://github.com/mesonbuild/meson/releases)
- [Commits](https://github.com/mesonbuild/meson/compare/0.63.3...0.64.1)

---
updated-dependencies:
- dependency-name: meson
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-01 10:28:47 +00:00
dependabot[bot] 58a1485fa9 build(deps): bump redhat-plumbers-in-action/differential-shellcheck
Bumps [redhat-plumbers-in-action/differential-shellcheck](https://github.com/redhat-plumbers-in-action/differential-shellcheck) from 3.1.1 to 3.2.1.
- [Release notes](https://github.com/redhat-plumbers-in-action/differential-shellcheck/releases)
- [Changelog](https://github.com/redhat-plumbers-in-action/differential-shellcheck/blob/main/CHANGELOG.md)
- [Commits](https://github.com/redhat-plumbers-in-action/differential-shellcheck/compare/1b1b75e42f0694c1012228513b21617a748c866e...f3cd08fcf12680861615270b29494d2b87c3e1cc)

---
updated-dependencies:
- dependency-name: redhat-plumbers-in-action/differential-shellcheck
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-01 10:03:09 +00:00
dependabot[bot] 690e7bfe8f build(deps): bump actions/upload-artifact from 3.1.0 to 3.1.1
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v3.1.0...83fd05a356d7e2593de66fc9913b3002723633cb)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-01 10:02:00 +00:00
dependabot[bot] 073747028b build(deps): bump redhat-plumbers-in-action/advanced-issue-labeler
Bumps [redhat-plumbers-in-action/advanced-issue-labeler](https://github.com/redhat-plumbers-in-action/advanced-issue-labeler) from 2.0.0 to 2.0.1.
- [Release notes](https://github.com/redhat-plumbers-in-action/advanced-issue-labeler/releases)
- [Commits](https://github.com/redhat-plumbers-in-action/advanced-issue-labeler/compare/fe9c43b7d77bd8bd7fbe86c2c217e74ebeea71f2...88209aef583c66312529c515d41ea6a710a4baba)

---
updated-dependencies:
- dependency-name: redhat-plumbers-in-action/advanced-issue-labeler
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-01 10:01:10 +00:00
Christian Brauner 3734fec727 TODO: add unprivileged nspawn item
Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
2022-12-01 10:42:47 +01:00
Christian Brauner 3922f98212 TODO: add socket reduction entry for nspawn
Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
2022-12-01 10:42:47 +01:00
Christian Brauner fdeabf571a TODO: add CLONE_PARENT entry for nspawn
Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
2022-12-01 10:42:47 +01:00
Christian Brauner 71b77f0689 TODO: consolidate nspawn items
Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
2022-12-01 10:42:47 +01:00
Yu Watanabe 28db63445c Merge pull request #25578 from mrc0mmand/test-shutdown-tweaks
test: give the container time to properly shut down on exception
2022-12-01 16:37:16 +09:00
Lennart Poettering d25c24d493 update TODO 2022-11-30 17:26:11 +01:00
Frantisek Sumsal 55f7c96c8d test: a couple of pylint-related tweaks 2022-11-30 16:18:50 +01:00
Frantisek Sumsal 8a7032cfb1 test: give the container time to properly shut down on exception
Otherwise the `terminate()` method sends SIGKILL rather quickly (~0.3s),
which then leaves a dangling scope on the host system, breaking further
test executions.
2022-11-30 16:13:19 +01:00
Daan De Meyer 98eb99b7e8 Merge pull request #25574 from bluca/gh_wf
actions: restrict development_freeze to main repo and disable codeql on security repo
2022-11-30 14:28:05 +01:00
Luca Boccassi c1fb3319ce GA: do not run codeql on systemd-security
Scanning is not available on private repositories
2022-11-30 10:59:03 +00:00
Luca Boccassi 77e6166679 GA: run development_freeze only on main repository
No point in running this checker on other forks
2022-11-30 10:59:03 +00:00
Yu Watanabe 6b15f2eff9 sd-netlink: fix assertion triggered by message_get_serial()
This fixes an issue introduced by 7b34bae3b1.

Fixes https://github.com/systemd/systemd/pull/25565#issuecomment-1331353945.
2022-11-30 10:16:17 +00:00
Yu Watanabe f3c8cb27b1 mkfs-util: fix memleak
Fixes an issure introduced by c75cf0164c.

Fixes CID#1501073.
2022-11-30 08:21:40 +01:00
Michal Koutný 862be54d57 cgtop: Update code comments 2022-11-30 09:40:56 +09:00
Yu Watanabe dc4f4c6e36 Merge pull request #25561 from poettering/btrfs-quota-opath-fix
tmpfiles: fix btrfs quota logic
2022-11-30 09:30:13 +09:00
Yu Watanabe c889685920 Merge pull request #25565 from poettering/dissect-optimizations
two dissect-image.c optimizations/tweaks
2022-11-30 09:28:42 +09:00
Nick Rosbrook 3c0562778b oomd: fix doc comment for oomd_fetch_cgroup_oom_preference
Explicitly state that ManagedOOMPreference is always honored when the
unit's cgroup is owned by root.
2022-11-29 16:01:58 -05:00
Nick Rosbrook 3b44e33ff4 man: clarify ManagedOOMPreference documentation
Explicitly state that ManagedOOMPreference is always honored when the
unit's cgroup is owned by root.
2022-11-29 16:01:58 -05:00
Nick Rosbrook 66bc4f6fb1 oomd: only check prefix_uid when uid != 0
If the cgroup is owned by root there is no need to get prefix_uid. Only
check prefix_uid when uid != 0, and then set MANAGED_OOM_PREFERENCE_NONE
and return early if uid != prefix_uid.
2022-11-29 16:01:54 -05:00
Lennart Poettering fb3921b823 dissect-image: merge handlers for 4 different partition designators into one
These four branches execute the exact same code these days, hence merge
them into one.
2022-11-29 18:34:59 +01:00
Lennart Poettering df4524cb37 dissect-image: don't probe swap partitions needlessly
We already know it's swap, we can assume it's also fstype swap, and
don#t need to probe things later again.
2022-11-29 18:34:29 +01:00
Michał Kotyla cb8d22fa84 hwdb: add Clevo touchpad toggle key quirks 2022-11-30 01:46:18 +09:00
Lennart Poettering c8d9ce4aa0 update TODO 2022-11-29 16:56:07 +01:00
Lennart Poettering 51f3dc2234 units: change Requires=systemd-networkd.service → BindsTo= one more time
Follow-up for da15f8406e which did the
change for systemd-networkd-wait-online.service, let's also do this for
systemd-networkd-wait-online@.service
2022-11-29 16:56:07 +01:00
Lennart Poettering e6eb581cb0 Merge pull request #25558 from poettering/fdisk-id128
add generic uuid/id128 helpers for libfdisk too
2022-11-29 16:06:10 +01:00
Lennart Poettering e3b9a5ff26 blkid: add helpers that get gpt partition uuid as sd_id128_t
just some refactoring to make things simpler.
2022-11-29 16:05:17 +01:00
Lennart Poettering e6d1d4c0b3 btrfs-util: convert O_PATH if necessary, in btrfs quota call
Fixes: #25468
2022-11-29 15:35:06 +01:00
Lennart Poettering 698bc1861e blockdev-util: move O_PATH fd conversion into btrfs_get_block_device_fd() to shorten things
And let's use a simple call to the new fd_reopen_condition() helper
there.
2022-11-29 15:34:27 +01:00
Lennart Poettering f1cab3d6dc btrfs-util: convert to fd_reopen_condition() 2022-11-29 15:33:51 +01:00
Lennart Poettering 5f5865f0ad fd-util: add new helper fd_reopen_conditional()
This is a wrapper around fd_reopen() that will reopen an fd if the
F_GETFL flags indicate this is necessary, and otherwise not.

This is useful for various utility calls that shall be able to operate
on O_PATH and without it, and might need to convert between the two
depending on what's passed in.
2022-11-29 15:32:47 +01:00
Lennart Poettering 0461375326 Merge pull request #25385 from drvink/main
systemd: Support OOMPolicy in scope units
2022-11-29 14:40:18 +01:00
Lennart Poettering 63b96eb9b3 fdisk-util: add fdisk_partition_get_type_as_id128() helper
Let's also add an easy accessor for the other per-partition UUID.
2022-11-29 12:07:15 +01:00
Lennart Poettering 02e32aa629 fdisk-util: add fdisk_partition_get_uuid_as_id128() helper
Inspired by: #25534
2022-11-29 12:07:15 +01:00
Joerg Behrmann 0ccfd3564b kernel-install: Add uki layout
Currently the kernel-install man page only documents the bls layout for use
with the boot loader spec type #1. 90-loaderentry.install uses this layout to
generate loader entries and copy the kernel image and initrd to $BOOT.

This commit documents a second layout "uki" and adds 90-uki-copy.install,
which copies a UKI "uki.efi" from the staging area or any file with the .efi
extension given on the command line to
$BOOT/EFI/Linux/$ENTRY_TOKEN-$KERNEl_VERSION(+$TRIES).efi

This allows for both locally generated and distro-provided UKIs to be handled
by kernel-install.
2022-11-29 11:33:27 +01:00
Lennart Poettering 87a7084b35 update TODO 2022-11-29 10:47:51 +01:00
Daan De Meyer 49d1fcd01c Merge pull request #25132 from yuwata/core-device-inactivate-removed-device-on-switching-root
core/device: inactivate removed device on switching root
2022-11-29 10:27:34 +01:00
Yu Watanabe 7a95d1d8d1 Merge pull request #25508 from enr0n/test-various-fixes
Fix test failures found in Ubuntu autopkgtest
2022-11-29 13:46:39 +09:00
Yu Watanabe f334a8c8e9 Merge pull request #25536 from yuwata/sd-netlink-several-fixes
sd-netlink: several fixes
2022-11-29 10:35:07 +09:00
Yu Watanabe c167ed0fd1 Merge pull request #25552 from yuwata/network-ndisc-trivial-fixes
network: NDisc: trivial fixes
2022-11-29 10:33:33 +09:00
Luca Boccassi 8936a2a8f0 Merge pull request #25532 from Werkov/fix-cgtop-args
cgtop: Do not rewrite -P or -k options
2022-11-28 22:20:47 +01:00
Tonći Galić bcad98ee4d hwdb: Add support for Elgato Stream Pedal (#25550)
This adds the [Elgato Stream Pedal](https://www.elgato.com/en/stream-deck-pedal)
as part of the supported family
2022-11-29 05:15:25 +09:00
Yu Watanabe 6a4f43cd66 network: drop invalid and unused flag
Route.flags can only take RTNH_F_ONLINK, and other flags are silently
dropped.
2022-11-29 04:31:27 +09:00