diff options
Diffstat (limited to 'drivers/isdn/gigaset/common.c')
-rw-r--r-- | drivers/isdn/gigaset/common.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/drivers/isdn/gigaset/common.c b/drivers/isdn/gigaset/common.c index d00acddd6213..68db361e766e 100644 --- a/drivers/isdn/gigaset/common.c +++ b/drivers/isdn/gigaset/common.c | |||
@@ -1037,16 +1037,8 @@ void gigaset_debugdrivers(void) | |||
1037 | } | 1037 | } |
1038 | spin_unlock_irqrestore(&driver_lock, flags); | 1038 | spin_unlock_irqrestore(&driver_lock, flags); |
1039 | } | 1039 | } |
1040 | EXPORT_SYMBOL_GPL(gigaset_debugdrivers); | ||
1041 | 1040 | ||
1042 | struct cardstate *gigaset_get_cs_by_tty(struct tty_struct *tty) | 1041 | static struct cardstate *gigaset_get_cs_by_minor(unsigned minor) |
1043 | { | ||
1044 | if (tty->index < 0 || tty->index >= tty->driver->num) | ||
1045 | return NULL; | ||
1046 | return gigaset_get_cs_by_minor(tty->index + tty->driver->minor_start); | ||
1047 | } | ||
1048 | |||
1049 | struct cardstate *gigaset_get_cs_by_minor(unsigned minor) | ||
1050 | { | 1042 | { |
1051 | unsigned long flags; | 1043 | unsigned long flags; |
1052 | static struct cardstate *ret = NULL; | 1044 | static struct cardstate *ret = NULL; |
@@ -1069,6 +1061,13 @@ struct cardstate *gigaset_get_cs_by_minor(unsigned minor) | |||
1069 | return ret; | 1061 | return ret; |
1070 | } | 1062 | } |
1071 | 1063 | ||
1064 | struct cardstate *gigaset_get_cs_by_tty(struct tty_struct *tty) | ||
1065 | { | ||
1066 | if (tty->index < 0 || tty->index >= tty->driver->num) | ||
1067 | return NULL; | ||
1068 | return gigaset_get_cs_by_minor(tty->index + tty->driver->minor_start); | ||
1069 | } | ||
1070 | |||
1072 | void gigaset_freedriver(struct gigaset_driver *drv) | 1071 | void gigaset_freedriver(struct gigaset_driver *drv) |
1073 | { | 1072 | { |
1074 | unsigned long flags; | 1073 | unsigned long flags; |