aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorTomoki Sekiyama <tomoki.sekiyama@hds.com>2014-05-02 18:58:24 -0400
committerFugang Duan <b38611@freescale.com>2014-06-26 20:20:54 -0400
commite16e4e2b30b59b0e2d5414da836cd73bb36333bb (patch)
tree417573cc7103aacac8b17c924e66b41d5cd682ee /drivers
parentcd7d39838c7643c0f42caf3eb2ac8a9176a16e31 (diff)
drivers/tty/hvc: don't free hvc_console_setup after init
When 'console=hvc0' is specified to the kernel parameter in x86 KVM guest, hvc console is setup within a kthread. However, that will cause SEGV and the boot will fail when the driver is builtin to the kernel, because currently hvc_console_setup() is annotated with '__init'. This patch removes '__init' to boot the guest successfully with 'console=hvc0'. Signed-off-by: Tomoki Sekiyama <tomoki.sekiyama@hds.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/tty/hvc/hvc_console.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/hvc/hvc_console.c b/drivers/tty/hvc/hvc_console.c
index eb255e807c06..ce028e159efe 100644
--- a/drivers/tty/hvc/hvc_console.c
+++ b/drivers/tty/hvc/hvc_console.c
@@ -186,7 +186,7 @@ static struct tty_driver *hvc_console_device(struct console *c, int *index)
186 return hvc_driver; 186 return hvc_driver;
187} 187}
188 188
189static int __init hvc_console_setup(struct console *co, char *options) 189static int hvc_console_setup(struct console *co, char *options)
190{ 190{
191 if (co->index < 0 || co->index >= MAX_NR_HVC_CONSOLES) 191 if (co->index < 0 || co->index >= MAX_NR_HVC_CONSOLES)
192 return -ENODEV; 192 return -ENODEV;