Re: [PATCH] backup timer for UARTs that lose interrupts (take 2)

From: George Anzinger
Date: Wed Nov 16 2005 - 12:31:06 EST


Could you _please_ not put inline patches after the signature mark ("-- "). In my mailer (mozilla) this causes the patch to be greyed out and, more importantly, NOT included in a reply. This, in turn, makes it hard to comment on details in the patch.

Thanks
George
--


Alex Williamson wrote:
Hi Russell,

I've revised the patch for this backup timer idea based on your
comments. Hopefully the restoring of the timer function to the default
serial8250_timeout is more obvious now. I also re-ordered some of the
conditions around the bug test to add further clarity. Please let me
know if you see any further issues with this patch. Patch below is
against 2.6.14-mm2. Here's the original patch description message:

The patch below works around a minor bug found in the UART of the
remote management card used in many HP ia64 and parisc servers (aka the
Diva UARTs). The problem is that the UART does not reassert the THRE
interrupt if it has been previously cleared and the IIR THRI bit is
re-enabled. This can produce a very annoying failure mode when used as
a serial console, allowing a boot/reboot to hang indefinitely until an
RX interrupt kicks it into working again (ie. an unattended reboot could
stall). Paul Bame submitted a complete workaround for 2.4 kernels a few
years ago - http://lkml.org/lkml/2003/5/6/203. The problem has not been
as prevalent on the 2.6 serial driver, thus the solution below is
simplified to only insert a backup timeout to kick the UART when it gets
into trouble. This runs alongside the normal interrupt driven UART code
and has a longer period that the standard polling driver to reduce CPU
overhead. The detection test should be safe for all UARTs and the
backup timer can easily be extended to include other UARTs with similar
disorders.

Please apply. Thanks,

Alex


--
George Anzinger george@xxxxxxxxxx
HRT (High-res-timers): http://sourceforge.net/projects/high-res-timers/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/