aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/tty_port.c
diff options
context:
space:
mode:
authorAlan Cox <alan@redhat.com>2009-01-02 08:48:11 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-01-02 13:19:41 -0500
commit6ed1dbaeadd62a026a93aa3ac8680d2dfe9f96b3 (patch)
treeaf470015e92b5abbc510935b61f953015addb58a /drivers/char/tty_port.c
parent3969ffba71d39ced700d09d9cfde83174396299e (diff)
tty: Make epca use the port helpers
Now the locking is straight and the port kref usage is straight we can replace lots of chunks of code with the standard port helpers Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/tty_port.c')
-rw-r--r--drivers/char/tty_port.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/char/tty_port.c b/drivers/char/tty_port.c
index b3175f54fe05..b580fcf629f8 100644
--- a/drivers/char/tty_port.c
+++ b/drivers/char/tty_port.c
@@ -286,7 +286,8 @@ int tty_port_close_start(struct tty_port *port, struct tty_struct *tty, struct f
286 port->flags |= ASYNC_CLOSING; 286 port->flags |= ASYNC_CLOSING;
287 tty->closing = 1; 287 tty->closing = 1;
288 spin_unlock_irqrestore(&port->lock, flags); 288 spin_unlock_irqrestore(&port->lock, flags);
289 if (port->closing_wait != ASYNC_CLOSING_WAIT_NONE) 289 if (port->flags & ASYNC_INITIALIZED &&
290 port->closing_wait != ASYNC_CLOSING_WAIT_NONE)
290 tty_wait_until_sent(tty, port->closing_wait); 291 tty_wait_until_sent(tty, port->closing_wait);
291 return 1; 292 return 1;
292} 293}