]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/um/drivers/chan_kern.c
[PATCH] convert i386 NUMA KVA space to bootmem
[linux-2.6-omap-h63xx.git] / arch / um / drivers / chan_kern.c
index cd13b91b9ff6a9702126282fb6e9dbc7fc0f9f90..7218c754505bf99a4a9a1888398d32d1b8aa849d 100644 (file)
@@ -186,9 +186,6 @@ static void tty_receive_char(struct tty_struct *tty, char ch)
                }
        }
 
-       if((tty->flip.flag_buf_ptr == NULL) ||
-          (tty->flip.char_buf_ptr == NULL))
-               return;
        tty_insert_flip_char(tty, ch, TTY_NORMAL);
 }
 
@@ -406,7 +403,7 @@ int chan_window_size(struct list_head *chans, unsigned short *rows_out,
        return 0;
 }
 
-void free_one_chan(struct chan *chan, int delay_free_irq)
+static void free_one_chan(struct chan *chan, int delay_free_irq)
 {
        list_del(&chan->list);
 
@@ -419,7 +416,7 @@ void free_one_chan(struct chan *chan, int delay_free_irq)
        kfree(chan);
 }
 
-void free_chan(struct list_head *chans, int delay_free_irq)
+static void free_chan(struct list_head *chans, int delay_free_irq)
 {
        struct list_head *ele, *next;
        struct chan *chan;
@@ -500,7 +497,7 @@ struct chan_type {
        struct chan_ops *ops;
 };
 
-struct chan_type chan_table[] = {
+static struct chan_type chan_table[] = {
        { "fd", &fd_ops },
 
 #ifdef CONFIG_NULL_CHAN
@@ -653,8 +650,7 @@ void chan_interrupt(struct list_head *chans, struct work_struct *task,
                chan = list_entry(ele, struct chan, list);
                if(!chan->input || (chan->ops->read == NULL)) continue;
                do {
-                       if((tty != NULL) &&
-                          (tty->flip.count >= TTY_FLIPBUF_SIZE)){
+                       if (tty && !tty_buffer_request_room(tty, 1)) {
                                schedule_delayed_work(task, 1);
                                goto out;
                        }