diff options
-rw-r--r-- | drivers/tty/serial/serial_core.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c index 1d3780cc3b70..a32dc4362224 100644 --- a/drivers/tty/serial/serial_core.c +++ b/drivers/tty/serial/serial_core.c | |||
@@ -1257,7 +1257,7 @@ static void uart_close(struct tty_struct *tty, struct file *filp) | |||
1257 | 1257 | ||
1258 | if (tty_hung_up_p(filp)) { | 1258 | if (tty_hung_up_p(filp)) { |
1259 | spin_unlock_irqrestore(&port->lock, flags); | 1259 | spin_unlock_irqrestore(&port->lock, flags); |
1260 | goto done; | 1260 | return; |
1261 | } | 1261 | } |
1262 | 1262 | ||
1263 | if ((tty->count == 1) && (port->count != 1)) { | 1263 | if ((tty->count == 1) && (port->count != 1)) { |
@@ -1279,7 +1279,7 @@ static void uart_close(struct tty_struct *tty, struct file *filp) | |||
1279 | } | 1279 | } |
1280 | if (port->count) { | 1280 | if (port->count) { |
1281 | spin_unlock_irqrestore(&port->lock, flags); | 1281 | spin_unlock_irqrestore(&port->lock, flags); |
1282 | goto done; | 1282 | return; |
1283 | } | 1283 | } |
1284 | 1284 | ||
1285 | /* | 1285 | /* |
@@ -1342,7 +1342,6 @@ static void uart_close(struct tty_struct *tty, struct file *filp) | |||
1342 | wake_up_interruptible(&port->open_wait); | 1342 | wake_up_interruptible(&port->open_wait); |
1343 | wake_up_interruptible(&port->close_wait); | 1343 | wake_up_interruptible(&port->close_wait); |
1344 | 1344 | ||
1345 | done: | ||
1346 | mutex_unlock(&port->mutex); | 1345 | mutex_unlock(&port->mutex); |
1347 | } | 1346 | } |
1348 | 1347 | ||