Skip to content

Commit

Permalink
[PATCH] hvc_console: Unregister the console in the exit routine.
Browse files Browse the repository at this point in the history
Be thorough in our exit routine, since it says it is there to be so.
Unregistering without registering is safe (checked in 2.6.10).

Signed-off-by: Milton Miller <[email protected]>
Signed-off-by: Anton Blanchard <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Milton Miller authored and Linus Torvalds committed Jul 8, 2005
1 parent 2b9e0ba commit 320da0d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/char/hvc_console.c
Original file line number Diff line number Diff line change
Expand Up @@ -846,8 +846,9 @@ int __init hvc_init(void)
}
module_init(hvc_init);

/* This isn't particularily necessary due to this being a console driver but it
* is nice to be thorough */
/* This isn't particularily necessary due to this being a console driver
* but it is nice to be thorough.
*/
static void __exit hvc_exit(void)
{
kthread_stop(hvc_task);
Expand All @@ -856,5 +857,6 @@ static void __exit hvc_exit(void)
tty_unregister_driver(hvc_driver);
/* return tty_struct instances allocated in hvc_init(). */
put_tty_driver(hvc_driver);
unregister_console(&hvc_con_driver);
}
module_exit(hvc_exit);

0 comments on commit 320da0d

Please sign in to comment.