From: Tobias Klauser Date: Tue, 5 Feb 2013 17:07:42 +0000 (+0100) Subject: tty: serial: altera_uart: Simplify altera_uart_init() X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=61bc65599f8118fc53975670f19c37fe2be92a3d;p=openwrt%2Fstaging%2Fblogic.git tty: serial: altera_uart: Simplify altera_uart_init() No need for two separate return statements, consolidate them. Signed-off-by: Tobias Klauser Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/tty/serial/altera_uart.c b/drivers/tty/serial/altera_uart.c index e133c8814bb5..13471dd95793 100644 --- a/drivers/tty/serial/altera_uart.c +++ b/drivers/tty/serial/altera_uart.c @@ -637,11 +637,9 @@ static int __init altera_uart_init(void) if (rc) return rc; rc = platform_driver_register(&altera_uart_platform_driver); - if (rc) { + if (rc) uart_unregister_driver(&altera_uart_driver); - return rc; - } - return 0; + return rc; } static void __exit altera_uart_exit(void)