summaryrefslogtreecommitdiff
path: root/drivers/tty/serial/68328serial.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/serial/68328serial.c')
-rw-r--r--drivers/tty/serial/68328serial.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/tty/serial/68328serial.c b/drivers/tty/serial/68328serial.c
index 66c38a3f74ce..f99a84526f82 100644
--- a/drivers/tty/serial/68328serial.c
+++ b/drivers/tty/serial/68328serial.c
@@ -1225,6 +1225,8 @@ rs68328_init(void)
if (tty_register_driver(serial_driver)) {
put_tty_driver(serial_driver);
+ for (i = 0; i < NR_PORTS; i++)
+ tty_port_destroy(&m68k_soft[i].tport);
printk(KERN_ERR "Couldn't register serial driver\n");
return -ENOMEM;
}