OSDN Git Service

ipmi/watchdog: fix wdog hang on panic waiting for ipmi response
authorRobert Lippert <roblip@gmail.com>
Thu, 20 Apr 2017 23:49:47 +0000 (16:49 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 24 Mar 2018 10:00:18 +0000 (11:00 +0100)
commite9e5ad6b0ef2f00ba23f550c1347bbfb44b66e20
tree204b71e07e560408d6d88767558087af8c97bdd9
parent7c1c184bb571e696ffcd57ed43c65f8c91a6d03e
ipmi/watchdog: fix wdog hang on panic waiting for ipmi response

[ Upstream commit 2c1175c2e8e5487233cabde358a19577562ac83e ]

Commit c49c097610fe ("ipmi: Don't call receive handler in the
panic context") means that the panic_recv_free is not called during a
panic and the atomic count does not drop to 0.

Fix this by only expecting one decrement of the atomic variable
which comes from panic_smi_free.

Signed-off-by: Robert Lippert <rlippert@google.com>
Signed-off-by: Corey Minyard <cminyard@mvista.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/char/ipmi/ipmi_watchdog.c