]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ipmi:si: Fix check for a misbehaving BMC
authorCorey Minyard <corey@minyard.net>
Fri, 13 Feb 2026 06:15:04 +0000 (00:15 -0600)
committerCorey Minyard <corey@minyard.net>
Mon, 23 Feb 2026 15:00:48 +0000 (09:00 -0600)
commitcae66f1a1dcd23e17da5a015ef9d731129f9d2dd
tree046fdb29aa47d4c55b6e1fc012046715cd505b80
parent62cd145453d577113f993efd025f258dd86aa183
ipmi:si: Fix check for a misbehaving BMC

There is a race on checking the state in the sender, it needs to be
checked under a lock.  But you also need a check to avoid issues with
a misbehaving BMC for run to completion mode.  So leave the check at
the beginning for run to completion, and add a check under the lock
to avoid the race.

Reported-by: Rafael J. Wysocki <rafael@kernel.org>
Fixes: bc3a9d217755 ("ipmi:si: Gracefully handle if the BMC is non-functional")
Cc: stable@vger.kernel.org # 4.18
Signed-off-by: Corey Minyard <corey@minyard.net>
Reviewed-by: Rafael J. Wysocki (Intel) <rafael@kernel.org>
drivers/char/ipmi/ipmi_si_intf.c