- fix-for-serial-uart-lockup.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     fix for serial uart lockup

has been removed from the -mm tree.  Its filename is

     fix-for-serial-uart-lockup.patch

This patch was probably dropped from -mm because
it has now been merged into a subsystem tree or
into Linus's tree, or because it was folded into
its parent patch in the -mm tree.

------------------------------------------------------
Subject: fix for serial uart lockup
From: Steven Rostedt <rostedt@xxxxxxxxxxx>


Try running the attached program on the machine that deadlocked (it is the
one with the buggy uart).  Without the patch, the serial_test will miss a
wake up, and then be stuck in the sleeping TASK_INTERRUPTIBLE state (at
least you can still kill it).  With the patch, it runs fine.

I ran the program with the following parameters:

# ./serial_test /dev/ttyS0 115200 8 0 0 4

(Disclaimer: I did not write this serial_test.  It was hacked up by my
customer to show me that this bug exists).

This may also be a bug with the vanilla kernel, since I don't see why it is
not.  I'll run more tests on the vanilla kernel, and if it too misses a
wake up, I'll submit this to vanilla as well.

Some 8250 uarts don't zero out the NO_INTERRUPT bit of the IIR register on
transmit empty interrupts.  If this happens, then the interrupt handler
won't process any transmits that are waiting, and we can have processes
stuck waiting to transmit over the serial.

This patch has the interrupt process the transmits regardless if the
interrupt handler didn't already handle the transmits, and the uart was
previously (on setup) detected to be buggy.

Signed-off-by: Steven Rostedt <rostedt@xxxxxxxxxxx>
Signed-off-by: Ingo Molnar <mingo@xxxxxxx>
Cc: Russell King <rmk@xxxxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 drivers/serial/8250.c |    8 ++++++++
 1 file changed, 8 insertions(+)

diff -puN drivers/serial/8250.c~fix-for-serial-uart-lockup drivers/serial/8250.c
--- devel/drivers/serial/8250.c~fix-for-serial-uart-lockup	2006-06-01 20:36:15.000000000 -0700
+++ devel-akpm/drivers/serial/8250.c	2006-06-01 20:36:15.000000000 -0700
@@ -1366,6 +1366,14 @@ static irqreturn_t serial8250_interrupt(
 				"irq%d\n", irq);
 			break;
 		}
+		/*
+		 * If we have a buggy TX line, that doesn't
+		 * notify us via iir that we need to transmit
+		 * then force the call.
+		 */
+		if (!handled && (up->bugs & UART_BUG_TXEN))
+			serial8250_handle_port(up, regs);
+
 	} while (l != end);
 
 	spin_unlock(&i->lock);
_

Patches currently in -mm which might be from rostedt@xxxxxxxxxxx are

fix-for-serial-uart-lockup.patch
jbd-avoid-kfree-null.patch
ext3_clear_inode-avoid-kfree-null.patch
sched-comment-bitmap-size-accounting.patch
unnecessary-long-index-i-in-sched.patch
pi-futex-rt-mutex-docs.patch
pi-futex-rt-mutex-docs-update.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux