summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBedel, Alban <alban.bedel@aerq.com>2019-07-31 14:01:58 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-09-30 16:44:41 +0100
commit95632e679df13fd5a45725e3752c49986ed2fe73 (patch)
tree45ea96902b3c7dce24ad05fff39588f6f4f1e5ad
parentbd1ccd4c28c99ae65a00b03ae98c4cde67f0043c (diff)
downloadpoky-95632e679df13fd5a45725e3752c49986ed2fe73.tar.gz
rng-tools: fix very long shutdown delay with systemd
The systemd service file has DefaultDependencies=no but is not properly configured to also stop the unit. Because of this the unit keep running after shutdown but systemd still waits for it to finish to then later resort to a hard kill. All this take 1m30s with the default configuration. To fix this problem add the missing Before=shutdown.target and Conflicts=shutdown.target to have systemd stop the unit on shutdown. (From OE-Core rev: b6daf8a5755842c0e38b1a88687a18432138a45a) Signed-off-by: Alban Bedel <alban.bedel@aerq.com> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-support/rng-tools/rng-tools/rngd.service3
1 files changed, 2 insertions, 1 deletions
diff --git a/meta/recipes-support/rng-tools/rng-tools/rngd.service b/meta/recipes-support/rng-tools/rng-tools/rngd.service
index f0355db14f..5c8253b5fb 100644
--- a/meta/recipes-support/rng-tools/rng-tools/rngd.service
+++ b/meta/recipes-support/rng-tools/rng-tools/rngd.service
@@ -2,7 +2,8 @@
2Description=Hardware RNG Entropy Gatherer Daemon 2Description=Hardware RNG Entropy Gatherer Daemon
3DefaultDependencies=no 3DefaultDependencies=no
4After=systemd-udev-settle.service 4After=systemd-udev-settle.service
5Before=sysinit.target 5Before=sysinit.target shutdown.target
6Conflicts=shutdown.target
6 7
7[Service] 8[Service]
8ExecStart=@SBINDIR@/rngd -f -r /dev/hwrng 9ExecStart=@SBINDIR@/rngd -f -r /dev/hwrng