Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1206819
| From | Corey Minyard <minyard@acm.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 7/7] ipmi/kcs: Don't run the KCS state machine when it is KCS_IDLE |
| Date | 2015-08-13 15:50 +0200 |
| Message-ID | <pX13j-4V5-7@gated-at.bofh.it> (permalink) |
| References | <pQJLQ-1sE-3@gated-at.bofh.it> <pQJLQ-1sE-15@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
This patch will break ATN handling on the interfaces. So we can't do this. It's going to be extremely hard to recover if the BMC is not working correctly when a panic happens. I'm not sure what can be done, but if you can fix it another way it would be good. -corey On 07/27/2015 12:55 AM, Hidehiro Kawai wrote: > If a BMC is unresponsive for some reason, it ends up completing > the requested message as an error, then kcs_event() is called once > to advance the state machine. However, since the BMC is > unresponsive now, the status of the KCS interface may not be > idle. As the result, the state machine can continue to run and > comsume CPU time indefinitely even if there is no more request > message. Moreover, if this happens in run-to-completion mode > (i.e. context of panic_event()), the kernel hangs up. > > To fix this problem, this patch ignores kcs_event() call if there > is no request message to be processed. > > Signed-off-by: Hidehiro Kawai <hidehiro.kawai.ez@hitachi.com> > --- > drivers/char/ipmi/ipmi_kcs_sm.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/char/ipmi/ipmi_kcs_sm.c b/drivers/char/ipmi/ipmi_kcs_sm.c > index 8c25f59..0e187fb 100644 > --- a/drivers/char/ipmi/ipmi_kcs_sm.c > +++ b/drivers/char/ipmi/ipmi_kcs_sm.c > @@ -353,6 +353,10 @@ static enum si_sm_result kcs_event(struct si_sm_data *kcs, long time) > if (kcs_debug & KCS_DEBUG_STATES) > printk(KERN_DEBUG "KCS: State = %d, %x\n", kcs->state, status); > > + /* We don't want to run the state machine when the state is IDLE */ > + if (kcs->state == KCS_IDLE) > + return SI_SM_IDLE; > + > /* All states wait for ibf, so just do it here. */ > if (!check_ibf(kcs, status, time)) > return SI_SM_CALL_WITH_DELAY; > > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
Re: [PATCH 7/7] ipmi/kcs: Don't run the KCS state machine when it is KCS_IDLE Corey Minyard <minyard@acm.org> - 2015-08-13 15:50 +0200 RE: [PATCH 7/7] ipmi/kcs: Don't run the KCS state machine when it is KCS_IDLE 河合英宏 / KAWAI,HIDEHIRO <hidehiro.kawai.ez@hitachi.com> - 2015-08-18 05:00 +0200
csiph-web