Re: [PATCH 12/12] tty: move the handling of the tty release logic

From: Yinghai Lu
Date: Tue Jul 31 2012 - 20:47:42 EST


On Fri, Jun 22, 2012 at 8:47 AM, Alan Cox <alan@xxxxxxxxxxxxxxxxxxx> wrote:
> Now that we don't have tty->termios tied to drivers->tty we can untangle
> the logic here. In addition we can push the removal logic out of the
> destructor path.
>
> At that point we can think about sorting out tty_port and console and all
> the other ugly hangovers.
>
> An important other property we now have is that the tty mutex does now cover
> the drivers array. An assumption other bits of the code made and which is
> necessary for the tty lock patch.
>
> Signed-off-by: Alan Cox <alan@xxxxxxxxxxxxxxx>
> ---
>
> drivers/tty/pty.c | 8 --------
> drivers/tty/tty_io.c | 16 +++++-----------
> drivers/tty/vt/vt.c | 1 -
> drivers/usb/serial/usb-serial.c | 3 +--
> include/linux/tty.h | 1 -
> include/linux/tty_driver.h | 11 +++--------
> 6 files changed, 9 insertions(+), 31 deletions(-)

Hi, Alan

This one cause regression on my test setup.

that setup is booting from pxe and initrd is updated from opensuse
11.3 rescue disk.

kernel has command line 115200, and later serial console will use
115200 automatically.

but with this one, serial console will switch back to 9600 instead.

bisect said:

36b3c070d2346c890d690d71f6eab02f8c511137 is the first bad commit
commit 36b3c070d2346c890d690d71f6eab02f8c511137
Author: Alan Cox <alan@xxxxxxxxxxxxxxx>
Date: Tue Jul 17 17:06:57 2012 +0100

tty: Move the handling of the tty release logic

Now that we don't have tty->termios tied to drivers->tty we can untangle
the logic here. In addition we can push the removal logic out of the
destructor path.

At that point we can think about sorting out tty_port and console and all
the other ugly hangovers.

Signed-off-by: Alan Cox <alan@xxxxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

:040000 040000 44db8111f7e5be2f60ae2b41328108a6e533f8a4
d0af41e84b2657e308a92e2ebad04ea5594e6bb4 M drivers
:040000 040000 f75618c564287072c6a6a9d5462355ab780b06b8
4606b8b123694a2e8aaf1d3708fda66bda843742 M include
--
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/