diff options
author | Wang YanQing <udknight@gmail.com> | 2013-05-08 14:14:07 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-05-20 15:27:58 -0400 |
commit | 618f2b90077ef22e5c7025fca4e9027bf75d918f (patch) | |
tree | c7c10973724e39f7091ca802620a966b6c9169e2 /drivers/tty | |
parent | dc9641895abb30aa456918a433a52e13fa0f56b1 (diff) |
vt: convert last unbind_con_driver call to do_unbind_con_driver
There is only one place use unbind_con_driver, this patch
convert it to do_unbind_con_driver too, then we can delete
unbind_con_driver to reduce code size and duplication.
Signed-off-by: Wang YanQing <udknight@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty')
-rw-r--r-- | drivers/tty/vt/vt.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/tty/vt/vt.c b/drivers/tty/vt/vt.c index 852d470d674b..a422322cf8b9 100644 --- a/drivers/tty/vt/vt.c +++ b/drivers/tty/vt/vt.c | |||
@@ -3303,8 +3303,11 @@ static int vt_unbind(struct con_driver *con) | |||
3303 | if (first == 0 && last == MAX_NR_CONSOLES -1) | 3303 | if (first == 0 && last == MAX_NR_CONSOLES -1) |
3304 | deflt = 1; | 3304 | deflt = 1; |
3305 | 3305 | ||
3306 | if (first != -1) | 3306 | if (first != -1) { |
3307 | unbind_con_driver(csw, first, last, deflt); | 3307 | console_lock(); |
3308 | do_unbind_con_driver(csw, first, last, deflt); | ||
3309 | console_unlock(); | ||
3310 | } | ||
3308 | 3311 | ||
3309 | first = -1; | 3312 | first = -1; |
3310 | last = -1; | 3313 | last = -1; |