RE: 2.6.9: serial_core: uart_open

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

 



> -----Original Message-----
> From: Russell King
> Sent: Friday, July 15, 2005 12:29 AM
> To: karl malbrain
> Cc: Linux-Kernel@Vger. Kernel. Org
> Subject: Re: 2.6.9: serial_core: uart_open
>
>
> On Thu, Jul 14, 2005 at 03:35:07PM -0700, karl malbrain wrote:
> > AT LAST I HAVE SOME DATA!!!
> >
> > The problem is that ALL SYSTEM CALLS to open "/dev/tty" are
> blocking!! even
> > with O_NDELAY set and even from completely disjoint sessions.
> I discovered
> > this via issuing "strace sh".  That's why the new xterm windows froze.
> >
> > The original process doing the open("/dev/ttyS1", O_RDWR) is
> listed in the
> > ps aux listing as status S+.
>
> Ok, 'S' means it's sleeping.
>
> Can you enable Magic SYSRQ, and ensure that you have a large kernel
> log buffer (the LOG_BUF_SHIFT configuration symbol).  Ensure that
> /proc/sys/kernel/sysrq is 1, and re-run your test such that you have
> something else waiting (eg, the strace sh).  Then hit Alt-SysRQ-T.
>
> You can then read the kernel messages with dmesg - you may need the
> -s argument to capture the entire kernel buffer.
>
> This will tell us where all processes are sleeping.

Here is the dump of the original process that's waiting for the
open("/dev/ttyS1", O_RDWR) to return:

test5         S C023B673  3036  5399   5224                     (NOTLB)
d0fb6e88 00000086 d3462ea0 c023b673 04000000 001123f9 3949e4f7 00003b4e
       d204e170 d204e2fc dfee9658 dfd4ec60 c0422448 dfee9640 c02390c0
d1f22940
       00000000 d204e170 c011c856 00000000 00000000 c0236d4c 00000000
dfee9640
Call Trace:
 [<c023b673>] serial8250_interrupt+0x0/0x200
 [<c02390c0>] uart_block_til_ready+0x198/0x224
 [<c011c856>] default_wake_function+0x0/0xc
 [<c0236d4c>] uart_startup+0xb6/0x1d8
 [<c011c856>] default_wake_function+0x0/0xc
 [<c023980b>] uart_change_pm+0x1c/0x24
 [<c023938a>] uart_open+0xd1/0x105
 [<c0218226>] tty_open+0x18f/0x3b8
 [<c016d78c>] chrdev_open+0x325/0x3b9
 [<c016256f>] dentry_open+0xbd/0x180
 [<c01624ac>] filp_open+0x36/0x3c
 [<c0301e98>] __cond_resched+0x14/0x3b
 [<c01da4fa>] direct_strncpy_from_user+0x3e/0x5d
 [<c0162970>] sys_open+0x31/0x7d
 [<c03036f3>] syscall_call+0x7/0xb

Hope this helps, karl m



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]
  Powered by Linux