diff options
Diffstat (limited to 'drivers/isdn/gigaset/common.c')
-rw-r--r-- | drivers/isdn/gigaset/common.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/isdn/gigaset/common.c b/drivers/isdn/gigaset/common.c index db621db67f61..880f6ef0e18d 100644 --- a/drivers/isdn/gigaset/common.c +++ b/drivers/isdn/gigaset/common.c | |||
@@ -720,12 +720,11 @@ struct cardstate *gigaset_initcs(struct gigaset_driver *drv, int channels, | |||
720 | 720 | ||
721 | tasklet_init(&cs->event_tasklet, gigaset_handle_event, | 721 | tasklet_init(&cs->event_tasklet, gigaset_handle_event, |
722 | (unsigned long) cs); | 722 | (unsigned long) cs); |
723 | tty_port_init(&cs->port); | ||
723 | cs->commands_pending = 0; | 724 | cs->commands_pending = 0; |
724 | cs->cur_at_seq = 0; | 725 | cs->cur_at_seq = 0; |
725 | cs->gotfwver = -1; | 726 | cs->gotfwver = -1; |
726 | cs->open_count = 0; | ||
727 | cs->dev = NULL; | 727 | cs->dev = NULL; |
728 | cs->tty = NULL; | ||
729 | cs->tty_dev = NULL; | 728 | cs->tty_dev = NULL; |
730 | cs->cidmode = cidmode != 0; | 729 | cs->cidmode = cidmode != 0; |
731 | cs->tabnocid = gigaset_tab_nocid; | 730 | cs->tabnocid = gigaset_tab_nocid; |
@@ -1051,8 +1050,6 @@ static struct cardstate *gigaset_get_cs_by_minor(unsigned minor) | |||
1051 | 1050 | ||
1052 | struct cardstate *gigaset_get_cs_by_tty(struct tty_struct *tty) | 1051 | struct cardstate *gigaset_get_cs_by_tty(struct tty_struct *tty) |
1053 | { | 1052 | { |
1054 | if (tty->index < 0 || tty->index >= tty->driver->num) | ||
1055 | return NULL; | ||
1056 | return gigaset_get_cs_by_minor(tty->index + tty->driver->minor_start); | 1053 | return gigaset_get_cs_by_minor(tty->index + tty->driver->minor_start); |
1057 | } | 1054 | } |
1058 | 1055 | ||