|
|
5808e7 |
From 6a6f108b59e47581d93cbc6bdc604ee84f1bb791 Mon Sep 17 00:00:00 2001
|
|
|
5808e7 |
From: Nick Rosbrook <nick.rosbrook@canonical.com>
|
|
|
5808e7 |
Date: Wed, 7 Sep 2022 13:25:13 -0400
|
|
|
5808e7 |
Subject: [PATCH] pstore: do not try to load all known pstore modules
|
|
|
5808e7 |
|
|
|
5808e7 |
Commit 70e74a5997 ("pstore: Run after modules are loaded") added After=
|
|
|
5808e7 |
and Wants= entries for all known kernel modules providing a pstore.
|
|
|
5808e7 |
|
|
|
5808e7 |
While adding these dependencies on systems where one of the modules is
|
|
|
5808e7 |
not present, or not configured, should not have a real affect on the
|
|
|
5808e7 |
system, it can produce annoying error messages in the kernel log. E.g.
|
|
|
5808e7 |
"mtd device must be supplied (device name is empty)" when the mtdpstore
|
|
|
5808e7 |
module is not configured correctly.
|
|
|
5808e7 |
|
|
|
5808e7 |
Since dependencies cannot be removed with drop-ins, if a distro wants to
|
|
|
5808e7 |
remove some of these modules from systemd-pstore.service, they need to
|
|
|
5808e7 |
patch units/systemd-pstore.service.in. On the other hand, if they want
|
|
|
5808e7 |
to append to the dependencies this can be done by shipping a drop-in.
|
|
|
5808e7 |
|
|
|
5808e7 |
Since the original intent of the previous commit was to fix [1], which
|
|
|
5808e7 |
only requires the efi_pstore module, remove all other kernel module
|
|
|
5808e7 |
dependencies from systemd-pstore.service, and let distros ship drop-ins
|
|
|
5808e7 |
to add dependencies if needed.
|
|
|
5808e7 |
|
|
|
5808e7 |
[1] https://github.com/systemd/systemd/issues/18540
|
|
|
5808e7 |
|
|
|
5808e7 |
(cherry picked from commit 8b8bd621e1d16808678fc3afed257df1fa03a281)
|
|
|
5808e7 |
|
|
|
5808e7 |
Related: #2158832
|
|
|
5808e7 |
---
|
|
|
5808e7 |
units/systemd-pstore.service.in | 4 ++--
|
|
|
5808e7 |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
5808e7 |
|
|
|
5808e7 |
diff --git a/units/systemd-pstore.service.in b/units/systemd-pstore.service.in
|
|
|
5808e7 |
index 1983a9738f..19ffa8d4e8 100644
|
|
|
5808e7 |
--- a/units/systemd-pstore.service.in
|
|
|
5808e7 |
+++ b/units/systemd-pstore.service.in
|
|
|
5808e7 |
@@ -16,8 +16,8 @@ DefaultDependencies=no
|
|
|
5808e7 |
After=systemd-remount-fs.service
|
|
|
5808e7 |
Conflicts=shutdown.target
|
|
|
5808e7 |
Before=sysinit.target shutdown.target
|
|
|
5808e7 |
-After=modprobe@efi_pstore.service modprobe@mtdpstore.service modprobe@chromeos_pstore.service modprobe@ramoops.service modprobe@pstore_zone.service modprobe@pstore_blk.service
|
|
|
5808e7 |
-Wants=modprobe@efi_pstore.service modprobe@mtdpstore.service modprobe@chromeos_pstore.service modprobe@ramoops.service modprobe@pstore_zone.service modprobe@pstore_blk.service
|
|
|
5808e7 |
+After=modprobe@efi_pstore.service
|
|
|
5808e7 |
+Wants=modprobe@efi_pstore.service
|
|
|
5808e7 |
|
|
|
5808e7 |
[Service]
|
|
|
5808e7 |
Type=oneshot
|