lkml.org 
[lkml]   [2010]   [Jun]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] panic: keep blinking in spite of long spin timer mode
On Fri, 28 May 2010 06:56:45 +0900
TAMUKI Shoichi <tamuki@linet.gr.jp> wrote:

> To keep panic_timeout accuracy when running under a hypervisor, the
> current implementation only spins on long time (1 second) calls to
> mdelay. That brings a good effect, but we must give up blinking even
> if we have a panic_blink.
>
> This patch keeps blinking in spite of long spin timer mode.
>
> We now have new kernel parameter (panic_longspin) to enable long spin
> timer mode when kernel panics. This is to be used when running under
> a hypervisor (default is disable).

The whole panic-blink setup seems rather poorly thought out.

Would it not be better if a call to (*panic_blink)() were to simply set
the state of the LED and then return? So callers can do

int state = 0;

for ( ; ; ) {
(*panic_blink)(state);
state ^= 1;
mdelay(MSEC_PER_SEC);
}
?


\
 
 \ /
  Last update: 2010-06-02 20:43    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site