summaryrefslogtreecommitdiff
path: root/meta-ibm
diff options
context:
space:
mode:
authorMatt Spinler <spinler@us.ibm.com>2022-01-15 00:51:02 +0300
committerMatt Spinler <spinler@us.ibm.com>2022-01-19 22:13:29 +0300
commit71f04aa47224ab5c2be7bb94e73687339ad4a353 (patch)
treef59188bdf82f8fbdfc2a7c1d7708184a85f034f2 /meta-ibm
parentbddf46355ffc130b69135fe14b3128bb003f18fe (diff)
downloadopenbmc-71f04aa47224ab5c2be7bb94e73687339ad4a353.tar.xz
meta-ibm: Manually magic close the fan watchdog
To support the watchdog application being able to restart after expiring the watchdog (by being killed) multiple times per BMC reboot, a manual magic close must be issued by writing a 'V' into the watchdog device before starting the watchdog. Without that, the underlying hardware watchdog wouldn't actually start running when the watchdog app was started again, such as on the next boot. Most watchdogs simply reboot the system upon expiration, but in this case it's being used to trip a GPIO that the fan hardware latches on to go to full speed so must support being restarted multiple times. The busybox watchdog application used to support this, but it was removed since it apparently caused some undesireable print statements from the kernel on other platforms. An alternative may be to fix this in the ASPEED watchdog driver, though I'm not sure what all that would entail or if it even makes sense. Tested: Expire and start the watchdog multiple times and the fans now go to full speed each time the watchdog expires, unlike before. Signed-off-by: Matt Spinler <spinler@us.ibm.com> Change-Id: I770c4fd7cca15949abd7de9dc07975562080f032
Diffstat (limited to 'meta-ibm')
-rw-r--r--meta-ibm/recipes-phosphor/fans/fan-watchdog/fan-watchdog.service1
1 files changed, 1 insertions, 0 deletions
diff --git a/meta-ibm/recipes-phosphor/fans/fan-watchdog/fan-watchdog.service b/meta-ibm/recipes-phosphor/fans/fan-watchdog/fan-watchdog.service
index 3f941836d8..16a5ae4583 100644
--- a/meta-ibm/recipes-phosphor/fans/fan-watchdog/fan-watchdog.service
+++ b/meta-ibm/recipes-phosphor/fans/fan-watchdog/fan-watchdog.service
@@ -6,6 +6,7 @@ Conflicts=obmc-fan-watchdog-takeover.target
[Service]
EnvironmentFile={envfiledir}/obmc/fan-watchdog/fan-watchdog.conf
+ExecStartPre=/bin/sh -c "echo V > ${{DEVICE}}"
ExecStart=/sbin/watchdog -T ${{TIMEOUT}} -t ${{INTERVAL}} -F ${{DEVICE}}
KillSignal=SIGKILL