[bug] WARNING: at drivers/char/tty_io.c:1266 tty_open+0x1ea/0x388()

From: Ingo Molnar
Date: Tue Jun 16 2009 - 03:11:30 EST



* Alan Cox <alan@xxxxxxxxxxxxxxxxxxx> wrote:

> On Sun, 14 Jun 2009 10:10:52 +0200
> Ingo Molnar <mingo@xxxxxxx> wrote:
>
> >
> > Ok, this is one for those who like to look at weird crashes/bugs.
> >
> > Here's a new regression that popped up in this merge window, there's
> > some sort of slab corruption going on in tty data structures:
>
> I split the ldisc and tty apart and redid the ldisc locking so its a fair
> bet I know what changeset is to blame, will just need to hunt it down a
> bit. kmemcheck found one leak case on Friday which I've fixed but not yet
> scribbles.
>
> > c65c9bc: tty: rewrite the ldisc locking
>
> Almost certainly that one and will investigate on Monday

I have applied your patch from yesterday (attached further below for
reference) and the SLAB corruption has not triggered - instead i'm
now getting this warning, after 96 reboots:

[ 20.782199] sshd used greatest stack depth: 5376 bytes left
[ 22.260149] ------------[ cut here ]------------
[ 22.261027] WARNING: at drivers/char/tty_io.c:1266 tty_open+0x1ea/0x388()
[ 22.262018] Hardware name: System Product Name
[ 22.262020] Modules linked in:
[ 22.262024] Pid: 2553, comm: modprobe Tainted: G W 2.6.30-tip #54059
[ 22.262026] Call Trace:
[ 22.262032] [<c102d810>] warn_slowpath_common+0x60/0x90
[ 22.262037] [<c102d84d>] warn_slowpath_null+0xd/0x10
[ 22.262041] [<c11a88ae>] tty_open+0x1ea/0x388
[ 22.262045] [<c108e4c2>] chrdev_open+0x11b/0x132
[ 22.262049] [<c108a8a6>] __dentry_open+0x167/0x265
[ 22.262052] [<c108aa3e>] nameidata_to_filp+0x2c/0x43
[ 22.262056] [<c108e3a7>] ? chrdev_open+0x0/0x132
[ 22.262060] [<c1094bbd>] do_filp_open+0x3cd/0x712
[ 22.262064] [<c1083460>] ? check_valid_pointer+0x1f/0x4e
[ 22.262068] [<c109cd26>] ? alloc_fd+0xcb/0xd5
[ 22.262071] [<c109cd26>] ? alloc_fd+0xcb/0xd5
[ 22.262075] [<c108a63d>] do_sys_open+0x4a/0xed
[ 22.262078] [<c1002a5e>] ? sysenter_exit+0xf/0x21
[ 22.262081] [<c108a722>] sys_open+0x1e/0x26
[ 22.262085] [<c1002a2b>] sysenter_do_call+0x12/0x36
[ 22.262087] ---[ end trace 81f0afc9843492f2 ]---
[ 31.191037] CPA self-test:

Another test-box has produced this warning too. (Same config and
same hw as i sent the details for earlier in this thread.)

So there's still something fishy going on.

Thanks,

Ingo

-------------------->