Re: [PATCH 1/3] ipmi:si: Don't block module unload if the BMC is messed up

Rafael J. Wysocki
2026-02-13T12:50:54Z

On Fri, Feb 13, 2026 at 7:55 AM Corey Minyard <corey@minyard.net> wrote:
>
> If the BMC is in a bad state, don't bother waiting for queues messages
> since there can't be any. Otherwise the unload is blocked until the
> BMC is back in a good state.
>
> Reported-by: Rafael J. Wysocki <rafael@kernel.org>
> Fixes: bc3a9d217755 ("ipmi:si: Gracefully handle if the BMC is non-functional")
> Signed-off-by: Corey Minyard <corey@minyard.net>

I have missed this case, but indeed it needs to be addressed.

Reviewed-by: Rafael J. Wysocki (Intel) <rafael@kernel.org>

> ---
> drivers/char/ipmi/ipmi_si_intf.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
> index 0049e3792ba1..3667033fcc51 100644
> --- a/drivers/char/ipmi/ipmi_si_intf.c
> +++ b/drivers/char/ipmi/ipmi_si_intf.c
> @@ -2234,7 +2234,8 @@ static void wait_msg_processed(struct smi_info *smi_info)
> unsigned long jiffies_now;
> long time_diff;
>
> - while (smi_info->curr_msg || (smi_info->si_state != SI_NORMAL)) {
> + while (smi_info->si_state != SI_HOSED &&
> + (smi_info->curr_msg || (smi_info->si_state != SI_NORMAL))) {
> jiffies_now = jiffies;
> time_diff = (((long)jiffies_now - (long)smi_info->last_timeout_jiffies)
> * SI_USEC_PER_JIFFY);
> --