From: Corey Minyard <minyard@acm.org>
To: Anton Lundin <glance@acc.umu.se>
Cc: openipmi-developer@lists.sourceforge.net,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [Openipmi-developer] Issue with panic handling and ipmi
Date: Mon, 20 Sep 2021 06:38:02 -0500 [thread overview]
Message-ID: <20210920113802.GC545073@minyard.net> (raw)
In-Reply-To: <20210917132648.GG108031@montezuma.acc.umu.se>
Well, that was dumb. Fix follows...
Thanks for working on this. On your approval, I'll send this to Linus.
-corey
ipmi:watchdog: Set panic count to proper value on a panic
You will get two decrements when the messages on a panic are sent, not
one, since 2033f6858970 ("ipmi: Free receive messages when in an oops")
was added, but the watchdog code had a bug where it didn't set the value
properly.
Reported-by: Anton Lundin <glance@acc.umu.se>
Cc: <Stable@vger.kernel.org> # v5.4+
Fixes: 2033f6858970 ("ipmi: Free receive messages when in an oops")
Signed-off-by: Corey Minyard <cminyard@mvista.com>
---
drivers/char/ipmi/ipmi_watchdog.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/char/ipmi/ipmi_watchdog.c b/drivers/char/ipmi/ipmi_watchdog.c
index e4ff3b50de7f..9a64a069ffd1 100644
--- a/drivers/char/ipmi/ipmi_watchdog.c
+++ b/drivers/char/ipmi/ipmi_watchdog.c
@@ -531,7 +531,7 @@ static void panic_halt_ipmi_set_timeout(void)
/* Wait for the messages to be free. */
while (atomic_read(&panic_done_count) != 0)
ipmi_poll_interface(watchdog_user);
- atomic_inc(&panic_done_count);
+ atomic_set(&panic_done_count, 2);
rv = __ipmi_set_timeout(&panic_halt_smi_msg,
&panic_halt_recv_msg,
&send_heartbeat_now);
next prev parent reply other threads:[~2021-09-20 11:38 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20210916145300.GD108031@montezuma.acc.umu.se>
2021-09-16 16:39 ` Issue with panic handling and ipmi Corey Minyard
2021-09-17 10:14 ` Anton Lundin
2021-09-17 12:07 ` Corey Minyard
2021-09-17 12:55 ` Anton Lundin
2021-09-17 13:19 ` [Openipmi-developer] " Corey Minyard
2021-09-17 13:26 ` Anton Lundin
2021-09-20 11:38 ` Corey Minyard [this message]
2021-09-20 14:12 ` Anton Lundin
2021-09-20 14:41 ` Corey Minyard
2021-10-27 17:59 ` Sasha Levin
2021-10-27 18:20 ` Corey Minyard
2021-10-28 1:39 ` Sasha Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210920113802.GC545073@minyard.net \
--to=minyard@acm.org \
--cc=glance@acc.umu.se \
--cc=linux-kernel@vger.kernel.org \
--cc=openipmi-developer@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox