WSL2-Linux-Kernel/net/irda/ircomm
Peter Hurley fef062cbf2 tty: Remove ASYNC_CLOSING checks in open()/hangup() methods
Since at least before 2.6.30, tty drivers that do not drop the tty lock
while closing cannot observe ASYNC_CLOSING set while holding the
tty lock; this includes the tty driver's open() and hangup() methods,
since the tty core calls these methods holding the tty lock.

For these drivers, waiting for ASYNC_CLOSING to clear while opening
is not required, since this condition cannot occur. Similarly, even
when the open() method drops and reacquires the tty lock after
blocking, ASYNC_CLOSING cannot be set (again, for drivers that
do not drop the tty lock while closing).

Now that tty port drivers no longer drop the tty lock while closing
(since 'tty: Remove tty_wait_until_sent_from_close()'), the same
conditions apply: waiting for ASYNC_CLOSING to clear while opening
is not required, nor is re-checking ASYNC_CLOSING after dropping and
reacquiring the tty lock while blocking (eg., in *_block_til_ready()).

Note: The ASYNC_CLOSING flag state is still maintained since several
bitrotting drivers use it for (dubious) other purposes.

Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17 21:11:29 -07:00
..
Kconfig tty: Added a CONFIG_TTY option to allow removal of TTY 2013-01-18 16:15:27 -08:00
Makefile Net: irda: ircomm: Makefile: Remove deprecated kbuild goal defintions 2010-11-22 08:16:12 -08:00
ircomm_core.c irda: Convert IRDA_DEBUG to pr_debug 2014-11-12 13:56:41 -05:00
ircomm_event.c irda: Fix build failures after IRDA_DEBUG->pr_debug 2014-11-12 22:01:14 -05:00
ircomm_lmp.c irda: Convert IRDA_DEBUG to pr_debug 2014-11-12 13:56:41 -05:00
ircomm_param.c irda: Convert function pointer arrays and uses to const 2014-12-10 15:33:16 -05:00
ircomm_ttp.c irda: Convert IRDA_DEBUG to pr_debug 2014-11-12 13:56:41 -05:00
ircomm_tty.c tty: Remove ASYNC_CLOSING checks in open()/hangup() methods 2015-10-17 21:11:29 -07:00
ircomm_tty_attach.c irda: Fix build failures after IRDA_DEBUG->pr_debug 2014-11-12 22:01:14 -05:00
ircomm_tty_ioctl.c irda: Convert IRDA_DEBUG to pr_debug 2014-11-12 13:56:41 -05:00