Re: TTY_FLIPBUF_SIZE too low causing dataloss on too fast serial lines?

Pavel Machek (pavel@atrey.karlin.mff.cuni.cz)
Fri, 28 May 1999 11:35:36 +0200


Hi!

> > One question though is how is your irda driver grabbing the characters?
> > Is it grabbing them all at interrupt time, or is it polling like many of
> > the high-speed intelligent serial boards? If it's polling, you *don't*
> > to use the flip buffers; instead, just throw it onto a local buffer and
> > just call the line discpline directly. (See the Rocketport driver for
> > an example of this). Remember, you don't *have* to use the flip buffer
> > abstraction; it's a service which the tty layer provides to reduce the
> > amount of time spent in the interrupt driver, but you can bypass it if
> > you wish.
>
> Question: Since tty_flip_buffer_push just shoves the request onto tq_timer,
> is it valid to use a private tty_flip_buffer_push that checks if the buffer
> is looking close to full and pushes it onto tq_immed then marks that queue
> to be run on the irq return (remembering we have no fast irq paths in 2.2
> any more)
>
> In fact, couldnt tty_flip_buffer_push do this ?

Well, I've seen the problem on receive side, not on send side. It
would be more like tty_schedule_flip looking for buffer being nearly
full and trying to que into immediate in such case.

BUT: when I wrote

my_schedule_flip(...)
{
queue_task(&tty->flip.tqueue, &tq_immediate);
mark_bh(IMMEDIATE_BH)
}

and used that instead of tty_schedule_flip, it did not seem to
help. (Am I doing something wrong?)
Pavel

-- 
The best software in life is free (not shareware)!		Pavel
GCM d? s-: !g p?:+ au- a--@ w+ v- C++@ UL+++ L++ N++ E++ W--- M- Y- R+

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/