aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/rocket.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/rocket.c')
-rw-r--r--drivers/tty/rocket.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/tty/rocket.c b/drivers/tty/rocket.c
index de88aa5566e5..777d5f9cf6cc 100644
--- a/drivers/tty/rocket.c
+++ b/drivers/tty/rocket.c
@@ -892,12 +892,12 @@ static int rp_open(struct tty_struct *tty, struct file *filp)
892{ 892{
893 struct r_port *info; 893 struct r_port *info;
894 struct tty_port *port; 894 struct tty_port *port;
895 int line = 0, retval; 895 int retval;
896 CHANNEL_t *cp; 896 CHANNEL_t *cp;
897 unsigned long page; 897 unsigned long page;
898 898
899 line = tty->index; 899 info = rp_table[tty->index];
900 if (line < 0 || line >= MAX_RP_PORTS || ((info = rp_table[line]) == NULL)) 900 if (info == NULL)
901 return -ENXIO; 901 return -ENXIO;
902 port = &info->port; 902 port = &info->port;
903 903
@@ -2277,7 +2277,6 @@ static int __init rp_init(void)
2277 * driver with the tty layer. 2277 * driver with the tty layer.
2278 */ 2278 */
2279 2279
2280 rocket_driver->owner = THIS_MODULE;
2281 rocket_driver->flags = TTY_DRIVER_DYNAMIC_DEV; 2280 rocket_driver->flags = TTY_DRIVER_DYNAMIC_DEV;
2282 rocket_driver->name = "ttyR"; 2281 rocket_driver->name = "ttyR";
2283 rocket_driver->driver_name = "Comtrol RocketPort"; 2282 rocket_driver->driver_name = "Comtrol RocketPort";