Messages in this thread | | | Date | Wed, 24 Nov 1999 16:40:25 -0500 | From | "Theodore Y. Ts'o" <> | Subject | Re: TTY Flip buffers |
| |
Date: Wed, 24 Nov 1999 12:12:48 -0800 (PST) From: Linux Lists <lists@cyclades.com>
Just one question: I looked at n_tty_receive_buf and I didn't see any protection / warn back mechanism (the function is void) as to "what if the room in the TTY buffer is too small to store all the data passed directly by the driver". What happens if the driver passes a data amount that's bigger than the available room in the TTY buffer??
The line discpline is responsible to calling the driver's throttle()/unthrottle() as the space in the tty buffer goes above and below the high and low watermarks; this is how hardware (and software) flow control is handled.
Linux gives plenty of time (something like 768 characters, if I remember correctly) for the sending device to stop sending characters; if the sending device ignores the flow control, the tty layer does the only thing it can do --- it drops the data on the floor.
- Ted
- 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/
| |