]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ipmi: Add limits to event and receive message requests
authorCorey Minyard <corey@minyard.net>
Mon, 20 Apr 2026 17:39:51 +0000 (12:39 -0500)
committerCorey Minyard <corey@minyard.net>
Tue, 28 Apr 2026 17:59:08 +0000 (12:59 -0500)
commitc4cca236968683eb0d59abfb12d5c7e4d8514227
tree2c1515d4e55f2d15be84f397d816a484a5b431d1
parent36920f30e78e69df01f9691c470b6f3ba8aebf98
ipmi: Add limits to event and receive message requests

The driver would just fetch events and receive messages until the
BMC said it was done.  To avoid issues with BMCs that never say they are
done, add a limit of 10 fetches at a time.

In addition, an si interface has an attn state it can return from the
hardware which is supposed to cause a flag fetch to see if the driver
needs to fetch events or message or a few other things.  If the attn
bit gets stuck, it's a similar problem.  So allow messages in between
flag fetches so the driver itself doesn't get stuck.

This is a more general fix than the previous fix for the specific bad
BMC, but should fix the more general issue of a BMC that won't stop
saying it has data.

This has been there from the beginning of the driver.  It's not a bug
per-se, but it is accounting for bugs in BMCs.

Reported-by: Matt Fleming <mfleming@cloudflare.com>
Closes: https://lore.kernel.org/lkml/20260415115930.3428942-1-matt@readmodwrite.com/
Fixes: <1da177e4c3f4> ("Linux-2.6.12-rc2")
Cc: stable@vger.kernel.org
Signed-off-by: Corey Minyard <corey@minyard.net>
drivers/char/ipmi/ipmi_si_intf.c
drivers/char/ipmi/ipmi_ssif.c