]> git.baikalelectronics.ru Git - kernel.git/commit
tty_ldisc: Fix BUG() on hangup
authorPhilippe Rétornaz <philippe.retornaz@epfl.ch>
Wed, 27 Oct 2010 15:13:21 +0000 (17:13 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 9 Nov 2010 23:05:50 +0000 (15:05 -0800)
commitdb0017c4eedc5a8bbb109dfb0098f82766e47de2
tree9c0db77569313d05ac0e7298984897f9c003da95
parente18f2c11ce38e8f9ea4471cb384478cdcfcccee3
tty_ldisc: Fix BUG() on hangup

A kernel BUG when bluetooth rfcomm connection drop while the associated
serial port is open is sometime triggered.

It seems that the line discipline can disappear between the
tty_ldisc_put and tty_ldisc_get. This patch fall back to the N_TTY line
discipline if the previous discipline is not available anymore.

Signed-off-by: Philippe Retornaz <philippe.retornaz@epfl.ch>
Acked-by: Alan Cox <alan@linux.intel.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/tty/tty_ldisc.c