serial/imx: propagate error of platform_driver_register in init routine
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Tue, 22 Nov 2011 13:22:55 +0000 (14:22 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sun, 27 Nov 2011 04:10:13 +0000 (20:10 -0800)
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/tty/serial/imx.c

index 163fc9021f5ad58a695c0fded23a300ed49b4627..962cafa175f713d24470f5d60aa290749f4fa3e3 100644 (file)
@@ -1476,7 +1476,7 @@ static int __init imx_serial_init(void)
        if (ret != 0)
                uart_unregister_driver(&imx_reg);
 
-       return 0;
+       return ret;
 }
 
 static void __exit imx_serial_exit(void)