Some systems may have multiple watchdogs and want systemd to manage a different one. This patch allows to set the WatchdogDevice setting in system.conf
Signed-off-by: Fabian Pflug <[email protected]> --- meta/recipes-core/systemd/systemd_259.5.bb | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/meta/recipes-core/systemd/systemd_259.5.bb b/meta/recipes-core/systemd/systemd_259.5.bb index f3ec0edae7..8cb523a330 100644 --- a/meta/recipes-core/systemd/systemd_259.5.bb +++ b/meta/recipes-core/systemd/systemd_259.5.bb @@ -253,6 +253,11 @@ WATCHDOG_TIMEOUT ??= "60" # and the watchdog is enabled. (defaults is no hardware watchdog use) WATCHDOG_RUNTIME_SEC ??= "" +# If a different device, other then /dev/watchdog0 should be used, set +# WATCHDOG_DEVICE_PATH to the full path to the watchdog device. +# (Will set the WatchdogDevice= option in /etc/systemd/system.conf) +WATCHDOG_DEVICE_PATH ??= "" + do_install() { meson_do_install @@ -368,6 +373,11 @@ do_install() { ${D}/${sysconfdir}/systemd/system.conf fi + if [ -n "${WATCHDOG_DEVICE_PATH}" ]; then + sed -i -e 's|#WatchdogDevice=|WatchdogDevice=${WATCHDOG_DEVICE_PATH}|' \ + ${D}/${sysconfdir}/systemd/system.conf + fi + # Actively disable Predictable Network Interface Names if ! ${@bb.utils.contains('PACKAGECONFIG', 'pni-names', 'true', 'false', d)}; then sed -i 's/^NamePolicy=.*/NamePolicy=/;s/^AlternativeNamesPolicy=.*/AlternativeNamesPolicy=/' ${D}${nonarch_libdir}/systemd/network/99-default.link -- 2.47.3
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#242080): https://lists.openembedded.org/g/openembedded-core/message/242080 Mute This Topic: https://lists.openembedded.org/mt/120464520/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
