]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/char/epca.c
mxser: Switch to kref tty
[linux-2.6-omap-h63xx.git] / drivers / char / epca.c
index 9d9ae1ca2925b825a526b093011c88d3a66ffa53..4998b2761e8f6e891b1595a686f1e29f948e9fcc 100644 (file)
@@ -186,7 +186,6 @@ static void pc_throttle(struct tty_struct *tty);
 static void pc_unthrottle(struct tty_struct *tty);
 static int pc_send_break(struct tty_struct *tty, int msec);
 static void setup_empty_event(struct tty_struct *tty, struct channel *ch);
-static void epca_setup(char *, int *);
 
 static int pc_write(struct tty_struct *, const unsigned char *, int);
 static int pc_init(void);
@@ -1377,6 +1376,7 @@ static void post_fep_init(unsigned int crd)
                unsigned long flags;
                u16 tseg, rseg;
 
+               tty_port_init(&ch->port);
                ch->brdchan = bc;
                ch->mailbox = gd;
                INIT_WORK(&ch->tqueue, do_softint);
@@ -1511,10 +1511,6 @@ static void post_fep_init(unsigned int crd)
                ch->fepstopca = 0;
 
                ch->close_delay = 50;
-               ch->port.count = 0;
-               ch->port.blocked_open = 0;
-               init_waitqueue_head(&ch->port.open_wait);
-               init_waitqueue_head(&ch->port.close_wait);
 
                spin_unlock_irqrestore(&epca_lock, flags);
        }
@@ -2513,7 +2509,8 @@ static void setup_empty_event(struct tty_struct *tty, struct channel *ch)
        memoff(ch);
 }
 
-static void epca_setup(char *str, int *ints)
+#ifndef MODULE
+static void __init epca_setup(char *str, int *ints)
 {
        struct board_info board;
        int               index, loop, last;
@@ -2767,6 +2764,17 @@ static void epca_setup(char *str, int *ints)
        num_cards++;
 }
 
+static int __init epca_real_setup(char *str)
+{
+       int ints[11];
+
+       epca_setup(get_options(str, 11, ints), ints);
+       return 1;
+}
+
+__setup("digiepca", epca_real_setup);
+#endif
+
 enum epic_board_types {
        brd_xr = 0,
        brd_xem,