Browse Source

serial: sccnxp: missing uart_unregister_driver() on error in sccnxp_probe()

Add the missing uart_unregister_driver() before return
from sccnxp_probe() in the error handling case.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Wei Yongjun 12 years ago
parent
commit
7a95b815da
1 changed files with 1 additions and 0 deletions
  1. 1 0
      drivers/tty/serial/sccnxp.c

+ 1 - 0
drivers/tty/serial/sccnxp.c

@@ -986,6 +986,7 @@ static int sccnxp_probe(struct platform_device *pdev)
 		return 0;
 	}
 
+	uart_unregister_driver(&s->uart);
 err_out:
 	if (!IS_ERR(s->regulator))
 		return regulator_disable(s->regulator);